[PATCH vkd3d 4/5] vkd3d-shader/hlsl: Remove trivial swizzles after each copy prop pass.
Giovanni Mascellani
gmascellani at codeweavers.com
Thu Feb 24 09:05:16 CST 2022
Hi,
Il 24/02/22 15:06, Matteo Bruni ha scritto:
> --- a/libs/vkd3d-shader/hlsl_codegen.c
> +++ b/libs/vkd3d-shader/hlsl_codegen.c
> @@ -1665,9 +1665,9 @@ int hlsl_emit_dxbc(struct hlsl_ctx *ctx, struct hlsl_ir_function_decl *entry_fun
> {
> progress = transform_ir(ctx, hlsl_fold_constants, body, NULL);
> progress |= copy_propagation_execute(ctx, body);
> + transform_ir(ctx, remove_trivial_swizzles, body, NULL);
Wouldn't it make sense to "progress |=" this one too? I guess that
removing a trivial swizzle can enable another round of constant folding
or copy propagation.
Giovanni.
More information about the wine-devel
mailing list