[clang] [llvm] [IR] Avoid creating icmp/fcmp constant expressions (PR #92885)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Tue May 21 02:34:48 PDT 2024
================
@@ -43,9 +43,9 @@
; CHECK: @mul = global ptr null
; CHECK: @xor = global ptr @A
; CHECK: @B = external global %Ty
-; CHECK: @icmp_ult1 = global i1 icmp ugt (ptr getelementptr inbounds (i64, ptr @A, i64 1), ptr @A)
+; CHECK: @icmp_ult1 = global i1 icmp ult (ptr @A, ptr getelementptr inbounds (i64, ptr @A, i64 1))
----------------
nikic wrote:
There are a few cases like this where we don't canonicalize constant expressions involving icmp anymore. This is because we also refuse to create new icmp expressions even if we already had one originally.
This is fine because it only happens if there was an icmp const expr in the first place, which will be removed shortly after this lands.
https://github.com/llvm/llvm-project/pull/92885
More information about the llvm-commits
mailing list