Bug 552619
| Summary: | gdb crash when xemacs is compiled with -feliminate-dwarf2-dups | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Jerry James <loganjerry> | ||||||
| Component: | gdb | Assignee: | Tom Tromey <tromey> | ||||||
| Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||||
| Severity: | medium | Docs Contact: | |||||||
| Priority: | low | ||||||||
| Version: | 12 | CC: | jan.kratochvil, patrickm, pmuldoon, tromey | ||||||
| Target Milestone: | --- | ||||||||
| Target Release: | --- | ||||||||
| Hardware: | x86_64 | ||||||||
| OS: | Linux | ||||||||
| Whiteboard: | abrt_hash:565693110765629e9050d67c3ea4d5d48a4e5125 | ||||||||
| Fixed In Version: | gdb-7.0.1-34.fc12 | Doc Type: | Bug Fix | ||||||
| Doc Text: | Story Points: | --- | |||||||
| Clone Of: | Environment: | ||||||||
| Last Closed: | 2010-03-16 00:50:26 UTC | Type: | --- | ||||||
| Regression: | --- | Mount Type: | --- | ||||||
| Documentation: | --- | CRM: | |||||||
| Verified Versions: | Category: | --- | |||||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||||
| Embargoed: | |||||||||
| Attachments: |
|
||||||||
|
Description
Jerry James
2010-01-05 17:09:01 UTC
Created attachment 381798 [details]
File: backtrace
Sure enough, without -feliminate-dwarf2-dups, gdb behaves normally. My first suspicion is that there is an underlying gcc bug. What version of gcc did you use? (gdb ideally should not crash on invalid dwarf, but my understanding is that some checking is omitted because it would slow down startup too much.) I apply updates aggressively, so there's no telling. :-) However, I just tried it again with the same results. gcc-4.4.3-4.fc12.x86_64 gdb-7.0.1-31.fc12.x86_64 I wonder if this has something to do with XEmacs' aggressive use of inline functions. I'm going to try a little test and see if I can trigger the bug. Created attachment 396395 [details]
Source file with an inline function
If I compile this source file with -feliminate-dwarf2-dups, then on starting up GDB, it warns:
Reading symbols from /tmp/test/inline-test...done.
DW_FORM_strp pointing outside of .debug_str section [in module /tmp/test/inline-test]
but doesn't if I omit the -feliminate-dwarf2-dups flag. I have no idea if this has anything to do with the crash. Maybe I need to define LOTS of inline functions....
Thanks for the test case. This is definitely a gdb bug, not a gcc bug. The problem is that DWARF 3 specified a change in the size of DW_FORM_ref_addr, and gdb did not implement this change. I'm working on it. I pushed the fix into upstream gdb. Jan, this should go into our releases as well. http://sourceware.org/ml/gdb-patches/2010-03/msg00219.html Thanks for tracking that down, Tom. gdb-7.0.1-34.fc12 has been submitted as an update for Fedora 12. http://admin.fedoraproject.org/updates/gdb-7.0.1-34.fc12 gdb-7.0.1-34.fc12 has been pushed to the Fedora 12 stable repository. If problems still persist, please make note of it in this bug report. |