[libc-commits] [libc] [libc] fix issues around stack protector (PR #74567)
Nick Desaulniers via libc-commits
libc-commits at lists.llvm.org
Wed Dec 6 11:53:33 PST 2023
================
@@ -9,15 +9,17 @@
#ifndef LLVM_LIBC_SRC___SUPPORT_OSUTIL_LINUX_QUICK_EXIT_H
#define LLVM_LIBC_SRC___SUPPORT_OSUTIL_LINUX_QUICK_EXIT_H
-#include "syscall.h" // For internal syscall function.
+#include "syscall.h" // For internal syscall function.
#include "src/__support/common.h"
#include <sys/syscall.h> // For syscall numbers.
namespace LIBC_NAMESPACE {
-LIBC_INLINE void quick_exit(int status) {
+// mark as no_stack_protector since TLS can be torn down before calling
+// quick_exit
+__attribute__((no_stack_protector)) LIBC_INLINE void quick_exit(int status) {
----------------
nickdesaulniers wrote:
should we use `[[gnu::no_stack_protector]]` style?
https://github.com/llvm/llvm-project/pull/74567
More information about the libc-commits
mailing list