I guess that the TAU-instrumented binary is in folder
"Release__tau-t1-mpi-pdt-profile-trace__tau-t1-mpi-pdt-profile-trace" (the latest in my workspace's folder).
So, when I run the instrumented executable from command line, I get the following output...
mpiuser@n00:~/workspace1/demo1/Release__tau-t1-mpi-pdt-profile-trace__tau-t1-mpi-pdt-profile-trace$ mpirun -np 4 ./demo1
Num processes: 4
Process 0 received "Greetings from process 1!"
Process 0 received "Greetings from process 2!"
Process 0 received "Greetings from process 3!"
Process 1 received "Hi, how are you?"
Process 2 received "Hi, how are you?"
Process 3 received "Hi, how are you?"
PI is approximately 3.1415926535897931
hello world from Costas
Error: TauTraceFlush(0): Fd is -1. Trace file not initialized
ERROR in configuration. Trace file not initialized. If this is an MPI application, please ensure that TAU MPI wrapper library is linked. If not, please ensure that TAU_PROFILE_SET_NODE(id); is called in the program (0 for sequential).
Error: TauTraceFlush(0): Fd is -1. Trace file not initialized
ERROR in configuration. Trace file not initialized. If this is an MPI application, please ensure that TAU MPI wrapper library is linked. If not, please ensure that TAU_PROFILE_SET_NODE(id); is called in the program (0 for sequential).
Error: TauTraceFlush(0): Fd is -1. Trace file not initialized
ERROR in configuration. Trace file not initialized. If this is an MPI application, please ensure that TAU MPI wrapper library is linked. If not, please ensure that TAU_PROFILE_SET_NODE(id); is called in the program (0 for sequential).
Error: TauTraceFlush(0): Fd is -1. Trace file not initialized
ERROR in configuration. Trace file not initialized. If this is an MPI application, please ensure that TAU MPI wrapper library is linked. If not, please ensure that TAU_PROFILE_SET_NODE(id); is called in the program (0 for sequential).
mpiuser@n00:~/workspace1/demo1/Release__tau-t1-mpi-pdt-profile-trace__tau-t1-mpi-pdt-profile-trace$
But when I compile and run the same source file from command line, it runs fine and produces some output .edf and .trc files.
mpiuser@n00:~/workspace1/demo1/src$ tau_cc.sh demo1.c -o d1
Debug: Parsing with PDT Parser
Executing> /mirror/mpiuser/pdtoolkit3.16/i386_linux/bin/cparse demo1.c -I/mirror/mpiuser/t/include -DPROFILING_ON -DTAU_GNU -DTAU_DOT_H_LESS_HEADERS -DTAU_MPI -DTAU_MPI_THREADED -DTAU_LINUX_TIMERS -DCPU_TIME -DTAU_MPIGREQUEST -DTAU_MPIDATAREP -DTAU_MPIERRHANDLER -DTAU_MPIATTRFUNCTION -DTAU_MPITYPEEX -DTAU_MPIADDERROR -DTAU_LARGEFILE -D_LARGEFILE64_SOURCE -DMPICH_IGNORE_CXX_SEEK -DTAU_MPICH2_MPI_IN_PLACE -DTAU_MPIFILE -DHAVE_TR1_HASH_MAP -DTRACING_ON -I/mirror/mpiuser/mpich2/include
Debug: Instrumenting with TAU
Executing> /mirror/mpiuser/t/i386_linux/bin/tau_instrumentor demo1.pdb demo1.c -o demo1.inst.c -c
Debug: Compiling (Individually) with Instrumented Code
Executing> /usr/bin/gcc -I. -c demo1.inst.c -DPROFILING_ON -DTAU_GNU -DTAU_DOT_H_LESS_HEADERS -DTAU_MPI -DTAU_MPI_THREADED -DTAU_LINUX_TIMERS -DCPU_TIME -DTAU_MPIGREQUEST -DTAU_MPIDATAREP -DTAU_MPIERRHANDLER -DTAU_MPIATTRFUNCTION -DTAU_MPITYPEEX -DTAU_MPIADDERROR -DTAU_LARGEFILE -D_LARGEFILE64_SOURCE -DMPICH_IGNORE_CXX_SEEK -DTAU_MPICH2_MPI_IN_PLACE -DTAU_MPIFILE -DHAVE_TR1_HASH_MAP -DTRACING_ON -I/mirror/mpiuser/t/include -I/mirror/mpiuser/mpich2/include -o demo1.o
Debug: Linking (Together) object files
Executing> /usr/bin/gcc demo1.o -L/mirror/mpiuser/t/i386_linux/lib -lTauMpi-t1-mpi-pdt-profile-trace -L/mirror/mpiuser/mpich2/lib -lmpichcxx -lmpich -lrt -L/mirror/mpiuser/t/i386_linux/lib -ltau-t1-mpi-pdt-profile-trace -Wl,--export-dynamic -L/usr/lib/gcc/i486-linux-gnu/4.4.3/ -lstdc++ -lgcc_s -o d1
Debug: cleaning inst file
Executing> /bin/rm -f demo1.inst.c
Debug: cleaning PDB file
Executing> /bin/rm -f demo1.pdb
mpiuser@n00:~/workspace1/demo1/src$ mpirun -np 4 ./d1
Num processes: 4
Process 0 received "Greetings from process 1!"
Process 0 received "Greetings from process 2!"
Process 0 received "Greetings from process 3!"
Process 2 received "Hi, how are you?"
Process 1 received "Hi, how are you?"
Process 3 received "Hi, how are you?"
PI is approximately 3.1415926535901937
hello world from Costas
mpiuser@n00:~/workspace1/demo1/src$ ls -l
total 7352
-rwxr-xr-x 1 mpiuser mpiuser 2493219 2010-11-12 22:12 d1
-rwxr-xr-x 1 mpiuser mpiuser 2493219 2010-11-12 22:07 demo001
-rwxr-xr-x 1 mpiuser mpiuser 2493219 2010-11-12 22:07 demo1
-rw-r--r-- 1 mpiuser mpiuser 2492 2010-11-12 20:26 demo1.c
-rw-r--r-- 1 mpiuser mpiuser 3104 2010-11-12 22:12 demo1.o
-rw-r--r-- 1 mpiuser mpiuser 1070 2010-11-12 22:14 events.0.edf
-rw-r--r-- 1 mpiuser mpiuser 1064 2010-11-12 22:14 events.1.edf
-rw-r--r-- 1 mpiuser mpiuser 1064 2010-11-12 22:14 events.2.edf
-rw-r--r-- 1 mpiuser mpiuser 1064 2010-11-12 22:14 events.3.edf
drwxr-xr-x 2 mpiuser mpiuser 4096 2010-11-09 21:36 gem
-rw-r--r-- 1 mpiuser mpiuser 1224 2010-11-12 22:14 tautrace.0.0.0.trc
-rw-r--r-- 1 mpiuser mpiuser 936 2010-11-12 22:14 tautrace.1.0.0.trc
-rw-r--r-- 1 mpiuser mpiuser 936 2010-11-12 22:14 tautrace.2.0.0.trc
-rw-r--r-- 1 mpiuser mpiuser 936 2010-11-12 22:14 tautrace.3.0.0.trc
mpiuser@n00:~/workspace1/demo1/src$
Thank you in advance,
Constantinos