aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2004-07-03 20:03:00 -0700
committerRichard Henderson <rth@gcc.gnu.org>2004-07-03 20:03:00 -0700
commit68d22aa55a9a4f491851f37a6a377ed50ea8e292 (patch)
tree73a30a6dcffb59862e4d2223eb5401f1705817cf /gcc
parentbdecd3343c71b1edce5f7069f63979d26e1b9f5e (diff)
downloadgcc-68d22aa55a9a4f491851f37a6a377ed50ea8e292.zip
gcc-68d22aa55a9a4f491851f37a6a377ed50ea8e292.tar.gz
gcc-68d22aa55a9a4f491851f37a6a377ed50ea8e292.tar.bz2
ia64.c (spill_xfmode_operand): Use assign_stack_temp instead of gen_mem_addressof.
* config/ia64/ia64.c (spill_xfmode_operand): Use assign_stack_temp instead of gen_mem_addressof. * config/ia64/ia64.md (movxf): Use assign_stack_temp to handle TImode output register. From-SVN: r84071
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog7
-rw-r--r--gcc/config/ia64/ia64.c13
-rw-r--r--gcc/config/ia64/ia64.md18
3 files changed, 30 insertions, 8 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 4bf082f..cf04490 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,12 @@
2004-07-03 Richard Henderson <rth@redhat.com>
+ * config/ia64/ia64.c (spill_xfmode_operand): Use assign_stack_temp
+ instead of gen_mem_addressof.
+ * config/ia64/ia64.md (movxf): Use assign_stack_temp to handle
+ TImode output register.
+
+2004-07-03 Richard Henderson <rth@redhat.com>
+
PR tree-optimization/16341
* tree-sra.c (sra_walk_function): Increment to next stmt before
processing the current stmt.
diff --git a/gcc/config/ia64/ia64.c b/gcc/config/ia64/ia64.c
index e631e87..90d4a1f 100644
--- a/gcc/config/ia64/ia64.c
+++ b/gcc/config/ia64/ia64.c
@@ -1640,17 +1640,16 @@ spill_xfmode_operand (rtx in, int force)
&& GET_MODE (SUBREG_REG (in)) == TImode
&& GET_CODE (SUBREG_REG (in)) == REG)
{
- rtx mem = gen_mem_addressof (SUBREG_REG (in), NULL_TREE, /*rescan=*/true);
- return gen_rtx_MEM (XFmode, copy_to_reg (XEXP (mem, 0)));
+ rtx memt = assign_stack_temp (TImode, 16, 0);
+ emit_move_insn (memt, SUBREG_REG (in));
+ return adjust_address (memt, XFmode, 0);
}
else if (force && GET_CODE (in) == REG)
{
- rtx mem = gen_mem_addressof (in, NULL_TREE, /*rescan=*/true);
- return gen_rtx_MEM (XFmode, copy_to_reg (XEXP (mem, 0)));
+ rtx memx = assign_stack_temp (XFmode, 16, 0);
+ emit_move_insn (memx, in);
+ return memx;
}
- else if (GET_CODE (in) == MEM
- && GET_CODE (XEXP (in, 0)) == ADDRESSOF)
- return change_address (in, XFmode, copy_to_reg (XEXP (in, 0)));
else
return in;
}
diff --git a/gcc/config/ia64/ia64.md b/gcc/config/ia64/ia64.md
index b185bc8..08a6d6c 100644
--- a/gcc/config/ia64/ia64.md
+++ b/gcc/config/ia64/ia64.md
@@ -746,9 +746,25 @@
if (! reload_in_progress && ! reload_completed)
{
- operands[0] = spill_xfmode_operand (operands[0], 0);
operands[1] = spill_xfmode_operand (operands[1], 0);
+ if (GET_MODE (op0) == TImode && GET_CODE (op0) == REG)
+ {
+ rtx memt, memx, in = operands[1];
+ if (CONSTANT_P (in))
+ in = validize_mem (force_const_mem (XFmode, in));
+ if (GET_CODE (in) == MEM)
+ memt = adjust_address (in, TImode, 0);
+ else
+ {
+ memt = assign_stack_temp (TImode, 16, 0);
+ memx = adjust_address (memt, XFmode, 0);
+ emit_move_insn (memx, in);
+ }
+ emit_move_insn (op0, memt);
+ DONE;
+ }
+
if (! ia64_move_ok (operands[0], operands[1]))
operands[1] = force_reg (XFmode, operands[1]);
}