1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 03:02:36 +01:00
llvm-mirror/test/TableGen
Craig Topper b6cd2e2aef [TableGen] Preserve order of output operands in DAGISelMatcherGen
Summary:
This fixes support in DAGISelMatcher backend for DAG nodes with multiple
result values. Previously the order of results in selected DAG nodes always
matched the order of results in ISel patterns. After the change the order of
results matches the order of operands in OutOperandList instead.

For example, given this definition from the attached test case:

  def INSTR : Instruction {
    let OutOperandList = (outs GPR:$r1, GPR:$r0);
    let InOperandList = (ins GPR:$t0, GPR:$t1);
    let Pattern = [(set i32:$r0, i32:$r1, (udivrem i32:$t0, i32:$t1))];
  }

the DAGISelMatcher backend currently produces a matcher that creates INSTR
nodes with the first result `$r0` and the second result `$r1`, contrary to the
order in the OutOperandList. The order of operands in OutOperandList does not
matter at all, which is unexpected (and unfortunate) because the order of
results of a DAG node does matters, perhaps a lot.

With this change, if the order in OutOperandList does not match the order in
Pattern, DAGISelMatcherGen emits CompleteMatch opcodes with the order of
results taken from OutOperandList. Backend writers can use it to express
result reorderings in TableGen.

If the order in OutOperandList matches the order in Pattern, the result of
DAGISelMatcherGen is unaffected.

Patch by Eugene Sharygin

Reviewers: andreadb, bjope, hfinkel, RKSimon, craig.topper

Reviewed By: craig.topper

Subscribers: nhaehnle, craig.topper, llvm-commits

Differential Revision: https://reviews.llvm.org/D55055

