[llvm-commits] [llvm] r168008 - in /llvm/trunk: include/llvm/Pass.h include/llvm/PassManager.h include/llvm/PassManagers.h lib/Analysis/IPA/CallGraphSCCPass.cpp lib/VMCore/PassManager.cpp tools/bugpoint/CrashDebugger.cpp tools/llc/llc.cpp tools/llvm-extract/llvm-extract.cpp tools/llvm-prof/llvm-prof.cpp tools/llvm-stress/llvm-stress.cpp tools/lto/LTOCodeGenerator.cpp tools/opt/opt.cpp

Chandler Carruth chandlerc at google.com
Wed Nov 14 18:51:07 PST 2012


On Wed, Nov 14, 2012 at 6:09 PM, Evan Cheng <evan.cheng at apple.com> wrote:
> Ok, I've walked through the code a couple of times and decided it's possible to hide the calls to doInitialization() and doFinalization() in MPPassManager::runOnModule(). I agree it's a change we should make and this will eliminate the need for out-of-tree projects to adopt the API change.

I'm really looking forward to working on the big picture problem...
I'll definitely be keeping these use cases in mind.

>
> The pass manager design is extremely confusing. It makes me sad. :-(
>
> Evan
>
> On Nov 14, 2012, at 4:56 PM, Chris Lattner <clattner at apple.com> wrote:
>
>>
>> On Nov 14, 2012, at 4:14 PM, Owen Anderson <resistor at mac.com> wrote:
>>
>>> Author: resistor
>>> Date: Wed Nov 14 18:14:15 2012
>>> New Revision: 168008
>>>
>>> URL: http://llvm.org/viewvc/llvm-project?rev=168008&view=rev
>>> Log:
>>> Add doInitialization and doFinalization methods to ModulePass's, to allow them to be re-initialized and reused on multiple Module's.
>>
>> Cool.  Is it feasible to have "run" call these implicitly?  This sort of patch:
>>
>>>  // Now that we have all of the passes ready, run them.
>>> +  Passes.doInitialization();
>>>  Passes.run(*M.get());
>>> +  Passes.doFinalization();
>>>
>>>  // Declare success.
>>>  if (!NoOutput || PrintBreakpoints)
>>
>> Makes me sad.
>>
>> -Chris
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits




More information about the llvm-commits mailing list