From: Fabian Cenedese <Cenedese@indel.ch>
To: gdb@sourceware.org
Subject: Fix for big enums in old gdb
Date: Mon, 08 May 2006 16:03:00 -0000 [thread overview]
Message-ID: <5.2.0.9.1.20060508123705.01fe6e80@NT_SERVER> (raw)
Hi
I have an old gdb (i know, not supported anymore) where I want to backport
a fix for big enums. gcc has no problem compiling an enum with a value
bigger than 0x80000000. It's supposed to use unsigned long instead of
long if a value is bigger than 0x7FFFFFFF. However our old gdb has a
problem reading this stabs info. Newer gdbs don't seem to have this problem
(even if read_huge_number fails the same way and only returns a long anyway)
Actually gdb-6.2.50 doesn't know the type either but at least it doesn't crash:
(gdb) ptype ERADef
type = <unknown type>
So I was looking for differences, mainly in stabsread.c. But I couldn't find
a change that seemed useful for this, neither in read_enum_type nor
in read_huge_number. Has anybody a hint what source parts may also
be important in regard of this problem?
Working:
.stabs "ERADef:t(0,24)=eeRAClear:1,eRAClearedByCode:-1,;",128,0,36,0
Crash:
.stabs "ERADef:t(0,24)=eeRAClear:1,eRAClearedByCode:4294967295,;",128,0,36,0
warning ("GDB internal error, type is NULL in stabsread.c\n");
Or ist there anything else I can do (except upgrading gdb)? Are these high
enum numbers not allowed in gdb? As read_huge_number still in the cvs
version only returns a long I don't know if that could work at all.
Thanks
bye Fabi
reply other threads:[~2006-05-08 11:28 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5.2.0.9.1.20060508123705.01fe6e80@NT_SERVER \
--to=cenedese@indel.ch \
--cc=gdb@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox