This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH, rs6000] Add support for the POWER7 dcffix instruction


The POWER Toolchain IPC team who is adding POWER7 support to valgrind
reminded me that Power ISA 2.06 added a new convert from integer to
decimal64 dfp instruction.  The following patch adds support for it.

This passed bootstrap and regression testing with no regressions.
Is this ok?  If so, when can this be committed?  Now or stage1?

Peter

	* config/rs6000/dfp.md (floatdidd2): New define_insn.

Index: gcc/config/rs6000/dfp.md
===================================================================
--- gcc/config/rs6000/dfp.md	(revision 183808)
+++ gcc/config/rs6000/dfp.md	(working copy)
@@ -546,6 +546,13 @@ (define_insn "*cmptd_internal1"
   "dcmpuq %0,%1,%2"
   [(set_attr "type" "fpcompare")])
 
+(define_insn "floatdidd2"
+  [(set (match_operand:DD 0 "gpc_reg_operand" "=d")
+	(float:DD (match_operand:DI 1 "gpc_reg_operand" "d")))]
+  "TARGET_DFP && TARGET_POPCNTD"
+  "dcffix %0,%1"
+  [(set_attr "type" "fp")])
+
 (define_insn "floatditd2"
   [(set (match_operand:TD 0 "gpc_reg_operand" "=d")
 	(float:TD (match_operand:DI 1 "gpc_reg_operand" "d")))]



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]