Hi all,
I am working on the extraction of the conditional predicates from the
basic blocks using LLVM.
I have written a pass using which i am able to extract the conditional as
well as unconditional branch instructions corresponding to different basic
blocks. I have written a separate tool to extract the control flow graph
(granularity of the level of basic blocks). Now i have to extract the
conditions from the IR which causes the branching.
Now, these predicate are in terms of conditions involving temporary
variables (llvm specific), in order to maintain consistent behaviour when
using this information with anyother simulator, it would be better if these
predicates have syntax very similar (or exactly) as that of the high level
language.
The questions are:
1. Is it possible to somehow intersperse IR and highlevel code of the
program (in C or C++).
2. Is it possible to incorporate some optimizations using llvm-gcc to make
the generated IR very close to the high level language, without affecting
the branch information.
Suggestions and answers are welcome.
Regards
Prabhat
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.llvm.org/pipermail/llvm-dev/attachments/20071219/b3e33f0e/attachment.html>