diff options
Diffstat (limited to 'rtl/legacy_gfx/gfx_sp_swizzle.sv')
| -rw-r--r-- | rtl/legacy_gfx/gfx_sp_swizzle.sv | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/rtl/legacy_gfx/gfx_sp_swizzle.sv b/rtl/legacy_gfx/gfx_sp_swizzle.sv new file mode 100644 index 0000000..d07d934 --- /dev/null +++ b/rtl/legacy_gfx/gfx_sp_swizzle.sv @@ -0,0 +1,19 @@ +`include "gfx/gfx_defs.sv" + +module gfx_sp_swizzle +( + input logic clk, + + input vec4 in, + input shuffler_deco deco, + input logic stall, + + output vec4 out +); + + always_ff @(posedge clk) + if (!stall) + for (integer i = 0; i < `FLOATS_PER_VEC; ++i) + out[i] <= in[deco.swizzle_op[i]]; + +endmodule |
