https://github.com/eronnen created 
https://github.com/llvm/llvm-project/pull/141407

The test fails because LLDB does not recognize any function which is not in the 
symbol table on armv7 

>From 27159c6f52e18bf3b11553ce380449b38689154d Mon Sep 17 00:00:00 2001
From: Ely Ronnen <elyron...@gmail.com>
Date: Sun, 25 May 2025 14:35:57 +0200
Subject: [PATCH] [lldb] skip unnamed symbol test on arm 32 architecture

---
 lldb/packages/Python/lldbsuite/test/decorators.py  | 14 ++++++++++++++
 .../TestUnnamedSymbolLookup.py                     |  2 ++
 2 files changed, 16 insertions(+)

diff --git a/lldb/packages/Python/lldbsuite/test/decorators.py 
b/lldb/packages/Python/lldbsuite/test/decorators.py
index 868e9f7e5eca0..e87e8d662e4ae 100644
--- a/lldb/packages/Python/lldbsuite/test/decorators.py
+++ b/lldb/packages/Python/lldbsuite/test/decorators.py
@@ -799,6 +799,20 @@ def arch_doesnt_match():
     return skipTestIfFn(arch_doesnt_match)
 
 
+def skipIfArch(arch):
+    """Decorate the item to skip tests if running on the specified 
architecture."""
+
+    def arch_matches():
+        target_arch = lldbplatformutil.getArchitecture()
+        if arch == target_arch:
+            return (
+                "Test does not run on " + arch + ", but target arch is " + 
target_arch
+            )
+        return None
+
+    return skipTestIfFn(arch_matches)
+
+
 def skipIfTargetAndroid(bugnumber=None, api_levels=None, archs=None):
     """Decorator to skip tests when the target is Android.
 
diff --git 
a/lldb/test/API/python_api/unnamed_symbol_lookup/TestUnnamedSymbolLookup.py 
b/lldb/test/API/python_api/unnamed_symbol_lookup/TestUnnamedSymbolLookup.py
index c0438f77fb1d1..f798ec342e41b 100644
--- a/lldb/test/API/python_api/unnamed_symbol_lookup/TestUnnamedSymbolLookup.py
+++ b/lldb/test/API/python_api/unnamed_symbol_lookup/TestUnnamedSymbolLookup.py
@@ -10,6 +10,8 @@
 
 # --keep-symbol causes error on Windows: llvm-strip.exe: error: option is not 
supported for COFF
 @skipIfWindows
+# Unnamed symbols don't get into the .eh_frame section on ARM, so LLDB can't 
find them.
+@skipIfArch("arm")
 class TestUnnamedSymbolLookup(TestBase):
     def test_unnamed_symbol_lookup(self):
         """Test looking up unnamed symbol synthetic name"""

_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to