summaryrefslogtreecommitdiffstats
path: root/llvm/utils/TableGen/DAGISelMatcherEmitter.cpp
Commit message (Collapse)AuthorAgeFilesLines
* rename PushMatcherNode -> ScopeMatcherNode to more accuratelyChris Lattner2010-02-251-9/+9
| | | | | | | reflect what it does. Switch the sense of the Next and the Check arms to be more logical. No functionality change. llvm-svn: 97093
* contract movechild+checktype into a new checkchild node, shrinking theChris Lattner2010-02-241-1/+7
| | | | | | x86 table by 1200 bytes. llvm-svn: 97053
* emit a histogram of the opcodes in comments.Chris Lattner2010-02-241-2/+59
| | | | llvm-svn: 97047
* Since the new instruction selector now works, I don't need to keepChris Lattner2010-02-241-1/+1
| | | | | | | | the old one around for comparative purposes: have the ENABLE_NEW_ISEL #define (which is not enabled on mainline) stop emitting the old isel at all, yay for build time win. llvm-svn: 97033
* implement a simple proof-of-concept optimization forChris Lattner2010-02-241-0/+7
| | | | | | | | the new isel: fold movechild+record+moveparent into a single recordchild N node. This shrinks the X86 table from 125443 to 117502 bytes. llvm-svn: 97031
* The new isel was not properly handling patterns that coveredChris Lattner2010-02-241-0/+9
| | | | | | | | | internal nodes with flag results. Record these with a new OPC_MarkFlagResults opcode and use this to update the interior nodes' flag results properly. This fixes CodeGen/X86/i256-add.ll with the new isel. llvm-svn: 97021
* really fix an off-by-one errorChris Lattner2010-02-231-1/+1
| | | | llvm-svn: 96845
* switch the value# in OPC_CompleteMatch and OPC_EmitNode to use aChris Lattner2010-02-231-5/+29
| | | | | | VBR encoding for the insanity being perpetrated by the spu backend. llvm-svn: 96843
* add a new Push2 opcode for targets (like cellspu) which haveChris Lattner2010-02-221-5/+18
| | | | | | | | ridiculously ginormous patterns and need more than one byte of displacement for encodings. This fixes CellSPU/fdiv.ll. SPU is still doing something else ridiculous though. llvm-svn: 96833
* add a new CheckMultiOpcode opcode for checking that a nodeChris Lattner2010-02-221-0/+9
| | | | | | | has one of the list of acceptable opcodes for a complex pattern. This fixes 4 regtest failures. llvm-svn: 96814
* emit table indexes before each row so that it is debuggable.Chris Lattner2010-02-211-7/+11
| | | | llvm-svn: 96730
* fix a table size miscomputation, target opcodes are 2 bytes.Chris Lattner2010-02-211-1/+1
| | | | | | | With this, the matcher actually works reasonably well, but crashes on larger examples in the scheduler. llvm-svn: 96727
* emit to the right streams, to avoid emitting the pushChris Lattner2010-02-211-15/+16
| | | | | | body before the push. llvm-svn: 96726
* implement the last known missing feature: updating uses of results Chris Lattner2010-02-211-5/+11
| | | | | | | of the matched pattern to use the newly created node results. Onto the "making it actually work" phase! llvm-svn: 96724
* Lots of improvements to the new dagisel emitter. This gets it toChris Lattner2010-02-211-18/+126
| | | | | | | | | | | | | | | | | | | the point where it is to the 95% feature complete mark, it just needs result updating to be done (then testing, optimization etc). More specificallly, this adds support for chain and flag handling on the result nodes, support for sdnodexforms, support for variadic nodes, memrefs, pinned physreg inputs, and probably lots of other stuff. In the old DAGISelEmitter, this deletes the dead code related to OperatorMap, cleans up a variety of dead stuff handling "implicit remapping" from things like globaladdr -> targetglobaladdr (which is no longer used because globaladdr always needs to be legalized), and some minor formatting fixes. llvm-svn: 96716
* add emitter support for integer constants and simple physreg references.Chris Lattner2010-02-191-3/+14
| | | | llvm-svn: 96663
* add support for referencing registers and immediates,Chris Lattner2010-02-181-2/+7
| | | | | | | building the tree to represent them but not emitting table entries for them yet. llvm-svn: 96617
* start sketching out the structure of code for result emission generation.Chris Lattner2010-02-181-0/+3
| | | | | | Nothing real here yet. llvm-svn: 96575
* rename the child field to 'next'. This is not a parent/child Chris Lattner2010-02-181-12/+12
| | | | | | relationship, this is a linear list relationship. llvm-svn: 96561
* eliminate the MatcherNodeWithChild class, give the 'child'Chris Lattner2010-02-181-5/+3
| | | | | | field to MatcherNode. llvm-svn: 96560
* improve comments, the matcher is now feature complete, on to codegen.Chris Lattner2010-02-171-1/+5
| | | | llvm-svn: 96464
* Emulate the current isel's "IsChainCompatible" logic for now.Chris Lattner2010-02-171-0/+4
| | | | | | | I'd like to eventually rip it out, but for now producing the same selections as the old matcher is more important. llvm-svn: 96458
* improve comments on OPC_Record to say what we're recording a node.Chris Lattner2010-02-171-1/+3
| | | | llvm-svn: 96433
* improve comments in generated matcher a bit.Chris Lattner2010-02-171-12/+12
| | | | llvm-svn: 96422
* make the new isel generator plop out a CheckComplexPattern functionChris Lattner2010-02-171-2/+40
| | | | | | | for evaluating complex patterns. Some cleanup has to happen before this can be used though. llvm-svn: 96419
* convert the new matcher to check intermediate nodes for a singleChris Lattner2010-02-161-5/+2
| | | | | | | | | use and only call IsProfitableToFold/IsLegalToFold on the load being folded, like the old dagiselemitter does. This substantially simplifies the code and improves opportunities for sharing. llvm-svn: 96368
* generate code for node and pattern predicates. Note that this won'tChris Lattner2010-02-161-11/+58
| | | | | | | build if enabled, it will fail with constness issues. I'll resolve these next. llvm-svn: 96336
* refactor some code into a local class.Chris Lattner2010-02-161-14/+22
| | | | llvm-svn: 96334
* add support for the new isel matcher to generate Chris Lattner2010-02-161-0/+6
| | | | | | (isprofitable|islegal)tofold checks. llvm-svn: 96331
* Check in the first big step of rewriting DAGISelEmitter to Chris Lattner2010-02-151-0/+217
produce a table based matcher instead of gobs of C++ Code. Though it's not done yet, the shrinkage seems promising, the table for the X86 ISel is 75K and still has a lot of optimization to come (compare to the ~1.5M of .o generated the old way, much of which will go away). The code is currently disabled by default (the #if 0 in DAGISelEmitter.cpp). When enabled it generates a dead SelectCode2 function in the DAGISel Header which will eventually replace SelectCode. There is still a lot of stuff left to do, which are documented with a trail of FIXMEs. llvm-svn: 96215
OpenPOWER on IntegriCloud