This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/29473] -masm=intel combined with -march=athlon64 has some issues.
- From: "ubizjak at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 12 Sep 2007 13:41:03 -0000
- Subject: [Bug target/29473] -masm=intel combined with -march=athlon64 has some issues.
- References: <bug-29473-13406@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #10 from ubizjak at gmail dot com 2007-09-12 13:41 -------
(In reply to comment #9)
> This still happens with GCC 4.3 when trying to bootstrap with BOOT_CFLAGS='-O2
> -g -fomit-frame-pointer -masm=intel' and it blocks me from working on bug
> 29493.
>
> /home/rask/build/gcc-x86_64-unknown-linux-gnu/./prev-gcc/xgcc
> -B/home/rask/build/gcc-x86_64-unknown-linux-gnu/./prev-gcc/
> -B/usr/local/x86_64-unknown-linux-gnu/bin/ -c -DHAVE_CONFIG_H -O2 -g
> -fomit-frame-pointer -masm=intel -I. -I/home/rask/src/gcc/libiberty/../include
> -W -Wall -Wwrite-strings -Wc++-compat -Wstrict-prototypes -pedantic
> /home/rask/src/gcc/libiberty/cplus-dem.c -o cplus-dem.o
> /tmp/cc74KiHp.s: Assembler messages:
> /tmp/cc74KiHp.s:818: Error: expecting string instruction after `rep'
> make[3]: *** [cplus-dem.o] Error 1
> make[3]: Leaving directory
> `/home/rask/build/gcc-x86_64-unknown-linux-gnu/libiberty'
> make[2]: *** [all-stage2-libiberty] Error 2
You could play a bit with line 14997 ""rep{\;| }ret" in config/i386/i386.md:
--cut here--
;; Used by x86_machine_dependent_reorg to avoid penalty on single byte RET
;; instruction Athlon and K8 have.
(define_insn "return_internal_long"
[(return)
(unspec [(const_int 0)] UNSPEC_REP)]
"reload_completed"
"rep{\;| }ret"
[(set_attr "length" "1")
(set_attr "length_immediate" "0")
(set_attr "prefix_rep" "1")
(set_attr "modrm" "0")])
--cht here--
You could try "rep ret", "rep\;ret" or "rep ; ret" here. Otherwise, this is an
assembler bug.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29473