OSDN Git Service

clean Lanai namespace
authorJacques Pienaar <jpienaar@google.com>
Thu, 16 Mar 2017 23:22:10 +0000 (23:22 +0000)
committerJacques Pienaar <jpienaar@google.com>
Thu, 16 Mar 2017 23:22:10 +0000 (23:22 +0000)
Summary: This patch cleans the namespace of the Lanai target.

Reviewers: jpienaar

Reviewed By: jpienaar

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D30955

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@298015 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/Lanai/AsmParser/LanaiAsmParser.cpp
lib/Target/Lanai/MCTargetDesc/LanaiMCCodeEmitter.cpp

index 57ead97..1d6c079 100644 (file)
@@ -1096,7 +1096,7 @@ StringRef LanaiAsmParser::splitMnemonic(StringRef Name, SMLoc NameLoc,
   return Mnemonic;
 }
 
-bool IsMemoryAssignmentError(const OperandVector &Operands) {
+static bool IsMemoryAssignmentError(const OperandVector &Operands) {
   // Detects if a memory operation has an erroneous base register modification.
   // Memory operations are detected by matching the types of operands.
   //
index f5b5335..1025467 100644 (file)
@@ -89,7 +89,7 @@ public:
 
 } // end anonymous namespace
 
-Lanai::Fixups FixupKind(const MCExpr *Expr) {
+static Lanai::Fixups FixupKind(const MCExpr *Expr) {
   if (isa<MCSymbolRefExpr>(Expr))
     return Lanai::FIXUP_LANAI_21;
   if (const LanaiMCExpr *McExpr = dyn_cast<LanaiMCExpr>(Expr)) {
@@ -134,8 +134,8 @@ unsigned LanaiMCCodeEmitter::getMachineOpValue(
 }
 
 // Helper function to adjust P and Q bits on load and store instructions.
-unsigned adjustPqBits(const MCInst &Inst, unsigned Value, unsigned PBitShift,
-                      unsigned QBitShift) {
+static unsigned adjustPqBits(const MCInst &Inst, unsigned Value,
+                             unsigned PBitShift, unsigned QBitShift) {
   const MCOperand AluOp = Inst.getOperand(3);
   unsigned AluCode = AluOp.getImm();