Skip to content

Commit

Permalink
Create function and data sections
Browse files Browse the repository at this point in the history
  • Loading branch information
Xeratec committed Dec 19, 2024
1 parent 94c6e22 commit 9735a5f
Show file tree
Hide file tree
Showing 5 changed files with 49 additions and 0 deletions.
4 changes: 4 additions & 0 deletions targets/chimera-convolve/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ target_include_directories(runtime_host
target_compile_options(runtime_host
PRIVATE
-O2
-ffunction-sections
-fdata-sections
)

target_compile_options(runtime_host
Expand Down Expand Up @@ -70,6 +72,8 @@ target_include_directories(runtime_cluster_snitch
target_compile_options(runtime_cluster_snitch
PRIVATE
-O2
-ffunction-sections
-fdata-sections
)

target_compile_options(runtime_cluster_snitch
Expand Down
2 changes: 2 additions & 0 deletions targets/chimera-host/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ target_include_directories(runtime_host
target_compile_options(runtime_host
PRIVATE
-O2
-ffunction-sections
-fdata-sections
)

target_compile_options(runtime_host
Expand Down
4 changes: 4 additions & 0 deletions targets/chimera-open/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ target_include_directories(runtime_host
target_compile_options(runtime_host
PRIVATE
-O2
-ffunction-sections
-fdata-sections
)

target_compile_options(runtime_host
Expand Down Expand Up @@ -70,6 +72,8 @@ target_include_directories(runtime_cluster_snitch
target_compile_options(runtime_cluster_snitch
PRIVATE
-O2
-ffunction-sections
-fdata-sections
)

target_compile_options(runtime_cluster_snitch
Expand Down
16 changes: 16 additions & 0 deletions tests/chimera-host/host/returnZero/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,20 @@ add_chimera_test(
# WIESEP: Link the host to the test executable
target_link_libraries(${TEST_NAME} PUBLIC ${TEST_NAME}_host)

################################################################################
# Debugging Options #
################################################################################

target_compile_options(${TEST_NAME}_host
PUBLIC
-ffunction-sections
-fdata-sections
)

# target_link_options(${TEST_NAME}
# PUBLIC
# -Wl,--print-memory-usage
# -Wl,--print-gc-sections
# -Wl,--gc-sections
# )

23 changes: 23 additions & 0 deletions tests/chimera-open/snitchCluster/simpleOffload/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,26 @@ add_chimera_test(
target_link_libraries(${TEST_NAME} PUBLIC ${TEST_NAME}_host)
target_link_libraries(${TEST_NAME} PUBLIC ${TEST_NAME}_cluster)

################################################################################
# Debugging Options #
################################################################################

target_compile_options(${TEST_NAME}_host
PUBLIC
-ffunction-sections
-fdata-sections
)

target_compile_options(${TEST_NAME}_cluster
PUBLIC
-ffunction-sections
-fdata-sections
)

# target_link_options(${TEST_NAME}
# PUBLIC
# -Wl,--print-memory-usage
# -Wl,--print-gc-sections
# -Wl,--gc-sections
# )

0 comments on commit 9735a5f

Please sign in to comment.