search for: tgsi_opcode_round

Displaying 5 results from an estimated 5 matches for "tgsi_opcode_round".

2014 Nov 18
2
[PATCH] nv50/ir: saturate FRC result to avoid completely bogus values
...src0 = fetchSrc(0, c); val0 = getScratch(); mkOp1(OP_FLOOR, TYPE_F32, val0, src0); - mkOp2(OP_SUB, TYPE_F32, dst0[c], src0, val0); + mkOp2(OP_SUB, TYPE_F32, val0, src0, val0); + mkOp1(OP_SAT, TYPE_F32, dst0[c], val0); } break; case TGSI_OPCODE_ROUND: -- 2.0.4
2014 Nov 18
2
[Mesa-dev] [PATCH] nv50/ir: saturate FRC result to avoid completely bogus values
...;> mkOp1(OP_FLOOR, TYPE_F32, val0, src0); >> - mkOp2(OP_SUB, TYPE_F32, dst0[c], src0, val0); >> + mkOp2(OP_SUB, TYPE_F32, val0, src0, val0); >> + mkOp1(OP_SAT, TYPE_F32, dst0[c], val0); >> } >> break; >> case TGSI_OPCODE_ROUND: >> > > I don't understand the math behind this. For any such large number, as > far as I can tell floor(val) == val and hence the end result ought to be > zero. Or doesn't your floor work like that? I could be thinking about this backwards, but let's say that floats...
2014 Nov 18
1
[Mesa-dev] [PATCH] nv50/ir: saturate FRC result to avoid completely bogus values
...0); >>>> - mkOp2(OP_SUB, TYPE_F32, dst0[c], src0, val0); >>>> + mkOp2(OP_SUB, TYPE_F32, val0, src0, val0); >>>> + mkOp1(OP_SAT, TYPE_F32, dst0[c], val0); >>>> } >>>> break; >>>> case TGSI_OPCODE_ROUND: >>>> >>> >>> I don't understand the math behind this. For any such large number, as >>> far as I can tell floor(val) == val and hence the end result ought to be >>> zero. Or doesn't your floor work like that? >> >> I could be thin...
2014 Nov 18
0
[Mesa-dev] [PATCH] nv50/ir: saturate FRC result to avoid completely bogus values
...val0 = getScratch(); > mkOp1(OP_FLOOR, TYPE_F32, val0, src0); > - mkOp2(OP_SUB, TYPE_F32, dst0[c], src0, val0); > + mkOp2(OP_SUB, TYPE_F32, val0, src0, val0); > + mkOp1(OP_SAT, TYPE_F32, dst0[c], val0); > } > break; > case TGSI_OPCODE_ROUND: > I don't understand the math behind this. For any such large number, as far as I can tell floor(val) == val and hence the end result ought to be zero. Or doesn't your floor work like that? Roland
2014 Nov 18
0
[Mesa-dev] [PATCH] nv50/ir: saturate FRC result to avoid completely bogus values
..._FLOOR, TYPE_F32, val0, src0); >>> - mkOp2(OP_SUB, TYPE_F32, dst0[c], src0, val0); >>> + mkOp2(OP_SUB, TYPE_F32, val0, src0, val0); >>> + mkOp1(OP_SAT, TYPE_F32, dst0[c], val0); >>> } >>> break; >>> case TGSI_OPCODE_ROUND: >>> >> >> I don't understand the math behind this. For any such large number, as >> far as I can tell floor(val) == val and hence the end result ought to be >> zero. Or doesn't your floor work like that? > > I could be thinking about this backwards,...