You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-fsanitize=function reads a type signature 8 bytes before the called function on every call through a function pointer. The trampoline is machine code copied into an mmap'd buffer and has none. It sits at the start of the buffer, so the 8 bytes before it are unmapped and the read segfaults.
CPython versions tested on:
CPython main branch
Operating systems tested on:
Linux
Output from running 'python -VV' on the command line:
test_perf_profiler is skipped on most sanitizers, and so it didn't catch this issue:
ifsupport.check_sanitizer(address=True, memory=True, ub=True, function=True):
# gh-109580: Skip the test because it does crash randomly if Python is# built with ASAN.raiseunittest.SkipTest("test crash randomly on ASAN/MSAN/UBSAN build")
Activity
vstinner commentedon Nov 4, 2026
test_perf_profiler is skipped on most sanitizers, and so it didn't catch this issue:
vstinner commentedon Nov 4, 2026
I don't think that it's worth it to bother with testing perf support in test_embed, so I suggest to skip tests on
perf_profiling:NekoAsakura commentedon Nov 4, 2026
The fix is not much bother, and we already have similar macros
_Py_NO_SANITIZE_ADDRESS/THREAD/MEMORY.