diff options
author | Richard Henderson <rth@cygnus.com> | 1999-11-05 10:19:55 -0800 |
---|---|---|
committer | Richard Henderson <rth@gcc.gnu.org> | 1999-11-05 10:19:55 -0800 |
commit | 467403ca5587335ab372bc19f8e261af067afe2f (patch) | |
tree | 1919db1a6a2c27a98d708b59e99c981afddedb10 /gcc | |
parent | 3948f9d08f16115e491d5dc8d08fa7d6fb0f0917 (diff) | |
download | gcc-467403ca5587335ab372bc19f8e261af067afe2f.zip gcc-467403ca5587335ab372bc19f8e261af067afe2f.tar.gz gcc-467403ca5587335ab372bc19f8e261af067afe2f.tar.bz2 |
i386.c (split_xf): New.
* i386.c (split_xf): New.
* i386-protos.h: Declare it.
* i386.md (movxf_1): Add general regs alternatives.
(movxf_1+1): New splitter for same.
From-SVN: r30419
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/config/i386/i386-protos.h | 1 | ||||
-rw-r--r-- | gcc/config/i386/i386.c | 20 | ||||
-rw-r--r-- | gcc/config/i386/i386.md | 18 |
4 files changed, 44 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 77bbb56..477361c 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +Fri Nov 5 10:18:11 1999 Richard Henderson <rth@cygnus.com> + + * i386.c (split_xf): New. + * i386-protos.h: Declare it. + * i386.md (movxf_1): Add general regs alternatives. + (movxf_1+1): New splitter for same. + Fri Nov 5 12:05:52 1999 Nick Clifton <nickc@cygnus.com> * function.c (purge_addressof_1): Add missing return values. diff --git a/gcc/config/i386/i386-protos.h b/gcc/config/i386/i386-protos.h index dafbcd1..7468ce8 100644 --- a/gcc/config/i386/i386-protos.h +++ b/gcc/config/i386/i386-protos.h @@ -73,6 +73,7 @@ extern void print_operand PROTO((FILE*, rtx, int)); extern void print_operand_address PROTO((FILE*, rtx)); extern void split_di PROTO((rtx[], int, rtx[], rtx[])); +extern void split_xf PROTO((rtx, rtx[3])); extern char *output_387_binary_op PROTO((rtx, rtx*)); extern char *output_fix_trunc PROTO((rtx, rtx*)); diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c index 0a8b1f6..0901960 100644 --- a/gcc/config/i386/i386.c +++ b/gcc/config/i386/i386.c @@ -2995,6 +2995,26 @@ split_di (operands, num, lo_half, hi_half) abort(); } } + +void +split_xf (orig, out) + rtx orig; + rtx out[3]; +{ + if (REG_P (orig)) + { + int regno = REGNO (orig); + out[0] = gen_rtx_REG (SImode, regno); + out[1] = gen_rtx_REG (SImode, regno + 1); + out[2] = gen_rtx_REG (SImode, regno + 2); + } + else + { + out[0] = change_address (orig, SImode, NULL_RTX); + out[1] = adj_offsettable_operand (out[0], 4); + out[2] = adj_offsettable_operand (out[0], 8); + } +} /* Output code to perform a 387 binary operation in INSN, one of PLUS, MINUS, MULT or DIV. OPERANDS are the insn operands, where operands[3] diff --git a/gcc/config/i386/i386.md b/gcc/config/i386/i386.md index 73a9e98..91745f1 100644 --- a/gcc/config/i386/i386.md +++ b/gcc/config/i386/i386.md @@ -1980,8 +1980,8 @@ }") (define_insn "*movxf_1" - [(set (match_operand:XF 0 "nonimmediate_operand" "=f,m,f") - (match_operand:XF 1 "general_operand" "fm,f,G"))] + [(set (match_operand:XF 0 "nonimmediate_operand" "=f,m,f,*r,o") + (match_operand:XF 1 "general_operand" "fm,f,G,*ro,*r"))] "" "* { @@ -2013,11 +2013,25 @@ return \"fld1\"; } break; + + case 3: case 4: + return \"#\"; } abort(); }" [(set_attr "type" "fmov")]) +(define_split + [(set (match_operand:XF 0 "nonimmediate_operand" "") + (match_operand:XF 1 "nonimmediate_operand" ""))] + "(REG_P (operands[0]) && ! FP_REGNO_P (REGNO (operands[0]))) + || (REG_P (operands[1]) && ! FP_REGNO_P (REGNO (operands[1])))" + [(set (match_dup 0) (match_dup 3)) + (set (match_dup 1) (match_dup 4)) + (set (match_dup 2) (match_dup 5))] + "split_xf (operands[1], &operands[3]); + split_xf (operands[0], &operands[0]);") + (define_insn "swapxf" [(set (match_operand:XF 0 "register_operand" "+f") (match_operand:XF 1 "register_operand" "+f")) |