This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug exp/19535] New: Print thread named field fails if compiled with g++ -m32 on x86
- From: "richard_sharman at mitel dot com" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Fri, 29 Jan 2016 15:45:18 +0000
- Subject: [Bug exp/19535] New: Print thread named field fails if compiled with g++ -m32 on x86
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=19535
Bug ID: 19535
Summary: Print thread named field fails if compiled with g++
-m32 on x86
Product: gdb
Version: 7.10
Status: NEW
Severity: normal
Priority: P2
Component: exp
Assignee: unassigned at sourceware dot org
Reporter: richard_sharman at mitel dot com
Target Milestone: ---
Created attachment 8935
--> https://sourceware.org/bugzilla/attachment.cgi?id=8935&action=edit
c/c++ program to demonstrate the problem
GDB cannot print a struct with a field called "thread" if the program is
compiled with g++ (not gcc) and with the -m32 option on a x86 system.
This is demonstrated by file f.cc. If compiled with gcc with or without -m32
gdb can print x.thread, but if compiled with g++ -m32 it gets the error "A
syntax error in expression, near `'."
To demonstrate this, source the file Run.sh which shows result of all 4
compilations and the result of gdb executing "print x.thread". For the first 3
cases it prints correctly, "(gdb) $2 = 2" is output. For the 4th case we get
"(gdb) A syntax error in expression, near `'."
This happens with gcc 4.8 and gcc 5.3, and gdb versions 7.6.1, 7.8 and 7.10.
With Hat Enterprise Linux (7.2-64.el6_5.2) there is one extra line of
information printed:
Missing separate debuginfos, use: debuginfo-install glibc-2.12-1.149.el6.i686
Attached files: f.cc Commands.gdb Run.sh
--
You are receiving this mail because:
You are on the CC list for the bug.