Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 315027

Summary: Detect unsupported gmon files and display error message
Product: [Tools] Linux Tools Reporter: Martin Gerhardy <martin.gerhardy>
Component: GProfAssignee: Xavier Raynaud <xraynaud>
Status: CLOSED WONTFIX QA Contact: Xavier Raynaud <xavier.raynaud>
Severity: normal    
Priority: P3 CC: ckluss
Version: 0.5.1   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard: stalebug

Description Martin Gerhardy CLA 2010-05-31 02:11:16 EDT
the eclipse pe parser works and finds the binary, but the gprof plugin still does not like the binary for opening a gmon.out file that was generated as on my linux box, just via mingw.
Comment 1 Martin Gerhardy CLA 2010-05-31 02:16:18 EDT
no further information in the error log
Comment 2 Martin Gerhardy CLA 2010-05-31 02:17:37 EDT
ah, btw. i used helios if that matters.
Comment 3 Xavier Raynaud CLA 2010-05-31 07:39:11 EDT
Hi,

Thanks for the bug report.
I guess ufo.exe is the same as in https://bugs.eclipse.org/bugs/show_bug.cgi?id=304163 ?

Is this file part of a CProject in your workspace ?

Xavier
Comment 4 Martin Gerhardy CLA 2010-05-31 09:30:33 EDT
yes, it a binary of the same game (just recompiled since attached ;))

the binary is shown under "Binaries" in the cproject - so yes, it's part of the workspace.
Comment 5 Martin Gerhardy CLA 2010-05-31 09:32:37 EDT
ah sorry - of course it's not the same binary - as the ufo.exe is a windows binary and the attached binary in the linked ticket was a 64bit linux binary.
Comment 6 Xavier Raynaud CLA 2010-06-14 09:21:10 EDT
Hi Martin,

Can you give me your cygwin binary, and also your gmon.out file, please ?

Many thanks,

Xavier
Comment 7 Xavier Raynaud CLA 2010-10-05 03:58:52 EDT
I investigate a bit on this topic.
There is 3 different format for gmon files:

o MAGIC
o BSD
o BSD44

It seems that cygwin/mingW generates BSD gmon files.

Unfortunately, for now, eclipse plug-in only support MAGIC format, which is, AFAIK, the default one on Linux.
Comment 8 Andrew Overholt CLA 2011-01-11 09:53:31 EST
Changing summary to more accurately reflect what needs to be done here.

I've opened bug bug 333980 to document the supported formats and bug 333984 to support the other formats.
Comment 9 Andrew Overholt CLA 2011-06-06 13:54:58 EDT
Unsetting target milestone for old bugs.
Comment 10 Andrew Overholt CLA 2011-09-30 15:17:47 EDT
Updating Xavier's email address for existing bugs.
Comment 11 Christof Kluß CLA 2013-06-24 08:01:40 EDT
Hi

is there a workaround für this "problem"? perhaps an option to say MinGW to create gmon.out in MAGIC format an not BSD?

test.exe
gprof test.dll gmon.out

works fine on console. But in Eclipse there is no reaction or error, when I doubleclick gmon.out and choose test.dll. 

thx
Christof
Comment 12 Eclipse Genie CLA 2015-06-15 07:30:51 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 13 Samuel BURG CLA 2016-06-08 08:19:30 EDT
gmon.out files in BSD format are supported by Eclipse-CDT under Windows + MinGW,
but only when generated from 32bits gcc with 32bits libs.

gmon.out files in 64 bits BSD format are currently not supported by Eclipse CDT + Windows + MinGW, even if the gmon.out file can still be read and analized from command line with gprof.

I have extensively tested 32-64 bits alternatives with different versions of Eclipse (Kepler, Luna, Mars) and GCC (old 32b MinGW, new 64b MinGW, 32b TDM_GCC, 64b TDM_GCC).

For now, the workaround is to build your 'Debug' with a 32b GCC and build your 'Release' with a 64b GCC. This can be achieved using the 'MINGW_HOME' environement variable : this variable can be adjust at a project-configuration level :
Properties -> C/C++Build -> Environement -> MINGW_HOME.
So, you can have a default 64b GCC/MinGW install for Release build, and a side 32b GCC used only for debuging and for gprof.
Comment 14 Eclipse Genie CLA 2018-05-31 16:31:40 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 15 Eclipse Genie CLA 2020-05-21 09:56:43 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 16 Eclipse Genie CLA 2022-05-12 04:38:55 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.