OSDN Git Service

(ASM_RETURN_CASE_JUMP): Use extl to explicitly sign extend index
authorkenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 25 Mar 1997 20:24:20 +0000 (20:24 +0000)
committerkenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 25 Mar 1997 20:24:20 +0000 (20:24 +0000)
register on TARGET_5200.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@13800 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/config/m68k/apollo68.h
gcc/config/m68k/coff.h
gcc/config/m68k/linux.h
gcc/config/m68k/mot3300.h
gcc/config/m68k/pbb.h

index 2e43dbd..8eed141 100644 (file)
@@ -1,5 +1,5 @@
 /* Definitions of target machine for GNU compiler.  Apollo 680X0 version.
-   Copyright (C) 1989,1992, 1996 Free Software Foundation, Inc.
+   Copyright (C) 1989, 1992, 1996, 1997 Free Software Foundation, Inc.
 
 This file is part of GNU CC.
 
@@ -180,8 +180,13 @@ 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    return "jmp %%pc@(2,%0:w)"
-
+#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)
 
 /* Here are the new register names.  */
 
index 2565cce..85b1061 100644 (file)
@@ -1,6 +1,6 @@
 /* Definitions of target machine for GNU compiler.
    m68k series COFF object files and debugging, version.
-   Copyright (C) 1994, 1996 Free Software Foundation, Inc.
+   Copyright (C) 1994, 1996, 1997 Free Software Foundation, Inc.
 
 This file is part of GNU CC.
 
@@ -55,7 +55,13 @@ 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    return "jmp %%pc@(2,%0:w)"
+#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)
 
 /* Here are the new register names.  */
 
index 5807597..10ef0e8 100644 (file)
@@ -156,9 +156,13 @@ Boston, MA 02111-1307, USA.  */
 
 /* Use the default action for outputting the case label.  */
 #undef ASM_OUTPUT_CASE_LABEL
-
-#define ASM_RETURN_CASE_JUMP \
-  return "jmp (2,%%pc,%0.w)"
+#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)
 
 /* This is how to output an assembler line that says to advance the
    location counter to a multiple of 2**LOG bytes.  */
index b4db771..d86874c 100644 (file)
@@ -1,6 +1,6 @@
 /* Definitions of target machine for GNU compiler,
    SysV68 Motorola 3300 Delta Series.
-   Copyright (C) 1987, 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
+   Copyright (C) 1987, 93, 94, 95, 96, 1997 Free Software Foundation, Inc.
    Contributed by Abramo and Roberto Bagnara (bagnara@dipisa.di.unipi.it)
    based on Alex Crain's 3B1 definitions.
    Maintained by Philippe De Muyter (phdm@info.ucl.ac.be).
@@ -566,7 +566,13 @@ do { long l;                                       \
 #define ASM_OUTPUT_CASE_FETCH(file, labelno, regname)\
        asm_fprintf (file, "12(%Rpc,%s.", regname)
 
-#define ASM_RETURN_CASE_JUMP   return "jmp 8(%%pc,%0.w)"
+#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)";               \
+  } while (0)
             
 #else /* USE_GAS */
 
index d73cda9..41319c2 100644 (file)
@@ -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 Free Software Foundation, Inc.
+   Copyright (C) 1987, 1988, 1990, 1996, 1997 Free Software Foundation, Inc.
 
 This file is part of GNU CC.
 
@@ -114,7 +114,13 @@ 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   return "jmp %%pc@(2,%0:w)"
+#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)
 
 /* Although the gas we use can create .ctor and .dtor sections from N_SETT
    stabs, it does not support section directives, so we need to have the loader