summaryrefslogtreecommitdiffstats
path: root/llvm/docs/TableGenFundamentals.html
diff options
context:
space:
mode:
authorDavid Greene <greened@obbligato.org>2009-05-14 21:54:42 +0000
committerDavid Greene <greened@obbligato.org>2009-05-14 21:54:42 +0000
commit98ed3c7273cbccb69ed322fe2223f3bccd5b7850 (patch)
treec2388cfe7d151c005df6880c92af4a9a0e04ab04 /llvm/docs/TableGenFundamentals.html
parente0dd1d57b3a335362da046e4e6f5ed96880f4d15 (diff)
downloadbcm5719-llvm-98ed3c7273cbccb69ed322fe2223f3bccd5b7850.tar.gz
bcm5719-llvm-98ed3c7273cbccb69ed322fe2223f3bccd5b7850.zip
Implement a !subst operation simmilar to $(subst) in GNU make to do
def/var/string substitution on generic pattern templates. For example: def Type; def v4f32 : Type; def TYPE : Type; class GenType<Type t> { let type = !(subst TYPE, v4f32, t); } def TheType : GenType<TYPE>; llvm-svn: 71801
Diffstat (limited to 'llvm/docs/TableGenFundamentals.html')
-rw-r--r--llvm/docs/TableGenFundamentals.html3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/docs/TableGenFundamentals.html b/llvm/docs/TableGenFundamentals.html
index 48fdd2a2018..0186453f368 100644
--- a/llvm/docs/TableGenFundamentals.html
+++ b/llvm/docs/TableGenFundamentals.html
@@ -404,6 +404,9 @@ the symbol table. If the type of 'a' does not match <em>type</em>, TableGen
aborts with an error. </dd>
<dt><tt>!nameconcat&lt;type&gt;(a, b)</tt></dt>
<dd>Shorthand for !cast<type>(!strconcat(a, b))</dd>
+<dt><tt>!subst(a, b, c)</tt></dt>
+ <dd>If 'a' and 'b' are of string type or are symbol references, substitute
+'b' for 'a' in 'c.' This operation is analogous to $(subst) in GNU make.</dd>
</dl>
<p>Note that all of the values have rules specifying how they convert to values
OpenPOWER on IntegriCloud