[Bug target/53386] Bad assembly code produced for m68000
mikpe at it dot uu.se
gcc-bugzilla@gcc.gnu.org
Thu May 17 12:06:00 GMT 2012
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53386
--- Comment #7 from Mikael Pettersson <mikpe at it dot uu.se> 2012-05-17 11:31:35 UTC ---
gcc-4.3.x changed gcc/config.gcc:
--- gcc-4.2.4/gcc/config.gcc 2008-03-13 20:11:43.000000000 +0100
+++ gcc-4.3.6/gcc/config.gcc 2011-02-25 00:02:14.000000000 +0100
...
-m68k-*-uclinux*) # Motorola m68k/ColdFire running uClinux with
uClibc
- tm_file="m68k/m68k.h m68k/m68k-none.h m68k/m68kelf.h dbxelf.h elfos.h
m68k/uclinux.h"
- tm_defines="${tm_defines} MOTOROLA USE_GAS"
- tmake_file=m68k/t-uclinux
+m68k-*-uclinuxoldabi*) # Motorola m68k/ColdFire running uClinux
+ # with uClibc, using the original
+ # m68k-elf-based ABI
+ default_m68k_cpu=68020
+ default_cf_cpu=5206
+ tm_file="${tm_file} m68k/m68k-none.h m68k/m68kelf.h dbxelf.h elfos.h
m68k/uclinux-oldabi.h"
+ tm_defines="${tm_defines} MOTOROLA=1"
+ tmake_file="m68k/t-floatlib m68k/t-uclinux"
+ use_fixproto=no
+ ;;
+m68k-*-uclinux*) # Motorola m68k/ColdFire running uClinux
+ # with uClibc, using the new GNU/Linux-style
+ # ABI.
+ default_m68k_cpu=68020
+ default_cf_cpu=5206
+ tm_file="${tm_file} dbxelf.h elfos.h svr4.h linux.h flat.h m68k/linux.h
m68k/uclinux.h ./sysroot-suffix.h"
+ tm_defines="${tm_defines} MOTOROLA=1 UCLIBC_DEFAULT=1"
+ extra_options="${extra_options} linux.opt"
+ tmake_file="m68k/t-floatlib m68k/t-uclinux m68k/t-mlibs"
use_fixproto=no
;;
Upping the default m68k cpu to 020 is suspicious, but the real problem is the
inclusion of m68k/linux.h in tm_files, as that disables strict-alignment
support, even when compiling with an explicit -m68000 option.
I don't know anthing about the uClinux m68k "old" and "new" ABIs, but it looks
like you will get correct behaviour if you build for m68k-uclinuxoldabi
--with-cpu=m68000.
More information about the Gcc-bugs
mailing list