xref: /aosp_15_r20/external/clang/test/CodeGen/relax.c (revision 67e74705e28f6214e480b399dd47ea732279e315)
1*67e74705SXin Li // REQUIRES: x86-registered-target
2*67e74705SXin Li // RUN: %clang_cc1 -triple x86_64-pc-linux-gnu -emit-obj --mrelax-relocations %s -mrelocation-model pic -o %t
3*67e74705SXin Li // RUN: llvm-readobj -r %t | FileCheck  %s
4*67e74705SXin Li 
5*67e74705SXin Li // CHECK: R_X86_64_REX_GOTPCRELX foo
6*67e74705SXin Li 
7*67e74705SXin Li extern int foo;
f(void)8*67e74705SXin Li int *f(void) {
9*67e74705SXin Li   return &foo;
10*67e74705SXin Li }
11