1# REQUIRES: system-linux 2 3# RUN: llvm-mc -dwarf-version=5 -filetype=obj -triple x86_64-unknown-linux %p/Inputs/dwarf5-locexpr-referrence-main.s -o %tmain.o 4# RUN: llvm-mc -dwarf-version=5 -filetype=obj -triple x86_64-unknown-linux %p/Inputs/dwarf5-locexpr-referrence-helper.s -o %thelper.o 5# RUN: %clang %cflags -dwarf-5 %tmain.o %thelper.o -o %t.exe -Wl,-q 6# RUN: llvm-bolt %t.exe -o %t.bolt --update-debug-sections --debug-thread-count=4 --cu-processing-batch-size=4 7# RUN: llvm-dwarfdump --show-form --verbose --debug-info %t.bolt | FileCheck --check-prefix=CHECK %s 8# RUN: llvm-dwarfdump --show-form --verbose --debug-addr %t.bolt | FileCheck --check-prefix=CHECKADDR %s 9 10## This test checks that we update relative DIE references with DW_OP_convert that are in locexpr 11## and checks the address table is correct. 12 13# CHECK: version = 0x0005 14# CHECK: DW_TAG_variable 15# CHECK-NEXT: DW_AT_location 16# CHECK-SAME: DW_OP_convert (0x00000028 -> 0x00000028) 17# CHECK-SAME: DW_OP_convert (0x0000002c -> 0x0000002c) 18# CHECK: version = 0x0005 19# CHECK: DW_TAG_variable 20# CHECK-NEXT: DW_AT_location 21# CHECK-SAME: DW_OP_convert (0x00000028 -> 0x00000092) 22# CHECK-SAME: DW_OP_convert (0x0000002c -> 0x00000096) 23# CHECK: version = 0x0005 24 25# CHECKADDR: Addrs: [ 26# CHECKADDR-NEXT: 0x0000000000001330 27# CHECKADDR-NEXT: 0x0000000000000000 28# CHECKADDR-NEXT: 0x0000000000001333 29# CHECKADDR-NEXT: ] 30# CHECKADDR: Addrs: [ 31# CHECKADDR-NEXT: 0x0000000000001340 32# CHECKADDR-NEXT: 0x0000000000000000 33# CHECKADDR-NEXT: 0x0000000000001343 34# CHECKADDR-NEXT: ] 35# CHECKADDR: Addrs: [ 36# CHECKADDR-NEXT: 0x0000000000001320 37# CHECKADDR-NEXT: 0x0000000000000000 38# CHECKADDR-NEXT: ] 39