diff options
author | Dave Airlie <[email protected]> | 2018-05-15 11:11:12 +1000 |
---|---|---|
committer | Dave Airlie <[email protected]> | 2018-06-04 05:58:42 +1000 |
commit | 67eccd6aa2b3fcc79a232479a58a0f52b9980001 (patch) | |
tree | cd41a0003b34a046726fa2e20dd84517d5aeef0a /src/compiler/nir/nir_print.c | |
parent | bad7332f7c6c2e5922ddca854a7b497b22c31682 (diff) |
nir: use num_components wrappers in print/validate.
These wrappers were introduces, so start using them.
Reviewed-by: Jason Ekstrand <[email protected]>
Diffstat (limited to 'src/compiler/nir/nir_print.c')
-rw-r--r-- | src/compiler/nir/nir_print.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/compiler/nir/nir_print.c b/src/compiler/nir/nir_print.c index fad274e62f6..7c3e93eb82a 100644 --- a/src/compiler/nir/nir_print.c +++ b/src/compiler/nir/nir_print.c @@ -199,9 +199,7 @@ print_alu_src(nir_alu_instr *instr, unsigned src, print_state *state) } } - unsigned live_channels = instr->src[src].src.is_ssa - ? instr->src[src].src.ssa->num_components - : instr->src[src].src.reg.reg->num_components; + unsigned live_channels = nir_src_num_components(instr->src[src].src); if (print_swizzle || used_channels != live_channels) { fprintf(fp, "."); |