[compiler-rt] [Test][ASan][Sanitizer] Make symbolizer test asan and simulator only (PR #158522)

via llvm-commits llvm-commits at lists.llvm.org
Sun Sep 14 18:41:48 PDT 2025


https://github.com/thetruestblue updated https://github.com/llvm/llvm-project/pull/158522

>From 514fadba12e896fed665635e16e43508c1d5313a Mon Sep 17 00:00:00 2001
From: thetruestblue <bgaston2 at apple.com>
Date: Sun, 14 Sep 2025 18:36:40 -0700
Subject: [PATCH] [Test][ASan][Sanitizer] Make symbolizer test asan and
 simulator only

Simulator environments run only atos symbolizer rather than falling back to dladdr.

Because sanitizer-common does not target simulators, move this test into asan and simulator only to make it predicatable test.

Original change sha: 0f9bfe0a02ffff077a1a98065069b52744e31723

rdar://108003900
---
 .../TestCases/Darwin/atos-symbolized-recover.cpp         | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)
 rename compiler-rt/test/{sanitizer_common => asan}/TestCases/Darwin/atos-symbolized-recover.cpp (69%)

diff --git a/compiler-rt/test/sanitizer_common/TestCases/Darwin/atos-symbolized-recover.cpp b/compiler-rt/test/asan/TestCases/Darwin/atos-symbolized-recover.cpp
similarity index 69%
rename from compiler-rt/test/sanitizer_common/TestCases/Darwin/atos-symbolized-recover.cpp
rename to compiler-rt/test/asan/TestCases/Darwin/atos-symbolized-recover.cpp
index 4234e0c9a9af3..08b31af136fa0 100644
--- a/compiler-rt/test/sanitizer_common/TestCases/Darwin/atos-symbolized-recover.cpp
+++ b/compiler-rt/test/asan/TestCases/Darwin/atos-symbolized-recover.cpp
@@ -1,12 +1,9 @@
 // Check that there is a warning when atos fails to symbolize an address
 // and that atos continues symbolicating correctly after.
 
-// RUN: %clangxx -O0 %s -o %t
+// RUN: %clangxx_asan -O0 %s -o %t
 // RUN: not %run %t 2>&1 | FileCheck %s
-
-// This test tests for undefined behavior and is leading to various failures. 
-// Going to disable to unblock CI and rethink a test for this. rdar://107846128
-// UNSUPPORTED: darwin
+// REQUIRES: iossim
 
 void bar() {
   void *invalid_addr = reinterpret_cast<void *>(0xDEADBEEF);
@@ -19,4 +16,4 @@ int main() {
   return 0;
   // CHECK: WARNING: atos failed to symbolize address{{.*}}
   // CHECK: {{.*}}atos-symbolized-recover.cpp:[[@LINE-3]]{{.*}}
-}
+}
\ No newline at end of file



More information about the llvm-commits mailing list