From ed1fe82954ec95687de9ecc0351b8a3c32e1937c Mon Sep 17 00:00:00 2001 From: Eric Botcazou Date: Wed, 10 Dec 2003 16:25:41 +0100 Subject: re PR target/13354 (internal compiler error: in sparc_emit_set_const32) PR target/13354 * config/sparc/sparc.c (sparc_output_mi_thunk): Load DELTA manually if one can do that with only one instruction. From-SVN: r74499 --- gcc/ChangeLog | 6 ++++++ gcc/config/sparc/sparc.c | 13 ++++++++++--- 2 files changed, 16 insertions(+), 3 deletions(-) (limited to 'gcc') diff --git a/gcc/ChangeLog b/gcc/ChangeLog index c10568e..71dfb7e 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2003-12-10 Eric Botcazou + + PR target/13354 + * config/sparc/sparc.c (sparc_output_mi_thunk): Load DELTA + manually if one can do that with only one instruction. + 2003-12-10 Nick Clifton * config.gcc (arm-linux): Include linux.h in tm_file so that diff --git a/gcc/config/sparc/sparc.c b/gcc/config/sparc/sparc.c index d33fd18..a3fdcc6 100644 --- a/gcc/config/sparc/sparc.c +++ b/gcc/config/sparc/sparc.c @@ -9085,10 +9085,17 @@ sparc_output_mi_thunk (FILE *file, tree thunk_fndecl ATTRIBUTE_UNUSED, if (!SPARC_SIMM13_P (delta)) { rtx scratch = gen_rtx_REG (Pmode, 1); - if (TARGET_ARCH64) - sparc_emit_set_const64 (scratch, delta_rtx); + + if (input_operand (delta_rtx, GET_MODE (scratch))) + emit_insn (gen_rtx_SET (VOIDmode, scratch, delta_rtx)); else - sparc_emit_set_const32 (scratch, delta_rtx); + { + if (TARGET_ARCH64) + sparc_emit_set_const64 (scratch, delta_rtx); + else + sparc_emit_set_const32 (scratch, delta_rtx); + } + delta_rtx = scratch; } -- cgit v1.1