Skip to content

Commit 27159c6

Browse files
committed
[lldb] skip unnamed symbol test on arm 32 architecture
1 parent 6bbaef1 commit 27159c6

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

lldb/packages/Python/lldbsuite/test/decorators.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -799,6 +799,20 @@ def arch_doesnt_match():
799799
return skipTestIfFn(arch_doesnt_match)
800800

801801

802+
def skipIfArch(arch):
803+
"""Decorate the item to skip tests if running on the specified architecture."""
804+
805+
def arch_matches():
806+
target_arch = lldbplatformutil.getArchitecture()
807+
if arch == target_arch:
808+
return (
809+
"Test does not run on " + arch + ", but target arch is " + target_arch
810+
)
811+
return None
812+
813+
return skipTestIfFn(arch_matches)
814+
815+
802816
def skipIfTargetAndroid(bugnumber=None, api_levels=None, archs=None):
803817
"""Decorator to skip tests when the target is Android.
804818

lldb/test/API/python_api/unnamed_symbol_lookup/TestUnnamedSymbolLookup.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@
1010

1111
# --keep-symbol causes error on Windows: llvm-strip.exe: error: option is not supported for COFF
1212
@skipIfWindows
13+
# Unnamed symbols don't get into the .eh_frame section on ARM, so LLDB can't find them.
14+
@skipIfArch("arm")
1315
class TestUnnamedSymbolLookup(TestBase):
1416
def test_unnamed_symbol_lookup(self):
1517
"""Test looking up unnamed symbol synthetic name"""

0 commit comments

Comments
 (0)