This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC 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: Best set of gcc options for debugging


Yes, stabs+ has more problems with every gcc release.  Use dwarf-2
instead.  If you must use stabs+, stick with gcc 3.3.4.

Here's my list of debug info regressions, found by anaylzing gdb test
suite results.

  gcc 3.4.0 versus gcc 3.3.4

    gcc/12267  [3.4 regression] function-at-a-time generates stabs in bad order
      (fixed in 3.5.0, won't fix in 3.4.x)
    gcc/13708  [3.4/3.5 regression] static java program crashes at startup, UTF-8 encironment
    gcc/13956  [3.4/3.5 regression] incorrect stabs for nested local variables
    gdb/1537   anonymous union at function scope, gcc 3.4
    gdb/1540   gcc gcc-3_4-branch emits DW_OP_piece but gdb does not support it

  gcc HEAD versus gcc 3.4.0
    gcc/13974  [3.5 regression] bad line marker in debug info
    gcc/14049  [3.5 regression] bad debug block info, dwarf-2, c++
    gcc/14860  [3.5 regression] gcc -gstabs+ fails to emit stabs for fundamental types
    gdb/1656   if gdb cannot find function return value location, random unitialized value is used
      (might have gone away, need to re-check)

With gcc 3.4.X, gcc/12267 will hurt you.
You can try turning off function-at-a-time.

With gcc HEAD, gcc/13974 would cause some of the symptoms that you
report.  And gcc/14860 causes about 800 non-PASS results with the gdb
test suite, and causes a lot of problems with any stabs+ program,

Michael C


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