radv: assert that the arg is declared when used in get_scalar_arg()

Help debugging.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15789>
This commit is contained in:
Samuel Pitoiset
2022-04-07 11:47:45 +02:00
committed by Marge Bot
parent a0f3839ce8
commit ace073eb0b
@@ -42,6 +42,7 @@ typedef struct {
static nir_ssa_def *
get_scalar_arg(nir_builder *b, unsigned size, struct ac_arg arg)
{
assert(arg.used);
return nir_load_scalar_arg_amd(b, size, .base = arg.arg_index);
}