[libc-commits] [libc] [libc] fix sysconf test for rv32 (PR #162685)

via libc-commits libc-commits at lists.llvm.org
Thu Oct 9 10:30:00 PDT 2025


================
@@ -90,7 +91,7 @@ LIBC_INLINE void Vector::fallback_initialize_unsync() {
                                      PROT_READ | PROT_WRITE,
                                      MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
   // We do not proceed if mmap fails.
-  if (mmap_ret <= 0)
+  if (mmap_ret <= 0 && mmap_ret > -EXEC_PAGESIZE)
----------------
lntue wrote:

Having a common check function and link to the linux kernel would be great.

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


More information about the libc-commits mailing list