xx PAPI

PAPI

Federico Cipolletta, Roland Haas

2020-07-01

Abstract

This thorn provides access to the PAPI library.

1 Using This Thorn Refer to the Cactus UserGuide, Sec. B2.2, in order to know how this thorn can be used in a compiled configuration and how to possibly linking another specific version, already installed steparately.

Note on possible ExternalLibraries’ location stripping

Each thorn contained in Cactus/arrangements/ExternalLibraries will automatically adopt the library version contained in the Cactus/arrangements/<library>/dist folder. In particular, the tarball in

Cactus/arrangements/<library>/dist is only used if either THORNxDIR is set to BUILD or is left empty and no

precompiled copy of the library is found. If another location is specified via the THORNxDIR variable in the <machine>.cfg file at compilation, then the Cactus/lib/sbin/strip-incdirs.sh script will automatically strip away (for safety reasons) the locations:

/include

/usr/include

/usr/local/include

from THORNxINCxDIRS which default to THORNxDIR/include. Therefore, if there is any need for using one already installed version of one external library, the aforementioned location should be avoided (e.g. indicating /home as the THORNxDIR will work with no problems if the required library is installed there) or should be carefully checked, in order to avoid unwanted stripping. The same stripping happens to THORNxLIBxDIRS in lib/sbin/strip-libdirs.sh with a larger list of directories:

/lib

/usr/lib

/usr/local/lib

/lib64

/usr/lib64

/usr/local/lib64

2 Parameters

11definexstatisticsxclocks 10Scope: privatex01  BOOLEAN

11Description: Define multiple clocks for each PAPI counter, providing min/max/avg/sdv

11                  10  x01  Default: no

11

11dgemmxn  10Scope: privatex01  INT

11Description: Matrix size; mem = 32 Nˆ2 bytes, cpu = 2 Nˆ3 flop

11 Range 10 x01 Default: 1000
111:*  10N=2000 requires 128 Mbyte and 16 Gflop; N=5000 requires 800 Mbyte and 250 Gflop

11

11eventsxdcache  10Scope: privatex01  STRING

11Description: PAPI events for data cache usage

11  Range  10  x01Default: PAPIxL1xDCA PAPIxL1xDCM PAPIxL2xDCA PAPIxL2xDCM PAPIxL3xDCA PAPIxL3xDCM

11                  10

11

11eventsxflops  10Scope: privatex01  STRING

11Description: PAPI events for flop/sec

11  Range  10  x01Default: PAPIxFPxOPS PAPIxDPxOPS PAPIxVECxDP PAPIxTOTxCYC PAPIxREFxCYC SIMDxFPx256:PACKEDxDOUBLE

11                  10

11

11eventsxicache  10Scope: privatex01  STRING

11Description: PAPI events for instruction cache usage

11  Range  10  x01Default: PAPIxL1xICA PAPIxL1xICM PAPIxL2xICA PAPIxL2xICM PAPIxL3xICA PAPIxL3xICM

11                  10

11

11eventsxipc  10Scope: privatex01  STRING

11Description: PAPI events for instructions/cycle

11  Range  10  x01Default: PAPIxTOTxCYC PAPIxTOTxINS PAPIxFPxINS PAPIxINTxINS

11                  10

11

11eventsxmemory  10Scope: privatex01  STRING

11Description: PAPI evens for memory accesses

11  Range  10  x01Default: PAPIxLDxINS PAPIxSRxINS PAPIxMEMxRCY PAPIxMEMxWCY

11                  10

11

11outxevery  10Scope: privatex01  INT

11Description: Output statistics every so many iterations

11 Range 10 x01 Default: (none)
11                  10after initial data and shutdown
111:*  10every so many iterations
11-1  10no statistics output

11

11perxthreadxstatistics10Scope: privatex01  BOOLEAN

11Description: Collect statistics per thread (instead of per process)

11                  10  x01  Default: yes

11

11usexmultiplexing 10Scope: privatex01  BOOLEAN

11Description: Use multiplexing to gather more, but less accurate information

11                  10  x01  Default: yes

11verbose  10Scope: privatex01  BOOLEAN

11Description: Output debug messages?

11                  10  x01  Default: no

11

3 Interfaces

General Implements: papi

4 Schedule This section lists all the variables which are assigned storage by thorn ExternalLibraries/PAPI. Storage can either last for the duration of the run (Always means that if this thorn is activated storage will be assigned, Conditional means that if this thorn is activated storage will be assigned for the duration of the run if some condition is met), or can be turned on for the duration of a schedule function.

Storage NONE

Scheduled Functions

CCTKxWRAGH x papixinit x initialise papi

11x11Language:11c
11 x 11Options: 11meta
11 x 11Type: 11function

11

CCTKxWRAGH x papixregisterxclock x set up cactus clock for papi x

11x11After: 11papixinit
11 x 11Language:11c
11 x 11Options: 11meta
11 x 11Type: 11function

11

CCTKxBASEGRID x papixdgemm x run a dgemm benchmark to test papi x

11x11Language:11c
11 x 11Options: 11meta
11 x 11Type: 11function

11

CCTKxANALYSIS x papixoutputxstatsxanalysis x output papi statistics x

11x11Language:11c
11 x 11Options: 11meta
11 x 11Type: 11function

11

CCTKxTERMINATE x papixoutputxstatsxterminate x output papi statistics x

11x11Language:11c
11 x 11Options: 11meta
11 x 11Type: 11function