@@ -6486,6 +6486,7 @@ cc_library(
64866486 ":Pass" ,
64876487 ":SPIRVCommonAttrToLLVMConversion" ,
64886488 ":SPIRVDialect" ,
6489+ ":SPIRVImageInterfaces" ,
64896490 ":SPIRVUtils" ,
64906491 ":Support" ,
64916492 ":TransformUtils" ,
@@ -7389,14 +7390,16 @@ cc_library(
73897390 ],
73907391)
73917392
7393+ td_library (
7394+ name = "SPIRVImageInterfacesTdFiles" ,
7395+ srcs = ["include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.td" ],
7396+ includes = ["include" ],
7397+ deps = [":OpBaseTdFiles" ],
7398+ )
7399+
73927400td_library (
73937401 name = "SPIRVOpsTdFiles" ,
7394- srcs = glob (["include/mlir/Dialect/SPIRV/IR/*.td" ]) + [
7395- # TODO: resolve circular dep, e.g.
7396- # * SPIRVImageInterfaces.td uses SPIRVBase.td
7397- # * SPIRVOps.h uses SPIRVImageInterfaces.h
7398- "include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.td" ,
7399- ],
7402+ srcs = glob (["include/mlir/Dialect/SPIRV/IR/*.td" ]),
74007403 includes = ["include" ],
74017404 deps = [
74027405 ":BuiltinDialectTdFiles" ,
@@ -7405,10 +7408,43 @@ td_library(
74057408 ":FunctionInterfacesTdFiles" ,
74067409 ":InferTypeOpInterfaceTdFiles" ,
74077410 ":OpBaseTdFiles" ,
7411+ ":SPIRVImageInterfacesTdFiles" ,
74087412 ":SideEffectInterfacesTdFiles" ,
74097413 ],
74107414)
74117415
7416+ gentbl_cc_library (
7417+ name = "SPIRVImageInterfacesIncGen" ,
7418+ tbl_outs = [
7419+ (
7420+ ["-gen-op-interface-decls" ],
7421+ "include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.h.inc" ,
7422+ ),
7423+ (
7424+ ["-gen-op-interface-defs" ],
7425+ "include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.cpp.inc" ,
7426+ ),
7427+ ],
7428+ tblgen = ":mlir-tblgen" ,
7429+ td_file = "include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.td" ,
7430+ deps = [
7431+ ":SPIRVImageInterfacesTdFiles" ,
7432+ ":SPIRVOpsTdFiles" ,
7433+ ],
7434+ )
7435+
7436+ cc_library (
7437+ name = "SPIRVImageInterfaces" ,
7438+ srcs = ["lib/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.cpp" ],
7439+ hdrs = ["include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.h" ],
7440+ includes = ["include" ],
7441+ deps = [
7442+ ":IR" ,
7443+ ":SPIRVImageInterfacesIncGen" ,
7444+ "//llvm:Support" ,
7445+ ],
7446+ )
7447+
74127448gentbl_cc_library (
74137449 name = "SPIRVOpsIncGen" ,
74147450 tbl_outs = [
@@ -7536,33 +7572,14 @@ gentbl_cc_library(
75367572 deps = [":SPIRVOpsTdFiles" ],
75377573)
75387574
7539- gentbl_cc_library (
7540- name = "SPIRVImageInterfacesIncGen" ,
7541- tbl_outs = [
7542- (
7543- ["-gen-op-interface-decls" ],
7544- "include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.h.inc" ,
7545- ),
7546- (
7547- ["-gen-op-interface-defs" ],
7548- "include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.cpp.inc" ,
7549- ),
7550- ],
7551- tblgen = ":mlir-tblgen" ,
7552- td_file = "include/mlir/Dialect/SPIRV/Interfaces/SPIRVImageInterfaces.td" ,
7553- deps = [":SPIRVOpsTdFiles" ],
7554- )
7555-
75567575cc_library (
75577576 name = "SPIRVDialect" ,
75587577 srcs = glob ([
75597578 "lib/Dialect/SPIRV/IR/*.cpp" ,
75607579 "lib/Dialect/SPIRV/IR/*.h" ,
7561- "lib/Dialect/SPIRV/Interfaces/*.cpp" ,
75627580 ]),
75637581 hdrs = glob ([
75647582 "include/mlir/Dialect/SPIRV/IR/*.h" ,
7565- "include/mlir/Dialect/SPIRV/Interfaces/*.h" ,
75667583 ]),
75677584 includes = ["include" ],
75687585 deps = [
@@ -7580,7 +7597,7 @@ cc_library(
75807597 ":SPIRVAttributesIncGen" ,
75817598 ":SPIRVAvailabilityIncGen" ,
75827599 ":SPIRVCanonicalizationIncGen" ,
7583- ":SPIRVImageInterfacesIncGen " ,
7600+ ":SPIRVImageInterfaces " ,
75847601 ":SPIRVOpsIncGen" ,
75857602 ":SideEffectInterfaces" ,
75867603 ":Support" ,
0 commit comments