From f611aaad3e08440037656b2557b66c2ae48a25d5 Mon Sep 17 00:00:00 2001 From: Eyck Jentzsch Date: Tue, 14 Jul 2026 22:12:15 -0700 Subject: [PATCH 1/4] changes build system tp skip interface and component moduels in build (cherry picked from commit abcedd74bd4c74e0f05246882a4d0af287f16b76) --- CMakeLists.txt | 18 +++++++++++++++--- third_party/CMakeLists.txt | 6 ++++-- 2 files changed, 19 insertions(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 5fedd0e63..3d5f7529e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -16,6 +16,8 @@ set(SCC_ARCHIVE_DIR_MODIFIER "" CACHE STRING "additional directory levels to sto set(SCC_LIBRARY_DIR_MODIFIER "" CACHE STRING "additional directory levels to store libraries") option(WITH_SCP4SCC "adds SCP compatibility layer for SCC, cannot be used together with a copy of SCP" OFF) option(ENABLE_CLANG_FORMAT "Enable clang-format targets" OFF) +option(WITHOUT_SCC_COMONENTS "Do not build scc components nodule" OFF) +option(WITHOUT_SCC_INTERFACES "Do not build scc components nodule" OFF) include(Common) @@ -137,8 +139,12 @@ add_subdirectory(src/common) if(SystemC_FOUND) enable_testing() - add_subdirectory(src/interfaces) - add_subdirectory(src/components) + if(NOT WITHOUT_SCC_INTERFACES) + add_subdirectory(src/interfaces) + endif() + if(NOT WITHOUT_SCC_COMPONENTS) + add_subdirectory(src/components) + endif() add_subdirectory(src/sysc) add_subdirectory(third_party) if(NOT BUILD_SCC_LIB_ONLY AND NOT (USE_NCSC_SYSTEMC OR USE_NCSC_SYSTEMC3)) @@ -172,7 +178,13 @@ if(SystemC_FOUND) target_include_directories(scc INTERFACE ${Boost_INCLUDE_DIRS}) target_link_libraries(scc INTERFACE ${Boost_datetime_LIBRARY}) endif() - target_link_libraries(scc INTERFACE scc-util scc-sysc components interfaces scv-tr) + target_link_libraries(scc INTERFACE scc-util scc-sysc scv-tr) + if(NOT WITHOUT_SCC_COMPONENTS) + target_link_libraries(scc INTERFACE components) + endif() + if(NOT WITHOUT_SCC_INTERFACES) + target_link_libraries(scc INTERFACE interfaces) + endif() set_target_properties(scc PROPERTIES PUBLIC_HEADER ${CMAKE_CURRENT_SOURCE_DIR}/src/scc.h ) diff --git a/third_party/CMakeLists.txt b/third_party/CMakeLists.txt index a01d7dc8a..59b477647 100644 --- a/third_party/CMakeLists.txt +++ b/third_party/CMakeLists.txt @@ -7,8 +7,6 @@ endif() ############################################################################### if(SystemC_FOUND) option(USE_CCI_100 "" OFF) - add_subdirectory(axi_chi) - add_subdirectory(scv-tr) if(NOT TARGET systemc-cci::systemc-cci AND NOT TARGET SystemC::cci) if(USE_CCI_100) add_subdirectory(cci-1.0.0) @@ -16,9 +14,13 @@ if(SystemC_FOUND) add_subdirectory(cci-1.0.1) endif() endif() + add_subdirectory(scv-tr) add_subdirectory(lwtr4sc/src) # add_subdirectory(lwtr4sc/example) if(WITH_SCP4SCC) add_subdirectory(scp4scc) endif() + if(NOT WITHOUT_SCC_INTERFACES) + add_subdirectory(axi_chi) + endif() endif() \ No newline at end of file From 8a4a603e9f476b8ce708859433bf0e133550a57d Mon Sep 17 00:00:00 2001 From: Aida SIDIBE Date: Thu, 16 Jul 2026 16:43:32 +0200 Subject: [PATCH 2/4] Resolving errors of catching polymorphic exceptions by value --- src/sysc/scc/report.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/sysc/scc/report.cpp b/src/sysc/scc/report.cpp index 23b0f2522..c25493d6d 100644 --- a/src/sysc/scc/report.cpp +++ b/src/sysc/scc/report.cpp @@ -281,7 +281,7 @@ void report_handler(const sc_report& rep, const sc_actions& actions) { if((actions & SC_DISPLAY) && (!log_cfg.file_logger || rep.get_verbosity() < SC_HIGH)) try { log2logger(*log_cfg.console_logger, rep, log_cfg); - } catch(spdlog::spdlog_ex e) { + } catch(const spdlog::spdlog_ex& e) { } if((actions & SC_LOG) && log_cfg.file_logger) { scc::LogConfig lcfg(log_cfg); @@ -294,7 +294,7 @@ void report_handler(const sc_report& rep, const sc_actions& actions) { if(actions & SC_STOP) { try { flush_loggers(); - } catch(spdlog::spdlog_ex e) { + } catch(const spdlog::spdlog_ex& e) { } #if SYSTEMC_VERSION < 20241015 static const int stop_expr = sc_core::SC_START_OF_SIMULATION | SC_RUNNING | SC_PAUSED; @@ -309,7 +309,7 @@ void report_handler(const sc_report& rep, const sc_actions& actions) { if(actions & SC_ABORT) { try { flush_loggers(); - } catch(spdlog::spdlog_ex e) { + } catch(const spdlog::spdlog_ex& e) { } spdlog::shutdown(); abort(); @@ -317,14 +317,14 @@ void report_handler(const sc_report& rep, const sc_actions& actions) { if(actions & SC_THROW) { try { flush_loggers(); - } catch(spdlog::spdlog_ex e) { + } catch(const spdlog::spdlog_ex& e) { } throw rep; } if(sc_time_stamp().value() && !sc_is_running()) { try { flush_loggers(); - } catch(spdlog::spdlog_ex e) { + } catch(const spdlog::spdlog_ex& e) { } } } From 9fff7101bb2966dc3b20b6ce7c9bdee9e4a05649 Mon Sep 17 00:00:00 2001 From: Eyck Jentzsch Date: Mon, 20 Jul 2026 11:56:06 -0700 Subject: [PATCH 3/4] disables tcp4tlm test --- tests/tcp4tlm_bridge/CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/tcp4tlm_bridge/CMakeLists.txt b/tests/tcp4tlm_bridge/CMakeLists.txt index 13768f7df..d35d7716c 100644 --- a/tests/tcp4tlm_bridge/CMakeLists.txt +++ b/tests/tcp4tlm_bridge/CMakeLists.txt @@ -56,5 +56,5 @@ grep -q "FINISHED" "${log0}" grep -q "FINISHED" "${log1}" ]=]) -add_test(NAME tcp4tlm_bridge_peer_ctest COMMAND bash ${CMAKE_CURRENT_BINARY_DIR}/run_tcp4tlm_bridge_ctest.sh $) -set_tests_properties(tcp4tlm_bridge_peer_ctest PROPERTIES TIMEOUT 60) +#add_test(NAME tcp4tlm_bridge_peer_ctest COMMAND bash ${CMAKE_CURRENT_BINARY_DIR}/run_tcp4tlm_bridge_ctest.sh $) +#set_tests_properties(tcp4tlm_bridge_peer_ctest PROPERTIES TIMEOUT 60) From 6775684b4d02b6834a2e4e8fa0ba84fad8e9cd1f Mon Sep 17 00:00:00 2001 From: Eyck Jentzsch Date: Mon, 20 Jul 2026 23:23:35 -0700 Subject: [PATCH 4/4] fixes C++11 backward compatibility --- src/sysc/scc/sc_variable.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/sysc/scc/sc_variable.h b/src/sysc/scc/sc_variable.h index c6f056bae..61d82af9b 100644 --- a/src/sysc/scc/sc_variable.h +++ b/src/sysc/scc/sc_variable.h @@ -19,6 +19,7 @@ #include "observer.h" #include "report.h" +#include "utilities.h" #include #include #include @@ -398,7 +399,7 @@ template struct sc_variable_vector { for(size_t i = old_size; i < sz; ++i) { std::stringstream ss; ss << name << "(" << i << ")"; - values[i] = std::make_unique>(ss.str().c_str(), def_val); + values[i] = scc::make_unique>(ss.str().c_str(), def_val); } }