mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-08-17 21:29:20 +00:00
Move some key maps from std::map to DenseMap. This improves the time to optimize Anton's testcase from 17.5s
to 15.7s. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@38480 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
a05a81b10a
commit
81c2a6ecbb
@ -556,6 +556,10 @@ class ValueNumberedSet {
|
|||||||
BitVector numbers;
|
BitVector numbers;
|
||||||
public:
|
public:
|
||||||
ValueNumberedSet() { numbers.resize(1); }
|
ValueNumberedSet() { numbers.resize(1); }
|
||||||
|
ValueNumberedSet(const ValueNumberedSet& other) {
|
||||||
|
numbers = other.numbers;
|
||||||
|
contents = other.contents;
|
||||||
|
}
|
||||||
|
|
||||||
typedef SmallPtrSet<Value*, 8>::iterator iterator;
|
typedef SmallPtrSet<Value*, 8>::iterator iterator;
|
||||||
|
|
||||||
@ -614,9 +618,9 @@ namespace {
|
|||||||
ValueTable VN;
|
ValueTable VN;
|
||||||
std::vector<Instruction*> createdExpressions;
|
std::vector<Instruction*> createdExpressions;
|
||||||
|
|
||||||
std::map<BasicBlock*, ValueNumberedSet> availableOut;
|
DenseMap<BasicBlock*, ValueNumberedSet> availableOut;
|
||||||
std::map<BasicBlock*, ValueNumberedSet> anticipatedIn;
|
DenseMap<BasicBlock*, ValueNumberedSet> anticipatedIn;
|
||||||
std::map<BasicBlock*, ValueNumberedSet> generatedPhis;
|
DenseMap<BasicBlock*, ValueNumberedSet> generatedPhis;
|
||||||
|
|
||||||
// This transformation requires dominator postdominator info
|
// This transformation requires dominator postdominator info
|
||||||
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
|
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
|
||||||
|
Loading…
Reference in New Issue
Block a user