diff options
author | Christoph Bumiller <[email protected]> | 2011-03-05 14:41:08 +0100 |
---|---|---|
committer | Christoph Bumiller <[email protected]> | 2011-03-05 14:53:23 +0100 |
commit | 533bf171d4c926e4ab6fcd0d51396b195b9e024f (patch) | |
tree | ad27eee423151586b3573668d1af172be0eff3b4 /src/gallium/drivers/nv50/nv50_tgsi_to_nc.c | |
parent | 17b9b757b704e0dcf370f7ae6e72c6e22601363d (diff) |
nv50: support the InstanceID system value
Diffstat (limited to 'src/gallium/drivers/nv50/nv50_tgsi_to_nc.c')
-rw-r--r-- | src/gallium/drivers/nv50/nv50_tgsi_to_nc.c | 7 |
1 files changed, 7 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 54b78e850ed..1449cb04c69 100644 --- a/src/gallium/drivers/nv50/nv50_tgsi_to_nc.c +++ b/src/gallium/drivers/nv50/nv50_tgsi_to_nc.c @@ -1159,6 +1159,13 @@ emit_fetch(struct bld_context *bld, const struct tgsi_full_instruction *insn, case TGSI_FILE_PREDICATE: res = bld_fetch_global(bld, &bld->pvs[idx][swz]); break; + case TGSI_FILE_SYSTEM_VALUE: + res = new_value(bld->pc, bld->ti->input_file, NV_TYPE_U32); + res->reg.id = bld->ti->sysval_map[idx]; + res = bld_insn_1(bld, NV_OP_LDA, res); + res = bld_insn_1(bld, NV_OP_CVT, res); + res->reg.type = NV_TYPE_F32; + break; default: NOUVEAU_ERR("illegal/unhandled src reg file: %d\n", src->Register.File); abort(); |