[LLVMdev] Adding an object to llc (analysis pass)

Silken Tiger st at iss.tu-darmstadt.de
Fri Jun 16 05:46:14 PDT 2006


Hi Chris and llvm list

Thanks for your answer.
> So again, this is the problem I described earlier:  you have a pass 
> (MParSchedule) which is a basic block pass.  This pass is being required 
> by another pass (your C backend-based thing) which is not a basic block 
> pass.  This is the problem, please see the "how to write a pass" doc.  The 
> fix is to change MParSchedule to be a function pass or modulepass.
Ok, after combining all your comments in this thread and reading the
documentation again. I think i figured it out:
Every Pass is allowed to depend on the same granularity (eg. ModulePass
on ModulePass) or coarser (eg. BasicBlockPass on Functionpass but *NOT*
the other way round).

So my here goes my problem: Since my C-Backend modified pass is a module
pass i can only depend on module passes. This stands in contrary to the 
proposed way to use the most apropriate (BasicBlock in my case) pass available.
Since there is no way for me in using this pass?

On a sidenote i have promised to update the documentation if i get my pass running.
Is the documentation in revision control somewhere to create my diff against it?

Thanks
ST




More information about the llvm-dev mailing list