mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-19 08:24:12 +00:00
Shrink wrapping in PEI:
- reduces _static_ callee saved register spills and restores similar to Chow's original algorithm. - iterative implementation with simple heuristic limits to mitigate compile time impact. - handles placing spills/restores for multi-entry, multi-exit regions in the Machine CFG without splitting edges. - passes test-suite in LLCBETA mode. Added contains() method to ADT/SparseBitVector. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@71438 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
589b1efe1b
commit
b9cfbd94ab
@ -641,8 +641,8 @@ public:
|
||||
return changed;
|
||||
}
|
||||
|
||||
// Intersect our bitmap with the complement of the RHS and return true if ours
|
||||
// changed.
|
||||
// Intersect our bitmap with the complement of the RHS and return true
|
||||
// if ours changed.
|
||||
bool intersectWithComplement(const SparseBitVector &RHS) {
|
||||
bool changed = false;
|
||||
ElementListIter Iter1 = Elements.begin();
|
||||
@ -685,8 +685,8 @@ public:
|
||||
}
|
||||
|
||||
|
||||
// Three argument version of intersectWithComplement. Result of RHS1 & ~RHS2
|
||||
// is stored into this bitmap.
|
||||
// Three argument version of intersectWithComplement.
|
||||
// Result of RHS1 & ~RHS2 is stored into this bitmap.
|
||||
void intersectWithComplement(const SparseBitVector<ElementSize> &RHS1,
|
||||
const SparseBitVector<ElementSize> &RHS2)
|
||||
{
|
||||
@ -775,6 +775,14 @@ public:
|
||||
return false;
|
||||
}
|
||||
|
||||
// Return true iff all bits set in this SparseBitVector are
|
||||
// also set in RHS.
|
||||
bool contains(const SparseBitVector<ElementSize> &RHS) const {
|
||||
SparseBitVector<ElementSize> Result(*this);
|
||||
Result &= RHS;
|
||||
return (Result == RHS);
|
||||
}
|
||||
|
||||
// Return the first set bit in the bitmap. Return -1 if no bits are set.
|
||||
int find_first() const {
|
||||
if (Elements.empty())
|
||||
@ -875,6 +883,8 @@ operator-(const SparseBitVector<ElementSize> &LHS,
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
// Dump a SparseBitVector to a stream
|
||||
template <unsigned ElementSize>
|
||||
void dump(const SparseBitVector<ElementSize> &LHS, llvm::OStream &out) {
|
||||
|
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user