brw: Validate that send payloads can't be imms or have source mods
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run

To ensure we haven't missed resolving these things.

Reviewed-by: Caio Oliveira <caio.oliveira@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34040>
This commit is contained in:
Kenneth Graunke 2025-08-05 23:14:20 -07:00 committed by Marge Bot
parent 22165defb5
commit 5e9de5317e

View file

@ -316,8 +316,15 @@ brw_validate(const brw_shader &s)
fsv_assert(inst->sources == SEND_NUM_SRCS);
fsv_assert(is_uniform(inst->src[SEND_SRC_DESC]));
fsv_assert(is_uniform(inst->src[SEND_SRC_EX_DESC]));
fsv_assert(inst->src[SEND_SRC_PAYLOAD1].file != BAD_FILE);
fsv_assert(inst->ex_mlen > 0 ||
inst->src[SEND_SRC_PAYLOAD2].file == BAD_FILE);
/* Send payloads cannot be immediates nor have source modifiers */
for (unsigned i = 0; i < 2; i++) {
fsv_assert(inst->src[SEND_SRC_PAYLOAD1 + i].file != IMM);
fsv_assert(!inst->src[SEND_SRC_PAYLOAD1 + i].abs);
fsv_assert(!inst->src[SEND_SRC_PAYLOAD1 + i].negate);
}
break;
case SHADER_OPCODE_SEND_GATHER: