News:

Accounts with zero posts and zero activity during the last months will be deleted periodically to fight SPAM!

Main Menu

SOLVED Plugins>Code Profiler; Output OK with GCC 10.3; Not parsed with GCC 11.2

Started by ChosenName, January 05, 2022, 04:10:42 PM

Previous topic - Next topic

ChosenName

I've been successfully using Code::Blocks as my IDE for some years now, with successive versions of mingw64 based on GCC 4.6 onwards.

With mingw64 based on GCC 10.3 the code profiler plugin parses the gmon.out file as expected. With mingw64 based on GCC 11.2 it does not and shows a blank gprof window. The file size is about the same (1,428kib vs. 1,430kib) so there would seem to be information contained in it.

I've looked online for bug reports or workarounds relating to gprof and mingw based on GCC 11.2 to no avail - so was wondering if this is something that anyone has experienced with Code::Blocks.

Any advice would be very much appreciated.

Miguel Gimenez


ChosenName


Miguel Gimenez

You must use the gprof.exe that came with MinGW11.2.

Is the Windows path set correctly?. You can check the configured path opening a console and executing gprof -h, the first line shows the complete path.

ChosenName

To the best of my knowledge the compiler is using the version of gprof.exe that is part of the compiler - and it does not work on the command line either.

Thanks for the pointer to the likely cause of the problem, much appreciated.

Miguel Gimenez

BTW, both files are almost empty (that is why 1.4 MB become 5 kB).

ChosenName

It seems so - yet one gives meaningful output and the other gives a blank page.

ChosenName

Problem solved - adding "-no-pie" to compiler and linker settings allows profiler output to be viewed successfully.