public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* Strange assembler-comments with -fverbose-asm
@ 2003-09-22 12:17 KRECKEL Richard NGLT
  0 siblings, 0 replies; only message in thread
From: KRECKEL Richard NGLT @ 2003-09-22 12:17 UTC (permalink / raw)
  To: 'gcc-help@gcc.gnu.org'; +Cc: 'martin.sterna@siemens.com'

Hi,

GCC 3.3.x with targets i386-{aout|coff} and possibly others generate wrong
comments
when called with -fverbose-asm.  Here is how to reproduce:

---<test.c>-----------------------------------------------------------------
------
int noop( int i )
{
    return i;
}
---<test.s>-----------------------------------------------------------------
------
        .file   "test.c"
/ GNU C version 3.3 (i386-aout)
/       compiled by GNU C version 3.1.1.
/ GGC heuristics: --param ggc-min-expand=55 --param ggc-min-heapsize=48115
/ options passed:  -D__GNUC__=3 -D__GNUC_MINOR__=3 -D__GNUC_PATCHLEVEL__=0
/ -auxbase -fverbose-asm
/ options enabled:  -fpeephole -ffunction-cse -fkeep-static-consts
/ -fpcc-struct-return -fgcse-lm -fgcse-sm -fsched-interblock -fsched-spec
/ -fbranch-count-reg -fcommon -fverbose-asm -fargument-alias
/ -fzero-initialized-in-bss -fident -fmath-errno -ftrapping-math -m80387
/ -mhard-float -mno-soft-float -mieee-fp -mfp-ret-in-387 -mcpu=i386
/ -march=i386

        .text
.globl _noop
_noop:
        pushl   %ebp
        movl    %esp, %ebp
        movl    8(%ebp), %eax   /  i
        leave
        ret
----------------------------------------------------------------------------
------

That comment in the third line of the function should be introduced 
by a '#', as opposed to by a '/'.

Here is a short way how to reproduce the problem, given gcc compiled with
--target=i386-aout and a corresponding as from binutils 2.14:

$ i386-aout-gcc -fverbose-asm -c test.c -v
Reading specs from /backup/txs32/lib/gcc-lib/i386-aout/3.3/specs
Konfiguriert mit: ../gcc-3.3/configure --prefix=/backup/txs32
--target=i386-aout
Thread model: single
gcc-Version 3.3
 /backup/txs32/lib/gcc-lib/i386-aout/3.3/cc1 -quiet -v -D__GNUC__=3
-D__GNUC_MINOR__=3 -D__GNUC_PATCHLEVEL__=0 test.c -quiet -dumpbase test.c
-auxbase test -version -fverbose-asm -o /tmp/ccIfergm.s
GNU C version 3.3 (i386-aout)
        compiled by GNU C version 3.1.1.
GGC heuristics: --param ggc-min-expand=55 --param ggc-min-heapsize=48115
nicht vorhandenes Verzeichnis >/backup/txs32/i386-aout/sys-include< wird
ignoriert
nicht vorhandenes Verzeichnis >/backup/txs32/i386-aout/include< wird
ignoriert
#include "..." search starts here:
#include <...> search starts here:
 /backup/txs32/include
 /backup/txs32/lib/gcc-lib/i386-aout/3.3/include
End of search list.
 /backup/txs32/lib/gcc-lib/i386-aout/3.3/../../../../i386-aout/bin/as
--traditional-format -o test.o /tmp/ccIfergm.s
/tmp/ccIfergm.s: Assembler messages:
/tmp/ccIfergm.s:19: Error: junk `/i' after register

Looks like a bug, doesn't it?

Regards
    -richy.
-- 
Richard B. Kreckel
Framatome ANP GmbH, NGLTS
<Richard.Kreckel@Framatome-ANP.COM>
Tel: (+49)9131/189-5275, Fax: (+49)9131/189-9908

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-09-22 12:17 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-09-22 12:17 Strange assembler-comments with -fverbose-asm KRECKEL Richard NGLT

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).