diff options
author | Chad Rosier <mcrosier@apple.com> | 2012-10-30 19:11:54 +0000 |
---|---|---|
committer | Chad Rosier <mcrosier@apple.com> | 2012-10-30 19:11:54 +0000 |
commit | 3d71688476951d56ac00a81b17c2f83fd781b208 (patch) | |
tree | 13c4910a677393f45e540d495ba0a5fee1a3f0eb /lib/CodeGen/MachineVerifier.cpp | |
parent | e7b406d7ac150189522f0a139f1a2f76bde2cb26 (diff) | |
download | external_llvm-3d71688476951d56ac00a81b17c2f83fd781b208.zip external_llvm-3d71688476951d56ac00a81b17c2f83fd781b208.tar.gz external_llvm-3d71688476951d56ac00a81b17c2f83fd781b208.tar.bz2 |
[inline asm] Implement mayLoad and mayStore for inline assembly. In general,
the MachineInstr MayLoad/MayLoad flags are based on the tablegen implementation.
For inline assembly, however, we need to compute these based on the constraints.
Revert r166929 as this is no longer needed, but leave the test case in place.
rdar://12033048 and PR13504
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167040 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/MachineVerifier.cpp')
-rw-r--r-- | lib/CodeGen/MachineVerifier.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/CodeGen/MachineVerifier.cpp b/lib/CodeGen/MachineVerifier.cpp index dca68da..69a3ae8 100644 --- a/lib/CodeGen/MachineVerifier.cpp +++ b/lib/CodeGen/MachineVerifier.cpp @@ -707,8 +707,9 @@ void MachineVerifier::verifyInlineAsm(const MachineInstr *MI) { report("Asm string must be an external symbol", MI); if (!MI->getOperand(1).isImm()) report("Asm flags must be an immediate", MI); - // Allowed flags are Extra_HasSideEffects = 1, and Extra_IsAlignStack = 2. - if (!isUInt<2>(MI->getOperand(1).getImm())) + // Allowed flags are Extra_HasSideEffects = 1, Extra_IsAlignStack = 2, + // Extra_AsmDialect = 4, Extra_MayLoad = 8, and Extra_MayStore = 16. + if (!isUInt<5>(MI->getOperand(1).getImm())) report("Unknown asm flags", &MI->getOperand(1), 1); assert(InlineAsm::MIOp_FirstOperand == 2 && "Asm format changed"); |