diff options
author | zhijian lin <zhijian@ca.ibm.com> | 2025-06-05 09:41:51 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-06-05 09:41:51 -0400 |
commit | a91b0d27806226d52db90a4fe83bb73a95f412f4 (patch) | |
tree | 25b4ff3867b2a3195f51061a3be01d4244c33f25 /clang/lib/CodeGen/CodeGenFunction.cpp | |
parent | 8830e3802a92dca1d08048ac1197d9b0542db048 (diff) | |
download | llvm-a91b0d27806226d52db90a4fe83bb73a95f412f4.zip llvm-a91b0d27806226d52db90a4fe83bb73a95f412f4.tar.gz llvm-a91b0d27806226d52db90a4fe83bb73a95f412f4.tar.bz2 |
[PowerPC] hoist xxspltiw instruction out of the loop with FMA mutation pass. (#111696)
Summary:
The patch fixes the issue [[PowerPC] missing VSX FMA Mutation optimize
in some case for option -schedule-ppc-vsx-fma-mutation-early
#111906](https://github.com/llvm/llvm-project/issues/111906)
In certain cases, the Register Coalescer pass—which eliminates COPY
instructions—can interfere with the PowerPC VSX FMA Mutation pass.
Specifically, it can prevent the mutation of a COPY adjacent to an
XSMADDADP into a single XSMADDMDP instruction. As a result, the xxspltiw
instruction is not hoisted out of the loop as expected, leading to
missed optimization opportunities.
To address this, the patch ensures that the `VSX FMA Mutation` pass runs
before the `Register Coalescer` pass when the
-schedule-ppc-vsx-fma-mutation-early option is enabled.
Diffstat (limited to 'clang/lib/CodeGen/CodeGenFunction.cpp')
0 files changed, 0 insertions, 0 deletions