This is an archive of the discontinued LLVM Phabricator instance.

[scudo] Add unmapTestOnly() to secondary.
ClosedPublic

Authored by hctim on May 20 2021, 2:13 PM.

Details

Summary

When trying to track down a vaddr-poisoning bug, I found that that the
secondary cache isn't emptied on test teardown. We should probably do
that to make the tests hermetic. Otherwise, repeating the tests lots of
times using --gtest_repeat fails after the mmap vaddr space is
exhausted.

To repro:
$ ninja check-scudo_standalone # build
$ ./projects/compiler-rt/lib/scudo/standalone/tests/ScudoUnitTest-x86_64-Test \
--gtest_filter=ScudoSecondaryTest.*:-ScudoSecondaryTest.SecondaryCombinations \
--gtest_repeat=10000

Diff Detail

Event Timeline

hctim created this revision.May 20 2021, 2:13 PM
hctim requested review of this revision.May 20 2021, 2:13 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 20 2021, 2:13 PM
Herald added a subscriber: Restricted Project. · View Herald Transcript
cryptoad accepted this revision.May 20 2021, 2:22 PM
This revision is now accepted and ready to land.May 20 2021, 2:22 PM
This revision was landed with ongoing or failed builds.May 24 2021, 4:15 PM
This revision was automatically updated to reflect the committed changes.