search for: tgsi_dst

Displaying 4 results from an estimated 4 matches for "tgsi_dst".

2009 Sep 10
0
[PATCH 02/13] nv50: add functions for swizzle resolution
...TGSI_OPCODE_KIL: + case TGSI_OPCODE_LIT: case TGSI_OPCODE_SCS: case TGSI_OPCODE_SIN: + */ + return TRUE; + default: + return FALSE; + } +} + +/* Returns a bitmask indicating which dst components depend + * on source s, component c (reverse of nv50_tgsi_src_mask). + */ +static unsigned +nv50_tgsi_dst_revdep(unsigned op, int s, int c) +{ + if (is_scalar_op(op)) + return 0x1; + + switch (op) { + case TGSI_OPCODE_DST: + return (1 << c) & (s ? 0xa : 0x6); + case TGSI_OPCODE_XPD: + switch (c) { + case 0: return 0x6; + case 1: return 0x5; + case 2: return 0x3; + case 3: return 0x0; +...
2009 Sep 10
0
[PATCH 01/13] nv50: extend insn src mask function
...E_2D: + mask &= 0xb; + break; + default: + break; + } + } + return mask; + case TGSI_OPCODE_XPD: + x = 0; + if (mask & 1) x |= 0x6; + if (mask & 2) x |= 0x5; + if (mask & 4) x |= 0x3; + return x; + default: + break; + } + + return mask; +} + static struct nv50_reg * tgsi_dst(struct nv50_pc *pc, int c, const struct tgsi_full_dst_register *dst) { @@ -1310,13 +1374,18 @@ nv50_program_tx_insn(struct nv50_pc *pc, const union tgsi_full_token *tok) for (i = 0; i < inst->Instruction.NumSrcRegs; i++) { const struct tgsi_full_src_register *fs = &inst->FullSr...
2009 Jun 21
0
[PATCH] nv50: better insn generation
...lean assimilate = FALSE; - int i, c; + int i, c, nr_dst = 0; mask = inst->FullDstRegisters[0].DstRegister.WriteMask; sat = inst->Instruction.Saturate == TGSI_SAT_ZERO_ONE; for (c = 0; c < 4; c++) { - if (mask & (1 << c)) + if (mask & (1 << c)) { dst[c] = tgsi_dst(pc, c, &inst->FullDstRegisters[0]); - else + ++nr_dst; + } else dst[c] = NULL; rdst[c] = NULL; src[0][c] = NULL; @@ -1313,8 +1315,13 @@ nv50_program_tx_insn(struct nv50_pc *pc, const union tgsi_full_token *tok) src[2][c] = NULL; } + pp_rtmp = &dst[ffs(mask) - 1]; + i...
2009 May 06
2
nv50: shader generation patches
Hi ! I've been trying to improve NV50 shader generation a bit the last couple of weeks, so here is what I've produced. I don't know if it's usable for you or just a pile of horrible hacks, but at least it makes some mesa demos render more correcly, p.e. the teapot (aside from mip-mapping issues of the floor texture), arbfplight, and I think the gears also didn't appear as they