mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-04-11 16:37:42 +00:00
Do one lookup instead of two.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@106415 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
37db6cdaea
commit
3193a689db
@ -185,8 +185,9 @@ unsigned FastISel::lookUpRegForValue(const Value *V) {
|
||||
// cache values defined by Instructions across blocks, and other values
|
||||
// only locally. This is because Instructions already have the SSA
|
||||
// def-dominates-use requirement enforced.
|
||||
if (ValueMap.count(V))
|
||||
return ValueMap[V];
|
||||
DenseMap<const Value *, unsigned>::iterator I = ValueMap.find(V);
|
||||
if (I != ValueMap.end())
|
||||
return I->second;
|
||||
return LocalValueMap[V];
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user