Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

tau_register_event(3) [debian man page]

TAU_REGISTER_EVENT(3)					      TAU Instrumentation API					     TAU_REGISTER_EVENT(3)

NAME
TAU_REGISTER_EVENT - Registers a user event SYNOPSIS
C/C++: TAU_REGISTER_EVENT(TauUserEvent variable, char *event_name); Fortran: TAU_REGISTER_EVENT(int variable(2), character event_name(size)); DESCRIPTION
TAU can profile user-defined events using TAU_REGISTER_EVENT. The meaning of the event is determined by the user. The first argument to TAU_REGISTER_EVENT is the pointer to an integer array. This array is declared with a save attribute as shown below. EXAMPLE
C/C++ : int user_square(int count) { TAU_REGISTER_EVENT(ue1, "UserSquare Event"); TAU_EVENT(ue1, count * count); return 0; } Fortran : integer eventid(2) save eventid call TAU_REGISTER_EVENT(eventid, 'Error in Iteration') call TAU_EVENT(eventid, count) SEE ALSO
TAU_EVENT(3), TAU_REGISTER_CONTEXT_EVENT(3), TAU_REPORT_STATISTICS(3), TAU_REPORT_THREAD_STATISTICS(3), TAU_GET_EVENT_NAMES(3), TAU_GET_EVENT_VALS(3) 08/31/2005 TAU_REGISTER_EVENT(3)

Check Out this Related Man Page

TAU_GET_EVENT_VALS(3)					      TAU Instrumentation API					     TAU_GET_EVENT_VALS(3)

NAME
TAU_GET_EVENT_VALS - Gets user event data for given user events. SYNOPSIS
C/C++: TAU_GET_EVENT_VALS(const char **inUserEvents, int numUserEvents, int **numEvents, double **max, double **min, double **mean, double **sumSqe); DESCRIPTION
Retrieves user defined event data for the specified user defined events. The list of events are specified by the first parameter (eventList) and the user specifies the number of events in the second parameter (numUserEvents). TAU returns the number of times the event was invoked in the numUserEvents. The max, min, mean values are returned in the following parameters. TAU computes the sum of squares of the given event and returns this value in the next argument (sumSqe). EXAMPLE
C/C++ : const char **eventList; int numEvents; TAU_GET_EVENT_NAMES(eventList, numEvents); cout << "numEvents: " << numEvents << endl; if (numEvents > 0) { int *numSamples; double *max; double *min; double *mean; double *sumSqr; TAU_GET_EVENT_VALS(eventList, numEvents, numSamples, max, min, mean, sumSqr); for (int i=0; i<numEvents; i++) { cout << "------------------- "; cout << "User Event: " << eventList[i] << endl; cout << "Number of Samples: " << numSamples[i] << endl; cout << "Maximum Value: " << max[i] << endl; cout << "Minimum Value: " << min[i] << endl; cout << "Mean Value: " << mean[i] << endl; cout << "Sum Squared: " << sumSqr[i] << endl; } } } SEE ALSO
TAU_REGISTER_EVENT(3), TAU_REGISTER_CONTEXT_EVENT(3), TAU_GET_EVENT_NAMES(3) 08/31/2005 TAU_GET_EVENT_VALS(3)
Man Page

4 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Shell Variable - Please help

Hello all, How can i access the value of variable within a variable? Please go through the following code: count=0 newstr=aaaa${count} echo "enter value : " read $newstr <---- Suppose the value entered by the user is "home" echo $newstr <---- This will print "aaaa0"... (4 Replies)
Discussion started by: nisha5
4 Replies

2. Shell Programming and Scripting

Help with variable declaration

I declared a variable x that gets the count(*) from a table. The table name is also defined as a variable. What's wrong with this statment : X=” select count(*) from ${table_name}“ then y = `${X}${table_name}' echo ${y} It throws an error saying count not found. Please... (1 Reply)
Discussion started by: dsravan
1 Replies

3. Shell Programming and Scripting

Using a variable within a variable name

Hello all, I am currently trying to over-complicate things by doing something similar to the code below: count=1 for x in $(cat /etc/filename); do file_$count=$(echo $variable| awk '{print $1}') count=$(( $count + 1 )) done What I expected was different variable names file_1 file_2 .... (1 Reply)
Discussion started by: Khoomfire
1 Replies

4. UNIX for Dummies Questions & Answers

To count total of specific character in a file and save its value to a variable

Hi all, I have a file that contains characters. How do I get total of spesific character from that file and save the count to a variable for doing for calculation. data.txt 1 2 2 2 2 3 3 4 5 6 7 8 5 4 3 4 (5 Replies)
Discussion started by: weslyarfan
5 Replies