summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/vc5/vc5_state.c
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2018-01-21 10:25:10 +0800
committerEric Anholt <[email protected]>2018-02-01 11:02:29 -0800
commit5329f35ea12fe70e9eff131b60979b810cbc5028 (patch)
tree36d5c6a330b1e20b0c3a269698ffaeb1818362b2 /src/gallium/drivers/vc5/vc5_state.c
parentdea902c93352b875178fef9b8a65fd53e52696b3 (diff)
broadcom/vc5: Add appropriate height padding for bank conflicts.
I thought I didn't need this because I was doing level-0-always-UIF and that the pad there would propagate down, but it turns out that for level 1 the padding ends up being chosen by the HW. This brings us closer to being able to turn on UIF XOR for increased performance, as well.
Diffstat (limited to 'src/gallium/drivers/vc5/vc5_state.c')
-rw-r--r--src/gallium/drivers/vc5/vc5_state.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/vc5/vc5_state.c b/src/gallium/drivers/vc5/vc5_state.c
index ea867279a06..a055d252b65 100644
--- a/src/gallium/drivers/vc5/vc5_state.c
+++ b/src/gallium/drivers/vc5/vc5_state.c
@@ -31,6 +31,7 @@
#include "util/u_helpers.h"
#include "vc5_context.h"
+#include "vc5_tiling.h"
#include "broadcom/common/v3d_macros.h"
#include "broadcom/cle/v3dx_pack.h"
@@ -787,6 +788,9 @@ vc5_create_sampler_view(struct pipe_context *pctx, struct pipe_resource *prsc,
tex.level_0_xor_enable = (rsc->slices[0].tiling ==
VC5_TILING_UIF_XOR);
+ if (tex.level_0_is_strictly_uif)
+ tex.level_0_ub_pad = rsc->slices[0].ub_pad;
+
#if V3D_VERSION >= 40
if (tex.uif_xor_disable ||
tex.level_0_is_strictly_uif) {