aboutsummaryrefslogtreecommitdiff
path: root/clang/unittests/Serialization/ModuleCacheTest.cpp
diff options
context:
space:
mode:
authorFlorian Hahn <flo@fhahn.com>2025-07-30 21:10:57 +0100
committerGitHub <noreply@github.com>2025-07-30 21:10:57 +0100
commitd74d841b65dc5ecc1adb87f94ee5c8073984e130 (patch)
tree154c0a020248748485bd5a0e50cf3eed9c676197 /clang/unittests/Serialization/ModuleCacheTest.cpp
parent8dd91996f008c47b986943499acf3e1abd4deaa8 (diff)
downloadllvm-d74d841b65dc5ecc1adb87f94ee5c8073984e130.zip
llvm-d74d841b65dc5ecc1adb87f94ee5c8073984e130.tar.gz
llvm-d74d841b65dc5ecc1adb87f94ee5c8073984e130.tar.bz2
[SECV] Try to push the op into ZExt: A + zext (-A + B) -> zext (B) (#151227)
Try to push the constant operand into a ZExt: A + zext (-A + B) -> zext (B), if trunc (A) + -A + B does not unsigned-wrap. The actual code supports ZExts with arbitrary number of arguments, hence the getAddExpr in the return. This helps SCEV reasoning in some cases, commonly when adding an offset to a zero-extended SCEV that subtracts the same offset. Note that this is restricted to cases where we can fold away an operand of the inner Add. This is needed to avoid bad interactions with patterns when forming ZExts, which try to push to ZExt to add operands. https://alive2.llvm.org/ce/z/q7d303 PR: https://github.com/llvm/llvm-project/pull/151227
Diffstat (limited to 'clang/unittests/Serialization/ModuleCacheTest.cpp')
0 files changed, 0 insertions, 0 deletions