diff --git a/libs/vkd3d-shader/hlsl_codegen.c b/libs/vkd3d-shader/hlsl_codegen.c index 51067960..27f16af5 100644 --- a/libs/vkd3d-shader/hlsl_codegen.c +++ b/libs/vkd3d-shader/hlsl_codegen.c @@ -5412,6 +5412,9 @@ void hlsl_run_const_passes(struct hlsl_ctx *ctx, struct hlsl_block *body) { bool progress; + lower_ir(ctx, lower_matrix_swizzles, body); + lower_ir(ctx, lower_index_loads, body); + lower_ir(ctx, lower_broadcasts, body); while (hlsl_transform_ir(ctx, fold_redundant_casts, body, NULL)); do diff --git a/tests/hlsl/array-size-expr.shader_test b/tests/hlsl/array-size-expr.shader_test index 366e25d5..0c9457ee 100644 --- a/tests/hlsl/array-size-expr.shader_test +++ b/tests/hlsl/array-size-expr.shader_test @@ -53,7 +53,7 @@ todo(glsl) draw quad probe all rgba (2, 3, 6, 1) % Additional level of indirection -[pixel shader todo fail(sm>=6)] +[pixel shader fail(sm>=6)] static const float array[8] = {1, 2, 3, 4, 5, 6, 7, 8}; static const int idx = 2; static const float array2[array[idx]] = {1, 2, 3}; @@ -64,11 +64,11 @@ float4 main() : sv_target } [test] -todo draw quad +todo(glsl) draw quad probe all rgba (2, 3, 6, 1) -[pixel shader fail(sm>=6) todo] +[pixel shader fail(sm>=6)] static const struct { float f; @@ -88,5 +88,5 @@ uniform 4 float 0.0 uniform 8 float 0.0 uniform 12 float 0.0 uniform 16 float 42.0 -todo draw quad +todo(glsl) draw quad probe all rgba (42, 42, 42, 42)