[PATCH] D104480: [Orc] add C-API for transform layer
Lang Hames via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 17 16:12:08 PDT 2021
lhames accepted this revision.
lhames added a comment.
This revision is now accepted and ready to land.
Apart from those two comments, this looks great!
Do you have commit access? If so, land away (with suggested changes), otherwise let me know and I can commit it.
================
Comment at: llvm/include/llvm-c/LLJIT.h:51-59
+/**
+ * A function for applying transformations as part of an transform layer.
+ *
+ * Clients can call LLVMOrcLLJITGetIRTransformLayer to obtain the transform
+ * layer of a LLJIT instance, and use LLVMOrcLLJITIRTransformLayerSetTransform
+ * to set the function. This can be used to override the default transform layer.
+ */
----------------
This isn't LLJIT specific -- It should go in Orc.h.
================
Comment at: llvm/include/llvm-c/LLJIT.h:234-240
+/**
+ * Set the transform function of the provided transform layer, passing through a
+ * pointer to user provided context.
+ */
+void LLVMOrcLLJITIRTransformLayerSetTransform(
+ LLVMOrcIRTransformLayerRef TransformLayer,
+ LLVMOrcIRTransformLayerTransformFunction F, void *Ctx);
----------------
This should go in Orc.h too.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D104480/new/
https://reviews.llvm.org/D104480
More information about the llvm-commits
mailing list