m68k.md (tablejump+2): Don't sign extend an address register.
* config/m68k/m68k.md (tablejump+2): Don't sign extend an address register. * config/m68k/apollo68.h (ASM_RETURN_CASE_JUMP): Likewise. * config/m68k/coff.h (ASM_RETURN_CASE_JUMP): Likewise. * config/m68k/linux.h (ASM_RETURN_CASE_JUMP): Likewise. * config/m68k/m68kelf.h (ASM_RETURN_CASE_JUMP): Likewise. * config/m68k/mot3300.h (ASM_RETURN_CASE_JUMP): Likewise. * config/m68k/netbsd-elf.h (ASM_RETURN_CASE_JUMP): Likewise. * config/m68k/pbb.h (ASM_RETURN_CASE_JUMP): Likewise. From-SVN: r62030
This commit is contained in:
parent
6d09ef27d4
commit
c1c1d12306
8 changed files with 117 additions and 50 deletions
|
@ -1,3 +1,15 @@
|
|||
2003-01-28 Andreas Schwab <schwab@suse.de>
|
||||
|
||||
* config/m68k/m68k.md (tablejump+2): Don't sign extend an address
|
||||
register.
|
||||
* config/m68k/apollo68.h (ASM_RETURN_CASE_JUMP): Likewise.
|
||||
* config/m68k/coff.h (ASM_RETURN_CASE_JUMP): Likewise.
|
||||
* config/m68k/linux.h (ASM_RETURN_CASE_JUMP): Likewise.
|
||||
* config/m68k/m68kelf.h (ASM_RETURN_CASE_JUMP): Likewise.
|
||||
* config/m68k/mot3300.h (ASM_RETURN_CASE_JUMP): Likewise.
|
||||
* config/m68k/netbsd-elf.h (ASM_RETURN_CASE_JUMP): Likewise.
|
||||
* config/m68k/pbb.h (ASM_RETURN_CASE_JUMP): Likewise.
|
||||
|
||||
2003-01-28 Richard Sandiford <rsandifo@redhat.com>
|
||||
|
||||
* combine.c (nonzero_bits): Fix check for negative divide operands.
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* Definitions of target machine for GNU compiler.
|
||||
m68k series COFF object files and debugging, version.
|
||||
Copyright (C) 1994, 1996, 1997, 2000 Free Software Foundation, Inc.
|
||||
Copyright (C) 1994, 1996, 1997, 2000, 2002 Free Software Foundation, Inc.
|
||||
|
||||
This file is part of GNU CC.
|
||||
|
||||
|
@ -55,12 +55,17 @@ Boston, MA 02111-1307, USA. */
|
|||
/* config/m68k.md has an explicit reference to the program counter,
|
||||
prefix this by the register prefix. */
|
||||
|
||||
#define ASM_RETURN_CASE_JUMP \
|
||||
do { \
|
||||
if (TARGET_5200) \
|
||||
return "ext%.l %0\n\tjmp %%pc@(2,%0:l)"; \
|
||||
else \
|
||||
return "jmp %%pc@(2,%0:w)"; \
|
||||
#define ASM_RETURN_CASE_JUMP \
|
||||
do { \
|
||||
if (TARGET_5200) \
|
||||
{ \
|
||||
if (ADDRESS_REG_P (operands[0])) \
|
||||
return "jmp %%pc@(2,%0:l)"; \
|
||||
else \
|
||||
return "ext%.l %0\n\tjmp %%pc@(2,%0:l)"; \
|
||||
} \
|
||||
else \
|
||||
return "jmp %%pc@(2,%0:w)"; \
|
||||
} while (0)
|
||||
|
||||
/* Here are the new register names. */
|
||||
|
|
|
@ -194,12 +194,17 @@ Boston, MA 02111-1307, USA. */
|
|||
|
||||
/* Use the default action for outputting the case label. */
|
||||
#undef ASM_OUTPUT_CASE_LABEL
|
||||
#define ASM_RETURN_CASE_JUMP \
|
||||
do { \
|
||||
if (TARGET_5200) \
|
||||
return "ext%.l %0\n\tjmp %%pc@(2,%0:l)"; \
|
||||
else \
|
||||
return "jmp %%pc@(2,%0:w)"; \
|
||||
#define ASM_RETURN_CASE_JUMP \
|
||||
do { \
|
||||
if (TARGET_5200) \
|
||||
{ \
|
||||
if (ADDRESS_REG_P (operands[0])) \
|
||||
return "jmp %%pc@(2,%0:l)"; \
|
||||
else \
|
||||
return "ext%.l %0\n\tjmp %%pc@(2,%0:l)"; \
|
||||
} \
|
||||
else \
|
||||
return "jmp %%pc@(2,%0:w)"; \
|
||||
} while (0)
|
||||
|
||||
/* This is how to output an assembler line that says to advance the
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
;;- Machine description for GNU compiler, Motorola 68000 Version
|
||||
;; Copyright (C) 1987, 1988, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001
|
||||
;; Copyright (C) 1987, 1988, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002
|
||||
;; Free Software Foundation, Inc.
|
||||
|
||||
;; This file is part of GNU CC.
|
||||
|
@ -6973,17 +6973,33 @@
|
|||
#ifdef SGS
|
||||
#ifdef ASM_OUTPUT_CASE_LABEL
|
||||
if (TARGET_5200)
|
||||
return \"ext%.l %0\;jmp 6(%%pc,%0.l)\";
|
||||
{
|
||||
if (ADDRESS_REG_P (operands[0]))
|
||||
return \"jmp 6(%%pc,%0.l)\";
|
||||
else
|
||||
return \"ext%.l %0\;jmp 6(%%pc,%0.l)\";
|
||||
}
|
||||
else
|
||||
return \"jmp 6(%%pc,%0.w)\";
|
||||
#else
|
||||
if (TARGET_5200)
|
||||
{
|
||||
if (ADDRESS_REG_P (operands[0]))
|
||||
{
|
||||
#ifdef CRDS
|
||||
return \"ext%.l %0\;jmp 2(pc,%0.l)\";
|
||||
return \"jmp 2(pc,%0.l)\";
|
||||
#else
|
||||
return \"extl %0\;jmp 2(%%pc,%0.l)\";
|
||||
return \"jmp 2(%%pc,%0.l)\";
|
||||
#endif /* end !CRDS */
|
||||
}
|
||||
else
|
||||
{
|
||||
#ifdef CRDS
|
||||
return \"ext%.l %0\;jmp 2(pc,%0.l)\";
|
||||
#else
|
||||
return \"extl %0\;jmp 2(%%pc,%0.l)\";
|
||||
#endif /* end !CRDS */
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -6997,11 +7013,22 @@
|
|||
#else /* not SGS */
|
||||
if (TARGET_5200)
|
||||
{
|
||||
if (ADDRESS_REG_P (operands[0]))
|
||||
{
|
||||
#ifdef MOTOROLA
|
||||
return \"ext%.l %0\;jmp (2,pc,%0.l)\";
|
||||
return \"jmp (2,pc,%0.l)\";
|
||||
#else
|
||||
return \"extl %0\;jmp pc@(2,%0:l)\";
|
||||
return \"jmp pc@(2,%0:l)\";
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
#ifdef MOTOROLA
|
||||
return \"ext%.l %0\;jmp (2,pc,%0.l)\";
|
||||
#else
|
||||
return \"extl %0\;jmp pc@(2,%0:l)\";
|
||||
#endif
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/* m68kelf support, derived from m68kv4.h */
|
||||
|
||||
/* Target definitions for GNU compiler for mc680x0 running System V.4
|
||||
Copyright (C) 1991, 1993, 2000 Free Software Foundation, Inc.
|
||||
Copyright (C) 1991, 1993, 2000, 2002 Free Software Foundation, Inc.
|
||||
|
||||
Written by Ron Guilmette (rfg@netcom.com) and Fred Fish (fnf@cygnus.com).
|
||||
|
||||
|
@ -73,12 +73,17 @@ Boston, MA 02111-1307, USA. */
|
|||
/* config/m68k.md has an explicit reference to the program counter,
|
||||
prefix this by the register prefix. */
|
||||
|
||||
#define ASM_RETURN_CASE_JUMP \
|
||||
do { \
|
||||
if (TARGET_5200) \
|
||||
return "ext%.l %0\n\tjmp %%pc@(2,%0:l)"; \
|
||||
else \
|
||||
return "jmp %%pc@(2,%0:w)"; \
|
||||
#define ASM_RETURN_CASE_JUMP \
|
||||
do { \
|
||||
if (TARGET_5200) \
|
||||
{ \
|
||||
if (ADDRESS_REG_P (operands[0])) \
|
||||
return "jmp %%pc@(2,%0:l)"; \
|
||||
else \
|
||||
return "ext%.l %0\n\tjmp %%pc@(2,%0:l)"; \
|
||||
} \
|
||||
else \
|
||||
return "jmp %%pc@(2,%0:w)"; \
|
||||
} while (0)
|
||||
|
||||
/* How to refer to registers in assembler output.
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* Definitions of target machine for GNU compiler,
|
||||
SysV68 Motorola 3300 Delta Series.
|
||||
Copyright (C) 1987, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000
|
||||
Copyright (C) 1987, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2002
|
||||
Free Software Foundation, Inc.
|
||||
Contributed by Abramo and Roberto Bagnara (bagnara@dipisa.di.unipi.it)
|
||||
based on Alex Crain's 3B1 definitions.
|
||||
|
@ -423,12 +423,17 @@ Boston, MA 02111-1307, USA. */
|
|||
#define ASM_OUTPUT_CASE_FETCH(file, labelno, regname)\
|
||||
asm_fprintf (file, "12(%Rpc,%s.", regname)
|
||||
|
||||
#define ASM_RETURN_CASE_JUMP \
|
||||
do { \
|
||||
if (TARGET_5200) \
|
||||
return "ext%.l %0\n\tjmp 8(%%pc,%0.l)"; \
|
||||
else \
|
||||
return "jmp 8(%%pc,%0.w)"; \
|
||||
#define ASM_RETURN_CASE_JUMP \
|
||||
do { \
|
||||
if (TARGET_5200) \
|
||||
{ \
|
||||
if (ADDRESS_REG_P (operands[0])) \
|
||||
return "jmp 8(%%pc,%0.l)"; \
|
||||
else \
|
||||
return "ext%.l %0\n\tjmp 8(%%pc,%0.l)"; \
|
||||
} \
|
||||
else \
|
||||
return "jmp 8(%%pc,%0.w)"; \
|
||||
} while (0)
|
||||
|
||||
#else /* USE_GAS */
|
||||
|
|
|
@ -11,7 +11,7 @@ This file is part of GNU CC.
|
|||
|
||||
GNU CC is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 1, or (at your option)
|
||||
the Free Software Foundation; either version 2, or (at your option)
|
||||
any later version.
|
||||
|
||||
GNU CC is distributed in the hope that it will be useful,
|
||||
|
@ -217,15 +217,18 @@ while (0)
|
|||
|
||||
/* Use the default action for outputting the case label. */
|
||||
#undef ASM_OUTPUT_CASE_LABEL
|
||||
#define ASM_RETURN_CASE_JUMP \
|
||||
do \
|
||||
{ \
|
||||
if (TARGET_5200) \
|
||||
return "ext%.l %0\n\tjmp %%pc@(2,%0:l)"; \
|
||||
else \
|
||||
return "jmp %%pc@(2,%0:w)"; \
|
||||
} \
|
||||
while (0)
|
||||
#define ASM_RETURN_CASE_JUMP \
|
||||
do { \
|
||||
if (TARGET_5200) \
|
||||
{ \
|
||||
if (ADDRESS_REG_P (operands[0])) \
|
||||
return "jmp %%pc@(2,%0:l)"; \
|
||||
else \
|
||||
return "ext%.l %0\n\tjmp %%pc@(2,%0:l)"; \
|
||||
} \
|
||||
else \
|
||||
return "jmp %%pc@(2,%0:w)"; \
|
||||
} while (0)
|
||||
|
||||
|
||||
/* This is how to output an assembler line that says to advance the
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* Definitions of target machine for GNU compiler.
|
||||
Citicorp/TTI Unicom PBB version (using GAS with a %-register prefix)
|
||||
Copyright (C) 1987, 1988, 1990, 1996, 1997 Free Software Foundation, Inc.
|
||||
Copyright (C) 1987, 1988, 1990, 1996, 1997, 2002 Free Software Foundation, Inc.
|
||||
|
||||
This file is part of GNU CC.
|
||||
|
||||
|
@ -109,12 +109,17 @@ Boston, MA 02111-1307, USA. */
|
|||
&& ! find_equiv_reg (0, get_last_insn (), 0, 0, 0, 8, Pmode)) \
|
||||
asm_fprintf (FILE, "\tmovl %Rd0,%Ra0\n"); }
|
||||
|
||||
#define ASM_RETURN_CASE_JUMP \
|
||||
do { \
|
||||
if (TARGET_5200) \
|
||||
return "ext%.l %0\n\tjmp %%pc@(2,%0:l)"; \
|
||||
else \
|
||||
return "jmp %%pc@(2,%0:w)"; \
|
||||
#define ASM_RETURN_CASE_JUMP \
|
||||
do { \
|
||||
if (TARGET_5200) \
|
||||
{ \
|
||||
if (ADDRESS_REG_P (operands[0])) \
|
||||
return "jmp %%pc@(2,%0:l)"; \
|
||||
else \
|
||||
return "ext%.l %0\n\tjmp %%pc@(2,%0:l)"; \
|
||||
} \
|
||||
else \
|
||||
return "jmp %%pc@(2,%0:w)"; \
|
||||
} while (0)
|
||||
|
||||
/* Although the gas we use can create .ctor and .dtor sections from N_SETT
|
||||
|
|
Loading…
Add table
Reference in a new issue