[PATCH] D106922: [Bazel] Make td_library usable as data

Geoffrey Martin-Noble via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 27 17:01:43 PDT 2021


GMNGeoffrey added inline comments.


================
Comment at: utils/bazel/llvm-project-overlay/mlir/tblgen.bzl:105
+    # Note that we include srcs in runfiles. A td_library doesn't compile to
+    # produce on the output: it's just a depset of source files and include
+    # directories. So if it is needed for execution of some rule (likely
----------------
jpienaar wrote:
> "to produce on the output" is difficult to parse for me
That's because it makes no sense :-D Fixed


================
Comment at: utils/bazel/llvm-project-overlay/mlir/tblgen.bzl:267
 
+    # Note: not using merge_all, as that is not available in Bazel 4.0
+    runfiles = ctx.runfiles(
----------------
jpienaar wrote:
> High-level comment here too?
I was less sure on this one since here we're gathering the files that gentbl_test itself needs to execute, which is much more normal. The gathering of runfiles from dependencies is just following the advice at https://docs.bazel.build/versions/main/skylark/rules.html#runfiles.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D106922/new/

https://reviews.llvm.org/D106922



More information about the llvm-commits mailing list