| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
| |
There are some that I didn't remove this round because they looked like
obvious stubs. There are dead variables in gtest too, they should be
fixed upstream.
llvm-svn: 158090
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
No functional change intended.
Sorry for the churn. The iterator classes are supposed to help avoid
giant commits like this one in the future. The TableGen-produced
register lists are getting quite large, and it may be necessary to
change the table representation.
This makes it possible to do so without changing all clients (again).
llvm-svn: 157854
|
|
|
|
|
|
| |
The dead code elimination with callbacks is still useful.
llvm-svn: 157100
|
|
|
|
|
|
| |
backend, not just libCodeGen
llvm-svn: 153906
|
|
|
|
|
|
| |
TargetInstrInfo, MachineRegisterInfo, LiveIntervals, and VirtRegMap are all passed into the constructor and stored as members instead of passed in to each method.
llvm-svn: 153903
|
|
|
|
| |
llvm-svn: 152001
|
|
|
|
|
|
|
|
| |
methods are no longer needed now that LinearScan has gone away.
(Contains tweaks trivialSpillEverywhere to enable the removal of getNewVRegs).
llvm-svn: 151658
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Passes after RegAlloc should be able to rely on MRI->getNumVirtRegs() == 0.
This makes sharing code for pre/postRA passes more robust.
Now, to check if a pass is running before the RA pipeline begins, use MRI->isSSA().
To check if a pass is running after the RA pipeline ends, use !MRI->getNumVirtRegs().
PEI resets virtual regs when it's done scavenging.
PTX will either have to provide its own PEI pass or assign physregs.
llvm-svn: 151032
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Creates a configurable regalloc pipeline.
Ensure specific llc options do what they say and nothing more: -reglloc=... has no effect other than selecting the allocator pass itself. This patch introduces a new umbrella flag, "-optimize-regalloc", to enable/disable the optimizing regalloc "superpass". This allows for example testing coalscing and scheduling under -O0 or vice-versa.
When a CodeGen pass requires the MachineFunction to have a particular property, we need to explicitly define that property so it can be directly queried rather than naming a specific Pass. For example, to check for SSA, use MRI->isSSA, not addRequired<PHIElimination>.
CodeGen transformation passes are never "required" as an analysis
ProcessImplicitDefs does not require LiveVariables.
We have a plan to massively simplify some of the early passes within the regalloc superpass.
llvm-svn: 150226
|
|
|
|
|
|
|
| |
When a virtual register is live across a call, limit the search space to
call-preserved registers.
llvm-svn: 150081
|
|
|
|
|
|
| |
Responding to code review.
llvm-svn: 148290
|
|
|
|
|
|
| |
More short term hackery until we have a way to configure passes that work on LiveIntervals.
llvm-svn: 148289
|
|
|
|
| |
llvm-svn: 148105
|
|
|
|
| |
llvm-svn: 147979
|
|
|
|
|
|
| |
This helper method is too simplistic for RAGreedy.
llvm-svn: 147976
|
|
|
|
|
|
| |
No functional change.
llvm-svn: 147972
|
|
|
|
|
|
|
|
|
|
|
| |
The register allocators don't currently support adding reserved
registers while they are running. Extend the MRI API to keep track of
the set of reserved registers when register allocation started.
Target hooks like hasFP() and needsStackRealignment() can look at this
set to avoid reserving more registers during register allocation.
llvm-svn: 147577
|
|
|
|
|
|
| |
No clients are iterating over interference overlaps.
llvm-svn: 137350
|
|
|
|
|
|
|
| |
A public interface is no longer needed since RegisterCoalescer is not an
analysis any more.
llvm-svn: 137082
|
|
|
|
| |
llvm-svn: 136178
|
|
|
|
|
|
|
|
| |
asm.c:2:7: error: ran out of registers during register allocation
asm(""::"r"(0), "r"(1), "r"(2), "r"(3), "r"(4), "r"(5), "r"(6), "r"(7), "r"(8), "r"(9));
^
llvm-svn: 134310
|
|
|
|
|
|
| |
remove the analysis group.
llvm-svn: 133899
|
|
|
|
| |
llvm-svn: 133895
|
|
|
|
|
|
|
|
|
| |
of reserved registers.
Use RegisterClassInfo in RABasic as well. This slightly changes som
allocation orders because RegisterClassInfo puts CSR aliases last.
llvm-svn: 132581
|
|
|
|
|
|
|
|
| |
The previous invalidation missed the alias interference caches.
Also add a stats counter for the number of repaired ranges.
llvm-svn: 131133
|
|
|
|
|
|
|
| |
This can't be just an assertion, users can always write impossible inline
assembly. Such an assembly statement should be included in the error message.
llvm-svn: 131024
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On the x86-64 and thumb2 targets, some registers are more expensive to encode
than others in the same register class.
Add a CostPerUse field to the TableGen register description, and make it
available from TRI->getCostPerUse. This represents the cost of a REX prefix or a
32-bit instruction encoding required by choosing a high register.
Teach the greedy register allocator to prefer cheap registers for busy live
ranges (as indicated by spill weight).
llvm-svn: 129864
|
|
|
|
|
|
| |
accidentally be skipped.
llvm-svn: 129373
|
|
|
|
|
|
| |
when compiling many small functions.
llvm-svn: 129321
|
|
|
|
|
|
|
|
| |
allocation.
LiveIntervals::findLiveInMBBs has to do a full binary search for each segment.
llvm-svn: 129292
|
|
|
|
| |
llvm-svn: 129276
|
|
|
|
| |
llvm-svn: 128935
|
|
|
|
|
|
|
| |
It is using a trivial rewriter that doesn't know how to insert spill code
requested by the standard spiller.
llvm-svn: 128688
|
|
|
|
|
|
| |
Empty ranges may represent undef values.
llvm-svn: 128144
|
|
|
|
|
|
|
|
|
| |
register number.
The live range of a virtual register may change which invalidates the cached
interference information.
llvm-svn: 127772
|
|
|
|
|
|
|
|
|
|
|
| |
Live range splitting can create a number of small live ranges containing only a
single real use. Spill these small live ranges along with the large range they
are connected to with copies. This enables memory operand folding and maximizes
the spill to fill distance.
Work in progress with known bugs.
llvm-svn: 127529
|
|
|
|
|
|
|
| |
This makes it possible to register delegates and get callbacks when the spiller
edits live ranges.
llvm-svn: 127389
|
|
|
|
|
|
| |
SmallVectors.
llvm-svn: 127388
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
allocated first.
This is based on the observation that long live ranges are more difficult to
allocate, so there is a better chance of solving the puzzle by handling the big
pieces first. The allocator will evict and split long alive ranges when they get
in the way.
RABasic is still using spill weights for its priority queue, so the interface to
the queue has been virtualized.
llvm-svn: 126259
|
|
|
|
|
|
|
|
|
|
| |
The rewriter works almost identically to -rewriter=trivial, except it also
eliminates any identity copies.
This makes the new register allocators independent of VirtRegRewriter.cpp which
will be going away at the same time as RegAllocLinearScan.
llvm-svn: 125967
|
|
|
|
| |
llvm-svn: 125802
|
|
|
|
| |
llvm-svn: 125789
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Registers are not allocated strictly in spill weight order when live range
splitting and spilling has created new shorter intervals with higher spill
weights.
When one of the new heavy intervals conflicts with a single lighter interval,
simply evict the old interval instead of trying to split the heavy one.
The lighter interval is a better candidate for splitting, it has a smaller use
density.
llvm-svn: 125151
|
|
|
|
|
|
|
|
| |
createMachineVerifierPass and MachineFunction::verify.
The banner is printed before the machine code dump, just like the printer pass.
llvm-svn: 122113
|
|
|
|
|
|
|
|
| |
RegAllocBase::VerifyEnabled.
Run the machine code verifier in a few interesting places during RegAllocGreedy.
llvm-svn: 122107
|
|
|
|
| |
llvm-svn: 121801
|
|
|
|
|
|
| |
LiveIntervalUnions.
llvm-svn: 121781
|
|
|
|
| |
llvm-svn: 121604
|
|
|
|
| |
llvm-svn: 121599
|
|
|
|
|
|
|
| |
heuristic to reshuffle register assignments when we can't find an
available reg.
llvm-svn: 121388
|