1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-22 18:54:02 +01:00

[gn build] (manually) Port d6a0560bf258

This commit is contained in:
Nico Weber 2021-03-10 21:56:49 -05:00
parent da49c75c2f
commit 0c13fbf3c6
5 changed files with 33 additions and 2 deletions

View File

@ -158,3 +158,15 @@ clang_tablegen("arm_cde_builtin_aliases") {
args = [ "-gen-arm-cde-builtin-aliases" ]
td_file = "arm_cde.td"
}
# RISC-V
clang_tablegen("riscv_vector_builtins") {
args = [ "-gen-riscv-vector-builtins" ]
td_file = "riscv_vector.td"
}
clang_tablegen("riscv_vector_builtin_cg") {
args = [ "-gen-riscv-vector-builtin-codegen" ]
td_file = "riscv_vector.td"
}

View File

@ -29,6 +29,7 @@ static_library("Basic") {
"//clang/include/clang/Basic:arm_sve_builtins",
"//clang/include/clang/Basic:arm_sve_typeflags",
"//clang/include/clang/Basic:diags_tablegen",
"//clang/include/clang/Basic:riscv_vector_builtins",
"//clang/include/clang/Basic:version",
]
deps = [

View File

@ -5,6 +5,7 @@ static_library("CodeGen") {
"//clang/include/clang/Basic:arm_cde_builtin_cg",
"//clang/include/clang/Basic:arm_mve_builtin_cg",
"//clang/include/clang/Basic:arm_sve_builtin_cg",
"//clang/include/clang/Basic:riscv_vector_builtin_cg",
"//clang/lib/AST",
"//clang/lib/Analysis",
"//clang/lib/Basic",

View File

@ -43,7 +43,21 @@ clang_tablegen("arm_cde") {
output_name = "arm_cde.h"
}
copy("arm_headers") {
# Generate riscv_vector.h
clang_tablegen("riscv_vector") {
args = [ "-gen-riscv-vector-header" ]
td_file = "//clang/include/clang/Basic/riscv_vector.td"
output_name = "riscv_vector.h"
}
# Generate riscv_vector_generic.h
clang_tablegen("riscv_vector_generic") {
args = [ "-gen-riscv-vector-generic-header" ]
td_file = "//clang/include/clang/Basic/riscv_vector.td"
output_name = "riscv_vector_generic.h"
}
copy("tablegen_headers") {
visibility = [ ":Headers" ]
deps = [
":arm_bf16",
@ -52,6 +66,8 @@ copy("arm_headers") {
":arm_mve",
":arm_neon",
":arm_sve",
":riscv_vector",
":riscv_vector_generic",
]
sources = []
foreach(dep, deps) {
@ -61,7 +77,7 @@ copy("arm_headers") {
}
copy("Headers") {
deps = [ ":arm_headers" ]
deps = [ ":tablegen_headers" ]
sources = [
"__clang_cuda_builtin_vars.h",

View File

@ -21,6 +21,7 @@ executable("clang-tblgen") {
"ClangTypeNodesEmitter.cpp",
"MveEmitter.cpp",
"NeonEmitter.cpp",
"RISCVVEmitter.cpp",
"SveEmitter.cpp",
"TableGen.cpp",
]