[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bgl-discuss] Profile problem



being not familar with libmpitrace_c.a and C++ code, I'm guessing here:

If you are using ibm compiler, you shouldn't link to
/bgl/BlueLight/ppcfloor/blrts-gnu/powerpc-bgl-blrts-gnu -lstdc++,
which is for gnu compiler, not ibm compiler.
If your code is C++ code, shouldn't you use blrts_xlC ?

/soft/tools/mpitrace/libmpitrace_c.a seems to be compiled with xlc.
So you may want to try putting -L/soft/tools/mpitrace -lmpitrace_c before
-L/bgl/BlueLight/ppcfloor/bglsys/lib/ -lmpich.rts ....

I suggest to try the following in your link line:

blrts_xlC -I./include -I/bgl/BlueLight/ppcfloor/bglsys/include
-I/bgl/home1/jinxu/work/Hybrid/include
-qdebug=function_trace -o turbulence180e ./append.o ./polylib.o
./turbulence180e.o
/bgl/home1/jinxu/work/Hybrid/Hlib/Linux/liblapack_LINUX.a
/bgl/home1/jinxu/work/Hybrid/Hlib/Linux/libblas_LINUX.a
-L/bgl/home1/jinxu/work/Hybrid/Hlib/Linux -lvec -lfftw -lrfftw
-L/soft/tools/mpitrace -lmpitrace_c
-L/bgl/BlueLight/ppcfloor/bglsys/lib/ -lmpich.rts -lmsglayer.rts
-lrts.rts -ldevices.rts

If that does not work, append the link path below to the above command.

-L/opt/ibmcmp/vacpp/7.0/blrts_dev_lib
-L/opt/ibmcmp/vacpp/7.0/blrts_lib -libmc++

A.Chan

On Fri, 14 Oct 2005, Xu, Jin wrote:

>
> Hi,
>
>   I am trying to profile code, but met problems. First is compiling with "-qdebug=function_trace" option. I use xlc compiler to compile C/C++ code.
>
> /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
>
>   work/Hybrid> cat Makefile.xlc.trace
> /opt/ibmcmp/vac/7.0/bin/blrts_xlc -I./include
-I/bgl/BlueLight/ppcfloor/bglsys/include
-I/bgl/home1/jinxu/work/Hybrid/include -qdebug=function_trace -c -o
./turbulence180e.o src/turbulence180e.C
>
> /opt/ibmcmp/vac/7.0/bin/blrts_xlc -I./include
-I/bgl/BlueLight/ppcfloor/bglsys/include
-I/bgl/home1/jinxu/work/Hybrid/include
-qdebug=function_trace -o turbulence180e ./append.o ./polylib.o
./turbulence180e.o /bgl/home1/jinxu/work/Hybrid/Hlib/Linux/liblapack_LINUX.a
/bgl/home1/jinxu/work/Hybrid/Hlib/Linux/libblas_LINUX.a
-L/bgl/home1/jinxu/work/Hybrid/Hlib/Linux -lvec -lfftw -lrfftw
-L/bgl/BlueLight/ppcfloor/bglsys/lib/ -lmpich.rts -lmsglayer.rts -lrts.rts
-ldevices.rts -lg2c -L/opt/ibmcmp/vacpp/7.0/blrts_dev_lib
-L/opt/ibmcmp/vacpp/7.0/blrts_lib -libmc++
-L/bgl/BlueLight/ppcfloor/blrts-gnu/powerpc-bgl-blrts-gnu/lib
-lstdc++ /soft/tools/mpitrace/libmpitrace_c.a
>
>   work/Hybrid> setenv PROFILE_LIB  /soft/tools
> work/Hybrid> ./Makefile.xlc.trace
> "src/turbulence180e.C", line 6495.16: 1540-1102 (W) "km" might be used before it is set.
> "src/turbulence180e.C", line 6495.24: 1540-1102 (W) "kn" might be used before it is set.
> /soft/tools/mpitrace/libmpitrace_c.a(function_trace.o): In function `print_memory_stats':
> /gsa/watgsa/.home/h1/walkup/mpi_trace/bgl/beta/function_trace.c:293: undefined reference to `PMPI_Gather'
> /gsa/watgsa/.home/h1/walkup/mpi_trace/bgl/beta/function_trace.c:296: undefined reference to `PMPI_Gather'
> /gsa/watgsa/.home/h1/walkup/mpi_trace/bgl/beta/function_trace.c:299: undefined reference to `PMPI_Gather'
>
> /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
>
>    I also tried compiling with -pg option:
>
> >GPROF
> >
> >   Compile your code with the "-pg" flag.
> >   You will get a gmon.out file.
> >         gprof myExe gmon.out.*
> >
>
> And I run the job as usual,
>
> cqsub -t 5:00 -n 16 -c 16 -m vn /home/jinxu/work/Hybrid/runs/turbulence180e.pg
>
> but does not get gmon.out files. What's wrong?
>
>
> Thanks,
>
> Jin
>
> - --------------------------------------------------------------------
> To add or remove yourself from this mailing list, use the 'notifyme'
> command on any BGL machine. To remove: notifyme -n, to add: notifyme -y.
>
>

- --------------------------------------------------------------------
To add or remove yourself from this mailing list, use the 'notifyme'
command on any BGL machine. To remove: notifyme -n, to add: notifyme -y.