forked from OSchip/llvm-project
parent
67fd3a50dc
commit
274fc82289
|
@ -1164,34 +1164,6 @@ private:
|
|||
/// currently building.
|
||||
MethodInfoMapTy MethodInfoMap;
|
||||
|
||||
/// ThunkInfo - The 'this' pointer adjustment as well as an optional return
|
||||
/// adjustment for a thunk.
|
||||
struct ThunkInfo {
|
||||
/// This - The 'this' pointer adjustment.
|
||||
ThisAdjustment This;
|
||||
|
||||
/// Return - The return adjustment.
|
||||
ReturnAdjustment Return;
|
||||
|
||||
ThunkInfo() { }
|
||||
|
||||
ThunkInfo(const ThisAdjustment &This, const ReturnAdjustment &Return)
|
||||
: This(This), Return(Return) { }
|
||||
|
||||
friend bool operator==(const ThunkInfo &LHS, const ThunkInfo &RHS) {
|
||||
return LHS.This == RHS.This && LHS.Return == RHS.Return;
|
||||
}
|
||||
|
||||
friend bool operator<(const ThunkInfo &LHS, const ThunkInfo &RHS) {
|
||||
if (LHS.This < RHS.This)
|
||||
return true;
|
||||
|
||||
return LHS.This == RHS.This && LHS.Return < RHS.Return;
|
||||
}
|
||||
|
||||
bool isEmpty() const { return This.isEmpty() && Return.isEmpty(); }
|
||||
};
|
||||
|
||||
typedef llvm::DenseMap<uint64_t, ThunkInfo> VtableThunksMapTy;
|
||||
|
||||
/// VTableThunks - The thunks by vtable index in the vtable currently being
|
||||
|
|
|
@ -83,7 +83,34 @@ struct ThisAdjustment {
|
|||
return LHS.NonVirtual == RHS.NonVirtual &&
|
||||
LHS.VCallOffsetOffset < RHS.VCallOffsetOffset;
|
||||
}
|
||||
};
|
||||
|
||||
/// ThunkInfo - The 'this' pointer adjustment as well as an optional return
|
||||
/// adjustment for a thunk.
|
||||
struct ThunkInfo {
|
||||
/// This - The 'this' pointer adjustment.
|
||||
ThisAdjustment This;
|
||||
|
||||
/// Return - The return adjustment.
|
||||
ReturnAdjustment Return;
|
||||
|
||||
ThunkInfo() { }
|
||||
|
||||
ThunkInfo(const ThisAdjustment &This, const ReturnAdjustment &Return)
|
||||
: This(This), Return(Return) { }
|
||||
|
||||
friend bool operator==(const ThunkInfo &LHS, const ThunkInfo &RHS) {
|
||||
return LHS.This == RHS.This && LHS.Return == RHS.Return;
|
||||
}
|
||||
|
||||
friend bool operator<(const ThunkInfo &LHS, const ThunkInfo &RHS) {
|
||||
if (LHS.This < RHS.This)
|
||||
return true;
|
||||
|
||||
return LHS.This == RHS.This && LHS.Return < RHS.Return;
|
||||
}
|
||||
|
||||
bool isEmpty() const { return This.isEmpty() && Return.isEmpty(); }
|
||||
};
|
||||
|
||||
/// ThunkAdjustment - Virtual and non-virtual adjustment for thunks.
|
||||
|
|
Loading…
Reference in New Issue