"//llvm/lib/Support",
"//llvm/lib/Target/WebAssembly/MCTargetDesc",
"//llvm/lib/Target/WebAssembly/TargetInfo",
+ "//llvm/lib/Target/WebAssembly/Utils",
]
include_dirs = [ ".." ]
sources = [ "WebAssemblyAsmParser.cpp" ]
"WebAssemblyTargetMachine.cpp",
"WebAssemblyTargetObjectFile.cpp",
"WebAssemblyTargetTransformInfo.cpp",
- "WebAssemblyUtilities.cpp",
]
}
"//llvm/lib/Support",
"//llvm/lib/Target/WebAssembly/MCTargetDesc",
"//llvm/lib/Target/WebAssembly/TargetInfo",
+ "//llvm/lib/Target/WebAssembly/Utils",
]
include_dirs = [ ".." ]
sources = [ "WebAssemblyDisassembler.cpp" ]
}
tablegen("WebAssemblyGenRegisterInfo") {
- visibility = [ ":MCTargetDesc" ]
+ visibility = [ ":tablegen" ]
args = [ "-gen-register-info" ]
td_file = "../WebAssembly.td"
}
td_file = "../WebAssembly.td"
}
+# This should contain tablegen targets generating .inc files included
+# by other targets. .inc files only used by .cpp files in this directory
+# should be in deps on the static_library instead.
+group("tablegen") {
+ visibility = [
+ ":MCTargetDesc",
+ "../Utils",
+ ]
+ public_deps = [ ":WebAssemblyGenRegisterInfo" ]
+}
+
static_library("MCTargetDesc") {
output_name = "LLVMWebAssemblyDesc"
# by other targets. .inc files only used by .cpp files in this directory
# should be in deps instead.
public_deps = [
- ":WebAssemblyGenRegisterInfo",
+ ":tablegen",
":WebAssemblyGenSubtargetInfo",
]
deps = [
"//llvm/lib/MC",
"//llvm/lib/Support",
"//llvm/lib/Target/WebAssembly/TargetInfo",
+ "//llvm/lib/Target/WebAssembly/Utils",
]
include_dirs = [ ".." ]
sources = [
--- /dev/null
+static_library("Utils") {
+ output_name = "LLVMWebAssemblyUtils"
+ deps = [
+ "//llvm/lib/CodeGen",
+ "//llvm/lib/IR",
+ "//llvm/lib/MC",
+ "//llvm/lib/Support",
+
+ # MCTargetDesc depends on Utils, so we can't depend on the full
+ # MCTargetDesc target here: it would form a cycle.
+ "//llvm/lib/Target/WebAssembly/MCTargetDesc:tablegen",
+ "//llvm/lib/Target/WebAssembly/TargetInfo",
+ ]
+ include_dirs = [ ".." ]
+ sources = [
+ "WebAssemblyUtilities.cpp",
+ "WebAssemblyTypeUtilities.cpp",
+ ]
+}