diff options
author | Dan Gohman <gohman@apple.com> | 2009-01-05 17:29:42 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2009-01-05 17:29:42 +0000 |
commit | 1d59d7843cb1f9d0e513be14f6f45b53ba3d7cbb (patch) | |
tree | f7ccf5aadb07c31206544c6264addc04bc0aaca2 /llvm/utils/llvm.grm | |
parent | 864ac5ad7902e7981378894a54c4873a719872e1 (diff) | |
download | bcm5719-llvm-1d59d7843cb1f9d0e513be14f6f45b53ba3d7cbb.tar.gz bcm5719-llvm-1d59d7843cb1f9d0e513be14f6f45b53ba3d7cbb.zip |
A few more polygen grammar updates.
- After GlobalAssign, emit addrspace before global/constant, to follow
the new syntax.
- Eliminate "type void", which is now invalid.
- Fix invalid liblists like [, "foo"].
- Tweak whitespace in a few places.
llvm-svn: 61706
Diffstat (limited to 'llvm/utils/llvm.grm')
-rw-r--r-- | llvm/utils/llvm.grm | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/llvm/utils/llvm.grm b/llvm/utils/llvm.grm index c5a40cee00f..4095858cd4b 100644 --- a/llvm/utils/llvm.grm +++ b/llvm/utils/llvm.grm @@ -69,7 +69,7 @@ FPType ::= float | double | "ppc_fp128" | fp128 | "x86_fp80"; LocalName ::= LOCALVAR | STRINGCONSTANT | PCTSTRINGCONSTANT ; OptLocalName ::= LocalName | _ ; -OptAddrSpace ::= - addrspace "(" ^ EUINT64VAL ^ ")" | _ ; +OptAddrSpace ::= - addrspace ^ "(" ^ EUINT64VAL ^ ")" | _ ; OptLocalAssign ::= LocalName "=" | _ ; @@ -261,13 +261,12 @@ Definition | declare FunctionProto | - module asm AsmBlock | OptLocalAssign type Types - | OptLocalAssign type void - | OptGlobalAssign GVVisibilityStyle ThreadLocal GlobalType ConstVal - OptAddrSpace GlobalVarAttributes - | OptGlobalAssign GVInternalLinkage GVVisibilityStyle ThreadLocal GlobalType - ConstVal OptAddrSpace GlobalVarAttributes - | OptGlobalAssign GVExternalLinkage GVVisibilityStyle ThreadLocal GlobalType - Types OptAddrSpace GlobalVarAttributes + | OptGlobalAssign GVVisibilityStyle ThreadLocal OptAddrSpace OptAddrSpace + ConstVal GlobalVarAttributes + | OptGlobalAssign GVInternalLinkage GVVisibilityStyle ThreadLocal OptAddrSpace + GlobalType ConstVal GlobalVarAttributes + | OptGlobalAssign GVExternalLinkage GVVisibilityStyle ThreadLocal OptAddrSpace + GlobalType Types GlobalVarAttributes | OptGlobalAssign GVVisibilityStyle alias AliasLinkage AliaseeRef | target TargetDefinition | deplibs "=" LibrariesDefinition @@ -278,9 +277,9 @@ AsmBlock ::= STRINGCONSTANT ; TargetDefinition ::= triple "=" STRINGCONSTANT | datalayout "=" STRINGCONSTANT ; -LibrariesDefinition ::= "[" LibList "]"; +LibrariesDefinition ::= "[" ( LibList | _ ) "]"; -LibList ::= LibList ^ "," STRINGCONSTANT | STRINGCONSTANT | _ ; +LibList ::= LibList ^ "," STRINGCONSTANT | STRINGCONSTANT ; ArgListH ::= ArgListH ^ "," Types OptParamAttrs OptLocalName | Types OptParamAttrs OptLocalName ; @@ -288,7 +287,7 @@ ArgListH ::= ArgListH ^ "," Types OptParamAttrs OptLocalName ArgList ::= ArgListH | ArgListH ^ "," "..." | "..." | _ ; FunctionHeaderH ::= OptCallingConv OptRetAttrs ResultTypes - GlobalName "(" ^ ArgList ^ ")" + GlobalName ^ "(" ^ ArgList ^ ")" OptFuncAttrs OptSection OptAlign OptGC ; BEGIN ::= ( begin | "{" ) ^ "\n"; |