Compare commits
5 Commits
32e4aa83b8
...
hotfix/lat
Author | SHA1 | Date | |
---|---|---|---|
66dc28c239 | |||
40470445f4 | |||
ea3ff3c0cd | |||
c941890901 | |||
b7c0fb2b1c |
@ -52,7 +52,7 @@ endif()
|
|||||||
add_library(riscv SHARED ${LIB_SOURCES})
|
add_library(riscv SHARED ${LIB_SOURCES})
|
||||||
target_compile_options(riscv PRIVATE -Wno-shift-count-overflow)
|
target_compile_options(riscv PRIVATE -Wno-shift-count-overflow)
|
||||||
target_include_directories(riscv PUBLIC incl ../external/elfio)
|
target_include_directories(riscv PUBLIC incl ../external/elfio)
|
||||||
target_link_libraries(riscv PUBLIC softfloat scc-util)
|
target_link_libraries(riscv PUBLIC softfloat scc-util jsoncpp)
|
||||||
target_link_libraries(riscv PUBLIC -Wl,--whole-archive dbt-core -Wl,--no-whole-archive)
|
target_link_libraries(riscv PUBLIC -Wl,--whole-archive dbt-core -Wl,--no-whole-archive)
|
||||||
set_target_properties(riscv PROPERTIES
|
set_target_properties(riscv PROPERTIES
|
||||||
VERSION ${PROJECT_VERSION}
|
VERSION ${PROJECT_VERSION}
|
||||||
@ -120,4 +120,4 @@ install(TARGETS riscv riscv-sim
|
|||||||
# CMAKE PACKAGING (for other CMake projects to use this one easily)
|
# CMAKE PACKAGING (for other CMake projects to use this one easily)
|
||||||
# _____________________________________________________________________________
|
# _____________________________________________________________________________
|
||||||
|
|
||||||
#include(PackageConfigurator)
|
#include(PackageConfigurator)
|
||||||
|
@ -302,7 +302,7 @@ public:
|
|||||||
|
|
||||||
void write_mstatus(T val) {
|
void write_mstatus(T val) {
|
||||||
auto mask = get_mask();
|
auto mask = get_mask();
|
||||||
auto new_val = (mstatus.st.value & ~mask) | (val & mask);
|
auto new_val = (mstatus.backing.val & ~mask) | (val & mask);
|
||||||
mstatus = new_val;
|
mstatus = new_val;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -33,10 +33,10 @@
|
|||||||
#ifndef _SYSC_SIFIVE_FE310_H_
|
#ifndef _SYSC_SIFIVE_FE310_H_
|
||||||
#define _SYSC_SIFIVE_FE310_H_
|
#define _SYSC_SIFIVE_FE310_H_
|
||||||
|
|
||||||
#include "scc/initiator_mixin.h"
|
#include <tlm/scc/scv/tlm_rec_initiator_socket.h>
|
||||||
|
#include "tlm/scc/initiator_mixin.h"
|
||||||
#include "scc/traceable.h"
|
#include "scc/traceable.h"
|
||||||
#include "scc/utilities.h"
|
#include "scc/utilities.h"
|
||||||
#include "scv4tlm/tlm_rec_initiator_socket.h"
|
|
||||||
#include <cci_configuration>
|
#include <cci_configuration>
|
||||||
#include <tlm>
|
#include <tlm>
|
||||||
#include <tlm_core/tlm_1/tlm_req_rsp/tlm_1_interfaces/tlm_core_ifs.h>
|
#include <tlm_core/tlm_1/tlm_req_rsp/tlm_1_interfaces/tlm_core_ifs.h>
|
||||||
@ -75,7 +75,7 @@ class core_wrapper;
|
|||||||
|
|
||||||
class core_complex : public sc_core::sc_module, public scc::traceable {
|
class core_complex : public sc_core::sc_module, public scc::traceable {
|
||||||
public:
|
public:
|
||||||
scc::initiator_mixin<scv4tlm::tlm_rec_initiator_socket<32>> initiator{"intor"};
|
tlm::scc::initiator_mixin<tlm::scc::scv::tlm_rec_initiator_socket<32>> initiator{"intor"};
|
||||||
|
|
||||||
sc_core::sc_in<sc_core::sc_time> clk_i{"clk_i"};
|
sc_core::sc_in<sc_core::sc_time> clk_i{"clk_i"};
|
||||||
|
|
||||||
|
@ -331,7 +331,7 @@ void core_complex::disass_output(uint64_t pc, const std::string instr_str) {
|
|||||||
tr_handle.record_attribute("PC", pc);
|
tr_handle.record_attribute("PC", pc);
|
||||||
tr_handle.record_attribute("INSTR", instr_str);
|
tr_handle.record_attribute("INSTR", instr_str);
|
||||||
tr_handle.record_attribute("MODE", lvl[cpu->get_mode()]);
|
tr_handle.record_attribute("MODE", lvl[cpu->get_mode()]);
|
||||||
tr_handle.record_attribute("MSTATUS", cpu->get_state().mstatus.st.value);
|
tr_handle.record_attribute("MSTATUS", cpu->get_state().mstatus.backing.val);
|
||||||
tr_handle.record_attribute("LTIME_START", quantum_keeper.get_current_time().value() / 1000);
|
tr_handle.record_attribute("LTIME_START", quantum_keeper.get_current_time().value() / 1000);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
@ -388,7 +388,7 @@ bool core_complex::read_mem(uint64_t addr, unsigned length, uint8_t *const data,
|
|||||||
if (is_fetch && tr_handle.is_active()) {
|
if (is_fetch && tr_handle.is_active()) {
|
||||||
tr_handle.end_transaction();
|
tr_handle.end_transaction();
|
||||||
}
|
}
|
||||||
auto preExt = new scv4tlm::tlm_recording_extension(tr_handle, this);
|
auto preExt = new tlm::scc::scv4tlm::tlm_recording_extension(tr_handle, this);
|
||||||
gp.set_extension(preExt);
|
gp.set_extension(preExt);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@ -434,7 +434,7 @@ bool core_complex::write_mem(uint64_t addr, unsigned length, const uint8_t *cons
|
|||||||
sc_time delay{quantum_keeper.get_local_time()};
|
sc_time delay{quantum_keeper.get_local_time()};
|
||||||
#ifdef WITH_SCV
|
#ifdef WITH_SCV
|
||||||
if (m_db != nullptr && tr_handle.is_valid()) {
|
if (m_db != nullptr && tr_handle.is_valid()) {
|
||||||
auto preExt = new scv4tlm::tlm_recording_extension(tr_handle, this);
|
auto preExt = new tlm::scc::scv4tlm::tlm_recording_extension(tr_handle, this);
|
||||||
gp.set_extension(preExt);
|
gp.set_extension(preExt);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
Reference in New Issue
Block a user