[libunwind] 6eb3532 - [libunwind] include alloca.h in test/aarch64_za_unwind.pass.cpp (#207376)
via cfe-commits
cfe-commits at lists.llvm.org
Wed Jul 8 00:04:12 PDT 2026
Author: Shreeyash Pandey
Date: 2026-07-08T12:33:55+05:30
New Revision: 6eb35326147077a18f6fc56540059d779d7e3d4b
URL: https://github.com/llvm/llvm-project/commit/6eb35326147077a18f6fc56540059d779d7e3d4b
DIFF: https://github.com/llvm/llvm-project/commit/6eb35326147077a18f6fc56540059d779d7e3d4b.diff
LOG: [libunwind] include alloca.h in test/aarch64_za_unwind.pass.cpp (#207376)
Glibc provides the alloca function as a part of stdlib.h when
_GNU_SOURCE is declared (which is the case with standard linux builds).
[1]
On non-glibc systems, this may not be the case (for example, picolibc).
These libraries may not implicitly include alloca.h as a part of the
standard lib.
[1]
https://github.com/bminor/glibc/blob/04e750e75b73957cf1c791535a3f4319534a52fc/stdlib/stdlib.h#L728
Signed-off-by: Shreeyash Pandey <shrpand at qti.qualcomm.com>
Added:
Modified:
libunwind/test/aarch64_za_unwind.pass.cpp
Removed:
################################################################################
diff --git a/libunwind/test/aarch64_za_unwind.pass.cpp b/libunwind/test/aarch64_za_unwind.pass.cpp
index 36536860c1a96..0e8e1f0de4f78 100644
--- a/libunwind/test/aarch64_za_unwind.pass.cpp
+++ b/libunwind/test/aarch64_za_unwind.pass.cpp
@@ -9,6 +9,7 @@
// REQUIRES: target={{aarch64-.+}}
// UNSUPPORTED: target={{.*-windows.*}}
+#include <alloca.h>
#include <libunwind.h>
#include <stdint.h>
#include <stdio.h>
More information about the cfe-commits
mailing list