brintos

brintos / llvm-project-archived public Read only

0
0
Text · 537 B · 5292ccc Raw
25 lines · plain
1## Check that unclaimed PC-relative relocation from data to code is detected2## and reported to the user.3 4# REQUIRES: system-linux5 6# RUN: %clang %cflags -no-pie %s -o %t.exe -Wl,-q -nostartfiles7# RUN: not llvm-bolt %t.exe -o %t.bolt --strict 2>&1 | FileCheck %s8 9# CHECK: BOLT-ERROR: 1 unclaimed PC-relative relocation(s) left in data10 11  .text12  .globl _start13  .type _start, %function14_start:15  movl $42, %eax16.L0:17  ret18  .size _start, .-_start19 20## Force relocation mode.21  .reloc 0, R_X86_64_NONE22 23  .section .rodata24  .long .L0-.25