aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeoffrey Keating <geoffk@apple.com>2004-01-06 21:03:06 +0000
committerGeoffrey Keating <geoffk@gcc.gnu.org>2004-01-06 21:03:06 +0000
commit0c90aa3c5cc34d1f67cdc3a8089c0a22c93d3648 (patch)
tree74d68dac15d8dfbef5c3b0a6a7f40cfdc119b414
parent5f383ba58b019dfcf2b3ab0872bcf19f9b3a317b (diff)
downloadgcc-0c90aa3c5cc34d1f67cdc3a8089c0a22c93d3648.zip
gcc-0c90aa3c5cc34d1f67cdc3a8089c0a22c93d3648.tar.gz
gcc-0c90aa3c5cc34d1f67cdc3a8089c0a22c93d3648.tar.bz2
rs6000.md (floatsitf2): Use expand_float rather than trying to generate RTL directly.
* config/rs6000/rs6000.md (floatsitf2): Use expand_float rather than trying to generate RTL directly. (fix_trunctfsi2): Use expand_fix rather than trying to generate RTL directly. From-SVN: r75485
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/config/rs6000/rs6000.md36
2 files changed, 21 insertions, 20 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 502d65b..6265cbe 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,10 @@
2004-01-06 Geoffrey Keating <geoffk@apple.com>
+ * config/rs6000/rs6000.md (floatsitf2): Use expand_float rather
+ than trying to generate RTL directly.
+ (fix_trunctfsi2): Use expand_fix rather than trying to generate
+ RTL directly.
+
* dwarf2out.c (add_const_value_attribute): Remove incorrect comment.
2004-01-06 David Edelsohn <edelsohn@gnu.org>
diff --git a/gcc/config/rs6000/rs6000.md b/gcc/config/rs6000/rs6000.md
index 602eabaf..273aec6 100644
--- a/gcc/config/rs6000/rs6000.md
+++ b/gcc/config/rs6000/rs6000.md
@@ -8290,19 +8290,17 @@
(float_extend:TF (match_dup 2)))]
"")
-(define_insn_and_split "floatsitf2"
+(define_expand "floatsitf2"
[(set (match_operand:TF 0 "gpc_reg_operand" "=f")
- (float:TF (match_operand:SI 1 "gpc_reg_operand" "r")))
- (clobber (match_scratch:DF 2 "=f"))]
+ (float:TF (match_operand:SI 1 "gpc_reg_operand" "r")))]
"(DEFAULT_ABI == ABI_AIX || DEFAULT_ABI == ABI_DARWIN)
&& TARGET_HARD_FLOAT && TARGET_FPRS && TARGET_LONG_DOUBLE_128"
- "#"
- "&& reload_completed"
- [(set (match_dup 2)
- (float:DF (match_dup 1)))
- (set (match_dup 0)
- (float_extend:TF (match_dup 2)))]
- "")
+{
+ rtx tmp = gen_reg_rtx (DFmode);
+ expand_float (tmp, operands[1], false);
+ emit_insn (gen_extenddftf2 (operands[0], tmp));
+ DONE;
+})
(define_insn_and_split "fix_trunctfdi2"
[(set (match_operand:DI 0 "gpc_reg_operand" "=*f")
@@ -8319,19 +8317,17 @@
(fix:DI (match_dup 2)))]
"")
-(define_insn_and_split "fix_trunctfsi2"
+(define_expand "fix_trunctfsi2"
[(set (match_operand:SI 0 "gpc_reg_operand" "=r")
- (fix:SI (match_operand:TF 1 "gpc_reg_operand" "f")))
- (clobber (match_scratch:DF 2 "=f"))]
+ (fix:SI (match_operand:TF 1 "gpc_reg_operand" "f")))]
"(DEFAULT_ABI == ABI_AIX || DEFAULT_ABI == ABI_DARWIN)
&& TARGET_HARD_FLOAT && TARGET_FPRS && TARGET_LONG_DOUBLE_128"
- "#"
- "&& reload_completed"
- [(set (match_dup 2)
- (float_truncate:DF (match_dup 1)))
- (set (match_dup 0)
- (fix:SI (match_dup 2)))]
- "")
+{
+ rtx tmp = gen_reg_rtx (DFmode);
+ emit_insn (gen_trunctfdf2 (tmp, operands[1]));
+ expand_fix (operands[0], tmp, false);
+ DONE;
+})
(define_insn "negtf2"
[(set (match_operand:TF 0 "gpc_reg_operand" "=f")