Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

papi_strerror(3) [centos man page]

PAPI_strerror(3)						       PAPI							  PAPI_strerror(3)

NAME
PAPI_strerror - Returns a string describing the PAPI error code. SYNOPSIS
Detailed Description C Interface: #include <papi.h> char * PAPI_strerror( int errorCode ); Parameters: code -- the error code to interpret Return values: *error -- a pointer to the error string. NULL -- the input error code to PAPI_strerror() is invalid. PAPI_strerror() returns a pointer to the error message corresponding to the error code code. If the call fails the function returns the NULL pointer. This function is not implemented in Fortran. Example: * int ret; * int EventSet = PAPI_NULL; * int native = 0x0; * char error_str[PAPI_MAX_STR_LEN]; * * ret = PAPI_create_eventset(&EventSet); * if (ret != PAPI_OK) * { * fprintf(stderr, "PAPI error %d: %s0, ret, PAPI_strerror(retval)); * exit(1); * } * // Add Total Instructions Executed to our EventSet * ret = PAPI_add_event(EventSet, PAPI_TOT_INS); * if (ret != PAPI_OK) * { * PAPI_perror( "PAPI_add_event"); * fprintf(stderr,"PAPI_error %d: %s0, ret, error_str); * exit(1); * } * // Start counting * ret = PAPI_start(EventSet); * if (ret != PAPI_OK) handle_error(ret); * See Also: PAPI_perror PAPI_set_opt PAPI_get_opt PAPI_shutdown PAPI_set_debug Author Generated automatically by Doxygen for PAPI from the source code. Version 5.2.0.0 Tue Jun 17 2014 PAPI_strerror(3)

Check Out this Related Man Page

PAPI_state(3)							       PAPI							     PAPI_state(3)

NAME
PAPI_state - Return the counting state of an EventSet. SYNOPSIS
Detailed Description C Interface: #include <papi.h> int PAPI_state( int EventSet, int * status ); Parameters: EventSet -- an integer handle for a PAPI event set as created by PAPI_create_eventset status -- an integer containing a boolean combination of one or more of the following nonzero constants as defined in the PAPI header file papi.h: o PAPI_STOPPED -- EventSet is stopped o PAPI_RUNNING -- EventSet is running o PAPI_PAUSED -- EventSet temporarily disabled by the library o PAPI_NOT_INIT -- EventSet defined, but not initialized o PAPI_OVERFLOWING -- EventSet has overflowing enabled o PAPI_PROFILING -- EventSet has profiling enabled o PAPI_MULTIPLEXING -- EventSet has multiplexing enabled o PAPI_ACCUMULATING -- reserved for future use o PAPI_HWPROFILING -- reserved for future use Return values: PAPI_OK PAPI_EINVAL One or more of the arguments is invalid. PAPI_ENOEVST The EventSet specified does not exist. PAPI_state() returns the counting state of the specified event set. Example: * int EventSet = PAPI_NULL; * int status = 0; * int ret; * * ret = PAPI_create_eventset(&EventSet); * if (ret != PAPI_OK) handle_error(ret); * * // Add Total Instructions Executed to our EventSet * ret = PAPI_add_event(EventSet, PAPI_TOT_INS); * if (ret != PAPI_OK) handle_error(ret); * * // Start counting * ret = PAPI_state(EventSet, &status); * if (ret != PAPI_OK) handle_error(ret); * printf("State is now %d0,status); * ret = PAPI_start(EventSet); * if (ret != PAPI_OK) handle_error(ret); * ret = PAPI_state(EventSet, &status); * if (ret != PAPI_OK) handle_error(ret); * printf("State is now %d0,status); * See Also: PAPI_stop PAPI_start Author Generated automatically by Doxygen for PAPI from the source code. Version 5.2.0.0 Tue Jun 17 2014 PAPI_state(3)
Man Page

5 More Discussions You Might Find Interesting

1. Programming

scheduling a process

hi there i m having a confusion here with the looping in this example below. can someone help me out!? #include<stdio.h> main() { char it = 'a'; char stop = 'z'; int x,ret; for(; it<'f';it++) { // for(x=0; x<32000;x++) ... (4 Replies)
Discussion started by: a25khan
4 Replies

2. Programming

gets

can any one help me why do i get the error like gets function is dangerous and should not be used while compile a file by gcc filename.c in ret hat linux (1 Reply)
Discussion started by: MKSRaja
1 Replies

3. Linux

Can background process access to stdout,stderr

Hi folks :) Can deamonized process access to stderr, stdout? I 'm trying to display error_num/return value of a function run() in stderr using fprintf(stderr, "function run() returns = %d", ret_val); run() is called after deamonizing the process. (1 Reply)
Discussion started by: katty
1 Replies

4. Programming

Functions

Hi All, Can any one help me. I am calling in a function2 with string as parameter from function1, the function1 gives 3 values. how i get the 3 values from funciton2 to function1. i have to give a return or something. thanks in advance. (2 Replies)
Discussion started by: uday.sena.m
2 Replies

5. Shell Programming and Scripting

Help in extracting fields from a file

I have an input file with contents like: 203969 OrdAcctCycChg USAGE_DAEMON1 203970 OrdAcctCycChg USAGE_DAEMON2 203971 OrdAcctCycChg USAGE_DAEMON3 203972 OrdAcctCycChg USAGE_DAEMON4 I need to extract variables in first column... (51 Replies)
Discussion started by: Rajesh Putnala
51 Replies