Mesa (master): nv50/ir/gk110: add postfactor support for fmul

Ilia Mirkin imirkin at kemper.freedesktop.org
Tue Mar 18 09:58:23 UTC 2014


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

Author: Ilia Mirkin <imirkin at alum.mit.edu>
Date:   Sat Mar 15 12:42:51 2014 -0400

nv50/ir/gk110: add postfactor support for fmul

Signed-off-by: Ilia Mirkin <imirkin at alum.mit.edu>

---

 src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gk110.cpp |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gk110.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gk110.cpp
index 81134a2..584ae4c 100644
--- a/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gk110.cpp
+++ b/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gk110.cpp
@@ -489,6 +489,8 @@ CodeEmitterGK110::emitFMUL(const Instruction *i)
       assert(i->postFactor == 0);
    } else {
       emitForm_21(i, 0x234, 0xc34);
+      code[1] |= ((i->postFactor > 0) ?
+                  (7 - i->postFactor) : (0 - i->postFactor)) << 12;
 
       RND_(2a, F);
       FTZ_(2f);




More information about the mesa-commit mailing list