Commit 76cea8e2 authored by Icecream95's avatar Icecream95 Committed by Marge Bot
Browse files

panfrost: Fix pack_32_2x16 implementation

Fixes: 6f0eff54 ("pan/bi: Implement packing ops between 32-bit vec1 and 16-bit vec2")
Part-of: <mesa/mesa!16181>
parent 92e5eee3
Pipeline #570992 waiting for manual action with stages
......@@ -1982,7 +1982,6 @@ bi_emit_alu(bi_builder *b, nir_alu_instr *instr)
* are the exceptions that need to handle swizzles specially. */
switch (instr->op) {
case nir_op_pack_32_2x16:
case nir_op_vec2:
case nir_op_vec3:
case nir_op_vec4: {
......@@ -2047,7 +2046,10 @@ bi_emit_alu(bi_builder *b, nir_alu_instr *instr)
return;
}
case nir_op_mov: {
case nir_op_mov:
case nir_op_pack_32_2x16: {
unsigned src_comps = nir_src_num_components(instr->src[0].src);
bi_index idx = bi_src_index(&instr->src[0].src);
bi_index unoffset_srcs[4] = { idx, idx, idx, idx };
......@@ -2058,8 +2060,8 @@ bi_emit_alu(bi_builder *b, nir_alu_instr *instr)
comps > 3 ? instr->src[0].swizzle[3] : 0,
};
if (sz == 1) sz = 16;
bi_make_vec_to(b, dst, unoffset_srcs, channels, comps, sz);
if (src_sz == 1) src_sz = 16;
bi_make_vec_to(b, dst, unoffset_srcs, channels, src_comps, src_sz);
return;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment