summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp
diff options
context:
space:
mode:
authorDaniel Sanders <daniel_l_sanders@apple.com>2019-12-17 14:29:14 +0000
committerDaniel Sanders <daniel_l_sanders@apple.com>2019-12-17 15:28:03 +0000
commit390c8baa5440dda8907688d9ef860f6982bd925f (patch)
treec2d470b68485ff8670787a354397c76fb9826183 /llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp
parent268f37df6e45c4b0603bd4d964483a0d84da44c1 (diff)
downloadbcm5719-llvm-390c8baa5440dda8907688d9ef860f6982bd925f.tar.gz
bcm5719-llvm-390c8baa5440dda8907688d9ef860f6982bd925f.zip
[gicombiner] Add the MatchDag structure and parse instruction DAG's from the input
Summary: The MatchDag structure is a representation of the checks that need to be performed and the dependencies that limit when they can happen. There are two kinds of node in the MatchDag: * Instrs - Represent a MachineInstr * Predicates - Represent a check that needs to be performed (i.e. opcode, is register, same machine operand, etc.) and two kinds of edges: * (Traversal) Edges - Represent a register that can be traversed to find one instr from another * Predicate Dependency Edges - Indicate that a predicate requires a piece of information to be tested. For example, the matcher: (match (MOV $t, $s), (MOV $d, $t)) with MOV declared as an instruction of the form: %dst = MOV %src1 becomes the following MatchDag with the following instruction nodes: __anon0_0 // $t=getOperand(0), $s=getOperand(1) __anon0_1 // $d=getOperand(0), $t=getOperand(1) traversal edges: __anon0_1[src1] --[t]--> __anon0_0[dst] predicate nodes: <<$mi.getOpcode() == MOV>>:$__anonpred0_2 <<$mi.getOpcode() == MOV>>:$__anonpred0_3 and predicate dependencies: __anon0_0 ==> __anonpred0_2[mi] __anon0_0 ==> __anonpred0_3[mi] The result of this parse is currently unused but can be tested using -gicombiner-stop-after-parse as done in parse-match-pattern.td. The dump for testing includes a graphviz format dump to allow the rule to be viewed visually. Later on, these MatchDag's will be used to generate code and to build an efficient decision tree. Reviewers: volkan, bogner Reviewed By: volkan Subscribers: arsenm, mgorny, mgrang, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D69077
Diffstat (limited to 'llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud