aboutsummaryrefslogtreecommitdiffstats
path: root/src/freedreno/ir3/ir3_context.c
diff options
context:
space:
mode:
authorKristian H. Kristensen <[email protected]>2019-03-26 10:31:54 -0700
committerKristian H. Kristensen <[email protected]>2019-03-27 13:26:02 -0700
commit893425a607a63a83e8a4c13fd963367c8d174678 (patch)
tree8854bd3625f9fbf5706dbd934f7c9f3f8fe37ded /src/freedreno/ir3/ir3_context.c
parent3c8779af325965a6c200b14ab4cc44c8f0b835e8 (diff)
freedreno/ir3: Push UBOs to constant file
We have a rather big constant file and it seems that the best way to use it is to upload all UBOs and lower UBO access the load_uniform. Signed-off-by: Kristian H. Kristensen <[email protected]> Reviewed-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/freedreno/ir3/ir3_context.c')
-rw-r--r--src/freedreno/ir3/ir3_context.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/freedreno/ir3/ir3_context.c b/src/freedreno/ir3/ir3_context.c
index 7c35b9ba65f..d6267165ec7 100644
--- a/src/freedreno/ir3/ir3_context.c
+++ b/src/freedreno/ir3/ir3_context.c
@@ -124,7 +124,7 @@ ir3_context_init(struct ir3_compiler *compiler,
* Immediates go last mostly because they are inserted in the CP pass
* after the nir -> ir3 frontend.
*/
- unsigned constoff = align(ctx->s->num_uniforms, 4);
+ unsigned constoff = align(ctx->so->shader->ubo_state.size / 16, 4);
unsigned ptrsz = ir3_pointer_size(ctx);
memset(&so->constbase, ~0, sizeof(so->constbase));