Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions clang/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,9 @@ set(ENABLE_LINKER_BUILD_ID OFF CACHE BOOL "pass --build-id to ld")
set(ENABLE_X86_RELAX_RELOCATIONS ON CACHE BOOL
"enable x86 relax relocations by default")

set(ENABLE_X86_APX_RELAX_RELOCATIONS OFF CACHE BOOL
"Enable x86 APX relax relocations by default")

set(PPC_LINUX_DEFAULT_IEEELONGDOUBLE OFF CACHE BOOL
"Enable IEEE binary128 as default long double format on PowerPC Linux.")

Expand Down
1 change: 1 addition & 0 deletions clang/cmake/caches/Fuchsia-stage2.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ set(CLANG_PLUGIN_SUPPORT OFF CACHE BOOL "")

set(ENABLE_LINKER_BUILD_ID ON CACHE BOOL "")
set(ENABLE_X86_RELAX_RELOCATIONS ON CACHE BOOL "")
set(ENABLE_X86_APX_RELAX_RELOCATIONS OFF CACHE BOOL "")

# TODO(#67176): relative-vtables doesn't play well with different default
# visibilities. Making everything hidden visibility causes other complications
Expand Down
1 change: 1 addition & 0 deletions clang/cmake/caches/Fuchsia.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ set(CLANG_PLUGIN_SUPPORT OFF CACHE BOOL "")

set(ENABLE_LINKER_BUILD_ID ON CACHE BOOL "")
set(ENABLE_X86_RELAX_RELOCATIONS ON CACHE BOOL "")
set(ENABLE_X86_APX_RELAX_RELOCATIONS OFF CACHE BOOL "")

set(LLVM_ENABLE_ASSERTIONS ON CACHE BOOL "")
set(LLVM_ENABLE_BACKTRACES ON CACHE BOOL "")
Expand Down
1 change: 1 addition & 0 deletions clang/include/clang/Basic/CodeGenOptions.def
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,7 @@ CODEGENOPT(UniqueInternalLinkageNames, 1, 0) ///< Internal Linkage symbols get u
CODEGENOPT(SplitMachineFunctions, 1, 0) ///< Split machine functions using profile information.
CODEGENOPT(PPCUseFullRegisterNames, 1, 0) ///< Print full register names in assembly
CODEGENOPT(X86RelaxRelocations, 1, 1) ///< -Wa,-mrelax-relocations={yes,no}
CODEGENOPT(X86APXRelaxRelocations, 1, 0) ///< -Wa,-mrelax-relocations={yes,no}
CODEGENOPT(X86Sse2Avx , 1, 0) ///< -Wa,-msse2avx

/// When false, this attempts to generate code as if the result of an
Expand Down
3 changes: 3 additions & 0 deletions clang/include/clang/Config/config.h.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,9 @@
/* enable x86 relax relocations by default */
#cmakedefine01 ENABLE_X86_RELAX_RELOCATIONS

/* enable x86 APX relax relocations by default */
#cmakedefine01 ENABLE_X86_APX_RELAX_RELOCATIONS

/* Enable IEEE binary128 as default long double format on PowerPC Linux. */
#cmakedefine01 PPC_LINUX_DEFAULT_IEEELONGDOUBLE

