[all-commits] [llvm/llvm-project] dd9f1a: [InstSimplify] Correctly handle comparison with ze...
Nikita Popov via All-commits
all-commits at lists.llvm.org
Thu Nov 14 02:55:41 PST 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: dd9f1a572b7c98b6761281bfa2d6bb351cbedb61
https://github.com/llvm/llvm-project/commit/dd9f1a572b7c98b6761281bfa2d6bb351cbedb61
Author: Nikita Popov <npopov at redhat.com>
Date: 2024-11-14 (Thu, 14 Nov 2024)
Changed paths:
M llvm/lib/Analysis/InstructionSimplify.cpp
M llvm/test/Transforms/InstSimplify/cmp-alloca-offsets.ll
Log Message:
-----------
[InstSimplify] Correctly handle comparison with zero-size allocs (#115728)
InstSimplify currently folds alloc1 == alloc2 to false, even if one of
them is a zero-size allocation. A zero-size allocation may have the same
address as another allocation.
This also disables the fold for the case where we're comparing a
zero-size alloc with the middle of another allocation. It's possible
that this case is legal to fold depending on our precise zero-size
allocation semantics, but LangRef currently doesn't specify this either
way, so we shouldn't make assumptions here.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list