This is an archive of the discontinued LLVM Phabricator instance.

scudo: Store header on deallocation before retagging memory.
ClosedPublic

Authored by pcc on Apr 22 2021, 11:22 PM.

Details

Summary

From a cache perspective it's better to store the header immediately
after loading it. If we delay this operation until after we've
retagged it's more likely that our header will have been evicted from
the cache and we'll need to fetch it again in order to perform the
compare-exchange operation.

For similar reasons, store the deallocation stack before retagging
instead of afterwards.

Diff Detail

Event Timeline

pcc requested review of this revision.Apr 22 2021, 11:22 PM
pcc created this revision.
Herald added a project: Restricted Project. · View Herald TranscriptApr 22 2021, 11:22 PM
Herald added a subscriber: Restricted Project. · View Herald Transcript
cryptoad accepted this revision.Apr 23 2021, 8:06 AM
This revision is now accepted and ready to land.Apr 23 2021, 8:06 AM
This revision was automatically updated to reflect the committed changes.