Revert "[lldb][NFC] Force some logging on to TestCortexMExceptionUnwind.py"
This reverts commit 336503c4e1cdb5eaefde0536a34f0a95bc0c57bf.
GitOrigin-RevId: 6a719387704c8c01b29bdb418a4d8a3b5df6b090
diff --git a/test/API/functionalities/unwind/cortex-m-exception/TestCortexMExceptionUnwind.py b/test/API/functionalities/unwind/cortex-m-exception/TestCortexMExceptionUnwind.py
index 0584923..30b2a52 100644
--- a/test/API/functionalities/unwind/cortex-m-exception/TestCortexMExceptionUnwind.py
+++ b/test/API/functionalities/unwind/cortex-m-exception/TestCortexMExceptionUnwind.py
@@ -12,18 +12,34 @@
class TestCortexMExceptionUnwind(TestBase):
NO_DEBUG_INFO_TESTCASE = True
+ # on the lldb-remote-linux-ubuntu CI, the binary.json's triple of
+ # armv7m-apple is not being set in the Target triple, and we're
+ # picking the wrong ABI plugin, ABISysV_arm.
+ # ABISysV_arm::CreateDefaultUnwindPlan() doesn't have a way to detect
+ # arm/thumb for a stack frame, or even the Target's triple for a
+ # Cortex-M part that is always thumb. It hardcodes r11 as the frame
+ # pointer register, which is correct for arm code but not thumb.
+ # It is never correct # on a Cortex-M target.
+ # The Darwin ABIMacOSX_arm diverges from AAPCS and always uses r7 for
+ # the frame pointer -- the thumb convention -- whether executing arm or
+ # thumb. So its CreateDefaultUnwindPlan picks the correct register for
+ # the frame pointer, and we can walk the stack.
+ # ABISysV_arm::CreateDefaultUnwindPlan will only get one frame and
+ # not be able to continue.
+ #
+ # This may only be occuring on a 32-bit Ubuntu bot; need to test
+ # 64-bit Ubuntu and confirm.
+ @skipUnlessDarwin
def test_no_fpu(self):
"""Test that we can backtrace correctly through an ARM Cortex-M Exception return stack"""
+ target = self.dbg.CreateTarget("")
exe = "binary.json"
with open(exe) as f:
exe_json = json.load(f)
exe_uuid = exe_json["uuid"]
- triple = exe_json["triple"]
- target = self.dbg.CreateTargetWithFileAndTargetTriple(exe, triple)
- self.runCmd("target list")
- self.runCmd("ima li -A -t -b")
+ target.AddModule(exe, "", exe_uuid)
self.assertTrue(target.IsValid())
core = self.getBuildArtifact("core")
@@ -32,8 +48,12 @@
process = target.LoadCore(core)
self.assertTrue(process.IsValid())
- self.runCmd("target list")
- self.runCmd("ima li -A -t -b")
+ if self.TraceOn():
+ self.runCmd("target list")
+ self.runCmd("image list")
+ self.runCmd("target modules dump sections")
+ self.runCmd("target modules dump symtab")
+ self.runCmd("bt")
thread = process.GetThreadAtIndex(0)
self.assertTrue(thread.IsValid())