[llvm] r225236 - [PM] Add a utility to the new pass manager for generating a pass which

Chandler Carruth chandlerc at gmail.com
Tue Jan 6 00:47:24 PST 2015


On Tue, Jan 6, 2015 at 12:16 AM, David Blaikie <dblaikie at gmail.com> wrote:

> This can be used in real pass pipelines to force the usually lazy
>> analysis running to eagerly compute something at a specific point,
>
>
> Any particular reason this would be useful/necessary?
>

Two ways I can think of off hand:

Force something to be computed across a domain before we start to mutate
that domain. For example, pre-compute something over an SCC before running
function passes that may mutate that SCC. Sub-domains can only query cached
analysis results from outer domains because we can't interrupt the peers to
run the pass lazily.

The second issue is with passes that just use 'getCachedResult' to acquire
a cached result (but not lazily run a pass) for some other reason such as
"efficiency". Unclear how often this will come up in the new pass manager,
but it happens a lot in the old one so I wanted to make sure we could do
it. I'm hopeful that the lazy running + aggressive caching will decrease or
remove this use case, but its unlikely to remove the first one. =/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150106/f4a45112/attachment.html>


More information about the llvm-commits mailing list