brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.5 KiB · 9df5fa0 Raw
68 lines · plain
1# REQUIRES: x862## Test that the address range contributed by an ICF folded function is identical3## to that of the folded-in function. Not considering ICF may lead to an address4## range whose low address equals the start address of the output section.5 6# RUN: llvm-mc -filetype=obj -triple=x86_64 %s -o %t.o7# RUN: ld.lld --gdb-index --icf=all --image-base=0x1000 -Ttext=0x1000 %t.o -o %t8# RUN: llvm-dwarfdump --gdb-index %t | FileCheck %s9 10# CHECK:      Address area offset = 0x38, has 2 entries:11# CHECK-NEXT:   Low/High address = [0x1001, 0x1002) (Size: 0x1), CU id = 012# CHECK-NEXT:   Low/High address = [0x1001, 0x1002) (Size: 0x1), CU id = 113 14.text15nop16 17.section .text.0,"ax"18.Lfunc_begin0:19  ret20.Lfunc_end0:21 22.section .text.1,"ax"23.Lfunc_begin1:24  ret25.Lfunc_end1:26 27.section  .debug_abbrev,"",@progbits28  .byte  1                         # Abbreviation Code29  .byte  65                        # DW_TAG_type_unit30  .byte  0                         # DW_CHILDREN_no31  .byte  0                         # EOM(1)32  .byte  0                         # EOM(2)33 34  .byte  2                         # Abbreviation Code35  .byte  17                        # DW_TAG_compile_unit36  .byte  0                         # DW_CHILDREN_no37  .byte  17                        # DW_AT_low_pc38  .byte  1                         # DW_FORM_addr39  .byte  18                        # DW_AT_high_pc40  .byte  6                         # DW_FORM_data441  .byte  0                         # EOM(1)42  .byte  0                         # EOM(2)43 44  .byte  0                         # EOM(3)45 46.section  .debug_info,"",@progbits47.Lcu_begin0:48  .long .Lcu_end0-.Lcu_begin0-4    # Length of Unit49  .short 5                         # DWARF version number50  .byte  1                         # DWARF Unit Type51  .byte  8                         # Address Size52  .long  .debug_abbrev             # Offset Into Abbrev. Section53  .byte  2                         # Abbrev [2] DW_TAG_compile_unit54  .quad  .Lfunc_begin0             # DW_AT_low_pc55  .long  .Lfunc_end0-.Lfunc_begin0 # DW_AT_high_pc56.Lcu_end0:57 58.Lcu_begin1:59  .long .Lcu_end1-.Lcu_begin1-4    # Length of Unit60  .short 5                         # DWARF version number61  .byte  1                         # DWARF Unit Type62  .byte  8                         # Address Size63  .long  .debug_abbrev             # Offset Into Abbrev. Section64  .byte  2                         # Abbrev [2] DW_TAG_compile_unit65  .quad  .Lfunc_begin1             # DW_AT_low_pc66  .long  .Lfunc_end1-.Lfunc_begin1 # DW_AT_high_pc67.Lcu_end1:68