Displaying 20 results from an estimated 10000 matches similar to: "[LLVMdev] GlobalsModRef"
2011 Nov 19
0
[LLVMdev] GlobalsModRef
Hi Jorge,
> I'm implementing an intra-procedural analysis. For correctness, during
> the analysis of each function I need to know which global variables
> may be modified by other functions in order to avoid wrong assumptions
> about those variables.
>
> I looked at lib/Analysis/IPA/GlobalsModRef.cpp and it seems that it
> does what I want. My problem is that I don't
2012 Aug 06
3
[LLVMdev] How to call some transformation passes (LoopRotate and LoopUnroll) from my own pass
Hello,
I wrote my own pass which needs to do some loop unrolling.
I can perform loop unrolling via opt:
opt -mem2reg -loops -loop-simplify -loop-rotate -lcssa -loop-unroll
-unroll-count=50 mytest.bc -o mytest.bc
This command works perfectly.
However, what I really want is to produce the **same behavior** but
from my own pass (i.e., I don't want to use opt). I wrote a Module
pass which
2012 Mar 23
3
[LLVMdev] Function Pass Manager
Hi,
I'm writing a function pass which is dynamically loaded by opt and I
need some analysis and passes to be run before my pass:
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
AU.addRequired<LoopInfo>();
AU.addPreserved<LoopInfo>();
AU.addRequiredID(LoopSimplifyID);
AU.addPreservedID(LoopSimplifyID);
2018 Jan 28
4
Polly Dependency Analysis in MyPass
Hello,
I need to analyze dependencies in my llvm ir by using polly. i created a
new pass called mypass there i added polly dependency analysis pass but
when i execute this pass in gdb i get no data.
Why is that so?
My code is follows;
namespace {
struct mypass : public FunctionPass {
static char ID;
mypass() : FunctionPass(ID) {
}
virtual bool runOnFunction(Function &F)
{
2011 May 30
1
[LLVMdev] about writing a functionpass requiring a modulepass
---------- Forwarded message ----------
From: Qingan Li <ww345ww at gmail.com>
Date: 2011/5/30
Subject:
To: llvmdev at cs.uiuc.edu
Hi,
I wrote an analysis pass, myPass, inherited from both ModulePass and
ProfileInfo, and this pass requires the CallGraph, i.e.,
* class myPass : public ModulePass, public ProfileInfo { ...};*
* void myPass::getAnalysisUsage(AnalysisUsage &AU) const
2018 Jan 29
0
Polly Dependency Analysis in MyPass
How do you compile the code? Within the Polly subdirectory using CMake?
How do you run your pass. Using "opt -mypass inputfile.ll"?
Michael
2018-01-28 9:30 GMT-06:00 hameeza ahmed via llvm-dev <llvm-dev at lists.llvm.org>:
> Hello,
>
> I need to analyze dependencies in my llvm ir by using polly. i created a new
> pass called mypass there i added polly dependency
2002 Nov 03
2
[LLVMdev] getAnalysis()
I'm having trouble with using getAnalysis() to access the results of one
pass from within another. I require the pass to be previously executed
as follows:
void MyPass::getAnalysisUsage(AnalysisUsage &Info) const {
Info.addRequired<TDDataStructures>();
}
Then I try to use it as follows:
bool MyPass::doInitialization(Module &M) {
TDDataStructures &dsgraph =
2010 Jul 22
3
[LLVMdev] Controlling the order of a FunctionPass
On Jul 22, 2010, at 2:05 PM, John Criswell wrote:
> If you write your pass as a ModulePass, then you can iterate over the
> functions in any order that you want.
I had considered that, but my FunctionPass depends on other passes
processing the functions first:
void MyPass::getAnalysisUsage(AnalysisUsage &AU) const {
AU.addRequired<UnifyFunctionExitNodes>();
2012 Aug 06
0
[LLVMdev] How to call some transformation passes (LoopRotate and LoopUnroll) from my own pass
On Aug 6, 2012, at 6:04 AM, Jorge Navas <navas at comp.nus.edu.sg> wrote:
>
> Hello,
>
> I wrote my own pass which needs to do some loop unrolling.
>
> I can perform loop unrolling via opt:
>
> opt -mem2reg -loops -loop-simplify -loop-rotate -lcssa -loop-unroll
> -unroll-count=50 mytest.bc -o mytest.bc
>
> This command works perfectly.
>
>
2011 Nov 21
5
[LLVMdev] Fwd: Problem getting LoopInfo inside non-LoopPass
I would have thought this would have been possible.
On Thu, Nov 17, 2011 at 3:49 PM, Ryan Taylor <ryta1203 at gmail.com> wrote:
> So is this simply not possible?
>
>
> On Thu, Nov 17, 2011 at 10:31 AM, Ryan Taylor <ryta1203 at gmail.com> wrote:
>
>> Nick,
>>
>> Thanks for this info, though this didn't help my problem at all.
>>
>>
2012 Apr 12
0
[LLVMdev] Function Pass Manager
Hi again,
I come back to this issue with an example. It's a pass which does
nothing but throw the 'Unable to schedule' error.
namespace {
struct MyPass : public FunctionPass {
static char ID; // Pass identification, replacement for typeid
MyPass() : FunctionPass(ID) {
initializeMyPassPass(*PassRegistry::getPassRegistry());
}
virtual void
2011 Nov 30
0
[LLVMdev] Fwd: Problem getting LoopInfo inside non-LoopPass
The following code is causing an "UNREACHABLE executed!" and a stack dump,
any ideas?
namespace {
struct myPass : public CallGraphSCCPass {
static char ID;
myPass() : CallGraphSCCPass(ID) {}
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
AU.setPreservesAll();
AU.addRequired<LoopInfo>();
}
virtual bool runOnSCC(CallGraphSCC &SCC)
2011 Nov 30
2
[LLVMdev] Fwd: Problem getting LoopInfo inside non-LoopPass
On Tue, Nov 29, 2011 at 6:59 PM, Ryan Taylor <ryta1203 at gmail.com> wrote:
> The following code is causing an "UNREACHABLE executed!" and a stack dump,
> any ideas?
The stack might be handy.
> namespace {
> struct myPass : public CallGraphSCCPass {
> static char ID;
> myPass() : CallGraphSCCPass(ID) {}
> virtual void getAnalysisUsage(AnalysisUsage
2013 Mar 03
1
[LLVMdev] Can a Function Pass require a Module Pass?
Dear LLVMers,
I am implementing a Function Pass and I would like to use analysis obtained
from a Module Pass. Some extracts of my code look like that:
struct MyPass : public FunctionPass {
static char ID;
MyPass() : FunctionPass(ID) {
PADriver &PD = getAnalysis<AModulePass>();
...
virtual void getAnalysisUsage(AnalysisUsage &AU) const{
2009 Apr 09
3
[LLVMdev] Pass Manager Restriction?
Having a ModulePass that requires a FunctionPass that in turn requires
another ModulePass results in an assertion being fired. Is this
expected behavior (that seems to be undocumented), or a bug?
Specifically, the following code will emit the assertion:
[VMCore/PassManager.cpp:1597: virtual void
llvm::ModulePass::assignPassManager(llvm::PMStack&,
llvm::PassManagerType): Assertion
2019 Mar 31
2
Unable to find requested analysis info (Interesting Assertion Failture for Specific Target Source Code)
Dear all,
Hi! I encounter an interesting assertion failure when implementing my Pass, which is defined with the member functions shown below:
======================My Pass======================================
bool MYPass::runOnModule(Module &M)
{
for (auto &F : M)
{
SE = &getAnalysis<ScalarEvolutionWrapperPass>(F).getSE();
......
2010 Jul 22
2
[LLVMdev] Controlling the order of a FunctionPass
Hi,
I would like my FunctionPasses to be invoked in reverse call graph
order (callees before callers). However, "Writing an LLVM Pass" notes
that "FunctionPass's do not require that they are executed in a
particular order." Is there any way at all to specify an ordering?
If this is not possible, I'm thinking of a workaround in which my
runOnFunction method
2010 Jul 22
0
[LLVMdev] Controlling the order of a FunctionPass
Trevor Harmon wrote:
> Hi,
>
> I would like my FunctionPasses to be invoked in reverse call graph
> order (callees before callers). However, "Writing an LLVM Pass" notes
> that "FunctionPass's do not require that they are executed in a
> particular order." Is there any way at all to specify an ordering?
>
> If this is not possible, I'm
2015 Oct 09
2
Get instance of CallGraph of a module in the pass
Hello,
I want an instance of CallGraph in my pass. By looking at -dot-callgraph
source, I've tried something like this:
CallGraphWrapperPass *CGWP = new CallGraphWrapperPass();
PM.add(CGWP);
CallGraph *CG = &CGWP->getCallGraph();
PM.add(new MyPass(CG));
I get the following error:
/home/riyad/installs/llvm-3.7.0/include/llvm/PassSupport.h:95:38: error: no
matching constructor for
2016 Jan 22
4
LLVM - getAnalysisUsage()
Hi,
I am using llvm-3.8 for my project. Following is my getAnalysisUsage() method:
virtual void getAnalysisUsage(AnalysisUsage &AU) const override
{
AU.setPreservesAll();
AU.addRequired<X>();
AU.addRequired<Y>();
AU.addRequired<Z>();
}
Now, if I call getAnalysis<X>(*F), instead of invoking just the X
pass, all the passes, i.e., X, Y and Z are being