[llvm] r203699 - Allow exclamation and tilde to be parsed as a part of the ppc asm operand.
Roman Divacky
rdivacky at freebsd.org
Wed Mar 12 12:25:58 PDT 2014
Author: rdivacky
Date: Wed Mar 12 14:25:57 2014
New Revision: 203699
URL: http://llvm.org/viewvc/llvm-project?rev=203699&view=rev
Log:
Allow exclamation and tilde to be parsed as a part of the ppc asm operand.
Modified:
llvm/trunk/lib/Target/PowerPC/AsmParser/PPCAsmParser.cpp
llvm/trunk/test/MC/PowerPC/ppc64-operands.s
Modified: llvm/trunk/lib/Target/PowerPC/AsmParser/PPCAsmParser.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/PowerPC/AsmParser/PPCAsmParser.cpp?rev=203699&r1=203698&r2=203699&view=diff
==============================================================================
--- llvm/trunk/lib/Target/PowerPC/AsmParser/PPCAsmParser.cpp (original)
+++ llvm/trunk/lib/Target/PowerPC/AsmParser/PPCAsmParser.cpp Wed Mar 12 14:25:57 2014
@@ -1205,6 +1205,8 @@ ParseOperand(SmallVectorImpl<MCParsedAsm
case AsmToken::Integer:
case AsmToken::Dot:
case AsmToken::Dollar:
+ case AsmToken::Exclaim:
+ case AsmToken::Tilde:
if (!ParseExpression(EVal))
break;
/* fall through */
Modified: llvm/trunk/test/MC/PowerPC/ppc64-operands.s
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/MC/PowerPC/ppc64-operands.s?rev=203699&r1=203698&r2=203699&view=diff
==============================================================================
--- llvm/trunk/test/MC/PowerPC/ppc64-operands.s (original)
+++ llvm/trunk/test/MC/PowerPC/ppc64-operands.s Wed Mar 12 14:25:57 2014
@@ -113,3 +113,10 @@
# CHECK: # encoding: [0x42,0x00,A,0bAAAAAA00]
bdnz $-8
+
+# CHECK: andi. 0, 3, 32767 # encoding: [0x70,0x60,0x7f,0xff]
+ andi. %r0,%r3,~0x8000 at l
+
+# CHECK: andi. 0, 3, 0 # encoding: [0x70,0x60,0x00,0x00]
+ andi. %r0,%r3,!0x8000 at l
+
More information about the llvm-commits
mailing list