[cfe-dev] LLVM- AST contents display and dependency analysis
renato.golin at linaro.org
Wed May 13 12:28:11 PDT 2015
On 13 May 2015 at 17:53, Reid Kleckner <rnk at google.com> wrote:
> If you want the AST, you want to use libTooling or libclang to
> programmatically examine the AST. The -ast-dump flag will print the AST for
> debugging purposes, but it cannot be deserialized.
Apologies for the lack of context. I sent him here. :)
Basically, he wants something similar to OpenMP (parallel loops,
separate threads, multi-core CPUs) but without having to specify
pragmas and command line options.
My assumption is that, doing it at the IR level, it's already too
late, because there's a lot of OpenMP that is Clang-based. So, if he
could add a pass (possibly out-of-tree), that could identify loops and
mark them with OpenMP pragmas (as they are, when the pragmas exist in
the source), then he could benefit from OpenMP without requiring the
users to add the pragmas to their sources or add command-line options
to their Makefiles.
In theory, if the toolchain he distributes has lib*omp in the right
place, it should be completely transparent.
Are my assumptions in the right track?
More information about the cfe-dev