This is an archive of the discontinued LLVM Phabricator instance.

[safestack] Add -fruntime-init to support invoking functions during runtime init
AbandonedPublic

Authored by mlemay-intel on May 2 2016, 10:27 PM.

Details

Reviewers
eugenis
pcc
Summary

SafeStack uses thread-local storage by default in most OSes for the unsafe stack
pointer. For SafeStack to be applied to functions that may be invoked while
initializing the dynamic linker and libc, the functions can be compiled to
support a single-threaded unsafe stack pointer. This flag signals that such code
should be emitted.

Diff Detail

Event Timeline

mlemay-intel retitled this revision from to [safestack] Add -fruntime-init to support invoking functions during runtime init.
mlemay-intel updated this object.
mlemay-intel added reviewers: pcc, eugenis.
mlemay-intel added a subscriber: cfe-commits.
mlemay-intel abandoned this revision.Oct 25 2016, 8:29 PM

I was able to setup a temporary thread control block early enough in musl libc initialization to obviate the need for an attribute like runtime_init.