Open asraa opened 1 month ago
@AlexanderViand-Intel maybe you can explain what part of the boilerplate seems confusing? Is it the invocation of gentbl_cc_library
? as in https://github.com/google/heir/blob/90796977be9b7da90f5dd8bd8a9fbfc75039cc33/lib/Dialect/Secret/Transforms/BUILD#L156C1-L156C18
Less "confusing", just somewhat verbose compared to add_heir_dialect(DialectName)
;)
The "convenience factor" that I like is that the CMake macro automatically generates inc files for ops, types, attributes, enums, etc based on whether the corresponding .td file exits (plus, at least for passes, a few additional rules based on observed use patterns). So there's less changing of build files when you add/remove .td files.
I think I can do that. Only caveat I can see rn is that the dependencies will have to be specified outside the macro.
for cmake:
for bazel: