summaryrefslogtreecommitdiff
path: root/test/TableGen/MultiClassDefName.td
Commit message (Collapse)AuthorAge
* [TableGen] Correctly generate implicit anonymous prototype defs in multiclassesHal Finkel2014-01-02
| | | | | | | | | | | | | | | | | | | | | | | | | | Even within a multiclass, we had been generating concrete implicit anonymous defs when parsing values (generally in value lists). This behavior was incorrect, and led to errors when multiclass parameters were used in the parameter list of the implicit anonymous def. If we had some multiclass: multiclass mc<string n> { ... : SomeClass<SomeOtherClass<n> > The capture of the multiclass parameter 'n' would not work correctly, and depending on how the implicit SomeOtherClass was used, either TableGen would ignore something it shouldn't, or would crash. To fix this problem, when inside a multiclass, we generate prototype anonymous defs for implicit anonymous defs (just as we do for explicit anonymous defs). Within the multiclass, the current record prototype is populated with a node that is essentially: !cast<SomeOtherClass>(!strconcat(NAME, anon_value_name)). This is then resolved to the correct concrete anonymous def, in the usual way, when NAME is resolved during multiclass instantiation. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@198348 91177308-0d34-0410-b5e6-96231b3b80d8
* [TableGen] Use the same anonymous name as the prefix on all multiclass defsHal Finkel2014-01-02
| | | | | | | | | | | | | | | | TableGen had been generating a different name for an anonymous multiclass's NAME for every def in the multiclass. This had an unfortunate side effect: it was impossible to reference one def within the multiclass from another (in the parameter list, for example). By making sure we only generate an anonymous name once per multiclass (which, as it turns out, requires only changing the name parameter to reference type), we can now concatenate NAME within the multiclass with a def name in order to generate a reference to that def. This does not matter so much, in and of itself, but is necessary for a follow-up commit that will fix variable capturing in implicit anonymous multiclass defs (and that is important). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@198340 91177308-0d34-0410-b5e6-96231b3b80d8
* Mark 36 tests as XFAIL:vg_leak in llvm/test/TableGen.NAKAMURA Takumi2013-11-10
| | | | | | | In historical reason, tblgen is not strictly required to be free from memory leaks. For now, I mark them as XFAIL, they could be fixed, though. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194353 91177308-0d34-0410-b5e6-96231b3b80d8
* FileCheckize some tests.Bill Wendling2013-08-22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@189060 91177308-0d34-0410-b5e6-96231b3b80d8
* llvm/test/TableGen: Remove XFAIL:vg_leak in dozen of tests, according to ↵NAKAMURA Takumi2012-12-11
| | | | | | llvm-x86_64-linux-vg_leak. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169862 91177308-0d34-0410-b5e6-96231b3b80d8
* s/tblgen/llvm-tblgen/g in a few missed places, including the testsPeter Collingbourne2011-10-06
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141294 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for XFAILing valgrind runs with memory leak checking independentlyJeffrey Yasskin2010-03-20
| | | | | | | | | | of runs without leak checking. We add -vg to the triple for non-checked runs, or -vg_leak for checked runs. Also use this to XFAIL the TableGen tests, since tablegen leaks like a sieve. This includes some valgrindArgs refactoring. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@99103 91177308-0d34-0410-b5e6-96231b3b80d8
* Allow multiclass def names to contain "#NAME"" where TableGen replacesDavid Greene2009-05-05
#NAME# with the name of the defm instantiating the multiclass. This is useful for AVX instruction naming where a "V" prefix is standard throughout the ISA. For example: multiclass SSE_AVX_Inst<...> { def SS : Instr<...>; def SD : Instr<...>; def PS : Instr<...>; def PD : Instr<...>; def V#NAME#SS : Instr<...>; def V#NAME#SD : Instr<...>; def V#NAME#PS : Instr<...>; def V#NAME#PD : Instr<...>; } defm ADD : SSE_AVX_Inst<...>; Results in ADDSS ADDSD ADDPS ADDPD VADDSS VADDSD VADDPS VADDPD git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70979 91177308-0d34-0410-b5e6-96231b3b80d8