diff options
author | Rob Clark <[email protected]> | 2019-05-06 14:52:27 -0700 |
---|---|---|
committer | Rob Clark <[email protected]> | 2019-05-07 07:26:00 -0700 |
commit | 23e7a34466c448c4c7c9a2c2e4d200dedf2584f7 (patch) | |
tree | 9feaa00be35bce3642c01a29588956ae237c6b09 /src/freedreno/ir3/ir3_a4xx.c | |
parent | ef3eecd66bdcaa3991dd2b53cb3e7285bed6d718 (diff) |
freedreno/ir3: consolidate const state
Combine the offsets of differenet parts of the constant space with (what
was formerly known as) ir3_driver_const_layout. Bunch of churn, but no
functional change.
Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/freedreno/ir3/ir3_a4xx.c')
-rw-r--r-- | src/freedreno/ir3/ir3_a4xx.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/freedreno/ir3/ir3_a4xx.c b/src/freedreno/ir3/ir3_a4xx.c index 426a143acfb..5fe15cf8e27 100644 --- a/src/freedreno/ir3/ir3_a4xx.c +++ b/src/freedreno/ir3/ir3_a4xx.c @@ -217,10 +217,11 @@ get_image_offset(struct ir3_context *ctx, const nir_variable *var, /* to calculate the byte offset (yes, uggg) we need (up to) three * const values to know the bytes per pixel, and y and z stride: */ - unsigned cb = regid(ctx->so->constbase.image_dims, 0) + - ctx->so->const_layout.image_dims.off[var->data.driver_location]; + struct ir3_const_state *const_state = &ctx->so->const_state; + unsigned cb = regid(const_state->offsets.image_dims, 0) + + const_state->image_dims.off[var->data.driver_location]; - debug_assert(ctx->so->const_layout.image_dims.mask & + debug_assert(const_state->image_dims.mask & (1 << var->data.driver_location)); /* offset = coords.x * bytes_per_pixel: */ |