Skip to content

Commit eaec6c9

Browse files
comment
1 parent 517934a commit eaec6c9

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

libc/src/stdlib/exit.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,12 @@
1414
namespace LIBC_NAMESPACE_DECL {
1515

1616
extern "C" void __cxa_finalize(void *);
17+
18+
// exit needs to clean up TLS and call associated destructors.
19+
// TODO: Strictly speaking, it is not valid to call exit in overlay mode
20+
// as we have no way to ensure system libc will call the TLS destructors.
21+
// We should run exit related tests in hermetic mode but this is currently
22+
// blocked by https://github.com/llvm/llvm-project/issues/133925.
1723
extern "C" [[gnu::weak]] void __cxa_thread_finalize();
1824

1925
// TODO: use recursive mutex to protect this routine.

0 commit comments

Comments
 (0)