This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: How to make gcc -S generate hexadecimal values, not decimal
Robert Pluim <rpluim@bigfoot.com> writes:
> Alain Enout <enout@eurecom.fr> writes:
>
> > Hello,
> >
> > When using the -S option of gcc to generate assembly code, values seem to be
> > decimal. This is very annoying, as my C code contains hexadecimal values :-).
> >
> > Does somebody know how to make gcc -S generate hexdecimal values in the
> > assembly code ? Or is there a tool which is aware of the assembly syntax
> > that could do that ?
> >
> > Thanks in advance.
>
> Have you tried 'objdump -d'? That seems to produce hex.
Thanks for the tip, but I've already tested that. I'd like to keep all .s
information, instead of disassembling .o file which has the disadvantage of
losing label information (and jumps are really less easy to read :-). At
present I use a mix of both files (real .s and disassembly), and I'd like to
get rid of one.
--
Alain ENOUT Research Engineer, Mobile Communications Dpt
enout@bach.eurecom.fr Phone: +33 (0)4 93 00 26 65
EURECOM, 2229 rte des cretes, BP 193, F-06904 Sophia Antipolis Cedex, France