aboutsummaryrefslogtreecommitdiffstats
path: root/lib/AsmParser
diff options
context:
space:
mode:
authorZhou Sheng <zhousheng00@gmail.com>2007-06-05 05:28:26 +0000
committerZhou Sheng <zhousheng00@gmail.com>2007-06-05 05:28:26 +0000
commitfebca3499e5624361142dda2cb3c2ea806bfcdb6 (patch)
tree310a377dac8a301e5e87a1cf852c71b416d56a19 /lib/AsmParser
parent45beb482c4f7c30f4d0bce962e4491ba2abc2e78 (diff)
downloadexternal_llvm-febca3499e5624361142dda2cb3c2ea806bfcdb6.zip
external_llvm-febca3499e5624361142dda2cb3c2ea806bfcdb6.tar.gz
external_llvm-febca3499e5624361142dda2cb3c2ea806bfcdb6.tar.bz2
Commit first round work of PR1373. "noalias" is now fully supported in
VMCore, BitCode, and Assembly. Documentation and test case paramattrs.ll updated also. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37432 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AsmParser')
-rw-r--r--lib/AsmParser/Lexer.l1
-rw-r--r--lib/AsmParser/llvmAsmParser.y11
2 files changed, 7 insertions, 5 deletions
diff --git a/lib/AsmParser/Lexer.l b/lib/AsmParser/Lexer.l
index ca6ee2c..6391d17 100644
--- a/lib/AsmParser/Lexer.l
+++ b/lib/AsmParser/Lexer.l
@@ -229,6 +229,7 @@ inreg { return INREG; }
sret { return SRET; }
nounwind { return NOUNWIND; }
noreturn { return NORETURN; }
+noalias { return NOALIAS; }
void { RET_TY(Type::VoidTy, VOID); }
float { RET_TY(Type::FloatTy, FLOAT); }
diff --git a/lib/AsmParser/llvmAsmParser.y b/lib/AsmParser/llvmAsmParser.y
index 01d67ed..94aeeca 100644
--- a/lib/AsmParser/llvmAsmParser.y
+++ b/lib/AsmParser/llvmAsmParser.y
@@ -1101,7 +1101,7 @@ Module *llvm::RunVMAsmParser(const char * AsmString, Module * M) {
%token <OtherOpVal> EXTRACTELEMENT INSERTELEMENT SHUFFLEVECTOR
// Function Attributes
-%token NORETURN INREG SRET NOUNWIND
+%token NORETURN INREG SRET NOUNWIND NOALIAS
// Visibility Styles
%token DEFAULT HIDDEN PROTECTED
@@ -1224,10 +1224,11 @@ OptCallingConv : /*empty*/ { $$ = CallingConv::C; } |
CHECK_FOR_ERROR
};
-ParamAttr : ZEXT { $$ = ParamAttr::ZExt; }
- | SEXT { $$ = ParamAttr::SExt; }
- | INREG { $$ = ParamAttr::InReg; }
- | SRET { $$ = ParamAttr::StructRet; }
+ParamAttr : ZEXT { $$ = ParamAttr::ZExt; }
+ | SEXT { $$ = ParamAttr::SExt; }
+ | INREG { $$ = ParamAttr::InReg; }
+ | SRET { $$ = ParamAttr::StructRet; }
+ | NOALIAS { $$ = ParamAttr::NoAlias; }
;
OptParamAttrs : /* empty */ { $$ = ParamAttr::None; }