Fix GCC unused-function warning. nv30/nvfx_fragprog.c:333:1: warning: ‘nv40_fp_bra’ defined but not used [-Wunused-function] nv40_fp_bra(struct nvfx_fpc *fpc, unsigned target) ^
Signed-off-by: Vinson Lee <v...@freedesktop.org> --- src/gallium/drivers/nouveau/nv30/nvfx_fragprog.c | 26 ------------------------ 1 file changed, 26 deletions(-) diff --git a/src/gallium/drivers/nouveau/nv30/nvfx_fragprog.c b/src/gallium/drivers/nouveau/nv30/nvfx_fragprog.c index 6600997..e843ab8 100644 --- a/src/gallium/drivers/nouveau/nv30/nvfx_fragprog.c +++ b/src/gallium/drivers/nouveau/nv30/nvfx_fragprog.c @@ -328,32 +328,6 @@ nv40_fp_rep(struct nvfx_fpc *fpc, unsigned count, unsigned target) //util_dynarray_append(&fpc->loop_stack, unsigned, target); } -/* warning: this only works forward, and probably only if not inside any IF */ -static void -nv40_fp_bra(struct nvfx_fpc *fpc, unsigned target) -{ - struct nvfx_relocation reloc; - uint32_t *hw; - fpc->inst_offset = fpc->fp->insn_len; - grow_insns(fpc, 4); - hw = &fpc->fp->insn[fpc->inst_offset]; - /* I really wonder why fp16 precision is used. Presumably the hardware ignores it? */ - hw[0] = (NV40_FP_OP_BRA_OPCODE_IF << NVFX_FP_OP_OPCODE_SHIFT) | - NV40_FP_OP_OUT_NONE | - (NVFX_FP_PRECISION_FP16 << NVFX_FP_OP_PRECISION_SHIFT); - /* Use .xxxx swizzle so that we check only src[0].x*/ - hw[1] = (NVFX_SWZ_IDENTITY << NVFX_FP_OP_COND_SWZ_X_SHIFT) | - (NVFX_FP_OP_COND_FL << NVFX_FP_OP_COND_SHIFT); - hw[2] = NV40_FP_OP_OPCODE_IS_BRANCH; /* | else_offset */ - hw[3] = 0; /* | endif_offset */ - reloc.target = target; - reloc.location = fpc->inst_offset + 2; - util_dynarray_append(&fpc->label_relocs, struct nvfx_relocation, reloc); - reloc.target = target; - reloc.location = fpc->inst_offset + 3; - util_dynarray_append(&fpc->label_relocs, struct nvfx_relocation, reloc); -} - static void nv40_fp_brk(struct nvfx_fpc *fpc) { -- 2.3.1 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev