[StackLifetime] Fix sign compare warning (NFC)
authorNikita Popov <npopov@redhat.com>
Fri, 6 Jan 2023 15:10:47 +0000 (16:10 +0100)
committerNikita Popov <npopov@redhat.com>
Fri, 6 Jan 2023 15:11:11 +0000 (16:11 +0100)
llvm/lib/Analysis/StackLifetime.cpp

index 9fc78fa..ee77e81 100644 (file)
@@ -76,7 +76,7 @@ static const AllocaInst *findMatchingAlloca(const IntrinsicInst &II,
     return nullptr;
   int64_t LifetimeSize = Size->getSExtValue();
 
-  if (LifetimeSize != -1 && LifetimeSize != *AllocaSize)
+  if (LifetimeSize != -1 && uint64_t(LifetimeSize) != *AllocaSize)
     return nullptr;
 
   return AI;