HomePhabricator

[builtins] Delay emutls deallocation for one round

Description

[builtins] Delay emutls deallocation for one round

Summary:
With Android/Bionic, delay deallocation to round 2 of 4. It must run after
C++ thread_local destructors have been called, but before the final 2
rounds, because emutls calls free, and jemalloc then needs another 2
rounds to free its thread-specific data.

Fixes https://github.com/android-ndk/ndk/issues/687

Reviewers: cmtice, srhines, jyknight, chh, echristo

Reviewed By: srhines, chh, echristo

Subscribers: echristo, delcypher, llvm-commits, #sanitizers

Differential Revision: https://reviews.llvm.org/D46978

Details

Committed
rprichardJun 11 2018, 6:32 PM
Reviewer
srhines
Differential Revision
D46978: [builtins] Delay emutls deallocation for one round
Parents
rL334462: [builtins] emutls cleanup: determine header size using sizeof
Branches
Unknown
Tags
Unknown