[cfe-dev] TreeTransform for AST tweaking
Ronan KERYELL via cfe-dev
cfe-dev at lists.llvm.org
Fri Aug 25 16:10:16 PDT 2017
Hello!
I work on a SYCL compiler ( https://github.com/triSYCL/triSYCL ) which
is basically implemented as a C++ user-library and some LLVM passes to
separate the host code from the device code and do some code
transformation at the LLVM level to add some runtime glue in between.
But now I need also to fix a few things at the Clang AST level, such as
changing the type of the argument capture of some lambda expressions
before Clang CodeGen.
My plan is to use a TreeTransform but I do not know where to do a
man-in-the-middle attack in Clang to put it at the highest level so I
can fix various things from 1 place with only 1 TreeTransform subclass.
Any hint?
It would be nice if it could be implemented as a Clang plugin to
minimize the intrusion too...
Thank you,
--
Ronan KERYELL
More information about the cfe-dev
mailing list