- Apr 15, 2008
-
-
Dan Gohman authored
ScheduleDAG; they don't correspond to any actual instructions so they don't need to be scheduled. This fixes a bug where the EntryToken was being scheduled multiple times in some cases, though it ended up not causing any trouble because EntryToken doesn't expand into anything. With this fixed the schedulers reliably schedule the expected number of units, so we can check this with an assertion. This requires a tweak to test/CodeGen/X86/loop-hoist.ll because it ends up getting scheduled differently in a trivial way, though it was enough to fool the prcontext+grep that the test does. llvm-svn: 49701
-
Dan Gohman authored
instead of blue to distinguish them from regular dependencies. llvm-svn: 49696
-
- Apr 14, 2008
-
-
Dan Gohman authored
llvm-svn: 49676
-
Dan Gohman authored
memory intrinsic expansion code. llvm-svn: 49666
-
Nicolas Geoffray authored
llvm-svn: 49652
-
Duncan Sands authored
much simpler than in LegalizeDAG because calls are not yet expanded into call sequences: that happens after type legalization has finished. llvm-svn: 49634
-
- Apr 13, 2008
-
-
Duncan Sands authored
in its maps. Add some sanity checks that catch this kind of thing. Hopefully these can be removed one day (once all problems are fixed!) but for the moment it seems wise to have them in. llvm-svn: 49612
-
Nicolas Geoffray authored
llvm-svn: 49611
-
- Apr 12, 2008
-
-
Duncan Sands authored
llvm-svn: 49583
-
Dan Gohman authored
on any current target and aren't optimized in DAGCombiner. Instead of using intermediate nodes, expand the operations, choosing between simple loads/stores, target-specific code, and library calls, immediately. Previously, the code to emit optimized code for these operations was only used at initial SelectionDAG construction time; now it is used at all times. This fixes some cases where rep;movs was being used for small copies where simple loads/stores would be better. This also cleans up code that checks for alignments less than 4; let the targets make that decision instead of doing it in target-independent code. This allows x86 to use rep;movs in low-alignment cases. Also, this fixes a bug that resulted in the use of rep;stos for memsets of 0 with non-constant memory size when the alignment was at least 4. It's better to use the library in this case, which can be significantly faster when the size is large. This also preserves more SourceValue information when memory intrinsics are lowered into simple loads/stores. llvm-svn: 49572
-
- Apr 11, 2008
-
-
Gabor Greif authored
llvm-svn: 49524
-
- Apr 07, 2008
-
-
Dan Gohman authored
review feedback from Chris quite a while ago. No functionality change. llvm-svn: 49348
-
Roman Levenstein authored
by Dan Gohman is fixed. llvm-svn: 49330
-
- Apr 06, 2008
-
-
Torok Edwin authored
If it cannot be expanded, it will keep the old behaviour and try to shrink the constant. Part of enhancement for PR2191. llvm-svn: 49280
-
- Apr 05, 2008
-
-
Dale Johannesen authored
before an invoke. Failure to do this causes references in the landing pad to variables that were not set. Fixes g++.dg/eh/delayslot1.C g++.dg/eh/fp-regs.C g++.old-deja/g++.brendan/eh1.C llvm-svn: 49243
-
- Apr 03, 2008
-
-
Evan Cheng authored
There is no point in creating a long live range defined by an implicit_def. Scheduler now duplicates implicit_def instruction for each of its uses. Therefore, if an implicit_def node has multiple uses, it will become a number of very short live ranges, rather than a long one. This will make coalescer's job easier. llvm-svn: 49164
-
Evan Cheng authored
llvm-svn: 49124
-
- Apr 02, 2008
-
-
Dale Johannesen authored
review feedback. -enable-eh is still accepted but doesn't do anything. EH intrinsics use Dwarf EH if the target supports that, and are handled by LowerInvoke otherwise. The separation of the EH table and frame move data is, I think, logically figured out, but either one still causes full EH info to be generated (not sure how to split the metadata correctly). MachineModuleInfo::needsFrameInfo is no longer used and is removed. llvm-svn: 49064
-
- Apr 01, 2008
-
-
Dale Johannesen authored
llvm-svn: 49046
-
Evan Cheng authored
llvm-svn: 49016
-
Evan Cheng authored
llvm-svn: 49014
-
Evan Cheng authored
llvm-svn: 49013
-
Evan Cheng authored
llvm-svn: 49012
-
Dale Johannesen authored
not marked nounwind, or for all functions when -enable-eh is set, provided the target supports Dwarf EH. llvm-gcc generates nounwind in the right places; other FEs will need to do so also. Given such a FE, -enable-eh should no longer be needed. llvm-svn: 49006
-
- Mar 31, 2008
-
-
Dan Gohman authored
llvm-svn: 48994
-
- Mar 30, 2008
-
-
Chris Lattner authored
patch by David Chisnall. llvm-svn: 48963
-
- Mar 29, 2008
-
-
Evan Cheng authored
llvm-svn: 48947
-
- Mar 28, 2008
-
-
Chris Lattner authored
llvm-svn: 48916
-
Duncan Sands authored
llvm-svn: 48914
-
- Mar 27, 2008
-
-
Duncan Sands authored
In order to handle indexed nodes I had to introduce a new constructor, and since I was there I factorized the code in the various load constructors. llvm-svn: 48894
-
Dan Gohman authored
nodes. This doesn't currently have much impact the generated code, but it does produce simpler-looking SelectionDAGs, and consequently simpler-looking ScheduleDAGs, because there are fewer spurious dependencies. In particular, CopyValueToVirtualRegister now uses the entry node as the input chain dependency for new CopyToReg nodes instead of calling getRoot and depending on the most recent memory reference. Also, rename UnorderedChains to PendingExports and pull it up from being a local variable in SelectionDAGISel::BuildSelectionDAG to being a member variable of SelectionDAGISel, so that it doesn't have to be passed around to all the places that need it. llvm-svn: 48893
-
Roman Levenstein authored
llvm-svn: 48873
-
Roman Levenstein authored
called LimitedSumOfUnscheduledPredsOfSuccs. It terminates the computation after a given treshold is reached. This new function is always faster, but brings real wins only on bigger test-cases. The old function SumOfUnscheduledPredsOfSuccs is left in-place for now and therefore a warning about an unused static function is produced. llvm-svn: 48872
-
- Mar 26, 2008
-
-
Roman Levenstein authored
LLVM Value/Use does and MachineRegisterInfo/MachineOperand does. This allows constant time for all uses list maintenance operations. The idea was suggested by Chris. Reviewed by Evan and Dan. Patch is tested and approved by Dan. On normal use-cases compilation speed is not affected. On very big basic blocks there are compilation speedups in the range of 15-20% or even better. llvm-svn: 48822
-
Roman Levenstein authored
llvm-svn: 48819
-
Roman Levenstein authored
This fixes Bugzilla #1835 (http://llvm.org/bugs/show_bug.cgi?id=1835). This patched is reviewed by Tanya and Dan. Dan tested and approved it. The reason for the bad performance of the old algorithm is that it is very naive and scans every time all nodes of the DAG in the worst case. This patch introduces a new algorithm based on the paper "Online algorithms for maintaining the topological order of a directed acyclic graph" by David J.Pearce and Paul H.J.Kelly. This is the MNR algorithm. It has a linear time worst-case and performs much better in most situations. The paper can be found here: http://fano.ics.uci.edu/cites/Document/Online-algorithms-for-maintaining-the-topological-order-of-a-directed-acyclic-graph.html The main idea of the new algorithm is to compute the topological ordering of the SNodes in the DAG and to maintain it even after DAG modifications. The topological ordering allows for very fast node reachability checks. Tests on very big input files with tens of thousands of instructions in a BB indicate huge speed-ups (up to 10x compilation time improvement) compared to the old version. llvm-svn: 48817
-
- Mar 25, 2008
-
-
Dan Gohman authored
marked read-write. Use const so that they can be allocated in a read-only segment. llvm-svn: 48800
-
Evan Cheng authored
Handle a special case xor undef, undef -> 0. Technically this should be transformed to undef. But this is such a common idiom (misuse) we are going to handle it. llvm-svn: 48792
-
Dan Gohman authored
llvm-svn: 48779
-
Evan Cheng authored
llvm-svn: 48755
-