Add new optimization keywords to the polygen grammar.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76811 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Dan Gohman 2009-07-22 22:45:30 +00:00
parent 08d012eba4
commit bfacb7e057

View File

@ -53,8 +53,8 @@ FPVAL ::= ESAPINTVAL ^ "." ^ EUAPINTVAL | "0x" ^ HexDigitSeq ;
The rest of this file is derived directly from llvmAsmParser.y. The rest of this file is derived directly from llvmAsmParser.y.
*) *)
ArithmeticOps ::= add | fadd | sub | fsub | mul | fmul | ArithmeticOps ::= + OptNW add | fadd | OptNW sub | fsub | OptNW mul | fmul |
udiv | sdiv | fdiv | urem | srem | frem ; udiv | OptExact sdiv | fdiv | urem | srem | frem ;
LogicalOps ::= shl | lshr | ashr | and | or | xor; LogicalOps ::= shl | lshr | ashr | and | or | xor;
CastOps ::= trunc | zext | sext | fptrunc | fpext | bitcast | CastOps ::= trunc | zext | sext | fptrunc | fpext | bitcast |
uitofp | sitofp | fptoui | fptosi | inttoptr | ptrtoint ; uitofp | sitofp | fptoui | fptosi | inttoptr | ptrtoint ;
@ -393,6 +393,10 @@ InstVal ::=
| MemoryInst ; | MemoryInst ;
OptVolatile ::= - volatile | _ ; OptVolatile ::= - volatile | _ ;
OptExact ::= - exact | _ ;
OptNSW ::= - nsw | _ ;
OptNUW ::= - nuw | _ ;
OptNW ::= OptNUW OptNSW ;
MemoryInst ::= malloc Types OptCAlign MemoryInst ::= malloc Types OptCAlign
| malloc Types ^ "," INTTYPE ValueRef OptCAlign | malloc Types ^ "," INTTYPE ValueRef OptCAlign