From 5c45eaf9b3578094c36911cbbd085097642d3b13 Mon Sep 17 00:00:00 2001 From: Karol Herbst Date: Mon, 31 Aug 2020 21:21:02 +0200 Subject: [PATCH] clover/spirv: fix vec3 alignment Signed-off-by: Karol Herbst Reviewed-by: Jason Ekstrand Part-of: --- src/gallium/frontends/clover/spirv/invocation.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/gallium/frontends/clover/spirv/invocation.cpp b/src/gallium/frontends/clover/spirv/invocation.cpp index 489bb62dde9..c3404f38b80 100644 --- a/src/gallium/frontends/clover/spirv/invocation.cpp +++ b/src/gallium/frontends/clover/spirv/invocation.cpp @@ -257,7 +257,8 @@ namespace { const auto elem_size = types_iter->second.size; const auto elem_nbs = get(inst, 3); const auto size = elem_size * elem_nbs; - types[id] = { module::argument::scalar, size, size, size, + const auto align = elem_size * util_next_power_of_two(elem_nbs); + types[id] = { module::argument::scalar, size, size, align, module::argument::zero_ext }; break; } -- 2.30.2