[all-commits] [llvm/llvm-project] a8332d: [libcxxabi] Make fallback malloc heap size configu...
Yuxuan Chen via All-commits
all-commits at lists.llvm.org
Wed Feb 11 17:50:04 PST 2026
Branch: refs/heads/users/yuxuanchen1997/libcxxabi-fallback-heap-size
Home: https://github.com/llvm/llvm-project
Commit: a8332da06c9de6ab0df4a32d148d4093b23fd199
https://github.com/llvm/llvm-project/commit/a8332da06c9de6ab0df4a32d148d4093b23fd199
Author: Yuxuan Chen <ych at meta.com>
Date: 2026-02-11 (Wed, 11 Feb 2026)
Changed paths:
M libcxxabi/CMakeLists.txt
M libcxxabi/src/fallback_malloc.cpp
Log Message:
-----------
[libcxxabi] Make fallback malloc heap size configurable via CMake
The emergency fallback heap used during exception handling when
malloc() fails (e.g. under OOM) was hardcoded to 512 bytes, which
is only enough for a few in-flight exceptions. In contrast, libstdc++
reserves ~73 KiB for this purpose.
Add a LIBCXXABI_FALLBACK_MALLOC_HEAP_SIZE CMake option (default 512)
so that builds targeting services that need to survive OOM conditions
can increase the pool size. Validate the value at both CMake configure
time and C++ compile time, since the heap's unsigned short offsets
limit it to ~256 KiB.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list