[llvm] r304990 - [LazyValueInfo] Make LVILatticeVal intersect method take arguments by reference so we don't copy ConstantRanges unless we need to.
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 8 10:08:58 PDT 2017
Author: ctopper
Date: Thu Jun 8 12:08:58 2017
New Revision: 304990
URL: http://llvm.org/viewvc/llvm-project?rev=304990&view=rev
Log:
[LazyValueInfo] Make LVILatticeVal intersect method take arguments by reference so we don't copy ConstantRanges unless we need to.
Modified:
llvm/trunk/lib/Analysis/LazyValueInfo.cpp
Modified: llvm/trunk/lib/Analysis/LazyValueInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Analysis/LazyValueInfo.cpp?rev=304990&r1=304989&r2=304990&view=diff
==============================================================================
--- llvm/trunk/lib/Analysis/LazyValueInfo.cpp (original)
+++ llvm/trunk/lib/Analysis/LazyValueInfo.cpp Thu Jun 8 12:08:58 2017
@@ -302,7 +302,7 @@ static bool hasSingleValue(const LVILatt
/// 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())
More information about the llvm-commits
mailing list