[llvm-bugs] [Bug 49441] New: RuntimeDyld relocation overflow (Regression in LLVM 12.rc2/trunk)
via llvm-bugs
llvm-bugs at lists.llvm.org
Thu Mar 4 06:57:10 PST 2021
https://bugs.llvm.org/show_bug.cgi?id=49441
Bug ID: 49441
Summary: RuntimeDyld relocation overflow (Regression in LLVM
12.rc2/trunk)
Product: libraries
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: Linker
Assignee: unassignedbugs at nondot.org
Reporter: wenzel.jakob at epfl.ch
CC: llvm-bugs at lists.llvm.org
Created attachment 24589
--> https://bugs.llvm.org/attachment.cgi?id=24589&action=edit
Reproducer -- crashes with an assertion failure on Trunk
Dear LLVM team,
I'm using LLVM to JIT-compile relocatable vectorized code across various
platforms.
With the latest LLVM trunk, a large portion of previously working code triggers
an assertion failure while applying relocations in RuntimeDyldCOFFX86_64
(Windows/x64):
Assertion failed: ((int64_t)Result <= INT32_MAX) && "Relocation overflow", file
C:\\llvm\lib\ExecutionEngine\RuntimeDyld\Targets/RuntimeDyldCOFFX86_64.h, line
105
The same works with LLVM 10 and 11. Something very strange is happening here as
well -- if I enable debug messages, I can see the identifiers of those
relocations, and one seems to have a bogus name, and a very large addend
(4294967295 == -0x1), which is what ultimately triggers the crash.
SectionID: 12
In Section 12 Offset 78 RelType:
4 TargetName: __real at 7fffffff Addend 0
In Section 12 Offset 87 RelType: 4 TargetName: __real at 3f000000 Addend 0
In Section 12 Offset 96 RelType: 4
TargetName: __real at 40490fdb Addend 0
In Section 12 Offset 111 RelType: 4 TargetName: __real at 3f800000 Addend 0
In Section 12 Offset 126 RelType: 4
TargetName: __real at 3d2cb352 Addend 0
In Section 12 Offset 140 RelType: 4 TargetName: __real at 3cc617e3 Addend 0
In Section 12 Offset 149 RelType: 4
TargetName: __real at 3d3a3ec7 Addend 0
In Section 12 Offset 158 RelType: 4 TargetName: __real at 3d9980f6 Addend 0
In Section 12 Offset 167 RelType: 4
TargetName: __real at 3e2aaae4 Addend 0
In Section 12 Offset 176 RelType: 4 TargetName: __real at 3fc90fdb Addend 0
In Section 12 Offset 185 RelType: 4
TargetName: __real at 80000000 Addend 0
In Section 12 Offset 289 RelType: 4 TargetName:
__ymm at 0000000000000000000000000000000000000000000000000000000000000000 Addend
4294967295
I've isolated the smallest piece of code in our test suite that triggers this
crash and wrapped into a tiny MCJIT harness. Please see the attached file.
Best,
Wenzel
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20210304/7b849988/attachment-0001.html>
More information about the llvm-bugs
mailing list