]> granicus.if.org Git - llvm/commitdiff
[XCore] Fix some Include What You Use warnings; other minor fixes (NFC).
authorEugene Zelenko <eugene.zelenko@gmail.com>
Fri, 3 Feb 2017 21:46:55 +0000 (21:46 +0000)
committerEugene Zelenko <eugene.zelenko@gmail.com>
Fri, 3 Feb 2017 21:46:55 +0000 (21:46 +0000)
This is preparation to reduce MCExpr.h dependencies.

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

lib/Target/XCore/InstPrinter/XCoreInstPrinter.cpp
lib/Target/XCore/InstPrinter/XCoreInstPrinter.h

index 500c84d2a41827f582fc917554bdb757380da25c..b03c1852281d149628e71227a2f50a340e85902f 100644 (file)
 //===----------------------------------------------------------------------===//
 
 #include "XCoreInstPrinter.h"
-#include "llvm/ADT/StringExtras.h"
+#include "llvm/ADT/StringRef.h"
 #include "llvm/MC/MCExpr.h"
 #include "llvm/MC/MCInst.h"
-#include "llvm/MC/MCInstrInfo.h"
 #include "llvm/MC/MCSymbol.h"
+#include "llvm/Support/Casting.h"
 #include "llvm/Support/ErrorHandling.h"
 #include "llvm/Support/raw_ostream.h"
+#include <cassert>
+
 using namespace llvm;
 
 #define DEBUG_TYPE "asm-printer"
index dc513f7b225b176214c84e0266d330c689d87ef0..8a7efe2e39c61a00c1a1583ef178d6292a7b46ea 100644 (file)
@@ -15,6 +15,8 @@
 
 #ifndef LLVM_LIB_TARGET_XCORE_INSTPRINTER_XCOREINSTPRINTER_H
 #define LLVM_LIB_TARGET_XCORE_INSTPRINTER_XCOREINSTPRINTER_H
+
+#include "llvm/ADT/StringRef.h"
 #include "llvm/MC/MCInstPrinter.h"
 
 namespace llvm {
@@ -32,12 +34,14 @@ public:
   void printRegName(raw_ostream &OS, unsigned RegNo) const override;
   void printInst(const MCInst *MI, raw_ostream &O, StringRef Annot,
                  const MCSubtargetInfo &STI) override;
+
 private:
   void printInlineJT(const MCInst *MI, int opNum, raw_ostream &O);
   void printInlineJT32(const MCInst *MI, int opNum, raw_ostream &O);
   void printOperand(const MCInst *MI, unsigned OpNo, raw_ostream &O);
   void printMemOperand(const MCInst *MI, int opNum, raw_ostream &O);
 };
+
 } // end namespace llvm
 
-#endif
+#endif // LLVM_LIB_TARGET_XCORE_INSTPRINTER_XCOREINSTPRINTER_H