Module: Mesa
Branch: master
Commit: 876b42663c4a72040a2084ed094d5a496b86aecd
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=876b42663c4a72040a2084ed094d5a496b86aecd

Author: Vincent Lejeune <v...@ovi.com>
Date:   Wed Oct  3 21:40:49 2012 +0200

radeon/llvm: add a pattern for fsqrt

Reviewed-by: Tom Stellard <thomas.stell...@amd.com>

---

 src/gallium/drivers/radeon/R600Instructions.td |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/src/gallium/drivers/radeon/R600Instructions.td 
b/src/gallium/drivers/radeon/R600Instructions.td
index 1689a2f..01a5bba 100644
--- a/src/gallium/drivers/radeon/R600Instructions.td
+++ b/src/gallium/drivers/radeon/R600Instructions.td
@@ -1018,6 +1018,9 @@ let Predicates = [isEGorCayman] in {
   def : Pat<(fp_to_uint R600_Reg32:$src),
     (FLT_TO_UINT_eg (TRUNC R600_Reg32:$src))>;
 
+  def : Pat<(fsqrt R600_Reg32:$src),
+    (MUL R600_Reg32:$src, (RECIPSQRT_CLAMPED_eg R600_Reg32:$src))>;
+
 
//===----------------------------------------------------------------------===//
 // Memory read/write instructions
 
//===----------------------------------------------------------------------===//

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to