summaryrefslogtreecommitdiffstats
path: root/include/llvm/MC
diff options
context:
space:
mode:
Diffstat (limited to 'include/llvm/MC')
-rw-r--r--include/llvm/MC/MCAsmLexer.h3
-rw-r--r--include/llvm/MC/MCParsedAsmOperand.h33
-rw-r--r--include/llvm/MC/MCSymbol.h5
3 files changed, 40 insertions, 1 deletions
diff --git a/include/llvm/MC/MCAsmLexer.h b/include/llvm/MC/MCAsmLexer.h
index da471d2..e9a6e3f 100644
--- a/include/llvm/MC/MCAsmLexer.h
+++ b/include/llvm/MC/MCAsmLexer.h
@@ -20,7 +20,8 @@ class SMLoc;
class Target;
/// AsmToken - Target independent representation for an assembler token.
-struct AsmToken {
+class AsmToken {
+public:
enum TokenKind {
// Markers
Eof, Error,
diff --git a/include/llvm/MC/MCParsedAsmOperand.h b/include/llvm/MC/MCParsedAsmOperand.h
new file mode 100644
index 0000000..7c2f5be
--- /dev/null
+++ b/include/llvm/MC/MCParsedAsmOperand.h
@@ -0,0 +1,33 @@
+//===-- llvm/MC/MCParsedAsmOperand.h - Asm Parser Operand -------*- C++ -*-===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+#ifndef LLVM_MC_MCASMOPERAND_H
+#define LLVM_MC_MCASMOPERAND_H
+
+namespace llvm {
+class SMLoc;
+
+/// MCParsedAsmOperand - This abstract class represents a source-level assembly
+/// instruction operand. It should be subclassed by target-specific code. This
+/// base class is used by target-independent clients and is the interface
+/// between parsing an asm instruction and recognizing it.
+class MCParsedAsmOperand {
+public:
+ MCParsedAsmOperand() {}
+ virtual ~MCParsedAsmOperand() {}
+
+ /// getStartLoc - Get the location of the first token of this operand.
+ virtual SMLoc getStartLoc() const;
+ /// getEndLoc - Get the location of the last token of this operand.
+ virtual SMLoc getEndLoc() const;
+};
+
+} // end namespace llvm.
+
+#endif
diff --git a/include/llvm/MC/MCSymbol.h b/include/llvm/MC/MCSymbol.h
index cfe04d8..eb59453 100644
--- a/include/llvm/MC/MCSymbol.h
+++ b/include/llvm/MC/MCSymbol.h
@@ -136,6 +136,11 @@ namespace llvm {
/// dump - Print the value to stderr.
void dump() const;
+
+ /// printMangledName - Print the specified string in mangled form if it uses
+ /// any unusual characters.
+ static void printMangledName(StringRef Str, raw_ostream &OS,
+ const MCAsmInfo *MAI);
};
} // end namespace llvm
OpenPOWER on IntegriCloud