mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-24 22:24:54 +00:00
ConstantRangesSet renamed to IntegersSubset. CRSBuilder renamed to IntegersSubsetMapping.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@157612 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -223,22 +223,22 @@ BasicBlock* LowerSwitch::newLeafBlock(CaseRange& Leaf, Value* Val,
|
||||
// Clusterify - Transform simple list of Cases into list of CaseRange's
|
||||
unsigned LowerSwitch::Clusterify(CaseVector& Cases, SwitchInst *SI) {
|
||||
|
||||
CRSBuilder TheClusterifier;
|
||||
IntegersSubsetToBB TheClusterifier;
|
||||
|
||||
// Start with "simple" cases
|
||||
for (SwitchInst::CaseIt i = SI->case_begin(), e = SI->case_end();
|
||||
i != e; ++i) {
|
||||
BasicBlock *SuccBB = i.getCaseSuccessor();
|
||||
ConstantRangesSet CRS = i.getCaseValueEx();
|
||||
TheClusterifier.add(CRS, SuccBB);
|
||||
IntegersSubset CaseRanges = i.getCaseValueEx();
|
||||
TheClusterifier.add(CaseRanges, SuccBB);
|
||||
}
|
||||
|
||||
TheClusterifier.optimize();
|
||||
|
||||
size_t numCmps = 0;
|
||||
for (CRSBuilder::RangeIterator i = TheClusterifier.begin(),
|
||||
for (IntegersSubsetToBB::RangeIterator i = TheClusterifier.begin(),
|
||||
e = TheClusterifier.end(); i != e; ++i, ++numCmps) {
|
||||
CRSBuilder::Cluster &C = *i;
|
||||
IntegersSubsetToBB::Cluster &C = *i;
|
||||
|
||||
// FIXME: Currently work with ConstantInt based numbers.
|
||||
// Changing it to APInt based is a pretty heavy for this commit.
|
||||
|
Reference in New Issue
Block a user