[libc-commits] [PATCH] D148290: Support custom attributes in pthread_create
Noah Goldstein via Phabricator via libc-commits
libc-commits at lists.llvm.org
Mon May 22 09:23:37 PDT 2023
goldstein.w.n added inline comments.
================
Comment at: libc/src/__support/threads/linux/thread.cpp:493
+ // TODO: We may have deallocated the stack. Can we reference local variables
+ // that may have spilled?
if (style == ThreadStyle::POSIX)
----------------
sivachandra wrote:
> This is a good catch! What do you think of just exiting with a return code of say -1 if the thread is detached? We can take this up separately.
Won't that be a massive memory leak?
Although its not super clear how to handle this w.o some degree of inline-assembly.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D148290/new/
https://reviews.llvm.org/D148290
More information about the libc-commits
mailing list