[libunwind] [libunwind] include alloca.h in test/aarch64_za_unwind.pass.cpp (PR #207376)
Shreeyash Pandey via cfe-commits
cfe-commits at lists.llvm.org
Tue Jul 7 02:06:35 PDT 2026
https://github.com/bojle updated https://github.com/llvm/llvm-project/pull/207376
>From 4f44c4931206dac919389a3caf44431f2d1e1f0b Mon Sep 17 00:00:00 2001
From: Shreeyash Pandey <shrpand at qti.qualcomm.com>
Date: Fri, 3 Jul 2026 04:34:17 -0700
Subject: [PATCH] [libunwind] include alloca.h in
test/aarch64_za_unwind.pass.cpp
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>
---
libunwind/test/aarch64_za_unwind.pass.cpp | 1 +
1 file changed, 1 insertion(+)
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