mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
change the protocol TargetAsmPArser::MatchInstruction method to take an
MCStreamer to emit into instead of an MCInst to fill in. This allows the matcher extra flexibility and is more convenient. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@115014 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -13,7 +13,7 @@
|
||||
#include "llvm/MC/MCParser/MCAsmParserExtension.h"
|
||||
|
||||
namespace llvm {
|
||||
class MCInst;
|
||||
class MCStreamer;
|
||||
class StringRef;
|
||||
class Target;
|
||||
class SMLoc;
|
||||
@@ -70,16 +70,16 @@ public:
|
||||
/// \param DirectiveID - the identifier token of the directive.
|
||||
virtual bool ParseDirective(AsmToken DirectiveID) = 0;
|
||||
|
||||
/// MatchInstruction - Recognize a series of operands of a parsed instruction
|
||||
/// as an actual MCInst. This returns false and fills in Inst on success and
|
||||
/// returns true on failure to match.
|
||||
/// MatchAndEmitInstruction - Recognize a series of operands of a parsed
|
||||
/// instruction as an actual MCInst and emit it to the specified MCStreamer.
|
||||
/// This returns false on success and returns true on failure to match.
|
||||
///
|
||||
/// On failure, the target parser is responsible for emitting a diagnostic
|
||||
/// explaining the match failure.
|
||||
virtual bool
|
||||
MatchInstruction(SMLoc IDLoc,
|
||||
const SmallVectorImpl<MCParsedAsmOperand*> &Operands,
|
||||
MCInst &Inst) = 0;
|
||||
MatchAndEmitInstruction(SMLoc IDLoc,
|
||||
const SmallVectorImpl<MCParsedAsmOperand*> &Operands,
|
||||
MCStreamer &Out) = 0;
|
||||
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user