agx: Make signal_pix instructions explicit
Rather than implicitly packing them with the sample_mask. Again, this is just changing where they're emitted, no functional changes yet. Bug for bug compatibility with the old behaviour. Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22353>
This commit is contained in:

committed by
Marge Bot

parent
bb530760a2
commit
8a6d74d15b
@@ -423,6 +423,7 @@ agx_write_sample_mask_1(agx_builder *b)
|
||||
* TODO: interactions with MSAA and gl_SampleMask writes
|
||||
*/
|
||||
agx_sample_mask(b, agx_immediate(1));
|
||||
agx_signal_pix(b, 1);
|
||||
b->shader->did_sample_mask = true;
|
||||
|
||||
assert(!(b->shader->nir->info.outputs_written &
|
||||
@@ -668,7 +669,8 @@ agx_emit_discard(agx_builder *b)
|
||||
b->shader->did_writeout = true;
|
||||
|
||||
b->shader->out->writes_sample_mask = true;
|
||||
return agx_sample_mask(b, agx_immediate(0));
|
||||
agx_sample_mask(b, agx_immediate(0));
|
||||
return agx_signal_pix(b, 1);
|
||||
}
|
||||
|
||||
static agx_instr *
|
||||
|
@@ -329,6 +329,7 @@ op("no_varyings", (0x80000051, 0xFFFFFFFF, 4, _), dests = 0, can_eliminate = Fal
|
||||
op("stop", (0x88, 0xFFFF, 2, _), dests = 0, can_eliminate = False)
|
||||
op("trap", (0x08, 0xFFFF, 2, _), dests = 0, can_eliminate = False)
|
||||
op("wait_pix", (0x48, 0xFF, 4, _), dests = 0, imms = [WRITEOUT], can_eliminate = False)
|
||||
op("signal_pix", (0x58, 0xFF, 4, _), dests = 0, imms = [WRITEOUT], can_eliminate = False)
|
||||
|
||||
# Sources are the image and the offset within shared memory
|
||||
# TODO: Do we need the short encoding?
|
||||
|
@@ -508,19 +508,6 @@ agx_pack_instr(struct util_dynarray *emission, struct util_dynarray *fixups,
|
||||
|
||||
unsigned size = 4;
|
||||
memcpy(util_dynarray_grow_bytes(emission, 1, size), &raw, size);
|
||||
|
||||
{
|
||||
/* This is actually a separate instruction.
|
||||
*
|
||||
* signal_pix 1, 0
|
||||
*
|
||||
* We don't model this correctly yet, but we should.
|
||||
*/
|
||||
uint32_t raw = 0x158;
|
||||
unsigned size = 4;
|
||||
memcpy(util_dynarray_grow_bytes(emission, 1, size), &raw, size);
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user