summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorShoaib Meenai <smeenai@fb.com>2017-10-17 01:41:14 +0000
committerShoaib Meenai <smeenai@fb.com>2017-10-17 01:41:14 +0000
commita42f60e7f7f745a3d7ab9ba4c31044cb16391aa0 (patch)
treeec38debabbba88401bdf58ad00595dc791352287 /llvm/lib
parent4d1969f22b28356ae37e0b2025c39d4623fe4235 (diff)
downloadbcm5719-llvm-a42f60e7f7f745a3d7ab9ba4c31044cb16391aa0.tar.gz
bcm5719-llvm-a42f60e7f7f745a3d7ab9ba4c31044cb16391aa0.zip
[ExecutionEngine] Correct the size of a write in a COFF i386 relocation
We want to be writing a 32bit value, so we should be writing 4 bytes instead of 2. Patch by Alex Langford <apl@fb.com>. Differential Revision: https://reviews.llvm.org/D38872 llvm-svn: 315964
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFI386.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFI386.h b/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFI386.h
index 901f77865ba..76c8f956300 100644
--- a/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFI386.h
+++ b/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFI386.h
@@ -209,7 +209,7 @@ public:
DEBUG(dbgs() << "\t\tOffset: " << RE.Offset
<< " RelType: IMAGE_REL_I386_SECREL Value: " << RE.Addend
<< '\n');
- writeBytesUnaligned(RE.Addend, Target, 2);
+ writeBytesUnaligned(RE.Addend, Target, 4);
break;
default:
llvm_unreachable("unsupported relocation type");
OpenPOWER on IntegriCloud