diff options
author | Ilia Mirkin <[email protected]> | 2016-05-07 16:14:01 -0400 |
---|---|---|
committer | Ilia Mirkin <[email protected]> | 2016-05-11 20:39:26 -0400 |
commit | f5fe9030021af830e6c4453f4ad1521cbb697c81 (patch) | |
tree | a72b5f07df3b79ba860f1b86ed91890695da7bb3 /src/gallium/drivers/nouveau/nvc0 | |
parent | 66a442687f72ccf92ce50bb414565cb80ed2ab53 (diff) |
nv50/ir: generalize interp fixups to be able to fixup anything
Signed-off-by: Ilia Mirkin <[email protected]>
Diffstat (limited to 'src/gallium/drivers/nouveau/nvc0')
-rw-r--r-- | src/gallium/drivers/nouveau/nvc0/nvc0_program.c | 12 | ||||
-rw-r--r-- | src/gallium/drivers/nouveau/nvc0/nvc0_program.h | 2 |
2 files changed, 7 insertions, 7 deletions
diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_program.c b/src/gallium/drivers/nouveau/nvc0/nvc0_program.c index ca6349cb09e..944efa042bf 100644 --- a/src/gallium/drivers/nouveau/nvc0/nvc0_program.c +++ b/src/gallium/drivers/nouveau/nvc0/nvc0_program.c @@ -593,7 +593,7 @@ nvc0_program_translate(struct nvc0_program *prog, uint16_t chipset, prog->immd_data = info->immd.buf; prog->immd_size = info->immd.bufSize; prog->relocs = info->bin.relocData; - prog->interps = info->bin.interpData; + prog->fixups = info->bin.fixupData; prog->num_gprs = MAX2(4, (info->bin.maxGPR + 1)); prog->num_barriers = info->numBarriers; @@ -740,10 +740,10 @@ nvc0_program_upload_code(struct nvc0_context *nvc0, struct nvc0_program *prog) if (prog->relocs) nv50_ir_relocate_code(prog->relocs, prog->code, code_pos, lib_pos, 0); - if (prog->interps) { - nv50_ir_change_interp(prog->interps, prog->code, - prog->fp.force_persample_interp, - prog->fp.flatshade); + if (prog->fixups) { + nv50_ir_apply_fixups(prog->fixups, prog->code, + prog->fp.force_persample_interp, + prog->fp.flatshade); for (int i = 0; i < 2; i++) { unsigned mask = prog->fp.color_interp[i] >> 4; unsigned interp = prog->fp.color_interp[i] & 3; @@ -817,7 +817,7 @@ nvc0_program_destroy(struct nvc0_context *nvc0, struct nvc0_program *prog) FREE(prog->code); /* may be 0 for hardcoded shaders */ FREE(prog->immd_data); FREE(prog->relocs); - FREE(prog->interps); + FREE(prog->fixups); if (prog->type == PIPE_SHADER_COMPUTE && prog->cp.syms) FREE(prog->cp.syms); if (prog->tfb) { diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_program.h b/src/gallium/drivers/nouveau/nvc0/nvc0_program.h index 8b8d221edfc..bd852e27c36 100644 --- a/src/gallium/drivers/nouveau/nvc0/nvc0_program.h +++ b/src/gallium/drivers/nouveau/nvc0/nvc0_program.h @@ -64,7 +64,7 @@ struct nvc0_program { uint8_t num_barriers; void *relocs; - void *interps; + void *fixups; struct nvc0_transform_feedback_state *tfb; |