]> granicus.if.org Git - llvm/commitdiff
[LazyValueInfo] Make LVILatticeVal intersect method take arguments by reference so...
authorCraig Topper <craig.topper@gmail.com>
Thu, 8 Jun 2017 17:08:58 +0000 (17:08 +0000)
committerCraig Topper <craig.topper@gmail.com>
Thu, 8 Jun 2017 17:08:58 +0000 (17:08 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@304990 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Analysis/LazyValueInfo.cpp

index a673b6d42471fab6d48e4af562de279e8f412628..87e7f9bf0af7aa6a2098a47f7d559fde560ddd75 100644 (file)
@@ -302,7 +302,7 @@ static bool hasSingleValue(const LVILatticeVal &Val) {
 ///   contradictory.  If this happens, we return some valid lattice value so as
 ///   not confuse the rest of LVI.  Ideally, we'd always return Undefined, but
 ///   we do not make this guarantee.  TODO: This would be a useful enhancement.
-static LVILatticeVal intersect(LVILatticeVal A, LVILatticeVal B) {
+static LVILatticeVal intersect(const LVILatticeVal &A, const LVILatticeVal &B) {
   // Undefined is the strongest state.  It means the value is known to be along
   // an unreachable path.
   if (A.isUndefined())