This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/17171] New: Unrecognized comments in generated asm


$ i386-aout-gcc -v
Reading specs from /data/scratch/bugprefix/lib/gcc/i386-aout/3.5.0/specs
Configured with: ../configure --prefix=/data/scratch/bugprefix --disable-nls
--target=i386-aout
Thread model: single
gcc version 3.5.0 20040822 (experimental)
$ cat noop.c
int noop(int x)
{
    return x;
}
$ i386-aout-gcc -c -fverbose-asm noop.c
/tmp/ccPuH6QY.s: Assembler messages:
/tmp/ccPuH6QY.s:18: Error: junk `/' after register
/tmp/ccPuH6QY.s:19: Error: junk `/' after register
/tmp/ccPuH6QY.s:20: Error: junk `/x' after register
$ i386-aout-gcc -S -fverbose-asm noop.c
$ cat noop.s
        .file   "noop.c"
/ GNU C version 3.5.0 20040822 (experimental) (i386-aout)
/       compiled by GNU C version 3.2.
/ GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
/ options passed:  -auxbase -fverbose-asm
/ options enabled:  -falign-loops -fargument-alias -fbranch-count-reg
/ -fcommon -feliminate-unused-debug-types -ffunction-cse -fgcse-las
/ -fgcse-lm -fgcse-sm -fident -fkeep-static-consts -fleading-underscore
/ -floop-optimize2 -fmath-errno -fpcc-struct-return -fpeephole
/ -fsched-interblock -fsched-spec -fsched-stalled-insns-dep -ftree-lim
/ -ftree-loop-optimize -fverbose-asm -fzero-initialized-in-bss -m80387
/ -mhard-float -mno-soft-float -mieee-fp -mfp-ret-in-387 -mno-red-zone
/ -mtune=i386 -march=i386

        .text
.globl _noop
_noop:
        pushl   %ebp    /
        movl    %esp, %ebp      /,
        movl    8(%ebp), %eax   / x, T.0
        leave
        ret
$ i386-aout-as -o noop.o noop.s
noop.s: Assembler messages:
noop.s:18: Error: junk `/' after register
noop.s:19: Error: junk `/' after register
noop.s:20: Error: junk `/x' after register
$ i386-aout-as --version
GNU assembler 2.15
Copyright 2002 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License.  This program has absolutely no warranty.
This assembler was configured for a target of `i386-aout'.

This is because gas doesn't like the slash as comment introducer.  It
prefers a hashmark.  This problem goes back to at least gcc 3.1.1.  Or is it
rather a binutils bug?

The patch for GCC I suggested last year does still work as of current mainline:
<http://gcc.gnu.org/ml/gcc-patches/2003-09/msg01562.html>.

-- 
           Summary: Unrecognized comments in generated asm
           Product: gcc
           Version: 3.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: Richard dot Kreckel at Framatome-ANP dot com
                CC: gcc-bugs at gcc dot gnu dot org,hjl at lucon dot org
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i386-aout


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17171


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]