Skip to content

Commit

Permalink
Add some documentation about PAPI counters in cmake file
Browse files Browse the repository at this point in the history
  • Loading branch information
nilsdeppe committed Dec 8, 2018
1 parent 79946ea commit 48fb895
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions cmake/SetupCharmProjections.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,19 @@ endfunction()

if (PROJECTIONS)
set(
CMAKE_CXX_LINK_FLAGS
"${CMAKE_CXX_LINK_FLAGS} -tracemode projections -tracemode summary"
)
CMAKE_CXX_LINK_FLAGS
"${CMAKE_CXX_LINK_FLAGS} -tracemode projections -tracemode summary"
)
# Sets the macro `SPECTRE_PAPI_COUNTERS` to a list of user-specfied PAPI
# counters (obtained from running `papi_avail`). The counters could be used
# in conjunction with Charm++'s user stats tracing facilities. However,
# care must be taken if/when this is implemented to not assume that an
# Action will start and end without any Actions being run in the middle.
# Because we sometimes elide calls to the Charm++ RTS when invoking
# Actions, an Action on a local component element could be executed as part
# of the current component element's execution. The PAPI counter stats
# must be kept separate for these two Actions in order for them to be
# meaningful.
if (PROJECTIONS_PAPI_COUNTERS)
check_charm_version_for_stat_tracing()

Expand Down Expand Up @@ -66,6 +76,8 @@ if (PROJECTIONS)
)
include(SetupPapi)
endif()
# Defines the macro SPECTRE_PROJECTIONS_USER_STATS if gathering user
# specified stats is supported by the Charm++ version.
if(PROJECTIONS_USER_STATS)
CHECK_CHARM_VERSION_FOR_STAT_TRACING()
add_definitions(-DSPECTRE_PROJECTIONS_USER_STATS)
Expand Down

0 comments on commit 48fb895

Please sign in to comment.