26 lines · plain
1# REQUIRES: system-linux2 3# RUN: llvm-mc -dwarf-version=4 -filetype=obj -triple x86_64-unknown-linux %p/Inputs/dwarf4-subprogram-single-ranges-main.s -o %t1.o4# RUN: %clang %cflags %t1.o -o %t.exe -Wl,-q5# RUN: llvm-bolt %t.exe -o %t.bolt --update-debug-sections6# RUN: llvm-objdump %t.bolt --disassemble > %t1.txt7# RUN: llvm-dwarfdump --show-form --verbose --debug-info %t.bolt >> %t1.txt8# RUN: cat %t1.txt | FileCheck --check-prefix=POSTCHECK %s9 10## This test checks BOLT correctly handles DW_TAG_subprogram with Ranges with single entry.11 12# POSTCHECK: _Z7doStuffi>:13# POSTCHECK: [[#%.6x,ADDR:]]14 15# POSTCHECK: DW_TAG_subprogram16# POSTCHECK-NEXT: DW_AT_frame_base17# POSTCHECK-NEXT: DW_AT_linkage_name18# POSTCHECK-SAME: _Z7doStuffi19# POSTCHECK-NEXT: DW_AT_name20# POSTCHECK-NEXT: DW_AT_decl_file21# POSTCHECK-NEXT: DW_AT_decl_line22# POSTCHECK-NEXT: DW_AT_type23# POSTCHECK-NEXT: DW_AT_external24# POSTCHECK-NEXT: DW_AT_low_pc [DW_FORM_addr] (0x0000000000[[#ADDR]])25# POSTCHECK-NEXT: DW_AT_high_pc [DW_FORM_data4] (0x0000001b)26