This is an archive of the discontinued LLVM Phabricator instance.

[libc] Add __cxa_atexit support to the atexit function.
ClosedPublic

Authored by sivachandra on Aug 4 2022, 4:23 PM.

Diff Detail

Event Timeline

sivachandra created this revision.Aug 4 2022, 4:23 PM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptAug 4 2022, 4:23 PM
sivachandra requested review of this revision.Aug 4 2022, 4:23 PM

I have incorporated some of the testing ideas suggested by @abrachet in https://reviews.llvm.org/D130966.

Rebase after splitting out ArrayStore in to a separate patch.

abrachet accepted this revision.Aug 8 2022, 8:09 AM
abrachet added inline comments.
libc/loader/linux/x86_64/start.cpp
120–121

I think this was sent out for review before the D131133, so just a reminder to change the aarch64 code to behave this way too

libc/src/stdlib/atexit.cpp
80

Might be worth adding a TODO here that eventually this will need to address the dso_handle argument.

libc/test/integration/loader/linux/init_fini_array_test.cpp
25–26

We can remove this TODO now

This revision is now accepted and ready to land.Aug 8 2022, 8:09 AM

Address comments.

Remove a TODO which is not relevant anymore.

sivachandra marked 3 inline comments as done.Aug 8 2022, 4:00 PM
This revision was landed with ongoing or failed builds.Aug 9 2022, 2:43 PM
This revision was automatically updated to reflect the committed changes.