Skip to content

Commit f041a9e

Browse files
committed
Merge from mainline. Complete 64076 merge from mainline.
llvm-svn: 64861
1 parent 811b9fd commit f041a9e

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

llvm/include/llvm/CodeGen/LiveInterval.h

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -271,6 +271,17 @@ namespace llvm {
271271
I = std::lower_bound(kills.begin(), kills.end(), KillIdx);
272272
return I != kills.end() && *I == KillIdx;
273273
}
274+
275+
/// isOnlyLROfValNo - Return true if the specified live range is the only
276+
/// one defined by the its val#.
277+
bool isOnlyLROfValNo( const LiveRange *LR) {
278+
for (const_iterator I = begin(), E = end(); I != E; ++I) {
279+
const LiveRange *Tmp = I;
280+
if (Tmp != LR && Tmp->valno == LR->valno)
281+
return false;
282+
}
283+
return true;
284+
}
274285

275286
/// MergeValueNumberInto - This method is called when two value nubmers
276287
/// are found to be equivalent. This eliminates V1, replacing all

0 commit comments

Comments
 (0)