Expand Down
3 changes: 3 additions & 0 deletions clang/include/clang/Driver/Options.td
Original file line number Diff line number Diff line change
Expand Up @@ -7442,6 +7442,9 @@ def mmapsyms_implicit : Flag<["-"], "mmapsyms=implicit">,
def mrelax_relocations_no : Flag<["-"], "mrelax-relocations=no">,
HelpText<"Disable x86 relax relocations">,
MarshallingInfoNegativeFlag<CodeGenOpts<"X86RelaxRelocations">>;
def mapx_relax_relocations_yes : Flag<["-"], "mapx-relax-relocations=yes">,
HelpText<"Enable x86 APX relax relocations">,
MarshallingInfoNegativeFlag<CodeGenOpts<"X86APXRelaxRelocations">>;
def msave_temp_labels : Flag<["-"], "msave-temp-labels">,
HelpText<"Save temporary labels in the symbol table. "
"Note this may change .s semantics and shouldn't generally be used "
Expand Down
3 changes: 3 additions & 0 deletions clang/include/clang/Driver/ToolChain.h
Original file line number Diff line number Diff line change
Expand Up @@ -473,6 +473,9 @@ class ToolChain {
/// Check whether to enable x86 relax relocations by default.
virtual bool useRelaxRelocations() const;

/// Check whether to enable x86 APX relax relocations by default.
virtual bool useAPXRelaxRelocations() const;

/// Check whether use IEEE binary128 as long double format by default.
bool defaultToIEEELongDouble() const;

Expand Down
1 change: 1 addition & 0 deletions clang/lib/CodeGen/BackendUtil.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -513,6 +513,7 @@ static bool initTargetOptions(const CompilerInstance &CI,
Options.MCOptions.Crel = CodeGenOpts.Crel;
Options.MCOptions.ImplicitMapSyms = CodeGenOpts.ImplicitMapSyms;
Options.MCOptions.X86RelaxRelocations = CodeGenOpts.X86RelaxRelocations;
Options.MCOptions.X86APXRelaxRelocations = CodeGenOpts.X86APXRelaxRelocations;
Options.MCOptions.CompressDebugSections =
CodeGenOpts.getCompressDebugSections();
if (CodeGenOpts.OutputAsmVariant != 3) // 3 (default): not specified
Expand Down
4 changes: 4 additions & 0 deletions clang/lib/Driver/ToolChain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,10 @@ bool ToolChain::useRelaxRelocations() const {
return ENABLE_X86_RELAX_RELOCATIONS;
}

bool ToolChain::useAPXRelaxRelocations() const {
return ENABLE_X86_APX_RELAX_RELOCATIONS;
}

bool ToolChain::defaultToIEEELongDouble() const {
return PPC_LINUX_DEFAULT_IEEELONGDOUBLE && getTriple().isOSLinux();
}
Expand Down
10 changes: 10 additions & 0 deletions clang/lib/Driver/ToolChains/Clang.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2602,6 +2602,8 @@ static void CollectArgsForIntegratedAssembler(Compilation &C,
bool Crel = false, ExperimentalCrel = false;
bool ImplicitMapSyms = false;
bool UseRelaxRelocations = C.getDefaultToolChain().useRelaxRelocations();
bool UseAPXRelaxRelocations =
C.getDefaultToolChain().useAPXRelaxRelocations();
bool UseNoExecStack = false;
bool Msa = false;
const char *MipsTargetFeature = nullptr;
Expand Down Expand Up @@ -2663,6 +2665,12 @@ static void CollectArgsForIntegratedAssembler(Compilation &C,
checkArg(IsELF, {"yes", "no"});
continue;
}
if (Equal.first == "-mapx-relax-relocations" ||
Equal.first == "--mapx-relax-relocations") {
UseAPXRelaxRelocations = Equal.second == "yes";
checkArg(IsELF, {"yes", "no"});
continue;
}
if (Value == "-msse2avx") {
CmdArgs.push_back("-msse2avx");
continue;
Expand Down Expand Up @@ -2874,6 +2882,8 @@ static void CollectArgsForIntegratedAssembler(Compilation &C,
CmdArgs.push_back("-mmsa");
if (!UseRelaxRelocations)
CmdArgs.push_back("-mrelax-relocations=no");
if (UseAPXRelaxRelocations)
CmdArgs.push_back("-mapx-relax-relocations=yes");
if (UseNoExecStack)
CmdArgs.push_back("-mnoexecstack");
if (MipsTargetFeature != nullptr) {
Expand Down
15 changes: 12 additions & 3 deletions clang/test/Driver/relax.s
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,20 @@
// CHECK: "-cc1as"
// CHECK: "-mrelax-relocations=no"

// RUN: %clang -### -c --target=x86_64-pc-linux -integrated-as -Wa,--mapx-relax-relocations=yes %s 2>&1 | FileCheck %s --check-prefix=APXREL_OPTION

// APXREL_OPTION: "-cc1as"
// APXREL_OPTION: "-mapx-relax-relocations=yes"

// RUN: %clang -cc1as -triple x86_64-pc-linux %s -o %t -filetype obj -mapx-relax-relocations=yes
// RUN: llvm-readobj -r %t | FileCheck --check-prefix=APXREL %s
// RUN: %clang -cc1as -triple x86_64-pc-linux %s -o %t -filetype obj
// RUN: llvm-readobj -r %t | FileCheck --check-prefix=REL %s
// RUN: llvm-readobj -r %t | FileCheck --check-prefix=NOAPXREL %s

// REL: R_X86_64_REX_GOTPCRELX foo
// REL: R_X86_64_CODE_4_GOTPCRELX foo
// APXREL: R_X86_64_REX_GOTPCRELX foo
// APXREL: R_X86_64_CODE_4_GOTPCRELX foo
// NOAPXREL: R_X86_64_REX_GOTPCRELX foo
// NOAPXREL: R_X86_64_GOTPCREL foo

movq foo@GOTPCREL(%rip), %rax
movq foo@GOTPCREL(%rip), %r16
5 changes: 5 additions & 0 deletions clang/tools/driver/cc1as_main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,8 @@ struct AssemblerInvocation {
LLVM_PREFERRED_TYPE(bool)
unsigned X86RelaxRelocations : 1;
LLVM_PREFERRED_TYPE(bool)
unsigned X86APXRelaxRelocations : 1;
LLVM_PREFERRED_TYPE(bool)
unsigned X86Sse2Avx : 1;

/// The name of the relocation model to use.
Expand Down Expand Up @@ -216,6 +218,7 @@ struct AssemblerInvocation {
Crel = false;
ImplicitMapsyms = 0;
X86RelaxRelocations = 0;
X86APXRelaxRelocations = 0;
X86Sse2Avx = 0;
}

Expand Down Expand Up @@ -388,6 +391,7 @@ bool AssemblerInvocation::CreateFromArgs(AssemblerInvocation &Opts,
Opts.Crel = Args.hasArg(OPT_crel);
Opts.ImplicitMapsyms = Args.hasArg(OPT_mmapsyms_implicit);
Opts.X86RelaxRelocations = !Args.hasArg(OPT_mrelax_relocations_no);
Opts.X86APXRelaxRelocations = Args.hasArg(OPT_mapx_relax_relocations_yes);
Opts.X86Sse2Avx = Args.hasArg(OPT_msse2avx);

Opts.AsSecureLogFile = Args.getLastArgValue(OPT_as_secure_log_file);
Expand Down Expand Up @@ -449,6 +453,7 @@ static bool ExecuteAssemblerImpl(AssemblerInvocation &Opts,
MCOptions.Crel = Opts.Crel;
MCOptions.ImplicitMapSyms = Opts.ImplicitMapsyms;
MCOptions.X86RelaxRelocations = Opts.X86RelaxRelocations;
MCOptions.X86APXRelaxRelocations = Opts.X86APXRelaxRelocations;
MCOptions.X86Sse2Avx = Opts.X86Sse2Avx;
MCOptions.CompressDebugSections = Opts.CompressDebugSections;
MCOptions.AsSecureLogFile = Opts.AsSecureLogFile;
Expand Down
6 changes: 3 additions & 3 deletions lld/ELF/Arch/X86_64.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -912,9 +912,9 @@ void X86_64::relocate(uint8_t *loc, const Relocation &rel, uint64_t val) const {
case R_X86_64_CODE_4_GOTPC32_TLSDESC:
case R_X86_64_TLSDESC_CALL:
case R_X86_64_TLSGD:
if (rel.expr == R_RELAX_TLS_GD_TO_LE) {
if (rel.expr == R_RELAX_TLS_GD_TO_LE && ctx.arg.relax) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use --no-relax to suppress TLS relaxation as well as GOTPCREL optimization.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure we need to change it. I assume the problem happens only when using old lld with new compiler. There's nothing to do with the new lld here.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makes the tests or user programs having APX EGPR/NDD/NF pass with "-no-relax" option.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to handle this case? The new lld has the ability to hanlde APX relocations. lld still does the ralax with "-no-relax" for the reset 3 relocations before the APX changes, isn't it?

relaxTlsGdToLe(loc, rel, val);
} else if (rel.expr == R_RELAX_TLS_GD_TO_IE) {
} else if (rel.expr == R_RELAX_TLS_GD_TO_IE && ctx.arg.relax) {
relaxTlsGdToIe(loc, rel, val);
} else {
checkInt(ctx, loc, val, 32, rel);
Expand All @@ -932,7 +932,7 @@ void X86_64::relocate(uint8_t *loc, const Relocation &rel, uint64_t val) const {
case R_X86_64_GOTTPOFF:
case R_X86_64_CODE_4_GOTTPOFF:
case R_X86_64_CODE_6_GOTTPOFF:
if (rel.expr == R_RELAX_TLS_IE_TO_LE) {
if (rel.expr == R_RELAX_TLS_IE_TO_LE && ctx.arg.relax) {
relaxTlsIeToLe(loc, rel, val);
} else {
checkInt(ctx, loc, val, 32, rel);
Expand Down
111 changes: 78 additions & 33 deletions lld/test/ELF/tls-opt.s
Original file line number Diff line number Diff line change
@@ -1,44 +1,84 @@
// REQUIRES: x86
// RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.o
// RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.o -x86-apx-relax-relocations=true
// RUN: ld.lld %t.o -o %t1
// RUN: llvm-readobj -r %t1 | FileCheck --check-prefix=NORELOC %s
// RUN: llvm-objdump --no-print-imm-hex -d --no-show-raw-insn %t1 | FileCheck --check-prefix=DISASM %s
// RUN: llvm-objdump --no-print-imm-hex -d --no-show-raw-insn %t1 | FileCheck --check-prefixes=DISASM,APXRELAX %s

// RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.o
// RUN: ld.lld %t.o -o %t1 --no-relax
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we need to check no-relax?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are instructions with APX EGPR or NDD/NF instructions in the test, and the R_X86_64_GOTTPOFF relocation is emitted. so we add this to suppress link relaxation for TLS relocation in LLD linker. I wonder if we need to emit warning or error in MC for this case (if users write such assembly code).

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But we didn't suppress link relaxation for non APX instruciton before, right?

// RUN: llvm-readobj -r %t1 | FileCheck --check-prefix=NORELOC %s
// RUN: llvm-objdump --no-print-imm-hex -d --no-show-raw-insn %t1 | FileCheck --check-prefixes=DISASM,NOAPXRELAX %s

// NORELOC: Relocations [
// NORELOC-NEXT: ]

// DISASM: <_start>:
// DISASM-NEXT: movq $-8, %rax
// DISASM-NEXT: movq $-8, %r15
// DISASM-NEXT: leaq -8(%rax), %rax
// DISASM-NEXT: leaq -8(%r15), %r15
// DISASM-NEXT: addq $-8, %rsp
// DISASM-NEXT: addq $-8, %r12
// DISASM-NEXT: movq $-4, %rax
// DISASM-NEXT: movq $-4, %r15
// DISASM-NEXT: leaq -4(%rax), %rax
// DISASM-NEXT: leaq -4(%r15), %r15
// DISASM-NEXT: addq $-4, %rsp
// DISASM-NEXT: addq $-4, %r12
// APXRELAX-NEXT: movq $-8, %rax
// APXRELAX-NEXT: movq $-8, %r15
// APXRELAX-NEXT: leaq -8(%rax), %rax
// APXRELAX-NEXT: leaq -8(%r15), %r15
// APXRELAX-NEXT: addq $-8, %rsp
// APXRELAX-NEXT: addq $-8, %r12
// APXRELAX-NEXT: movq $-4, %rax
// APXRELAX-NEXT: movq $-4, %r15
// APXRELAX-NEXT: leaq -4(%rax), %rax
// APXRELAX-NEXT: leaq -4(%r15), %r15
// APXRELAX-NEXT: addq $-4, %rsp
// APXRELAX-NEXT: addq $-4, %r12

// NOAPXRELAX-NEXT: movq -12(%rip), %rax
// NOAPXRELAX-NEXT: movq -12(%rip), %r15
// NOAPXRELAX-NEXT: addq -12(%rip), %rax
// NOAPXRELAX-NEXT: addq -12(%rip), %r15
// NOAPXRELAX-NEXT: addq -12(%rip), %rsp
// NOAPXRELAX-NEXT: addq -12(%rip), %r12
// NOAPXRELAX-NEXT: movq -8(%rip), %rax
// NOAPXRELAX-NEXT: movq -8(%rip), %r15
// NOAPXRELAX-NEXT: addq -8(%rip), %rax
// NOAPXRELAX-NEXT: addq -8(%rip), %r15
// NOAPXRELAX-NEXT: addq -8(%rip), %rsp
// NOAPXRELAX-NEXT: addq -8(%rip), %r12

# EGPR
// DISASM-NEXT: movq $-8, %r16
// DISASM-NEXT: movq $-8, %r20
// DISASM-NEXT: movq $-4, %r16
// DISASM-NEXT: addq $-8, %r16
// DISASM-NEXT: addq $-8, %r28
// DISASM-NEXT: addq $-4, %r16
// APXRELAX-NEXT: movq $-8, %r16
// APXRELAX-NEXT: movq $-8, %r20
// APXRELAX-NEXT: movq $-4, %r16
// APXRELAX-NEXT: addq $-8, %r16
// APXRELAX-NEXT: addq $-8, %r28
// APXRELAX-NEXT: addq $-4, %r16

// NOAPXRELAX-NEXT: movq -12(%rip), %r16
// NOAPXRELAX-NEXT: movq -12(%rip), %r20
// NOAPXRELAX-NEXT: movq -8(%rip), %r16
// NOAPXRELAX-NEXT: addq -12(%rip), %r16
// NOAPXRELAX-NEXT: addq -12(%rip), %r28
// NOAPXRELAX-NEXT: addq -8(%rip), %r16

# NDD
// DISASM-NEXT: addq $-8, %r16, %r16
// DISASM-NEXT: addq $-8, %r16, %r20
// DISASM-NEXT: addq $-8, %r16, %rax
// DISASM-NEXT: addq $-8, %rax, %r16
// DISASM-NEXT: addq $-8, %r8, %r16
// DISASM-NEXT: addq $-8, %rax, %r12
// APXRELAX-NEXT: addq $-8, %r16, %r16
// APXRELAX-NEXT: addq $-8, %r16, %r20
// APXRELAX-NEXT: addq $-8, %r16, %rax
// APXRELAX-NEXT: addq $-8, %rax, %r16
// APXRELAX-NEXT: addq $-8, %r8, %r16
// APXRELAX-NEXT: addq $-8, %rax, %r12

// NOAPXRELAX-NEXT: addq -12(%rip), %r16, %r16
// NOAPXRELAX-NEXT: addq -12(%rip), %r16, %r20
// NOAPXRELAX-NEXT: addq -12(%rip), %r16, %rax
// NOAPXRELAX-NEXT: addq -12(%rip), %rax, %r16
// NOAPXRELAX-NEXT: addq %r8, -12(%rip), %r16
// NOAPXRELAX-NEXT: addq -12(%rip), %rax, %r12

# NDD + NF
// DISASM-NEXT: {nf} addq $-8, %r8, %r16
// DISASM-NEXT: {nf} addq $-8, %rax, %r12
// APXRELAX-NEXT: {nf} addq $-8, %r8, %r16
// APXRELAX-NEXT: {nf} addq $-8, %rax, %r12

// NOAPXRELAX-NEXT: {nf} addq %r8, -12(%rip), %r16
// NOAPXRELAX-NEXT: {nf} addq -12(%rip), %rax, %r12

# NF
// DISASM-NEXT: {nf} addq $-8, %r12
// APXRELAX-NEXT: {nf} addq $-8, %r12
// NOAPXRELAX-NEXT: {nf} addq -12(%rip), %r12

// LD to LE:
// DISASM-NEXT: movq %fs:0, %rax
Expand All @@ -47,10 +87,15 @@
// DISASM-NEXT: leaq -4(%rax), %rcx

// GD to LE:
// DISASM-NEXT: movq %fs:0, %rax
// DISASM-NEXT: leaq -8(%rax), %rax
// DISASM-NEXT: movq %fs:0, %rax
// DISASM-NEXT: leaq -4(%rax), %rax
// APXRELAX-NEXT: movq %fs:0, %rax
// APXRELAX-NEXT: leaq -8(%rax), %rax
// APXRELAX-NEXT: movq %fs:0, %rax
// APXRELAX-NEXT: leaq -4(%rax), %rax

// NOAPXRELAX-NEXT: leaq -12(%rip), %rdi
// NOAPXRELAX-NEXT: callq 0x20126c
// NOAPXRELAX-NEXT: leaq -8(%rip), %rdi
// NOAPXRELAX-NEXT: callq 0x20127c

// LD to LE:
// DISASM: <_DTPOFF64_1>:
Expand Down
9 changes: 7 additions & 2 deletions lld/test/ELF/x86-64-gotpc-no-relax-err.s
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
# REQUIRES: x86
# RUN: split-file %s %t
# RUN: llvm-mc -filetype=obj -triple=x86_64 %t/a.s -o %t/a.o -x86-apx-relax-relocations=true
# RUN: not ld.lld --no-relax -T %t/lds %t/a.o -o /dev/null 2>&1 | FileCheck %s --implicit-check-not=error: --check-prefixes=CHECK,APXRELAX

# RUN: llvm-mc -filetype=obj -triple=x86_64 %t/a.s -o %t/a.o
# RUN: not ld.lld --no-relax -T %t/lds %t/a.o -o /dev/null 2>&1 | FileCheck %s --implicit-check-not=error:
# RUN: not ld.lld --no-relax -T %t/lds %t/a.o -o /dev/null 2>&1 | FileCheck %s --implicit-check-not=error: --check-prefixes=CHECK,NOAPXRELAX

## Test diagnostics for unrelaxed GOTPCRELX overflows. In addition, test that there is no
## `>>> defined in` for linker synthesized __stop_* symbols (there is no
Expand All @@ -13,9 +16,11 @@
# CHECK-NEXT: error: {{.*}}:(.text+0x9): relocation R_X86_64_REX_GOTPCRELX out of range: 2147483659 is not in [-2147483648, 2147483647]; references '__stop_data'
# CHECK-NEXT: >>> defined in <internal>
# CHECK-EMPTY:
# CHECK-NEXT: error: {{.*}}:(.text+0x11): relocation R_X86_64_CODE_4_GOTPCRELX out of range: 2147483651 is not in [-2147483648, 2147483647]; references '__stop_data'
# APXRELAX-NEXT: error: {{.*}}:(.text+0x11): relocation R_X86_64_CODE_4_GOTPCRELX out of range: 2147483651 is not in [-2147483648, 2147483647]; references '__stop_data'
# NOAPXRELAX-NEXT: error: {{.*}}:(.text+0x11): relocation R_X86_64_GOTPCREL out of range: 2147483651 is not in [-2147483648, 2147483647]; references '__stop_data'
# CHECK-NEXT: >>> defined in <internal>


#--- a.s
movl __stop_data@GOTPCREL(%rip), %eax # out of range
movq __stop_data@GOTPCREL(%rip), %rax # out of range
Expand Down
Loading
Loading