diff options
author | XChy <xxs_chy@outlook.com> | 2025-09-02 23:54:12 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-09-02 23:54:12 +0800 |
commit | cb80fa756c4fcbc4f5deba16da857ed309e044cf (patch) | |
tree | 1ab965001b6660afb8033a72e7ffa2fe09e7c3e2 /clang/lib/Frontend/FrontendAction.cpp | |
parent | 8dee9e465bac6f1f85d37820f8ee15b5bd2118a6 (diff) | |
download | llvm-cb80fa756c4fcbc4f5deba16da857ed309e044cf.zip llvm-cb80fa756c4fcbc4f5deba16da857ed309e044cf.tar.gz llvm-cb80fa756c4fcbc4f5deba16da857ed309e044cf.tar.bz2 |
[VectorCombine] Support pattern `bitop(bitcast(x), C) -> bitcast(bitop(x, InvC))` (#155216)
Resolves #154797.
This patch adds the fold `bitop(bitcast(x), C) -> bitop(bitcast(x),
cast(InvC)) -> bitcast(bitop(x, InvC))`.
The helper function `getLosslessInvCast` tries to calculate the constant
`InvC`, satisfying `castop(InvC) == C`, and will try its best to keep
the poison-generated flags of the cast operation.
Diffstat (limited to 'clang/lib/Frontend/FrontendAction.cpp')
0 files changed, 0 insertions, 0 deletions