[Lldb-commits] [lldb] 92cd68f - [lldb] Simplify debug_{rnglists, ranges}.s tests
Pavel Labath via lldb-commits
lldb-commits at lists.llvm.org
Wed Dec 4 08:06:58 PST 2019
Author: Pavel Labath
Date: 2019-12-04T17:08:23+01:00
New Revision: 92cd68f48ed14c6ee90b3ad830af3c2d7879428a
URL: https://github.com/llvm/llvm-project/commit/92cd68f48ed14c6ee90b3ad830af3c2d7879428a
DIFF: https://github.com/llvm/llvm-project/commit/92cd68f48ed14c6ee90b3ad830af3c2d7879428a.diff
LOG: [lldb] Simplify debug_{rnglists,ranges}.s tests
Remove things irrelevant to the test.
Added:
Modified:
lldb/test/Shell/SymbolFile/DWARF/debug_ranges.s
lldb/test/Shell/SymbolFile/DWARF/debug_rnglists.s
Removed:
################################################################################
diff --git a/lldb/test/Shell/SymbolFile/DWARF/debug_ranges.s b/lldb/test/Shell/SymbolFile/DWARF/debug_ranges.s
index bbe5cb220c2d..13eea1b80706 100644
--- a/lldb/test/Shell/SymbolFile/DWARF/debug_ranges.s
+++ b/lldb/test/Shell/SymbolFile/DWARF/debug_ranges.s
@@ -3,16 +3,13 @@
# RUN: llvm-mc -triple=x86_64-pc-linux -filetype=obj %s > %t
# RUN: %lldb %t -o "image lookup -v -s lookup_ranges" -o exit | FileCheck %s
-# CHECK: Function: id = {0x7fffffff0000001c}, name = "ranges", range = [0x0000000000000000-0x0000000000000004)
-# CHECK: Blocks: id = {0x7fffffff0000001c}, range = [0x00000000-0x00000004)
-# CHECK-NEXT: id = {0x7fffffff0000002d}, ranges = [0x00000001-0x00000002)[0x00000003-0x00000004)
+# CHECK: Function: id = {0x7fffffff0000002b}, name = "ranges", range = [0x0000000000000000-0x0000000000000004)
+# CHECK: Blocks: id = {0x7fffffff0000002b}, range = [0x00000000-0x00000004)
+# CHECK-NEXT: id = {0x7fffffff0000003f}, ranges = [0x00000001-0x00000002)[0x00000003-0x00000004)
.text
.p2align 12
- .globl ranges
- .type ranges, at function
-ranges: # @ranges
-.Lfoo_begin:
+ranges:
nop
.Lblock1_begin:
lookup_ranges:
@@ -22,21 +19,14 @@ lookup_ranges:
.Lblock2_begin:
nop
.Lblock2_end:
-.Lfunc_end0:
- .size ranges, .Lfunc_end0-ranges
- # -- End function
- .section .debug_str,"MS", at progbits,1
-.Lproducer:
- .asciz "Hand-written DWARF"
-.Lranges:
- .asciz "ranges"
+.Lranges_end:
.section .debug_abbrev,"", at progbits
.byte 1 # Abbreviation Code
.byte 17 # DW_TAG_compile_unit
.byte 1 # DW_CHILDREN_yes
.byte 37 # DW_AT_producer
- .byte 14 # DW_FORM_strp
+ .byte 8 # DW_FORM_string
.byte 17 # DW_AT_low_pc
.byte 1 # DW_FORM_addr
.byte 18 # DW_AT_high_pc
@@ -51,7 +41,7 @@ lookup_ranges:
.byte 18 # DW_AT_high_pc
.byte 6 # DW_FORM_data4
.byte 3 # DW_AT_name
- .byte 14 # DW_FORM_strp
+ .byte 8 # DW_FORM_string
.byte 0 # EOM(1)
.byte 0 # EOM(2)
.byte 5 # Abbreviation Code
@@ -71,13 +61,13 @@ lookup_ranges:
.long .debug_abbrev # Offset Into Abbrev. Section
.byte 8 # Address Size (in bytes)
.byte 1 # Abbrev [1] 0xb:0x7b DW_TAG_compile_unit
- .long .Lproducer # DW_AT_producer
- .quad .Lfoo_begin # DW_AT_low_pc
- .long .Lfunc_end0-.Lfoo_begin # DW_AT_high_pc
+ .asciz "Hand-written DWARF" # DW_AT_producer
+ .quad ranges # DW_AT_low_pc
+ .long .Lranges_end-ranges # DW_AT_high_pc
.byte 2 # Abbrev [2] 0x2a:0x4d DW_TAG_subprogram
- .quad .Lfoo_begin # DW_AT_low_pc
- .long .Lfunc_end0-.Lfoo_begin # DW_AT_high_pc
- .long .Lranges # DW_AT_name
+ .quad ranges # DW_AT_low_pc
+ .long .Lranges_end-ranges # DW_AT_high_pc
+ .asciz "ranges" # DW_AT_name
.byte 5 # Abbrev [5] 0x61:0x15 DW_TAG_lexical_block
.long .Ldebug_ranges0 # DW_AT_ranges
.byte 0 # End Of Children Mark
@@ -86,9 +76,9 @@ lookup_ranges:
.section .debug_ranges,"", at progbits
.Ldebug_ranges0:
- .quad .Lblock1_begin-.Lfoo_begin
- .quad .Lblock1_end-.Lfoo_begin
- .quad .Lblock2_begin-.Lfoo_begin
- .quad .Lblock2_end-.Lfoo_begin
+ .quad .Lblock1_begin-ranges
+ .quad .Lblock1_end-ranges
+ .quad .Lblock2_begin-ranges
+ .quad .Lblock2_end-ranges
.quad 0
.quad 0
diff --git a/lldb/test/Shell/SymbolFile/DWARF/debug_rnglists.s b/lldb/test/Shell/SymbolFile/DWARF/debug_rnglists.s
index 5d95b80e8da6..7daa32da8aff 100644
--- a/lldb/test/Shell/SymbolFile/DWARF/debug_rnglists.s
+++ b/lldb/test/Shell/SymbolFile/DWARF/debug_rnglists.s
@@ -3,16 +3,13 @@
# RUN: llvm-mc -triple=x86_64-pc-linux -filetype=obj %s > %t
# RUN: %lldb %t -o "image lookup -v -s lookup_rnglists" -o exit | FileCheck %s
-# CHECK: Function: id = {0x7fffffff00000021}, name = "rnglists", range = [0x0000000000000000-0x0000000000000004)
-# CHECK: Blocks: id = {0x7fffffff00000021}, range = [0x00000000-0x00000004)
-# CHECK-NEXT: id = {0x7fffffff00000032}, ranges = [0x00000001-0x00000002)[0x00000003-0x00000004)
+# CHECK: Function: id = {0x7fffffff00000030}, name = "rnglists", range = [0x0000000000000000-0x0000000000000004)
+# CHECK: Blocks: id = {0x7fffffff00000030}, range = [0x00000000-0x00000004)
+# CHECK-NEXT: id = {0x7fffffff00000046}, ranges = [0x00000001-0x00000002)[0x00000003-0x00000004)
.text
.p2align 12
- .globl rnglists
- .type rnglists, at function
-rnglists: # @rnglists
-.Lfoo_begin:
+rnglists:
nop
.Lblock1_begin:
lookup_rnglists:
@@ -22,21 +19,14 @@ lookup_rnglists:
.Lblock2_begin:
nop
.Lblock2_end:
-.Lfunc_end0:
- .size rnglists, .Lfunc_end0-rnglists
- # -- End function
- .section .debug_str,"MS", at progbits,1
-.Lproducer:
- .asciz "Hand-written DWARF"
-.Lrnglists:
- .asciz "rnglists"
+.Lrnglists_end:
.section .debug_abbrev,"", at progbits
.byte 1 # Abbreviation Code
.byte 17 # DW_TAG_compile_unit
.byte 1 # DW_CHILDREN_yes
.byte 37 # DW_AT_producer
- .byte 14 # DW_FORM_strp
+ .byte 8 # DW_FORM_string
.byte 17 # DW_AT_low_pc
.byte 1 # DW_FORM_addr
.byte 18 # DW_AT_high_pc
@@ -53,7 +43,7 @@ lookup_rnglists:
.byte 18 # DW_AT_high_pc
.byte 6 # DW_FORM_data4
.byte 3 # DW_AT_name
- .byte 14 # DW_FORM_strp
+ .byte 8 # DW_FORM_string
.byte 0 # EOM(1)
.byte 0 # EOM(2)
.byte 5 # Abbreviation Code
@@ -74,14 +64,14 @@ lookup_rnglists:
.byte 8 # Address Size (in bytes)
.long .debug_abbrev # Offset Into Abbrev. Section
.byte 1 # Abbrev [1] 0xc:0x5f DW_TAG_compile_unit
- .long .Lproducer # DW_AT_producer
- .quad .Lfoo_begin # DW_AT_low_pc
- .long .Lfunc_end0-.Lfoo_begin # DW_AT_high_pc
+ .asciz "Hand-written DWARF" # DW_AT_producer
+ .quad rnglists # DW_AT_low_pc
+ .long .Lrnglists_end-rnglists # DW_AT_high_pc
.long .Lrnglists_table_base0 # DW_AT_rnglists_base
.byte 2 # Abbrev [2] 0x2b:0x37 DW_TAG_subprogram
- .quad .Lfoo_begin # DW_AT_low_pc
- .long .Lfunc_end0-.Lfoo_begin # DW_AT_high_pc
- .long .Lrnglists # DW_AT_name
+ .quad rnglists # DW_AT_low_pc
+ .long .Lrnglists_end-rnglists # DW_AT_high_pc
+ .asciz "rnglists" # DW_AT_name
.byte 5 # Abbrev [5] 0x52:0xf DW_TAG_lexical_block
.byte 0 # DW_AT_ranges
.byte 0 # End Of Children Mark
@@ -99,12 +89,10 @@ lookup_rnglists:
.long .Ldebug_ranges0-.Lrnglists_table_base0
.Ldebug_ranges0:
.byte 4 # DW_RLE_offset_pair
- .uleb128 .Lblock1_begin-.Lfoo_begin # starting offset
- .uleb128 .Lblock1_end-.Lfoo_begin # ending offset
+ .uleb128 .Lblock1_begin-rnglists # starting offset
+ .uleb128 .Lblock1_end-rnglists # ending offset
.byte 4 # DW_RLE_offset_pair
- .uleb128 .Lblock2_begin-.Lfoo_begin # starting offset
- .uleb128 .Lblock2_end-.Lfoo_begin # ending offset
+ .uleb128 .Lblock2_begin-rnglists # starting offset
+ .uleb128 .Lblock2_end-rnglists # ending offset
.byte 0 # DW_RLE_end_of_list
.Ldebug_rnglist_table_end0:
- .section .debug_macinfo,"", at progbits
- .byte 0 # End Of Macro List Mark
More information about the lldb-commits
mailing list