summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/nv50/nv50_tgsi_to_nc.c
diff options
context:
space:
mode:
authorChristoph Bumiller <e0425955@student.tuwien.ac.at>2010-07-27 18:25:37 +0200
committerChristoph Bumiller <e0425955@student.tuwien.ac.at>2010-07-31 18:32:35 +0200
commit5705b45b6a050f908120779e6049853931a8025a (patch)
treedd283adcd77ca46124c53fbe889978729050231e /src/gallium/drivers/nv50/nv50_tgsi_to_nc.c
parent5de5e4fd5c7c6d55e9b3aadbaae0ca34e2662e2c (diff)
nv50: explicitly set src type for SET ops
Need to do this more nicely for all ops.
Diffstat (limited to 'src/gallium/drivers/nv50/nv50_tgsi_to_nc.c')
-rw-r--r--src/gallium/drivers/nv50/nv50_tgsi_to_nc.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gallium/drivers/nv50/nv50_tgsi_to_nc.c b/src/gallium/drivers/nv50/nv50_tgsi_to_nc.c
index da7fe746f4..aafb5e8295 100644
--- a/src/gallium/drivers/nv50/nv50_tgsi_to_nc.c
+++ b/src/gallium/drivers/nv50/nv50_tgsi_to_nc.c
@@ -20,6 +20,8 @@
* SOFTWARE.
*/
+/* XXX: need to clean this up so we get the typecasting right more naturally */
+
#include <unistd.h>
#include "nv50_context.h"
@@ -1173,6 +1175,10 @@ bld_instruction(struct bld_context *bld,
dst0[c]->insn->set_cond = translate_setcc(insn->Instruction.Opcode);
dst0[c]->reg.type = infer_dst_type(insn->Instruction.Opcode);
+ dst0[c]->insn->src[0]->typecast =
+ dst0[c]->insn->src[1]->typecast =
+ infer_src_type(insn->Instruction.Opcode);
+
if (dst0[c]->reg.type != NV_TYPE_F32)
break;
dst0[c] = bld_insn_1(bld, NV_OP_ABS, dst0[c]);