Page MenuHomePhabricator

[BasicAA] Don't pass through AA metadata (NFCI)

Authored by nikic on Oct 24 2020, 8:11 AM.



BasicAA itself doesn't make use of AA metadata, but passes it through to recursive queries and makes it part of the cache key. Aliasing decisions that are based on AA metadata (i.e. TBAA and ScopedAA) are based *only* on AA metadata, so checking them with different pointer values or sizes is not useful, the result will always be the same.

By itself, this change is a mild compile-time improvement ( However, the actual goal here is to remove the AA metadata from the cache key and thus reduce it's size significantly (from 96 to 32 bytes), which will be the more impactful change. I plan to do that as a followup, but could also include it here.

Diff Detail

Event Timeline

nikic created this revision.Oct 24 2020, 8:11 AM
Herald added a project: Restricted Project. · View Herald TranscriptOct 24 2020, 8:11 AM
nikic requested review of this revision.Oct 24 2020, 8:11 AM
asbirlea accepted this revision.Oct 28 2020, 1:28 PM

This is an interesting point. IIUC, your argument is that the entry point into AA is always through AAResults and can rely on the invocation result for TBAA or ScopedAA from there, while the recursive invocations into these same analyses cannot yield stricter results. I cannot think of a case when this is not true.

This revision is now accepted and ready to land.Oct 28 2020, 1:28 PM