[libc-commits] [libc] [libc] Simple __stack_chk_guard implementation (PR #78804)

Nick Desaulniers via libc-commits libc-commits at lists.llvm.org
Fri Jan 19 15:55:06 PST 2024


================
@@ -19,6 +19,7 @@ set(TARGET_LIBC_ENTRYPOINTS
 
     # compiler entrypoints (no corresponding header)
     libc.src.compiler.__stack_chk_fail
+    libc.src.compiler.__stack_chk_guard
----------------
nickdesaulniers wrote:

Doesn't that mean then that we //can't// use libc/src/compiler/linux/__stack_chk_guard.cpp for x86?

I guess I have a question around do we need to match existing ABI for different architectures as glibc, or can we do our own ABI? If we do our own ABI, I'd much rather have per thread stack canaries, than a single global for all threads.

https://github.com/llvm/llvm-project/pull/78804


More information about the libc-commits mailing list