endif identified for 100% of cpu time

pgprof identifies endif statements as taking all the time in my program, which runs for two minutes. I had hoped for detailed information. The following flags specify single threading, no optimization, no GPU? I’m not yet all that familiar with pgfortran flags and it’s possible that one of the later options increases the optimization level. I saw no message indicating this.

Please advise. I’d like to see detailed profiling information. Optimization is the only reason I can think of to cause the result, that’s why I mention it. Maybe there are other flags to enhance the profiled code? pgcollect didn’t work with this program, probably because the source is not contained in a single directory. Thank you, Dave.

The main program and private libraries are compiled and assembled with

OS windows7

$ “c:/Program Files (x86)/PGI/win32/13.6/bin”/pgf90.exe --version

pgf90 13.6-0 32-bit target on x86-64 Windows -tp sandybridge
Copyright 1989-2000, The Portland Group, Inc. All Rights Reserved.
Copyright 2000-2013, STMicroelectronics, Inc. All Rights Reserved.

Compiler & options to build objects
“c:/Program Files (x86)/PGI/win32/13.6/bin”/pgf90.exe -Minfo=pfo -Mprof=lines -tp=px-32 -g -O0 -Mpreprocess -Bstatic -Mbackslash -Mextend -Mbounds -Mfprelaxed -Mnoflushz -Mnodaz -Minform=warn

Compiler & options to link into executable
All the compilation flags along with these options and libraries
“c:/Program Files (x86)/PGI/win32/13.6/bin”/pgf90.exe -Wl,/libpath:“c:\program files (x86)\pgi\win32\13.6\lib” -Wl,/libpath:“C:\Program Files\PGI\Microsoft Open Tools 11\lib” -Wl,/libpath:“C:\Program Files (x86)\Windows Kits\8.0\Lib\win8\um\x86” -Yl,“C:\Program Files\PGI\Microsoft Open Tools 11\bin” -stack=10000000,10000000 -o $@ -Wl,/libpath:“private” $< private.lib imsl.lib FCLIB.lib crush32.lib OTSW32.lib user32.lib gdi32.lib dispf.lib skr90l32.lib

Hi David,

I sent this to our Tools group but unfortunately, they aren’t sure. Is it possible to send us a reproducing example?

They would also be interested in investigating why pgcollect didn’t work with it.


Please don’t hold your breath awaiting a response. Could take a month. I’ll try to provide a minimal (smaller, anyway) source that reproduces the issue. I add that when I profiled only two of the source files by line,
that of the main program and that containing the next-level interesting subroutine pgprof worked as expected.