aboutsummaryrefslogtreecommitdiff
path: root/gcc/config/fr30
diff options
context:
space:
mode:
authorRichard Kenner <kenner@vlsi1.ultra.nyu.edu>2001-07-02 19:47:44 +0000
committerRichard Kenner <kenner@gcc.gnu.org>2001-07-02 15:47:44 -0400
commitf4ef873c3108a163d7789b137b391c3853c25011 (patch)
tree35bfff21e3c73e0c27ad267a7d90a3719cfb86af /gcc/config/fr30
parent494fff4cea67e3d1415788d318fb4448cf9411c5 (diff)
downloadgcc-f4ef873c3108a163d7789b137b391c3853c25011.zip
gcc-f4ef873c3108a163d7789b137b391c3853c25011.tar.gz
gcc-f4ef873c3108a163d7789b137b391c3853c25011.tar.bz2
emit-rtl.c (adjust_address): New function.
* emit-rtl.c (adjust_address): New function. * expr.h (adjust_address): Add declaration. * builtins.c: Replace some calls to change_address with calls to it or to validize_mem. * caller-save.c, dwarf2out.c, except.c, expmed.c, expr.c: Likewise. * function.c, config/a29k/a29k.md, config/alpha/alpha.c: Likewise. * config/arm/arm.c, config/convex/convex.c: Likewise. * config/dsp16xx/dsp16xx.md, config/fr30/fr30.c: Likewise. * config/i386/i386.c, config/i386/i386.md: Likewise. * config/ia64/ia64.c, config/ia64/ia64.md: Likewise. * config/m32r/m32r.c, config/m68k/m68k.md: Likewise. * config/m88k/m88k.c, config/mips/mips.md: Likewise. * config/ns32k/ns32k.c, config/rs6000/rs6000.c: Likewise. * config/sh/sh.c, config/sparc/sparc.md: Likewise. From-SVN: r43702
Diffstat (limited to 'gcc/config/fr30')
-rw-r--r--gcc/config/fr30/fr30.c44
-rw-r--r--gcc/config/fr30/fr30.md4
2 files changed, 22 insertions, 26 deletions
diff --git a/gcc/config/fr30/fr30.c b/gcc/config/fr30/fr30.c
index 51a5c26..0c18c65 100644
--- a/gcc/config/fr30/fr30.c
+++ b/gcc/config/fr30/fr30.c
@@ -1,7 +1,5 @@
-/*{{{ Introduction */
-
/* FR30 specific functions.
- Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
Contributed by Cygnus Solutions.
This file is part of GNU CC.
@@ -1008,9 +1006,12 @@ fr30_move_double (operands)
if (reverse)
{
- emit_insn (gen_rtx_SET (VOIDmode, dest1, change_address (src, SImode, addr)));
- emit_insn (gen_rtx_SET (SImode, dest0, gen_rtx_REG (SImode, REGNO (addr))));
- emit_insn (gen_rtx_SET (SImode, dest0, plus_constant (dest0, UNITS_PER_WORD)));
+ emit_insn (gen_rtx_SET (VOIDmode, dest1,
+ change_address (src, SImode, addr)));
+ emit_insn (gen_rtx_SET (SImode, dest0,
+ gen_rtx_REG (SImode, REGNO (addr))));
+ emit_insn (gen_rtx_SET (SImode, dest0,
+ plus_constant (dest0, UNITS_PER_WORD)));
new_mem = gen_rtx_MEM (SImode, dest0);
MEM_COPY_ATTRIBUTES (new_mem, src);
@@ -1019,9 +1020,12 @@ fr30_move_double (operands)
}
else
{
- emit_insn (gen_rtx_SET (VOIDmode, dest0, change_address (src, SImode, addr)));
- emit_insn (gen_rtx_SET (SImode, dest1, gen_rtx_REG (SImode, REGNO (addr))));
- emit_insn (gen_rtx_SET (SImode, dest1, plus_constant (dest1, UNITS_PER_WORD)));
+ emit_insn (gen_rtx_SET (VOIDmode, dest0,
+ change_address (src, SImode, addr)));
+ emit_insn (gen_rtx_SET (SImode, dest1,
+ gen_rtx_REG (SImode, REGNO (addr))));
+ emit_insn (gen_rtx_SET (SImode, dest1,
+ plus_constant (dest1, UNITS_PER_WORD)));
new_mem = gen_rtx_MEM (SImode, dest1);
MEM_COPY_ATTRIBUTES (new_mem, src);
@@ -1054,12 +1058,15 @@ fr30_move_double (operands)
src0 = operand_subword (src, 0, TRUE, mode);
src1 = operand_subword (src, 1, TRUE, mode);
- emit_insn (gen_rtx_SET (VOIDmode, change_address (dest, SImode, addr), src0));
-
- if (REGNO (addr) == STACK_POINTER_REGNUM)
- emit_insn (gen_rtx_SET (VOIDmode, change_address (dest, SImode, plus_constant (stack_pointer_rtx, UNITS_PER_WORD)), src1));
- else if (REGNO (addr) == FRAME_POINTER_REGNUM)
- emit_insn (gen_rtx_SET (VOIDmode, change_address (dest, SImode, plus_constant (frame_pointer_rtx, UNITS_PER_WORD)), src1));
+ emit_insn (gen_rtx_SET (VOIDmode,
+ change_address (dest, SImode, addr),
+ src0));
+
+ if (REGNO (addr) == STACK_POINTER_REGNUM
+ || REGNO (addr) == FRAME_POINTER_REGNUM)
+ emit_insn (gen_rtx_SET (VOIDmode,
+ adjust_address (dest, SImode, UNITS_PER_WORD),
+ src1));
else
{
rtx new_mem;
@@ -1087,10 +1094,3 @@ fr30_move_double (operands)
return val;
}
-
-/*}}}*/
-
-/* Local Variables: */
-/* folded-file: t */
-/* End: */
-
diff --git a/gcc/config/fr30/fr30.md b/gcc/config/fr30/fr30.md
index 296cdb2..d7e6115 100644
--- a/gcc/config/fr30/fr30.md
+++ b/gcc/config/fr30/fr30.md
@@ -1,5 +1,3 @@
-;;{{{ Comment
-
;; FR30 machine description.
;; Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc.
;; Contributed by Cygnus Solutions.
@@ -1441,5 +1439,3 @@
;; mode: md
;; folded-file: t
;; End:
-
-;;}}}