Skip to content

Commit

Permalink
[bazel]Fix bazel build past 2e6cc79 (llvm#124112)
Browse files Browse the repository at this point in the history
Split target under LLVMIR/Transforms to avoid deps loop.
  • Loading branch information
dklimkin authored Jan 23, 2025
1 parent 90e9895 commit 0c66644
Showing 1 changed file with 36 additions and 5 deletions.
41 changes: 36 additions & 5 deletions utils/bazel/llvm-project-overlay/mlir/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -5545,10 +5545,22 @@ gentbl_cc_library(

cc_library(
name = "LLVMIRTransforms",
srcs = glob([
"lib/Dialect/LLVMIR/Transforms/*.cpp",
]),
hdrs = glob(["include/mlir/Dialect/LLVMIR/Transforms/*.h"]),
srcs = glob(
[
"lib/Dialect/LLVMIR/Transforms/*.cpp",
],
exclude = ["lib/Dialect/LLVMIR/Transforms/LegalizeForExport.cpp"],
),
hdrs = glob(
[
"include/mlir/Dialect/LLVMIR/Transforms/*.h",
],
exclude = [
"include/mlir/Dialect/LLVMIR/Transforms/DIExpressionLegalization.h",
"include/mlir/Dialect/LLVMIR/Transforms/DIExpressionRewriter.h",
"include/mlir/Dialect/LLVMIR/Transforms/LegalizeForExport.h",
],
),
includes = ["include"],
deps = [
":Analysis",
Expand All @@ -5557,6 +5569,7 @@ cc_library(
":IR",
":InliningUtils",
":LLVMDialect",
":LLVMIRTransformsLegalizeForExport",
":LLVMPassIncGen",
":NVVMDialect",
":Pass",
Expand All @@ -5567,6 +5580,23 @@ cc_library(
],
)

cc_library(
name = "LLVMIRTransformsLegalizeForExport",
srcs = ["lib/Dialect/LLVMIR/Transforms/LegalizeForExport.cpp"],
hdrs = [
"include/mlir/Dialect/LLVMIR/Transforms/DIExpressionLegalization.h",
"include/mlir/Dialect/LLVMIR/Transforms/DIExpressionRewriter.h",
"include/mlir/Dialect/LLVMIR/Transforms/LegalizeForExport.h",
],
includes = ["include"],
deps = [
":IR",
":LLVMPassIncGen",
":LLVMDialect",
":Pass",
],
)

td_library(
name = "GPUOpsTdFiles",
srcs = [
Expand Down Expand Up @@ -6459,6 +6489,7 @@ cc_library(
":NVVMOpsIncGen",
":SideEffectInterfaces",
":Support",
":ToLLVMIRTranslation",
"//llvm:AsmParser",
"//llvm:Core",
"//llvm:Support",
Expand Down Expand Up @@ -9212,8 +9243,8 @@ cc_library(
":IR",
":LLVMConversionIncGen",
":LLVMDialect",
":LLVMIRTransforms",
":LLVMIntrinsicConversionIncGen",
":LLVMIRTransformsLegalizeForExport",
":OpenMPDialect",
":Support",
":TransformUtils",
Expand Down

0 comments on commit 0c66644

Please sign in to comment.