OUT

Attributes and varyings

fixed bit field field the encoding fixes should be

OUT (reg)

6362616059585756555453525150494847464544434241403938373635343332
1111101111100
313029282726252423222120191817161514131211109876543210
Rbpred.notpredRd

bits 63:48: 1111 1011 1110 0---

Runs execute_OUT with Form() 0.

OUT (cbuf)

6362616059585756555453525150494847464544434241403938373635343332
1110101111100cbuf.bankcbuf.offset
313029282726252423222120191817161514131211109876543210
cbuf.offsetpred.notpredRd

bits 63:48: 1110 1011 1110 0---

Runs execute_OUT with Form() 1.

OUT (imm)

6362616059585756555453525150494847464544434241403938373635343332
1111011imm.sign11100imm
313029282726252423222120191817161514131211109876543210
immpred.notpredRd

bits 63:48: 1111 011- 1110 0---

Runs execute_OUT with Form() 2.

Fields

The operation reads some of these fields in some forms alone (it chooses by Form()), so the diagrams show only the decoder's.

FieldBitsFrom
[40]40execute_OUT
[39]39execute_OUT
Rb27:20RegB()
stream021:20execute_OUT
pred.not19the decoder
pred18:16the decoder
Rd7:0Dst()

Operation Sail

OUT: a geometry program's vertex emitted (bit 39) and its primitive cut (bit 40) on the stream that the register at 20, the constant buffer word or the immediate names (its low two bits). Each stream the program uses is a selection of its own; stream 0's vertex is the vertex stages' end (transform feedback, the position's fix, the primitive's number), another's its transform feedback's capture. d becomes the next output's handle, 0

let stream0 = match Form() { 2 => ZeroExtend(Field(20, 2), 32), 1 => CbufWord(), _ => R_read(RegB()) };
let stream = Bits32(stream0) & 0x00000003; /* a word at run time, an immediate's too */
foreach (target from 0 to 3) {
    if target == 0 | MOD(DIV(StreamMask(), 2 ^ target), 2) == 1 then {
        StreamSelect(stream, target);
        if Field(39, 1) == 0b1 then {
            if target == 0 then VertexEnd() else XfbCapture(target);
            EmitVertex(target);
            if HasPointSize(true) & not_bool(PointSizeUsed()) then DefaultPointSize()
        };
        if Field(40, 1) == 0b1 then EndPrimitive(target);
        StreamEnd()
    }
};
R_write(Dst(), 0x00000000)

Made from ScarletNX's Sail at 166ad3910f80. The Sail and the encodings' file are ScarletNX's (GPL-3.0-or-later); its encodings are from Eden's maxwell.inc (GPL-2.0-or-later).