This is an archive of the discontinued LLVM Phabricator instance.

[NewPM] Make eager analysis invalidation per-adaptor
ClosedPublic

Authored by aeubanks on Nov 4 2021, 9:22 AM.

Details

Summary

Follow-up change to D111575.
We don't need eager invalidation on every adaptor. Most notably,
adaptors running passes that use very few analyses, or passes that
purely invalidate specific analyses.

Also allow testing of this via a pipeline string
"function<eager-inv>()".

The compile time/memory impact of this is very comparable to D111575.
https://llvm-compile-time-tracker.com/compare.php?from=9a2eec512a29df45c90c2fcb741e9d5c693b1383&to=b9f20bcdea138060967d95a98eab87ce725b22bb&stat=instructions

Diff Detail

Event Timeline

aeubanks created this revision.Nov 4 2021, 9:22 AM
aeubanks requested review of this revision.Nov 4 2021, 9:22 AM
Herald added a project: Restricted Project. · View Herald TranscriptNov 4 2021, 9:22 AM
nikic added a comment.Nov 4 2021, 10:43 AM

Does this also need a change to the pipeline printing code?

aeubanks updated this revision to Diff 384811.Nov 4 2021, 10:50 AM

make pipeline printing code work with "function<eager-inv>"

This change's numbers look better overall. The compile-time regressions are smaller across the board and the memory gains are still there, in some cases reduced and in some cases improved. I don't think the level of noise is that high.
Overall, this change is the right approach both conceptually (only invalidate in these adaptors) and given the practical results.

nikic accepted this revision.Nov 4 2021, 3:37 PM

LGTM

This revision is now accepted and ready to land.Nov 4 2021, 3:37 PM
This revision was automatically updated to reflect the committed changes.