[llvm-dev] Find loops in LLVM bytecode
Jia-Ju Bai via llvm-dev
llvm-dev at lists.llvm.org
Wed Sep 23 19:22:18 PDT 2015
Thanks, John and Michael.
But I am not used to write LLVM passes. I always write a basic
transformation program to modified LLVM bytecode files.
This transformation program traverses and analyzes instructions,
basicblocks and functions.
Is there a way of extracting loops used for me?
On 09/23/2015 11:50 AM, John Criswell wrote:
> I think you want to look at the LoopInfoWrapperPass (see the doxygen
> at http://llvm.org/doxygen/classllvm_1_1LoopInfoWrapperPass.html).
> Your pass will use the analysis results from LoopInfoWrapperPass to
> get references to LoopInfo objects which can then be used to find
> loops (if memory serves me correctly).
More information about the llvm-dev