]> granicus.if.org Git - llvm/commitdiff
[BPF] Move InstPrinter files to MCTargetDesc. NFC
authorRichard Trieu <rtrieu@google.com>
Sat, 11 May 2019 01:13:21 +0000 (01:13 +0000)
committerRichard Trieu <rtrieu@google.com>
Sat, 11 May 2019 01:13:21 +0000 (01:13 +0000)
For some targets, there is a circular dependency between InstPrinter and
MCTargetDesc.  Merging them together will fix this.  For the other targets,
the merging is to maintain consistency so all targets will have the same
structure.

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

lib/Target/BPF/BPFAsmPrinter.cpp
lib/Target/BPF/CMakeLists.txt
lib/Target/BPF/InstPrinter/CMakeLists.txt [deleted file]
lib/Target/BPF/InstPrinter/LLVMBuild.txt [deleted file]
lib/Target/BPF/LLVMBuild.txt
lib/Target/BPF/MCTargetDesc/BPFInstPrinter.cpp [moved from lib/Target/BPF/InstPrinter/BPFInstPrinter.cpp with 98% similarity]
lib/Target/BPF/MCTargetDesc/BPFInstPrinter.h [moved from lib/Target/BPF/InstPrinter/BPFInstPrinter.h with 92% similarity]
lib/Target/BPF/MCTargetDesc/BPFMCTargetDesc.cpp
lib/Target/BPF/MCTargetDesc/CMakeLists.txt
lib/Target/BPF/MCTargetDesc/LLVMBuild.txt

index ba4dfa4810dd62f00533e0c8093b4aa766f02ed1..fa114b257dab35d06d320969ff3e66d33a5d1dba 100644 (file)
@@ -16,7 +16,7 @@
 #include "BPFMCInstLower.h"
 #include "BPFTargetMachine.h"
 #include "BTFDebug.h"
-#include "InstPrinter/BPFInstPrinter.h"
+#include "MCTargetDesc/BPFInstPrinter.h"
 #include "llvm/CodeGen/AsmPrinter.h"
 #include "llvm/CodeGen/MachineConstantPool.h"
 #include "llvm/CodeGen/MachineFunctionPass.h"
index c18adf859d352f46fc88b6695758cbb0454ccc37..37c03aa511e3318efc13a9c17d2eddbe6e60a261 100644 (file)
@@ -30,6 +30,5 @@ add_llvm_target(BPFCodeGen
 
 add_subdirectory(AsmParser)
 add_subdirectory(Disassembler)
-add_subdirectory(InstPrinter)
 add_subdirectory(MCTargetDesc)
 add_subdirectory(TargetInfo)
diff --git a/lib/Target/BPF/InstPrinter/CMakeLists.txt b/lib/Target/BPF/InstPrinter/CMakeLists.txt
deleted file mode 100644 (file)
index f9e9161..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-add_llvm_library(LLVMBPFAsmPrinter
-  BPFInstPrinter.cpp
-  )
diff --git a/lib/Target/BPF/InstPrinter/LLVMBuild.txt b/lib/Target/BPF/InstPrinter/LLVMBuild.txt
deleted file mode 100644 (file)
index 6a5b3f5..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-;===- ./lib/Target/BPF/InstPrinter/LLVMBuild.txt ---------------*- Conf -*--===;
-;
-; Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-; See https://llvm.org/LICENSE.txt for license information.
-; SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-;
-;===------------------------------------------------------------------------===;
-;
-; This is an LLVMBuild description file for the components in this subdirectory.
-;
-; For more information on the LLVMBuild system, please see:
-;
-;   http://llvm.org/docs/LLVMBuild.html
-;
-;===------------------------------------------------------------------------===;
-
-[component_0]
-type = Library
-name = BPFAsmPrinter
-parent = BPF
-required_libraries = MC Support
-add_to_library_groups = BPF
index 3cafd1c0acc3fd98c042aa27e732f153cfe4eaa6..9a55d0b1b9bf1f7aa3f8748aef1b18caf0c33d29 100644 (file)
@@ -15,7 +15,7 @@
 ;===------------------------------------------------------------------------===;
 
 [common]
-subdirectories = AsmParser InstPrinter Disassembler MCTargetDesc TargetInfo
+subdirectories = AsmParser Disassembler MCTargetDesc TargetInfo
 
 [component_0]
 type = TargetGroup
@@ -33,7 +33,6 @@ required_libraries =
  CodeGen
  Core
  MC
- BPFAsmPrinter
  BPFDesc
  BPFInfo
  SelectionDAG
similarity index 98%
rename from lib/Target/BPF/InstPrinter/BPFInstPrinter.cpp
rename to lib/Target/BPF/MCTargetDesc/BPFInstPrinter.cpp
index 91411a745d7f6eae30bd16ecbbaaf2282493ec51..079202994c8d7e5f6afd0e2bdd9746a1478efb92 100644 (file)
@@ -10,7 +10,7 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "BPFInstPrinter.h"
+#include "MCTargetDesc/BPFInstPrinter.h"
 #include "llvm/MC/MCAsmInfo.h"
 #include "llvm/MC/MCExpr.h"
 #include "llvm/MC/MCInst.h"
similarity index 92%
rename from lib/Target/BPF/InstPrinter/BPFInstPrinter.h
rename to lib/Target/BPF/MCTargetDesc/BPFInstPrinter.h
index 3472423c46665f94dbedc62c759a19faaa3afd7b..8c9a0bc94cffbad5136d6eb6c1c0c1fed45d6ea6 100644 (file)
@@ -10,8 +10,8 @@
 //
 //===----------------------------------------------------------------------===//
 
-#ifndef LLVM_LIB_TARGET_BPF_INSTPRINTER_BPFINSTPRINTER_H
-#define LLVM_LIB_TARGET_BPF_INSTPRINTER_BPFINSTPRINTER_H
+#ifndef LLVM_LIB_TARGET_BPF_MCTARGETDESC_BPFINSTPRINTER_H
+#define LLVM_LIB_TARGET_BPF_MCTARGETDESC_BPFINSTPRINTER_H
 
 #include "llvm/MC/MCInstPrinter.h"
 
index 037587ff7b29fadfdca1639580cfabe66380c9d7..6a3af28ab3031b9b032c571378f6b88728090271 100644 (file)
@@ -12,7 +12,7 @@
 
 #include "MCTargetDesc/BPFMCTargetDesc.h"
 #include "BPF.h"
-#include "InstPrinter/BPFInstPrinter.h"
+#include "MCTargetDesc/BPFInstPrinter.h"
 #include "MCTargetDesc/BPFMCAsmInfo.h"
 #include "llvm/MC/MCInstrAnalysis.h"
 #include "llvm/MC/MCInstrInfo.h"
index 5fcd8743da536a3cf051aa5b6ba53a71cfd4652c..44f3dbf1ce64f4e2c622cb9593a3e81dab0a18a0 100644 (file)
@@ -1,6 +1,7 @@
 add_llvm_library(LLVMBPFDesc
   BPFMCTargetDesc.cpp
   BPFAsmBackend.cpp
+  BPFInstPrinter.cpp
   BPFMCCodeEmitter.cpp
   BPFELFObjectWriter.cpp
   )
index adfd3e7f91c20b2170aec1356d5a46c4d622f6c6..7c9d9c71ba75786a68c4ab6dc7ec1e7a223d6719 100644 (file)
@@ -18,5 +18,5 @@
 type = Library
 name = BPFDesc
 parent = BPF
-required_libraries = MC BPFAsmPrinter BPFInfo Support
+required_libraries = MC BPFInfo Support
 add_to_library_groups = BPF