mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-10-25 10:27:04 +00:00
Move equality function for AliasAnalysis::Location from DenseMapInfo to Location struct so it can be used in other types of maps
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236237 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -134,6 +134,10 @@ public:
|
|||||||
Copy.AATags = AAMDNodes();
|
Copy.AATags = AAMDNodes();
|
||||||
return Copy;
|
return Copy;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool operator==(const AliasAnalysis::Location &Other) const {
|
||||||
|
return Ptr == Other.Ptr && Size == Other.Size && AATags == Other.AATags;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
/// getLocation - Fill in Loc with information about the memory reference by
|
/// getLocation - Fill in Loc with information about the memory reference by
|
||||||
@@ -615,9 +619,7 @@ struct DenseMapInfo<AliasAnalysis::Location> {
|
|||||||
}
|
}
|
||||||
static bool isEqual(const AliasAnalysis::Location &LHS,
|
static bool isEqual(const AliasAnalysis::Location &LHS,
|
||||||
const AliasAnalysis::Location &RHS) {
|
const AliasAnalysis::Location &RHS) {
|
||||||
return LHS.Ptr == RHS.Ptr &&
|
return LHS == RHS;
|
||||||
LHS.Size == RHS.Size &&
|
|
||||||
LHS.AATags == RHS.AATags;
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user