mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-14 16:33:28 +00:00
blockfreq: Really fix r206548 (and r206549)
Turns out this code is dead. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@206554 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
b08b9d7c09
commit
a9da909e57
@ -369,38 +369,6 @@ typedef BlockFrequencyInfoImplBase::PackagedLoopData PackagedLoopData;
|
||||
typedef BlockFrequencyInfoImplBase::Weight Weight;
|
||||
typedef BlockFrequencyInfoImplBase::FrequencyData FrequencyData;
|
||||
|
||||
/// \brief Stack entry describing a loop.
|
||||
struct LoopStackEntry {
|
||||
BlockNode LoopHead;
|
||||
BlockNode LatestBackedge;
|
||||
};
|
||||
|
||||
/// \brief Stack describing currently open loops.
|
||||
struct LoopStack {
|
||||
std::vector<LoopStackEntry> OpenLoops;
|
||||
|
||||
void push(const BlockNode &LoopHead, const BlockNode &LatestBackedge) {
|
||||
assert(LoopHead.isValid());
|
||||
assert(LatestBackedge.isValid());
|
||||
OpenLoops.emplace_back(LoopHead, LatestBackedge);
|
||||
}
|
||||
void pop(const BlockNode &FinishedNode) {
|
||||
while (!empty() && top().LatestBackedge <= FinishedNode)
|
||||
OpenLoops.pop_back();
|
||||
}
|
||||
bool empty() const { return OpenLoops.empty(); }
|
||||
const LoopStackEntry &top() const {
|
||||
assert(!OpenLoops.empty());
|
||||
return OpenLoops.back();
|
||||
}
|
||||
void adjustAfterFinishing(const BlockNode &Current,
|
||||
const BlockNode &LatestBackedge) {
|
||||
pop(Current);
|
||||
if (LatestBackedge.isValid() && LatestBackedge > Current)
|
||||
push(Current, LatestBackedge);
|
||||
}
|
||||
};
|
||||
|
||||
/// \brief Dithering mass distributer.
|
||||
///
|
||||
/// This class splits up a single mass into portions by weight, dithering to
|
||||
|
Loading…
x
Reference in New Issue
Block a user