This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [commit] Support 64-bit constants/enums on 32-bit host [Re: [PATCH] Allow 64-bit enum values]
- From: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- To: Tom Tromey <tromey at redhat dot com>
- Cc: Siddhesh Poyarekar <siddhesh at redhat dot com>, gdb-patches at sourceware dot org
- Date: Tue, 17 Apr 2012 21:09:03 +0200
- Subject: Re: [commit] Support 64-bit constants/enums on 32-bit host [Re: [PATCH] Allow 64-bit enum values]
- References: <20120220132724.GB4753@spoyarek.pnq.redhat.com> <87d397syts.fsf@fleche.redhat.com> <20120229135148.GA32128@spoyarek.pnq.redhat.com> <20120301224428.GA30631@host2.jankratochvil.net> <20120305063542.GA30196@spoyarek.pnq.redhat.com> <20120305080512.GA12311@host2.jankratochvil.net> <20120321100630.GA14496@spoyarek.pnq.redhat.com> <20120417130833.GB15356@host2.jankratochvil.net> <878vhuwhrd.fsf@fleche.redhat.com>
On Tue, 17 Apr 2012 16:32:54 +0200, Tom Tromey wrote:
> I am thinking that presumably people who build a 32-bit gdb without
> --enable-64-bit-bfd are interested in the smallest memory footprint.
> Also presumably they are not likely to be debugging many 64 bit
> processes or perhaps even using enums with values requiring 64 bits;
> certainly those would be relatively rare cases. So, if LOC_CONST_BYTES
> works, it would be an overall memory savings.
While I would never have that idea myself I can also do:
#ifdef BFD64
LONGEST ivalue;
#else
long ivalue;
#endif
It always keeps the memory footprint and makes 64-bit constants working on
32-bit gdb --enable-64-bit-bfd builds.
Regards,
Jan