Analyzers
Talk to fellow users of Intel Analyzer tools (Intel VTune™ Profiler, Intel Advisor)
4995 Discussions

Profiling Fortran code with VTune on Linux

Dny
Beginner
321 Views
Hello ,

I'm profiling a code in fortran 90 using VTune Performance Analyzer 9.1 for Linux* build 226 .

I have a file which has a subroutine (E.g. INNER_SUBROUTINE) defined inside another subroutine(E.g. OUTER_SUBROUTINE) and outer subroutine call to inner subroutine.
But when I goes down to function level in VTune it shows me different function name .

When I go down to see the source code vtune giving an error "Cannot open Source view data".

See the sample code below.

SUBROUTINE OUTER_SUBROUTINE(NM)
--------
--------
CALL INNER_SUBROUTINE (NM)
--------
--------

CONTAINS

SUBROUTINE INNER_SUBROUTINE (NM)
--------
--------
END SUBROUTINE INNER_SUBROUTINE

END SUBROUTINE OUTER_SUBROUTINE


Can you please tell me how I can drill down to source of hotspot function for fortran subroutine?

In VTune I see the function name which is formed by module name , outer subsroutine name and inner subroutine name (I observe that it has format __ ). It means we cant find same function name in any of my source files , so VTune giving me error of not able to view data .

Can you please guide me how should I compile (any specific flags to be used ) my application so that I can see the source code of hot spot function in VTune.
Thanking You,

Regards,
Dny
0 Kudos
1 Reply
David_A_Intel1
Employee
321 Views
Hi Dny!

First, what Fortran compiler are you using? And what version?

Second, the key is really the debug info generated by the compiler. If full symbolic info is available, the VTune analyzer should be able to display the source. One test I would recommend is to load the module into the Static Module Viewer (see File menu) and verify all symbols are present and then right-click on this inner subroutine and select View Source. If you are able to open the Source view from this data, then you should be able to drill down from sampling data.

Edit: Sorry, I didn't notice the reference to Linux*. :-( However, you could download an eval version of the VTune analyzer for Windows at http://www.intel.com/software/products/global/eval.htm and try out the above.

0 Kudos
Reply