From: Michel Dänzer <[email protected]>

Fixes 37 piglit tests and allows e.g. FlightGear to run with radeonsi.

Signed-off-by: Michel Dänzer <[email protected]>
---
 lib/Target/R600/SIInstructions.td |   10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/lib/Target/R600/SIInstructions.td 
b/lib/Target/R600/SIInstructions.td
index 4164c55..85bb73a 100644
--- a/lib/Target/R600/SIInstructions.td
+++ b/lib/Target/R600/SIInstructions.td
@@ -1326,6 +1326,16 @@ def : Pat<
 >;
 
 def : Pat <
+  (fcos AllReg_32:$src0),
+  (V_COS_F32_e32 (V_MUL_F32_e32 AllReg_32:$src0, (V_MOV_IMM_I32 
CONST.TWO_PI_INV)))
+>;
+
+def : Pat <
+  (fsin AllReg_32:$src0),
+  (V_SIN_F32_e32 (V_MUL_F32_e32 AllReg_32:$src0, (V_MOV_IMM_I32 
CONST.TWO_PI_INV)))
+>;
+
+def : Pat <
   (int_AMDGPU_cube VReg_128:$src),
   (INSERT_SUBREG (INSERT_SUBREG (INSERT_SUBREG (INSERT_SUBREG (v4f32 
(IMPLICIT_DEF)),
     (V_CUBETC_F32 (EXTRACT_SUBREG VReg_128:$src, sel_x),
-- 
1.7.10.4

_______________________________________________
mesa-dev mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to