search for: op_txf

Displaying 11 results from an estimated 11 matches for "op_txf".

2015 Jan 11
2
[PATCH v2] nv50/ir: Handle OP_CVT when folding constant expressions
...'t hugely care >>> though. >> Actually i can't remember why that was added in the first place, i'll go >> ahead and follow your advice here. > Oh wait... this was to support saturating an array access into a u16... > > const int sat = (i->op == OP_TXF) ? 1 : 0; > DataType sTy = (i->op == OP_TXF) ? TYPE_U32 : TYPE_F32; > bld.mkCvt(OP_CVT, TYPE_U16, layer, sTy, src)->saturate = sat; > > So... basically if the source is a U32 and the dest is a U16, we want > to saturate there? IMO this is such a minor use-ca...
2014 Apr 04
2
[PATCH 1/2] nvc0: add support for texture gather
...c/gallium/drivers/nouveau/codegen/nv50_ir_emit_gk110.cpp index b716d54..a4b50ee 100644 --- a/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gk110.cpp +++ b/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gk110.cpp @@ -984,6 +984,9 @@ CodeEmitterGK110::emitTEX(const TexInstruction *i) case OP_TXF: code[1] = 0x78000000; break; + case OP_TXG: + code[1] = 0x7dc00000; + break; default: code[1] = 0x7d800000; break; @@ -1005,6 +1008,11 @@ CodeEmitterGK110::emitTEX(const TexInstruction *i) code[1] = 0x70000000;...
2015 Jan 11
2
[PATCH v2] nv50/ir: Handle OP_CVT when folding constant expressions
On 11.01.2015 01:58, Ilia Mirkin wrote: > On Fri, Jan 9, 2015 at 8:24 PM, Tobias Klausmann > <tobias.johannes.klausmann at mni.thm.de> wrote: >> Folding for conversions: F32->(U{16/32}, S{16/32}) and (U{16/32}, {S16/32})->F32 >> >> Signed-off-by: Tobias Klausmann <tobias.johannes.klausmann at mni.thm.de> >> --- >> V2: beat me, whip me, split
2015 Jan 11
0
[PATCH v2] nv50/ir: Handle OP_CVT when folding constant expressions
...turates or not. I don't hugely care >> though. > > Actually i can't remember why that was added in the first place, i'll go > ahead and follow your advice here. Oh wait... this was to support saturating an array access into a u16... const int sat = (i->op == OP_TXF) ? 1 : 0; DataType sTy = (i->op == OP_TXF) ? TYPE_U32 : TYPE_F32; bld.mkCvt(OP_CVT, TYPE_U16, layer, sTy, src)->saturate = sat; So... basically if the source is a U32 and the dest is a U16, we want to saturate there? IMO this is such a minor use-case that it doesn't rea...
2015 Jan 11
0
[PATCH v2] nv50/ir: Handle OP_CVT when folding constant expressions
...t;>> >>> Actually i can't remember why that was added in the first place, i'll go >>> ahead and follow your advice here. >> >> Oh wait... this was to support saturating an array access into a u16... >> >> const int sat = (i->op == OP_TXF) ? 1 : 0; >> DataType sTy = (i->op == OP_TXF) ? TYPE_U32 : TYPE_F32; >> bld.mkCvt(OP_CVT, TYPE_U16, layer, sTy, src)->saturate = sat; >> >> So... basically if the source is a U32 and the dest is a U16, we want >> to saturate there? IMO this is...
2014 Sep 25
0
[PATCH] gm107/ir: fix texture argument order
...handle + // coords + // array + offsets + // derivatives if (chipset >= NVISA_GK104_CHIPSET) { if (i->tex.rIndirectSrc >= 0 || i->tex.sIndirectSrc >= 0) { @@ -634,12 +649,17 @@ NVC0LoweringPass::handleTEX(TexInstruction *i) const int sat = (i->op == OP_TXF) ? 1 : 0; DataType sTy = (i->op == OP_TXF) ? TYPE_U32 : TYPE_F32; bld.mkCvt(OP_CVT, TYPE_U16, layer, sTy, src)->saturate = sat; - for (int s = dim; s >= 1; --s) - i->setSrc(s, i->getSrc(s - 1)); - i->setSrc(0, layer); + if (i-...
2015 Jan 11
2
[PATCH v2] nv50/ir: Handle OP_CVT when folding constant expressions
...gt;>>> Actually i can't remember why that was added in the first place, i'll go >>>> ahead and follow your advice here. >>> Oh wait... this was to support saturating an array access into a u16... >>> >>> const int sat = (i->op == OP_TXF) ? 1 : 0; >>> DataType sTy = (i->op == OP_TXF) ? TYPE_U32 : TYPE_F32; >>> bld.mkCvt(OP_CVT, TYPE_U16, layer, sTy, src)->saturate = sat; >>> >>> So... basically if the source is a U32 and the dest is a U16, we want >>> to satur...
2013 Dec 08
0
[PATCH] nv50: TXF already has integer arguments, don't try to convert from f32
...rget.isArray()) { - Value *layer = i->getSrc(arg - 1); - LValue *src = new_LValue(func, FILE_GPR); - bld.mkCvt(OP_CVT, TYPE_U32, src, TYPE_F32, layer); - bld.mkOp2(OP_MIN, TYPE_U32, src, src, bld.loadImm(NULL, 511)); - i->setSrc(arg - 1, src); - + if (i->op != OP_TXF) { + // array index must be converted to u32, but it's already an integer + // for TXF + Value *layer = i->getSrc(arg - 1); + LValue *src = new_LValue(func, FILE_GPR); + bld.mkCvt(OP_CVT, TYPE_U32, src, TYPE_F32, layer); + bld.mkOp2(OP_MIN, TYP...
2014 Feb 20
0
[PATCH] nv50: enable txg where supported
...on *i) code[0] |= 0x01000000; break; case OP_TXG: - code[0] = 0x01000000; + code[0] |= 0x01000000; code[1] = 0x80000000; break; default: @@ -1790,6 +1790,7 @@ CodeEmitterNV50::emitInstruction(Instruction *insn) case OP_TXB: case OP_TXL: case OP_TXF: + case OP_TXG: emitTEX(insn->asTex()); break; case OP_TXQ: diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp index d226d0c..ccddb9a 100644 --- a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_...
2014 Feb 28
0
[PATCH] nv50: enable texture query lod
...0] = 0x01000000; code[1] = 0x80000000; break; + case OP_TXLQ: + code[1] = 0x60020000; + break; default: assert(i->op == OP_TEX); break; @@ -1790,6 +1793,7 @@ CodeEmitterNV50::emitInstruction(Instruction *insn) case OP_TXB: case OP_TXL: case OP_TXF: + case OP_TXLQ: emitTEX(insn->asTex()); break; case OP_TXQ: diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp index d226d0c..10ec8c6 100644 --- a/src/gallium/drivers/nouveau/codegen/nv50_ir_from...
2015 Jan 11
2
[PATCH] nv50/ir: Handle OP_CVT when folding constant expressions
On Sun, Jan 11, 2015 at 5:48 PM, Tobias Klausmann <tobias.johannes.klausmann at mni.thm.de> wrote: > > > On 11.01.2015 23:12, Ilia Mirkin wrote: >> >> On Sun, Jan 11, 2015 at 5:08 PM, Tobias Klausmann >> <tobias.johannes.klausmann at mni.thm.de> wrote: >>> >>> >>> On 11.01.2015 22:54, Ilia Mirkin wrote: >>>>