- Aug 19, 2010
-
-
Evan Cheng authored
llvm-svn: 111537
-
Michael J. Spencer authored
The Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.30319.01 implements parts of C++0x based on the draft standard. An old version of the draft had a bug that makes std::pair<T1*, T2*>(something, 0) fail to compile. This is because the template<class U, class V> pair(U&& x, V&& y) constructor is selected, even though it later fails to implicitly convert U and V to frist_type and second_type. This has been fixed in n3090, but it seems that Microsoft is not going to update msvc. llvm-svn: 111535
-
Evan Cheng authored
llvm-svn: 111531
-
Evan Cheng authored
llvm-svn: 111530
-
Jim Grosbach authored
base registers were required. This will allow for slightly better packing of the locals when alignment padding is necessary after callee saved registers. llvm-svn: 111508
-
Jim Grosbach authored
llvm-svn: 111453
-
Evan Cheng authored
If any def of a machine-sink candidate has local uses, it's obviously not safe to sink it to a successor block. This bug has been hidden because a later check for critical-edge disable these illegal optimizations. This patch should significantly reduce the amount of time spent on checking dominator information for obviously unsafe sinking. llvm-svn: 111450
-
Jim Grosbach authored
frame index reference to an object in the local block is seen, check if it's near enough to any previously allocaated base register to re-use. rdar://8277890 llvm-svn: 111443
-
- Aug 18, 2010
-
-
Jakob Stoklund Olesen authored
map discovers the iterated dominance frontier for free. llvm-svn: 111400
-
Jakob Stoklund Olesen authored
We must complete the DFS, otherwise we might miss needed phi-defs, and prematurely color live ranges with a non-dominating value. This is not a big deal since we get to color more of the CFG and the next mapValue call will be faster. llvm-svn: 111397
-
Jakob Stoklund Olesen authored
llvm-svn: 111394
-
Jakob Stoklund Olesen authored
LiveIntervalMap maps values from a parent LiveInterval to a child interval that is a strict subset. It will create phi-def values as needed to preserve the VNInfo SSA form in the child interval. This leads to an algorithm very similar to the one in SSAUpdaterImpl.h, but with enough differences that the code can't be reused: - We don't need to manipulate PHI instructions. - LiveIntervals have kills. - We have MachineDominatorTree. - We can use df_iterator. llvm-svn: 111393
-
Bill Wendling authored
llvm-svn: 111384
-
Jim Grosbach authored
Nothing fancy, just ask the target if any currently available base reg is in range for the instruction under consideration and use the first one that is. Placeholder ARM implementation simply returns false for now. ongoing saga of rdar://8277890 llvm-svn: 111374
-
Jakob Stoklund Olesen authored
llvm-svn: 111366
-
Jim Grosbach authored
the local block. Resolve references to those indices to a new base register. For simplification and testing purposes, a new virtual base register is allocated for each frame index being resolved. The result is truly horrible, but correct, code that's good for exercising the new code paths. Next up is adding thumb1 support, which should be very simple. Following that will be adding base register re-use and implementing a reasonable ARM heuristic for when a virtual base register should be generated at all. llvm-svn: 111315
-
Dale Johannesen authored
PR 7882. Follows suggestion by Amaury Pouly, thanks. llvm-svn: 111306
-
- Aug 17, 2010
-
-
Evan Cheng authored
PHI elimination shouldn't require machineloopinfo since it's used at -O0. Move the requirement to LiveIntervalAnalysis instead. Note this does not change the number of times machineloopinfo is computed. llvm-svn: 111285
-
Evan Cheng authored
llvm-svn: 111281
-
Jim Grosbach authored
llvm-svn: 111274
-
Jim Grosbach authored
whether to allocate a virtual frame base register to resolve the frame index reference in it. Implement a simple version for ARM to aid debugging. In LocalStackSlotAllocation, scan the function for frame index references to local frame indices and ask the target whether to allocate virtual frame base registers for any it encounters. Purely infrastructural for debug output. Next step is to actually allocate base registers, then add intelligent re-use of them. rdar://8277890 llvm-svn: 111262
-
Evan Cheng authored
Move the decision logic whether it's a good idea to split a critical edge to clients. Also fixed an erroneous check. An edge is only a back edge when the from and to blocks are in the same loop. llvm-svn: 111256
-
Evan Cheng authored
llvm-svn: 111250
-
Eric Christopher authored
llvm-svn: 111223
-
Evan Cheng authored
PHI elimination should not break back edge. It can cause some significant code placement issues. rdar://8263994 good: LBB0_2: mov r2, r0 . . . mov r1, r2 bne LBB0_2 bad: LBB0_2: mov r2, r0 . . . @ BB#3: mov r1, r2 b LBB0_2 llvm-svn: 111221
-
Jim Grosbach authored
llvm-svn: 111206
-
Jim Grosbach authored
mapping. Have the local block track its alignment requirement, and then apply that when the block itself is allocated. Previously, offsets could get adjusted in PEI to be different, relative to one another, than the block allocation thought they would be, which defeats the point of doing the allocation this way. Continuing rdar://8277890 llvm-svn: 111197
-
- Aug 16, 2010
-
-
Eli Friedman authored
emission. llvm-svn: 111177
-
Jim Grosbach authored
llvm-svn: 111164
-
Jakob Stoklund Olesen authored
llvm-svn: 111156
-
- Aug 14, 2010
-
-
Ted Kremenek authored
llvm-svn: 111063
-
Jim Grosbach authored
experimental pass that allocates locals relative to one another before register allocation and then assigns them to actual stack slots as a block later in PEI. This will eventually allow targets with limited index offset range to allocate additional base registers (not just FP and SP) to more efficiently reference locals, as well as handle situations where locals cannot be referenced via SP or FP at all (dynamic stack realignment together with variable sized objects, for example). It's currently incomplete and almost certainly buggy. Work in progress. Disabled by default and gated via the -enable-local-stack-alloc command line option. rdar://8277890 llvm-svn: 111059
-
Jakob Stoklund Olesen authored
The earliestStart argument is entirely specific to linear scan allocation, and can be easily calculated by RegAllocLinearScan. Replace std::vector with SmallVector. llvm-svn: 111055
-
- Aug 13, 2010
-
-
Jakob Stoklund Olesen authored
When a live range is contained a single block, we can split it around instruction clusters. The current approach is very primitive, splitting before and after the largest gap between uses. llvm-svn: 111043
-
Jim Grosbach authored
llvm-svn: 111019
-
Jakob Stoklund Olesen authored
numbers match. The old check could accidentally leave holes in openli. Also let useIntv add all ranges for the phi-def value inserted by enterIntvAtEnd. This works as long at the value mapping is established in enterIntvAtEnd. llvm-svn: 110995
-
Jakob Stoklund Olesen authored
function to do it. llvm-svn: 110994
-
Jakob Stoklund Olesen authored
This can happen if the original interval has been broken into two disconnected parts. Ideally, we should be able to detect when the graph is disconnected and create separate intervals, but that code is not implemented yet. Example: Two basic blocks are both branching to a loop header. Our interval is defined in both basic blocks, and live into the loop along both edges. We decide to split the interval around the loop. The interval is split into an inside part and an outside part. The outside part now has two disconnected segments, one in each basic block. If we later decide to split the outside interval into single blocks, we get one interval per basic block and an empty dupli for the remainder. llvm-svn: 110976
-
Jakob Stoklund Olesen authored
split intervals. THis means the analysis can be used for multiple splits as long as curli doesn't shrink. llvm-svn: 110975
-
- Aug 12, 2010
-
-
Jakob Stoklund Olesen authored
If a phi-def value were removed from the interval, the phi-kill flags are no longer valid. llvm-svn: 110949
-