forked from OSchip/llvm-project
parent
2231c2cac3
commit
6265ab8c10
|
@ -98,7 +98,7 @@ private:
|
|||
|
||||
Value *Val;
|
||||
Use *Next;
|
||||
PointerIntPair<Use**, 2, PrevPtrTag> Prev;
|
||||
PointerIntPair<Use**, 2, PrevPtrTag> Prev;
|
||||
|
||||
void setPrev(Use **NewPrev) {
|
||||
Prev.setPointer(NewPrev);
|
||||
|
|
|
@ -138,11 +138,11 @@ struct AugmentedUse : Use {
|
|||
|
||||
User *Use::getUser() const {
|
||||
const Use *End = getImpliedUser();
|
||||
PointerIntPair<User*, 1, Tag>& ref(static_cast<const AugmentedUse*>(End - 1)->ref);
|
||||
PointerIntPair<User*, 1, Tag>& ref(static_cast<const AugmentedUse*>(End - 1)->ref);
|
||||
User *She = ref.getPointer();
|
||||
return ref.getInt()
|
||||
? She
|
||||
: (User*)End;
|
||||
? She
|
||||
: (User*)End;
|
||||
}
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
@ -154,7 +154,7 @@ Use *User::allocHungoffUses(unsigned N) const {
|
|||
+ sizeof(AugmentedUse)
|
||||
- sizeof(Use)));
|
||||
Use *End = Begin + N;
|
||||
PointerIntPair<User*, 1, Tag>& ref(static_cast<AugmentedUse&>(End[-1]).ref);
|
||||
PointerIntPair<User*, 1, Tag>& ref(static_cast<AugmentedUse&>(End[-1]).ref);
|
||||
ref.setPointer(const_cast<User*>(this));
|
||||
ref.setInt(tagOne);
|
||||
return Use::initTags(Begin, End);
|
||||
|
|
Loading…
Reference in New Issue