Bug 66858

Summary: Missing definition for NVFX_FP_OP_OPCODE_KILL_IF
Product: Mesa Reporter: Andrew Dunai <andunai>
Component: OtherAssignee: mesa-dev
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: medium    
Version: git   
Hardware: x86-64 (AMD64)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:

Description Andrew Dunai 2013-07-12 15:04:05 UTC
I could not compile ./src/gallium/drivers/nv30/nvfx_fragprog.c because it contained undefined constant `NVFX_FP_OP_OPCODE_KILL_IF`.

According to this newsletter - http://www.mail-archive.com/mesa-dev@lists.freedesktop.org/msg41057.html - it is new name for `NVFX_FP_OP_OPCODE_KIL`.
So I added new define with the value of NVFX_FP_OP_OPCODE_KIL:

#define NVFX_FP_OP_OPCODE_KILL_IF 0x12

To file `./src/gallium/drivers/nv30/nvfx_shader.h`. After this everything went normal.
Comment 1 Brian Paul 2013-07-12 15:16:34 UTC
That's my fault.  But I believe this is the correct fix (undo the change to that line):

--- a/src/gallium/drivers/nv30/nvfx_fragprog.c
+++ b/src/gallium/drivers/nv30/nvfx_fragprog.c
@@ -197,7 +197,7 @@ nvfx_fp_emit(struct nvfx_fpc *fpc, struct nvfx_insn insn)
    hw = &fp->insn[fpc->inst_offset];
    memset(hw, 0, sizeof(uint32_t) * 4);
 
-   if (insn.op == NVFX_FP_OP_OPCODE_KILL_IF)
+   if (insn.op == NVFX_FP_OP_OPCODE_KIL)
       fp->fp_control |= NV30_3D_FP_CONTROL_USES_KIL;
    hw[0] |= (insn.op << NVFX_FP_OP_OPCODE_SHIFT);
    hw[0] |= (insn.mask << NVFX_FP_OP_OUTMASK_SHIFT);


Can you test that?
Comment 2 Andrew Dunai 2013-07-12 15:54:17 UTC
Confirmed. I'm closing the ticket. Great job on developing 9.2, good luck!

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.