Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion cmake/FindVerilator.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ if (VERILATOR_FOUND)
return()
endif()

cmake_policy(SET CMP0144 OLD)

find_package(PackageHandleStandardArgs REQUIRED)

include(SystemCPackage)
Expand All @@ -35,7 +37,7 @@ if(EXISTS ${CMAKE_BINARY_DIR}/conanbuildinfo.cmake)
endif()
find_program(VERILATOR_EXECUTABLE
NAMES verilator verilator_bin verilator_bin_dbg
HINTS ${CONAN_VERILATOR_ROOT} ENV VERILATOR_ROOT
HINTS ${VERILATOR_ROOT} ENV VERILATOR_ROOT
PATH_SUFFIXES bin
REQUIRED
DOC "Path to the Verilator executable"
Expand Down
8 changes: 1 addition & 7 deletions cmake/clang-format.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,5 @@ add_custom_target(${FORMAT_TARGET_NAME}

add_custom_target(${FORMAT_TARGET_NAME}-check
COMMENT "Checking clang-format changes"
# Use ! to negate the result for correct output
COMMAND !
${CLANG_FORMAT_BIN}
-style=file
-output-replacements-xml
${ALL_SOURCE_FILES}
| grep -q "replacement offset"
COMMAND ${CLANG_FORMAT_BIN} -style=file --dry-run -Werror ${ALL_SOURCE_FILES}
)
2 changes: 1 addition & 1 deletion src/common/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ target_include_directories(${PROJECT_NAME} PUBLIC
)
if( NOT MSVC)
# rigtorp/SPSCQueue.h uses std::hardware_destructive_interference_size which is HW dependend. GCC>14 warns about it
target_compile_options(${PROJECT_NAME} PUBLIC -Wno-interference-size)
target_compile_options(${PROJECT_NAME} PUBLIC $<$<COMPILE_LANGUAGE:CXX>:-Wno-interference-size>)
endif()
if(TARGET lz4::lz4)
target_link_libraries(${PROJECT_NAME} PUBLIC lz4::lz4)
Expand Down
2 changes: 1 addition & 1 deletion src/common/util/delegate.h
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ template <class R, class... A> class delegate<R(A...)> {
using deleter_type = void (*)(void*);

void* object_ptr_{nullptr};
stub_ptr_type stub_ptr_{};
stub_ptr_type stub_ptr_{nullptr};

deleter_type deleter_{};

Expand Down
2 changes: 1 addition & 1 deletion src/interfaces/obi/pin/target.h
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ target<DATA_WIDTH, ADDR_WIDTH, ID_WIDTH, USER_WIDTH>::target::nb_transport_bw(pa

template <unsigned int DATA_WIDTH, unsigned int ADDR_WIDTH, unsigned int ID_WIDTH, unsigned int USER_WIDTH>
inline void target<DATA_WIDTH, ADDR_WIDTH, ID_WIDTH, USER_WIDTH>::achannel_req_t() {
wait(SC_ZERO_TIME);
wait(sc_core::SC_ZERO_TIME);
wait(clk_i.posedge_event());
while(true) {
while(resetn_i.read() == false)
Expand Down
20 changes: 12 additions & 8 deletions src/sysc/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ find_package(ZLIB)

option(ENABLE_SQLITE "Enable SQLite backend for SCV" ON)
option(ENABLE_PYTHON4SC "Enable Python interpreter integration" OFF)
option(DISABLE_QKD_WARNING "Disbale the warning about multi-threaded quantum keeper when using SystemC 2.3.4" OFF)

if (MSVC)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /bigobj")
Expand Down Expand Up @@ -89,6 +90,9 @@ endif()

add_library(${PROJECT_NAME} ${LIB_SOURCES})
add_library(scc::${PROJECT_NAME} ALIAS ${PROJECT_NAME})
if(DISABLE_QKD_WARNING)
target_compile_definitions(${PROJECT_NAME} PUBLIC NO_MTQK)
endif()
if(FULL_TRACE_TYPE_LIST)
target_compile_definitions(${PROJECT_NAME} PRIVATE FULL_TRACE_TYPE_LIST)
endif()
Expand All @@ -107,11 +111,11 @@ if(ENABLE_PYTHON4SC)
target_compile_options(${PROJECT_NAME} PRIVATE -fvisibility=hidden)
target_link_libraries(${PROJECT_NAME} PUBLIC pybind11::embed) #pybind11::headers)
endif()
#if(TARGET fmt::fmt-header-only)
# target_link_libraries(${PROJECT_NAME} PRIVATE fmt::fmt-header-only)
#else()
if(TARGET fmt::fmt-header-only)
target_link_libraries(${PROJECT_NAME} PRIVATE fmt::fmt-header-only)
else()
target_link_libraries(${PROJECT_NAME} PRIVATE fmt::fmt)
#endif()
endif()
if(TARGET spdlog::spdlog_header_only)
target_link_libraries(${PROJECT_NAME} PRIVATE spdlog::spdlog_header_only)
else()
Expand Down Expand Up @@ -188,11 +192,11 @@ if(TARGET lz4::lz4)
target_link_libraries(${PROJECT_NAME} PRIVATE lz4::lz4)
endif()
target_compile_definitions(${PROJECT_NAME} PUBLIC FMT_SHARED)
#if(${CMAKE_SYSTEM_NAME} STREQUAL "Linux" AND TARGET fmt::fmt-header-only)
# target_link_libraries(${PROJECT_NAME} PUBLIC fmt::fmt-header-only)
#else()
if(TARGET fmt::fmt-header-only)
target_link_libraries(${PROJECT_NAME} PUBLIC fmt::fmt-header-only)
else()
target_link_libraries(${PROJECT_NAME} PUBLIC fmt::fmt)
#endif()
endif()
target_link_libraries(${PROJECT_NAME} PUBLIC fstapi Threads::Threads ${CMAKE_DL_LIBS})

if(CLANG_TIDY_EXE)
Expand Down
2 changes: 2 additions & 0 deletions src/sysc/tlm/scc/quantum_keeper.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@

#include "quantum_keeper_st.h"
#if SC_VERSION_MAJOR < 3
#ifndef NO_MTQK
#warning "Multithreaded quantum keeper is only supported with SystemC 3.0 and newer"
#endif
namespace tlm {
namespace scc {
using quantumkeeper_mt = quantumkeeper_st;
Expand Down