llvm-svn: 348326
2018-12-05 00:47:59 +00:00
..
2003-08-03-PassCode.td
2006-09-18-LargeInt.td
2010-03-24-PrematureDefaults.td
AllowDuplicateRegisterNames.td
ambiguous-composition.td [TableGen] Examine entire subreg compositions to detect ambiguity 2018-11-29 18:20:08 +00:00
AnonDefinitionOnDemand.td
arithmetic.td
AsmPredicateCondsEmission.td
AsmVariant.td
BitOffsetDecoder.td
BitsInit.td
BitsInitOverflow.td
cast-list-initializer.td
cast-multiclass.td [TableGen] fix assert in !cast when used out of definition in a multiclass 2018-10-10 10:52:57 +00:00
cast-typeerror.td
cast.td
ClassInstanceValue.td
code.td
compare.td
ConcatenatedSubregs.td
ConstraintChecking1.td [TableGen] Better error checking for TIED_TO constraints. 2018-11-28 11:43:49 +00:00
ConstraintChecking2.td [TableGen] Better error checking for TIED_TO constraints. 2018-11-28 11:43:49 +00:00
ConstraintChecking3.td [TableGen] Better error checking for TIED_TO constraints. 2018-11-28 11:43:49 +00:00
ConstraintChecking4.td [TableGen] Better error checking for TIED_TO constraints. 2018-11-28 11:43:49 +00:00
ConstraintChecking5.td [TableGen] Better error checking for TIED_TO constraints. 2018-11-28 11:43:49 +00:00
ConstraintChecking6.td [TableGen] Better error checking for TIED_TO constraints. 2018-11-28 11:43:49 +00:00
ConstraintChecking7.td [TableGen] Better error checking for TIED_TO constraints. 2018-11-28 11:43:49 +00:00
ConstraintChecking.inc [TableGen] Better error checking for TIED_TO constraints. 2018-11-28 11:43:49 +00:00
CStyleComment.td
dag-functional.td
dag-isel-res-order.td [TableGen] Preserve order of output operands in DAGISelMatcherGen 2018-12-05 00:47:59 +00:00
Dag.td TableGen: Streamline the semantics of NAME 2018-06-04 14:26:05 +00:00
defmclass.td
DefmInherit.td
DefmInsideMultiClass.td
defset-typeerror.td
defset.td
DuplicateFieldValues.td
eq.td
eqbit.td
FastISelEmitter.td [FastISel] Permit instructions to be skipped for FastISel generation. 2018-05-22 14:36:58 +00:00
FieldAccess.td
foldl.td
foreach-eval.td
foreach-leak.td [TableGen] Don't quote variable name when printing !foreach. 2018-05-02 13:17:26 +00:00
foreach-multiclass.td TableGen: Allow foreach in multiclass to depend on template args 2018-06-21 13:35:44 +00:00
foreach.td
ForeachList.td
ForeachLoop.td
ForwardRef.td
GeneralList.td
generic-tables-instruction.td TableGen/SearchableTables: Support more generic enums and tables 2018-06-21 13:36:22 +00:00
generic-tables.td TableGen/SearchableTables: Support more generic enums and tables 2018-06-21 13:36:22 +00:00
GlobalISelEmitter-PR39045.td [globalisel][tblgen] Table optimization should consider the C++ code in C++ predicates 2018-09-25 17:59:02 +00:00
GlobalISelEmitter.td [globalisel][tablegen] Add support for C++ predicates on PatFrags and use it to support BFC on ARM. 2018-06-15 23:13:43 +00:00
HwModeSelect.td
if-empty-list-arg.td
if-type.td
if.td
ifbit.td
Include.inc
Include.td
IntBitInit.td
intrinsic-long-name.td [IR] Split Intrinsics.inc into enums and implementations 2018-06-23 02:02:38 +00:00
intrinsic-struct.td [IR] Split Intrinsics.inc into enums and implementations 2018-06-23 02:02:38 +00:00
intrinsic-varargs.td [IR] Split Intrinsics.inc into enums and implementations 2018-06-23 02:02:38 +00:00
isa.td
JSON-check.py [TableGen] Add a general-purpose JSON backend. 2018-07-11 08:40:19 +00:00
JSON.td [lit, python] Always add quotes around the python path in lit 2018-08-06 22:37:44 +00:00
LazyChange.td
LetInsideMultiClasses.td
lisp.td TableGen: Streamline the semantics of NAME 2018-06-04 14:26:05 +00:00
list-element-bitref.td
ListArgs.td
ListArgsSimple.td
listconcat.td
ListConversion.td
ListManip.td
ListOfList.td
ListSlices.td
lit.local.cfg
LoLoL.td
math.td
MultiClass-defm-fail.td
MultiClass-defm.td
MultiClass.td
MultiClassDefName.td TableGen: Streamline the semantics of NAME 2018-06-04 14:26:05 +00:00
MultiClassInherit.td
MultiPat.td
name-resolution-consistency.td TableGen: Streamline the semantics of NAME 2018-06-04 14:26:05 +00:00
nested-comment.td
NestedForeach.td TableGen: Allow foreach in multiclass to depend on template args 2018-06-21 13:35:44 +00:00
Paste.td
pr8330.td
prep-diag1.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag2.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag3.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag4.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag5.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag6.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag7.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag8.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag9.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag10.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag11-include.inc [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag11.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag12-include.inc [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag12.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag13.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-diag14.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-region-include.inc [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
prep-region-processing.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
RegisterBankEmitter.td
RegisterEncoder.td
RelTest.td
searchabletables-intrinsic.td TableGen/SearchableTables: Support more generic enums and tables 2018-06-21 13:36:22 +00:00
self-reference-recursion.td
self-reference-typeerror.td
self-reference.td
SetTheory.td
SiblingForeach.td
size.td
Slice.td
strconcat.td
String.td
subst2.td
subst.td TableGen: Streamline the semantics of NAME 2018-06-04 14:26:05 +00:00
SuperSubclassSameName.td
TargetInstrInfo.td
TargetInstrSpec.td
template-arg-dependency.td
TemplateArgRename.td
Tree.td
TreeNames.td
trydecode-emission2.td [GISel]: Add Opcodes for CTLZ/CTTZ/CTPOP 2018-08-04 01:22:12 +00:00
trydecode-emission3.td [GISel]: Add Opcodes for CTLZ/CTTZ/CTPOP 2018-08-04 01:22:12 +00:00
trydecode-emission.td [GISel]: Add Opcodes for CTLZ/CTTZ/CTPOP 2018-08-04 01:22:12 +00:00
TwoLevelName.td
UnsetBitInit.td
unterminated-c-comment-include.inc [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
unterminated-c-comment.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
unterminated-code-block-include.inc [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
unterminated-code-block.td [TableGen] Preprocessing support 2018-11-27 18:57:43 +00:00
UnterminatedComment.td
usevalname.td
ValidIdentifiers.td