21 lines · plain
1## Check that BOLT reports an error for a binary with no relocations with the --icf=safe option.2 3# REQUIRES: system-linux, asserts4# RUN: llvm-mc -filetype=obj -triple x86_64-unknown-linux %s -o %t1.o5# RUN: %clang %cflags %t1.o -o %t.exe6# RUN: not llvm-bolt --no-threads %t.exe --icf=safe -o %t.bolt 2>&1 | FileCheck --check-prefix=SAFEICFCHECK %s7 8# SAFEICFCHECK: BOLT-ERROR: binary built without relocations. Safe ICF is not supported9 10## int main(int argc, char **argv) {11## return temp;12## }13 .globl main14 .type main,@function15main:16 .cfi_startproc17 retq18.Lfunc_end8:19 .size main, .-main20 .cfi_endproc21