[Lldb-commits] [lldb] [lldb] Fix block address resolution for functions in multiple sections (PR #137955)
David Spickett via lldb-commits
lldb-commits at lists.llvm.org
Fri May 2 08:33:08 PDT 2025
================
@@ -0,0 +1,102 @@
+# REQUIRES: x86, lld
+
+# RUN: split-file %s %t
+# RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux %t/file.s -o %t/file.o
+# RUN: ld.lld %t/file.o -o %t/file.out -T %t/file.lds
+# RUN: %lldb %t/file.out -o "disassemble --name func1" -o exit | FileCheck %s
+
+# CHECK: (lldb) disassemble --name func1
+# CHECK: file.out`func1:
+# CHECK-NEXT: file.out[0x0] <+0>: int $0x2a
+# CHECK: file.out`func1:
+# CHECK-NEXT: file.out[0x1000] <+4096>: int $0x2f
+
+
+#--- file.lds
+PHDRS {
----------------
DavidSpickett wrote:
I saw the fairly generic test name and thought "I'm not going to have any idea what this is checking when it fails randomly in the future" because I assumed it would have some strange ordering but did not immediately see where.
But it's just the code being split at all, that's the reason to test this. So the added comments do make that clearer.
https://github.com/llvm/llvm-project/pull/137955
More information about the lldb-commits
mailing list