Rebase to official papi-7.0.0.
This commit is contained in:
parent
29cf6d80ba
commit
a3381efaf2
1
.gitignore
vendored
1
.gitignore
vendored
@ -24,3 +24,4 @@ papi-4.1.0.tar.gz
|
||||
/papi-5.6.0.tar.gz
|
||||
/papi-5.7.0.tar.gz
|
||||
/papi-6.0.0.tar.gz
|
||||
/papi-7.0.0.tar.gz
|
||||
|
@ -1,34 +0,0 @@
|
||||
commit 9a44d82928ed17ba2ff21eb88b89c5829d0ea30e
|
||||
Author: Steve Kaufmann <steven.kaufmann@hpe.com>
|
||||
Date: Wed Jun 24 14:08:08 2020 -0400
|
||||
|
||||
Added PAPI preset support for Fujitsu A64FX.
|
||||
|
||||
Signed-off-by: Heike Jagode <jagode@icl.utk.edu>
|
||||
|
||||
diff --git a/src/papi_events.csv b/src/papi_events.csv
|
||||
index 8e96adfbd..1b5c15542 100644
|
||||
--- a/src/papi_events.csv
|
||||
+++ b/src/papi_events.csv
|
||||
@@ -1877,6 +1877,21 @@ PRESET,PAPI_L2_DCR,NOT_DERIVED,L2D_CACHE_RD
|
||||
PRESET,PAPI_L2_DCW,NOT_DERIVED,L2D_CACHE_WR
|
||||
PRESET,PAPI_L2_LDM,NOT_DERIVED,L2D_CACHE_REFILL_RD
|
||||
|
||||
+#########################
|
||||
+# ARM Fujitsu A64FX #
|
||||
+#########################
|
||||
+CPU,arm_a64fx
|
||||
+#
|
||||
+PRESET,PAPI_TOT_INS,NOT_DERIVED,INST_RETIRED
|
||||
+PRESET,PAPI_TOT_CYC,NOT_DERIVED,CPU_CYCLES
|
||||
+PRESET,PAPI_FP_INS,NOT_DERIVED,VFP_SPEC
|
||||
+PRESET,PAPI_VEC_INS,NOT_DERIVED,ASE_SPEC
|
||||
+PRESET,PAPI_L1_DCM,NOT_DERIVED,L1D_CACHE_REFILL
|
||||
+PRESET,PAPI_L1_ICA,NOT_DERIVED,L1I_CACHE
|
||||
+PRESET,PAPI_L1_ICM,NOT_DERIVED,L1I_CACHE_REFILL
|
||||
+PRESET,PAPI_L2_DCH,NOT_DERIVED,L2D_CACHE
|
||||
+PRESET,PAPI_L2_DCM,NOT_DERIVED,L2D_CACHE_REFILL
|
||||
+
|
||||
#
|
||||
CPU,mips_74k
|
||||
#
|
@ -1,348 +0,0 @@
|
||||
commit 38290c41abbb105ca198411ec3c466ac027f5b8f
|
||||
Author: Frank Winkler <frankbook@Franks-MacBook-Air.local>
|
||||
Date: Fri Apr 24 16:18:22 2020 +0200
|
||||
|
||||
Fixed configure options for shared and static builds.
|
||||
|
||||
1) --with-static-lib=no (force PAPI to build shared libraries and tools)
|
||||
2) --with-shlib-tools (use internal libpfm via rpath-link)
|
||||
|
||||
diff --git a/src/configure.in b/src/configure.in
|
||||
index 3cf47edc1..1f58f7c8e 100644
|
||||
--- a/src/configure.in
|
||||
+++ b/src/configure.in
|
||||
@@ -200,9 +200,13 @@ else
|
||||
AC_MSG_ERROR([cannot find dlopen and dlerror symbols neither in the base system libraries nor in -ldl])
|
||||
fi
|
||||
fi
|
||||
+
|
||||
+# Disable LDL for static builds
|
||||
+# if test "x${STATIC}" = "x"; then
|
||||
+# LDL=""
|
||||
+# fi
|
||||
AC_SUBST(LDL)
|
||||
-
|
||||
-
|
||||
+
|
||||
if test "$OS" = "CLE"; then
|
||||
virtualtimer=times
|
||||
tls=__thread
|
||||
@@ -827,10 +831,6 @@ AC_ARG_WITH(static_tools,
|
||||
AC_MSG_RESULT(yes)],
|
||||
[AC_MSG_RESULT(no)])
|
||||
|
||||
-if test "$static_lib" = "no"; then
|
||||
- AC_MSG_ERROR(Building tests and utilities static but no static papi library to be built)
|
||||
-fi
|
||||
-
|
||||
AC_MSG_CHECKING(for linking with papi shared library of tests and utilities)
|
||||
AC_ARG_WITH(shlib_tools,
|
||||
[ --with-shlib-tools Specify linking with papi library of tests and utilities],
|
||||
@@ -839,6 +839,14 @@ AC_ARG_WITH(shlib_tools,
|
||||
[shlib_tools=no
|
||||
AC_MSG_RESULT(no)])
|
||||
|
||||
+if test "$static_lib" = "no"; then
|
||||
+ shlib_tools=yes
|
||||
+fi
|
||||
+
|
||||
+if test "$static_lib" = "no" -a "$shlib_tools" = "no"; then
|
||||
+ AC_MSG_ERROR(Building tests and utilities static but no static papi library to be built)
|
||||
+fi
|
||||
+
|
||||
if test "$shlib_tools" = "yes"; then
|
||||
if test "$shared_lib" != "yes"; then
|
||||
AC_MSG_ERROR(Building static but specified shared linking for tests and utilities)
|
||||
@@ -847,6 +855,8 @@ if test "$shlib_tools" = "yes"; then
|
||||
AC_MSG_ERROR([Building shared but specified static linking])
|
||||
fi
|
||||
LINKLIB='$(SHLIB)'
|
||||
+ #WORKAROUND: if libpfm cannot be found at link time
|
||||
+ LDFLAGS="$LDFLAGS -Wl,-rpath-link,$PWD/libpfm4/lib"
|
||||
elif test "$shlib_tools" = "no"; then
|
||||
if test "$static_lib" != "yes"; then
|
||||
AC_MSG_ERROR([Building shared but specified static linking for tests and utilities])
|
||||
commit d6f4e34d083f18cfdba38dd5e4bbfb2a580b8a9e
|
||||
Author: Frank Winkler <frankbook@Franks-MacBook-Air.local>
|
||||
Date: Fri Apr 24 16:38:18 2020 +0200
|
||||
|
||||
Another test for "--with-static-tools".
|
||||
|
||||
diff --git a/src/configure.in b/src/configure.in
|
||||
index 1f58f7c8e..e8d769578 100644
|
||||
--- a/src/configure.in
|
||||
+++ b/src/configure.in
|
||||
@@ -201,10 +201,6 @@ else
|
||||
fi
|
||||
fi
|
||||
|
||||
-# Disable LDL for static builds
|
||||
-# if test "x${STATIC}" = "x"; then
|
||||
-# LDL=""
|
||||
-# fi
|
||||
AC_SUBST(LDL)
|
||||
|
||||
if test "$OS" = "CLE"; then
|
||||
@@ -831,6 +827,11 @@ AC_ARG_WITH(static_tools,
|
||||
AC_MSG_RESULT(yes)],
|
||||
[AC_MSG_RESULT(no)])
|
||||
|
||||
+# Disable LDL for static builds
|
||||
+# if test "$STATIC" = "-static"; then
|
||||
+# LDL=""
|
||||
+# fi
|
||||
+
|
||||
AC_MSG_CHECKING(for linking with papi shared library of tests and utilities)
|
||||
AC_ARG_WITH(shlib_tools,
|
||||
[ --with-shlib-tools Specify linking with papi library of tests and utilities],
|
||||
commit 1c333c9954b872cda1b4d873fa81b14ec58a58a7
|
||||
Author: Frank Winkler <frankbook@Franks-MacBook-Air.local>
|
||||
Date: Thu Apr 30 18:51:34 2020 +0200
|
||||
|
||||
Fixed static build.
|
||||
- SDE component is disabled
|
||||
- "ctest" shlib is disabled
|
||||
|
||||
diff --git a/src/configure.in b/src/configure.in
|
||||
index e8d769578..0eee98ea1 100644
|
||||
--- a/src/configure.in
|
||||
+++ b/src/configure.in
|
||||
@@ -827,10 +827,11 @@ AC_ARG_WITH(static_tools,
|
||||
AC_MSG_RESULT(yes)],
|
||||
[AC_MSG_RESULT(no)])
|
||||
|
||||
-# Disable LDL for static builds
|
||||
-# if test "$STATIC" = "-static"; then
|
||||
-# LDL=""
|
||||
-# fi
|
||||
+# Disable LDL AND SDE for static builds
|
||||
+if test "$STATIC" = "-static"; then
|
||||
+ LDL=""
|
||||
+ SDE_ENABLED=
|
||||
+fi
|
||||
|
||||
AC_MSG_CHECKING(for linking with papi shared library of tests and utilities)
|
||||
AC_ARG_WITH(shlib_tools,
|
||||
@@ -1768,6 +1769,7 @@ for comp in $components; do
|
||||
if test "x$comp" = "xsde" ; then
|
||||
LDFLAGS="$LDFLAGS $LRT"
|
||||
LIBS="$LIBS $LRT"
|
||||
+ SDE_ENABLED=1
|
||||
fi
|
||||
done
|
||||
|
||||
@@ -1862,6 +1864,7 @@ AC_SUBST(BGP_SYSDIR)
|
||||
AC_SUBST(BITFLAGS)
|
||||
AC_SUBST(COMPONENT_RULES)
|
||||
AC_SUBST(COMPONENTS)
|
||||
+AC_SUBST(SDE_ENABLED)
|
||||
AC_SUBST(FTEST_TARGETS)
|
||||
AC_SUBST(HAVE_NO_OVERRIDE_INIT)
|
||||
AC_SUBST(BGPM_INSTALL_DIR)
|
||||
diff --git a/src/ctests/Makefile.recipies b/src/ctests/Makefile.recipies
|
||||
index b7c1963d7..44e19b398 100644
|
||||
--- a/src/ctests/Makefile.recipies
|
||||
+++ b/src/ctests/Makefile.recipies
|
||||
@@ -11,7 +11,11 @@ MPX = max_multiplex multiplex1 multiplex2 mendes-alt sdsc-mpx sdsc2-mpx \
|
||||
MPXPTHR = multiplex1_pthreads multiplex3_pthreads kufrin
|
||||
MPI = mpi_hl mpi_omp_hl \
|
||||
mpifirst
|
||||
+
|
||||
+ifeq ($(STATIC),)
|
||||
SHARED = shlib
|
||||
+endif
|
||||
+
|
||||
SERIAL = serial_hl serial_hl_ll_comb\
|
||||
all_events all_native_events branches calibrate case1 case2 \
|
||||
cmpinfo code2name derived describe destroy disable_component \
|
||||
@@ -344,8 +348,10 @@ case2: case2.c $(TESTLIB) $(PAPILIB)
|
||||
low-level: low-level.c $(TESTLIB) $(DOLOOPS) $(PAPILIB)
|
||||
$(CC) $(INCLUDE) $(CFLAGS) $(TOPTFLAGS) low-level.c $(TESTLIB) $(DOLOOPS) $(PAPILIB) $(LDFLAGS) -o low-level
|
||||
|
||||
+ifeq ($(STATIC),)
|
||||
shlib: shlib.c $(TESTLIB) $(PAPILIB)
|
||||
$(CC) $(INCLUDE) $(CFLAGS) $(TOPTFLAGS) shlib.c $(TESTLIB) $(PAPILIB) $(LDFLAGS) -o shlib $(LDL)
|
||||
+endif
|
||||
|
||||
exeinfo: exeinfo.c $(TESTLIB) $(PAPILIB)
|
||||
-$(CC) $(INCLUDE) $(CFLAGS) $(TOPTFLAGS) exeinfo.c $(TESTLIB) $(PAPILIB) $(LDFLAGS) -o exeinfo
|
||||
diff --git a/src/ctests/Makefile.target.in b/src/ctests/Makefile.target.in
|
||||
index edc04f1b7..af64e157c 100644
|
||||
--- a/src/ctests/Makefile.target.in
|
||||
+++ b/src/ctests/Makefile.target.in
|
||||
@@ -10,6 +10,7 @@ INCLUDE = -I. -I@includedir@ -I$(testlibdir) -I$(validationlibdir)
|
||||
LIBDIR = @libdir@
|
||||
LIBRARY = @LIBRARY@
|
||||
SHLIB = @SHLIB@
|
||||
+STATIC = @STATIC@
|
||||
PAPILIB = ../@LINKLIB@
|
||||
TESTLIB = $(testlibdir)/libtestlib.a
|
||||
LDFLAGS = @LDFLAGS@ @LDL@ @STATIC@
|
||||
diff --git a/src/utils/Makefile b/src/utils/Makefile
|
||||
index 4abfd6cb8..64a2b8f9f 100644
|
||||
--- a/src/utils/Makefile
|
||||
+++ b/src/utils/Makefile
|
||||
@@ -48,8 +48,13 @@ papi_mem_info: papi_mem_info.o $(PAPILIB)
|
||||
papi_multiplex_cost: papi_multiplex_cost.o $(PAPILIB) cost_utils.o
|
||||
$(CC) -o papi_multiplex_cost papi_multiplex_cost.o cost_utils.o $(PAPILIB) -lm $(LDFLAGS)
|
||||
|
||||
+ifneq ($(SDE_ENABLED),)
|
||||
papi_native_avail: papi_native_avail.o $(PAPILIB) print_header.o papi_sde_interface.o
|
||||
$(CC) -o papi_native_avail papi_native_avail.o $(PAPILIB) print_header.o $(LDFLAGS) papi_sde_interface.o
|
||||
+else
|
||||
+papi_native_avail: papi_native_avail.o $(PAPILIB) print_header.o
|
||||
+ $(CC) -o papi_native_avail papi_native_avail.o $(PAPILIB) print_header.o $(LDFLAGS)
|
||||
+endif
|
||||
|
||||
papi_version: papi_version.o $(PAPILIB)
|
||||
$(CC) -o papi_version papi_version.o $(PAPILIB) $(LDFLAGS)
|
||||
@@ -65,8 +70,10 @@ cost_utils.o: ../testlib/papi_test.h cost_utils.c
|
||||
print_header.o: print_header.h print_header.c
|
||||
$(CC) $(INCLUDE) $(CFLAGS) $(OPTFLAGS) -c print_header.c
|
||||
|
||||
+ifneq ($(SDE_ENABLED),)
|
||||
papi_sde_interface.o: papi_sde_interface.c
|
||||
$(CC) $(INCLUDE) $(CFLAGS) $(OPTFLAGS) -c papi_sde_interface.c
|
||||
+endif
|
||||
|
||||
clean:
|
||||
rm -f *.o *.stderr *.stdout core *~ $(ALL)
|
||||
diff --git a/src/utils/Makefile.target.in b/src/utils/Makefile.target.in
|
||||
index bcdbe94e9..9c76b37af 100644
|
||||
--- a/src/utils/Makefile.target.in
|
||||
+++ b/src/utils/Makefile.target.in
|
||||
@@ -9,6 +9,7 @@ INCLUDE = -I. -I@includedir@ -I$(testlibdir)
|
||||
LIBDIR = @libdir@
|
||||
LIBRARY = @LIBRARY@
|
||||
SHLIB = @SHLIB@
|
||||
+SDE_ENABLED = @SDE_ENABLED@
|
||||
PAPILIB = ../@LINKLIB@
|
||||
TESTLIB = $(testlibdir)/libtestlib.a
|
||||
LDFLAGS = @LDFLAGS@ @LDL@ @STATIC@
|
||||
diff --git a/src/utils/papi_native_avail.c b/src/utils/papi_native_avail.c
|
||||
index ae6dbb9e5..902ed7996 100644
|
||||
--- a/src/utils/papi_native_avail.c
|
||||
+++ b/src/utils/papi_native_avail.c
|
||||
@@ -51,8 +51,9 @@
|
||||
|
||||
#include "papi.h"
|
||||
#include "print_header.h"
|
||||
+#ifdef SDE_ENABLED
|
||||
#include "components/sde/interface/papi_sde_interface.h"
|
||||
-
|
||||
+#endif
|
||||
#define EVT_LINE 80
|
||||
#define EVT_LINE_BUF_SIZE 4096
|
||||
|
||||
@@ -84,7 +85,9 @@ print_help( char **argv )
|
||||
printf( "\nGeneral command options:\n" );
|
||||
printf( "\t-h, --help print this help message\n" );
|
||||
printf( "\t-c, --check attempts to add each event\n");
|
||||
+#ifdef SDE_ENABLED
|
||||
printf( "\t-sde FILE lists SDEs that are registered by the library or executable in FILE\n" );
|
||||
+#endif
|
||||
printf( "\t-e EVENTNAME display detailed information about named native event\n" );
|
||||
printf( "\t-i EVENTSTR include only event names that contain EVENTSTR\n" );
|
||||
printf( "\t-x EVENTSTR exclude any event names that contain EVENTSTR\n" );
|
||||
@@ -368,6 +371,7 @@ parse_event_qualifiers( PAPI_event_info_t * info )
|
||||
return ( 1 );
|
||||
}
|
||||
|
||||
+#ifdef SDE_ENABLED
|
||||
void
|
||||
invoke_hook_fptr( char *lib_path )
|
||||
{
|
||||
@@ -394,6 +398,7 @@ invoke_hook_fptr( char *lib_path )
|
||||
dlclose(dl_handle);
|
||||
return;
|
||||
}
|
||||
+#endif
|
||||
|
||||
int
|
||||
main( int argc, char **argv )
|
||||
@@ -444,6 +449,7 @@ main( int argc, char **argv )
|
||||
return 2;
|
||||
}
|
||||
|
||||
+#ifdef SDE_ENABLED
|
||||
/*
|
||||
The following code will execute if the user wants to list the SDEs in the
|
||||
library (or executable) stored in flags.path. This code will not list the
|
||||
@@ -514,6 +520,7 @@ skip_lib:
|
||||
if( NULL != cmd ) free(cmd);
|
||||
}
|
||||
no_sdes:
|
||||
+#endif //SDE_ENABLED
|
||||
|
||||
/* Do this code if the event name option was specified on the commandline */
|
||||
if ( flags.named ) {
|
||||
commit b5111efaf1b234541c94b8ef7e5791bf8eb094b3
|
||||
Author: Frank Winkler <frankbook@franks-air.localdomain>
|
||||
Date: Thu May 7 09:00:53 2020 +0200
|
||||
|
||||
Added CFLAG -DSDE.
|
||||
|
||||
diff --git a/src/configure.in b/src/configure.in
|
||||
index 0eee98ea1..781148e5b 100644
|
||||
--- a/src/configure.in
|
||||
+++ b/src/configure.in
|
||||
@@ -1767,6 +1767,7 @@ tests="$tests comp_tests"
|
||||
# check for SDE component to determine if we need -lrt in LDFLAGS
|
||||
for comp in $components; do
|
||||
if test "x$comp" = "xsde" ; then
|
||||
+ CFLAGS="$CFLAGS -DSDE"
|
||||
LDFLAGS="$LDFLAGS $LRT"
|
||||
LIBS="$LIBS $LRT"
|
||||
SDE_ENABLED=1
|
||||
diff --git a/src/utils/papi_native_avail.c b/src/utils/papi_native_avail.c
|
||||
index 902ed7996..7d90c4064 100644
|
||||
--- a/src/utils/papi_native_avail.c
|
||||
+++ b/src/utils/papi_native_avail.c
|
||||
@@ -51,9 +51,10 @@
|
||||
|
||||
#include "papi.h"
|
||||
#include "print_header.h"
|
||||
-#ifdef SDE_ENABLED
|
||||
+#if SDE
|
||||
#include "components/sde/interface/papi_sde_interface.h"
|
||||
#endif
|
||||
+
|
||||
#define EVT_LINE 80
|
||||
#define EVT_LINE_BUF_SIZE 4096
|
||||
|
||||
@@ -85,7 +86,7 @@ print_help( char **argv )
|
||||
printf( "\nGeneral command options:\n" );
|
||||
printf( "\t-h, --help print this help message\n" );
|
||||
printf( "\t-c, --check attempts to add each event\n");
|
||||
-#ifdef SDE_ENABLED
|
||||
+#if SDE
|
||||
printf( "\t-sde FILE lists SDEs that are registered by the library or executable in FILE\n" );
|
||||
#endif
|
||||
printf( "\t-e EVENTNAME display detailed information about named native event\n" );
|
||||
@@ -371,7 +372,7 @@ parse_event_qualifiers( PAPI_event_info_t * info )
|
||||
return ( 1 );
|
||||
}
|
||||
|
||||
-#ifdef SDE_ENABLED
|
||||
+#if SDE
|
||||
void
|
||||
invoke_hook_fptr( char *lib_path )
|
||||
{
|
||||
@@ -449,7 +450,7 @@ main( int argc, char **argv )
|
||||
return 2;
|
||||
}
|
||||
|
||||
-#ifdef SDE_ENABLED
|
||||
+#if SDE
|
||||
/*
|
||||
The following code will execute if the user wants to list the SDEs in the
|
||||
library (or executable) stored in flags.path. This code will not list the
|
||||
@@ -520,7 +521,7 @@ skip_lib:
|
||||
if( NULL != cmd ) free(cmd);
|
||||
}
|
||||
no_sdes:
|
||||
-#endif //SDE_ENABLED
|
||||
+#endif //SDE
|
||||
|
||||
/* Do this code if the event name option was specified on the commandline */
|
||||
if ( flags.named ) {
|
@ -1,106 +0,0 @@
|
||||
commit 3625bdbad9fd57d1cdb1e5615854545167d4adcb
|
||||
Author: Anthony Castaldo <TonyCastaldo@icl.utk.edu>
|
||||
Date: Wed Aug 26 17:18:29 2020 -0400
|
||||
|
||||
This modifies PAPI_library_init() to initialize components in two classes,
|
||||
separated by the initialization of the papi thread structure. The first class
|
||||
is those that need no thread structure, currently everything but perf_event and
|
||||
perf_event_uncore. Following the init of the threading structure, we init the
|
||||
second class (perf_event and perf_event_uncore) that DOES need the thread
|
||||
structure to successfully init_component(). This required a change to
|
||||
_papi_hwi_init_global(), to add an argument to distinguish which class it
|
||||
should initialize.
|
||||
|
||||
diff --git a/src/papi.c b/src/papi.c
|
||||
index 33cc29935..ed75af493 100644
|
||||
--- a/src/papi.c
|
||||
+++ b/src/papi.c
|
||||
@@ -1151,7 +1151,23 @@ PAPI_library_init( int version )
|
||||
papi_return( init_retval );
|
||||
}
|
||||
|
||||
- /* Initialize thread globals, including the main threads */
|
||||
+ /* Initialize component globals EXCEPT for perf_event, perf_event_uncore.
|
||||
+ * To avoid race conditions, these components use the thread local storage
|
||||
+ * construct initialized by _papi_hwi_init_global_threads(), from within
|
||||
+ * their init_component(). So these must have init_component() run AFTER
|
||||
+ * _papi_hwi_init_global_threads. Other components demand that init threads
|
||||
+ * run AFTER init_component(), which sets up globals they need.
|
||||
+ */
|
||||
+
|
||||
+ tmp = _papi_hwi_init_global( 0 ); /* Selector 0 to skip perf_event, perf_event_uncore */
|
||||
+ if ( tmp ) {
|
||||
+ init_retval = tmp;
|
||||
+ _papi_hwi_shutdown_global_internal( );
|
||||
+ _in_papi_library_init_cnt--;
|
||||
+ papi_return( init_retval );
|
||||
+ }
|
||||
+
|
||||
+ /* Initialize thread globals, including the main threads */
|
||||
|
||||
tmp = _papi_hwi_init_global_threads( );
|
||||
if ( tmp ) {
|
||||
@@ -1161,9 +1177,9 @@ PAPI_library_init( int version )
|
||||
papi_return( init_retval );
|
||||
}
|
||||
|
||||
- /* Initialize component globals */
|
||||
+ /* Initialize perf_event, perf_event_uncore components */
|
||||
|
||||
- tmp = _papi_hwi_init_global( );
|
||||
+ tmp = _papi_hwi_init_global( 1 ); /* Selector 1 for only perf_event, perf_event_uncore */
|
||||
if ( tmp ) {
|
||||
init_retval = tmp;
|
||||
_papi_hwi_shutdown_global_internal( );
|
||||
diff --git a/src/papi_internal.c b/src/papi_internal.c
|
||||
index 5a1ccd433..e6dd319c2 100644
|
||||
--- a/src/papi_internal.c
|
||||
+++ b/src/papi_internal.c
|
||||
@@ -1928,11 +1928,13 @@ int papi_num_components = ( sizeof ( _papi_hwd ) / sizeof ( *_papi_hwd ) ) - 1;
|
||||
* Routine that initializes all available components.
|
||||
* A component is available if a pointer to its info vector
|
||||
* appears in the NULL terminated_papi_hwd table.
|
||||
+ * Modified to accept an arg: 0=do not init perf_event or
|
||||
+ * perf_event_uncore. 1=init ONLY perf_event or perf_event_uncore.
|
||||
*/
|
||||
int
|
||||
-_papi_hwi_init_global( void )
|
||||
+_papi_hwi_init_global( int PE_OR_PEU )
|
||||
{
|
||||
- int retval, i = 0;
|
||||
+ int retval, is_pe_peu, i = 0;
|
||||
|
||||
retval = _papi_hwi_innoculate_os_vector( &_papi_os_vector );
|
||||
if ( retval != PAPI_OK ) {
|
||||
@@ -1940,14 +1942,16 @@ _papi_hwi_init_global( void )
|
||||
}
|
||||
|
||||
while ( _papi_hwd[i] ) {
|
||||
-
|
||||
+ is_pe_peu = 0;
|
||||
+ if (strcmp(_papi_hwd[i]->cmp_info.name, "perf_event") == 0) is_pe_peu=1;
|
||||
+ if (strcmp(_papi_hwd[i]->cmp_info.name, "perf_event_uncore") == 0) is_pe_peu=1;
|
||||
retval = _papi_hwi_innoculate_vector( _papi_hwd[i] );
|
||||
if ( retval != PAPI_OK ) {
|
||||
return retval;
|
||||
}
|
||||
|
||||
/* We can be disabled by user before init */
|
||||
- if (!_papi_hwd[i]->cmp_info.disabled) {
|
||||
+ if (!_papi_hwd[i]->cmp_info.disabled && (PE_OR_PEU == is_pe_peu)) {
|
||||
retval = _papi_hwd[i]->init_component( i );
|
||||
_papi_hwd[i]->cmp_info.disabled=retval;
|
||||
|
||||
diff --git a/src/papi_internal.h b/src/papi_internal.h
|
||||
index 6492fea4e..e0f5acd74 100644
|
||||
--- a/src/papi_internal.h
|
||||
+++ b/src/papi_internal.h
|
||||
@@ -467,7 +467,7 @@ int _papi_hwi_read( hwd_context_t * context, EventSetInfo_t * ESI,
|
||||
long long *values );
|
||||
int _papi_hwi_cleanup_eventset( EventSetInfo_t * ESI );
|
||||
int _papi_hwi_convert_eventset_to_multiplex( _papi_int_multiplex_t * mpx );
|
||||
-int _papi_hwi_init_global( void );
|
||||
+int _papi_hwi_init_global( int PE_OR_PEU );
|
||||
int _papi_hwi_init_global_internal( void );
|
||||
int _papi_hwi_init_os(void);
|
||||
void _papi_hwi_init_errors(void);
|
34628
papi-no-iozone.patch
34628
papi-no-iozone.patch
File diff suppressed because it is too large
Load Diff
23
papi.spec
23
papi.spec
@ -10,18 +10,14 @@
|
||||
%{!?with_pcp: %global with_pcp 1}
|
||||
Summary: Performance Application Programming Interface
|
||||
Name: papi
|
||||
Version: 6.0.0
|
||||
Release: 12%{?dist}
|
||||
Version: 7.0.0
|
||||
Release: 1%{?dist}
|
||||
License: BSD
|
||||
Requires: papi-libs = %{version}-%{release}
|
||||
URL: http://icl.cs.utk.edu/papi/
|
||||
Source0: http://icl.cs.utk.edu/projects/papi/downloads/%{name}-%{version}.tar.gz
|
||||
Patch1: papi-python3.patch
|
||||
Patch2: papi-a64fx.patch
|
||||
Patch3: papi-no-iozone.patch
|
||||
Patch4: papi-config.patch
|
||||
Patch5: papi-nostatic.patch
|
||||
Patch6: papi-init_thread.patch
|
||||
BuildRequires: make
|
||||
BuildRequires: autoconf
|
||||
BuildRequires: doxygen
|
||||
@ -90,18 +86,9 @@ the PAPI user-space libraries and interfaces.
|
||||
%prep
|
||||
%setup -q
|
||||
%patch1 -p1 -b .python3
|
||||
%patch2 -p1 -b .a64fx
|
||||
%patch3 -p1
|
||||
%patch4 -p1
|
||||
%patch5 -p1
|
||||
%patch6 -p1 -b .thread
|
||||
|
||||
%build
|
||||
# This package fails to build with LTO due to undefined symbols. LTO
|
||||
# was disabled in OpenSuSE as well, but with no real explanation why
|
||||
# beyond the undefined symbols. It really shold be investigated further.
|
||||
# Disable LTO
|
||||
%define _lto_cflags %{nil}
|
||||
|
||||
%if %{without bundled_libpfm}
|
||||
# Build our own copy of libpfm.
|
||||
@ -133,7 +120,7 @@ autoconf
|
||||
%configure --with-perf-events \
|
||||
%{?libpfm_config} \
|
||||
%{?static_lib_config} \
|
||||
--with-shared-lib=yes --with-shlib --with-shlib-tools \
|
||||
--with-shared-lib=yes --with-shlib-tools \
|
||||
--with-components="appio coretemp example infiniband lmsensors lustre micpower mx net %{?pcp_enable} rapl stealtime"
|
||||
# implicit enabled components: perf_event perf_event_uncore
|
||||
#components currently left out because of build configure/build issues
|
||||
@ -172,6 +159,7 @@ find %{buildroot} -type f -executable ! -iname "*.py" ! -iname "*.sh" | xargs ch
|
||||
|
||||
%files devel
|
||||
%{_includedir}/*.h
|
||||
%{_includedir}/*.hpp
|
||||
%if %{with bundled_libpfm}
|
||||
%{_includedir}/perfmon/*.h
|
||||
%endif
|
||||
@ -193,6 +181,9 @@ find %{buildroot} -type f -executable ! -iname "*.py" ! -iname "*.sh" | xargs ch
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Wed Nov 16 2022 William Cohen <wcohen@redhat.com> - 7.0.0-1
|
||||
- Rebase to official papi-7.0.0.
|
||||
|
||||
* Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 6.0.0-12
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
|
||||
|
||||
|
2
sources
2
sources
@ -1 +1 @@
|
||||
SHA512 (papi-6.0.0.tar.gz) = 2a4a245d64c3ac05ca9664194ac406cfb360fc0935afdee115ca0fc3f24b6051d1130426ed959fac2f711a2239100b37a4dfe8e0885697f4f4c049554c95258a
|
||||
SHA512 (papi-7.0.0.tar.gz) = 4c5d5eef5c89e72c41fa44eb384e66a615957ac6cbc56c9f80bdca297589808ead854389b4414f14c157d5ff5b70001126c3ba33aba0557277a801e49ef44403
|
||||
|
Loading…
Reference in New Issue
Block a user