This is the mail archive of the mailing list for the GDB project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Debugging partially optimised code

>>>>> "Robert" == Robert Lupton the Good <> writes:

Robert> I'm reasonably capable of debugging -O3 code, but sometimes you
Robert> really want the non-optimised version.  However, after
Robert> recompiling just a couple of files -O0 and relinking (using g++
Robert> 4.4.6) I am having trouble.

Robert> In particular, setting a breakpoint within the non-optimised
Robert> routine results in a break in what is apparently the shared
Robert> object library (!?).  I didn't think that gcc did link-time
Robert> optimisation (and I certainly didn't pass any -O flags to the
Robert> linker). Frame 1 is OK, but frame 0 certainly isn't what I
Robert> wanted; note that both and
Robert> were compiled -O0 (although other object
Robert> files in the linked libraries were linked -O3)

Robert> Any ideas?

There isn't enough information here to go on.

The problem could range from user error (sorry) to compiler bug to gdb
bug.  It depends on various specifics that we don't know.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]