diff options
author | Bill Wendling <isanbard@gmail.com> | 2013-02-06 06:52:58 +0000 |
---|---|---|
committer | Bill Wendling <isanbard@gmail.com> | 2013-02-06 06:52:58 +0000 |
commit | 63b8819445c809afcf381bb499d26291c85c45c9 (patch) | |
tree | 63672b925565117faa942e48892d6f380964fab8 /llvm/lib/AsmParser/LLToken.h | |
parent | 821d6af6c22ab33fc8e382e3c1eda5f7849d3ca9 (diff) | |
download | bcm5719-llvm-63b8819445c809afcf381bb499d26291c85c45c9.tar.gz bcm5719-llvm-63b8819445c809afcf381bb499d26291c85c45c9.zip |
Initial submission for the attribute group feature.
Attribute groups are of the form:
#0 = attributes { noinline "no-sse" "cpu"="cortex-a8" alignstack=4 }
Target-dependent attributes are represented as strings. Attributes can have
optional values associated with them. E.g., the "cpu" attribute has the value
"cortex-a8".
Target-independent attributes are listed as enums inside the attribute classes.
Multiple attribute groups can be referenced by the same object. In that case,
the attributes are merged together.
llvm-svn: 174493
Diffstat (limited to 'llvm/lib/AsmParser/LLToken.h')
-rw-r--r-- | llvm/lib/AsmParser/LLToken.h | 43 |
1 files changed, 23 insertions, 20 deletions
diff --git a/llvm/lib/AsmParser/LLToken.h b/llvm/lib/AsmParser/LLToken.h index c9ecd21470c..8c18a3be602 100644 --- a/llvm/lib/AsmParser/LLToken.h +++ b/llvm/lib/AsmParser/LLToken.h @@ -30,6 +30,7 @@ namespace lltok { lparen, rparen, // ( ) backslash, // \ (not /) exclaim, // ! + hash, // # kw_x, kw_true, kw_false, @@ -90,35 +91,36 @@ namespace lltok { kw_ptx_kernel, kw_ptx_device, kw_spir_kernel, kw_spir_func, - kw_signext, - kw_zeroext, + // Attributes: + kw_attributes, + kw_alwaysinline, + kw_address_safety, + kw_byval, + kw_inlinehint, kw_inreg, - kw_sret, - kw_nounwind, - kw_noreturn, + kw_minsize, + kw_naked, + kw_nest, kw_noalias, kw_nocapture, - kw_byval, - kw_nest, + kw_noduplicate, + kw_noimplicitfloat, + kw_noinline, + kw_nonlazybind, + kw_noredzone, + kw_noreturn, + kw_nounwind, + kw_optsize, kw_readnone, kw_readonly, - kw_uwtable, kw_returns_twice, - - kw_inlinehint, - kw_noinline, - kw_alwaysinline, - kw_optsize, + kw_signext, kw_ssp, kw_sspreq, kw_sspstrong, - kw_noredzone, - kw_noimplicitfloat, - kw_naked, - kw_nonlazybind, - kw_address_safety, - kw_minsize, - kw_noduplicate, + kw_sret, + kw_uwtable, + kw_zeroext, kw_type, kw_opaque, @@ -155,6 +157,7 @@ namespace lltok { // Unsigned Valued tokens (UIntVal). GlobalID, // @42 LocalVarID, // %42 + AttrGrpID, // #42 // String valued tokens (StrVal). LabelStr, // foo: |