Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
28655 Discussions

can't get intel fortran profiling for source code using Shark.

Daniel_Gandolfo
Beginner
358 Views
Well, I have read numerous threads on the same problem which apparently has not got a solution here...
When using Shark for Intel fortran code profiling, one does not see profiling information at the source line level because Shark does not display source code timing information (well, it does in assembler, but...).

This seems to come from some obscure underscore handling in the linking phase that should be resolved by adding the -save-temps -assume nounderscore options in the compilation phase.

Apparently, this worked for some users but if you link against MKL libraries, it does not work (even with static ones). You get something like :

Undefined symbols:
"_vsldeletestream", referenced from:
_MAIN__ in Cycle2D.o
"_vdrnguniform", referenced from:
_bec_IP_therm_winsize_pbc in Cycle2D.o
_bec_IP_mc_update_pbc in Cycle2D.o
_bec_IP_mc_update_free in Cycle2D.o
"_vslsavestreamf", referenced from:
_bec_IP_backup_conf in Cycle2D.o
"_vslnewstream", referenced from:
_bec_IP_init_parameters in Cycle2D.o
"_vslloadstreamf", referenced from:
_bec_IP_init_parameters in Cycle2D.o
ld: symbol(s) not found

and it seems to be the end of the story: one cannot use Shark for profiling at the line level of code if one needs MKL....

Am I right or some clever idea has appeared somewhere ?

Best, Daniel.
0 Kudos
2 Replies
Alexander_C_Intel
358 Views
Hi Daniel,
Several years ago I ran Shark profiling for Intel Fortran code. Indeed -save-temps was required to get source view in Shark (this is mainly due to XCode model).
For the case of MKL
1) I do not think MKL is provided with some source code or debug information. Inside MKL routines you could see timings for assembler only. Is this what you expect?
2) Does the linking issue happens with -save-temps? It seems the environment is not set so the compiler cannot find MKL libraries.
Alexander
0 Kudos
Daniel_Gandolfo
Beginner
358 Views

Well, the same status as before, I gave up at that time...

Even with the -save-temps compiler option, Shark does not show Fortran code with timing informations (as it should ?). Maybe symbols are not made available to Shark, I don't know... I see on the web that this problem seems to be shared by many users. Also, I don't see what Xcode has to see with it because Xcode is not launched during profiling.

Here is my compiler characteristic : Intel(R) Fortran Intel(R) 64 Compiler Professional for applications running on Intel(R) 64, Version 11.1    Build 20100806 Package ID: m_cprof_p_11.1.089

Also, I use SHARK 4.7.3

Any help, advices are welcome.

Best,

Daniel.

 

 

 

0 Kudos
Reply