File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
llvm/lib/ExecutionEngine/JITLink Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -227,7 +227,7 @@ class MachOAtomGraphBuilder_x86_64 : public MachOAtomGraphBuilder {
227
227
AtomToFix = &*AtomToFixOrErr;
228
228
}
229
229
230
- if (FixupAddress + (1 << RI.r_length ) >
230
+ if (FixupAddress + static_cast <JITTargetAddress> (1 << RI.r_length ) >
231
231
AtomToFix->getAddress () + AtomToFix->getContent ().size ())
232
232
return make_error<JITLinkError>(
233
233
" Relocation content extends past end of fixup atom" );
@@ -290,7 +290,8 @@ class MachOAtomGraphBuilder_x86_64 : public MachOAtomGraphBuilder {
290
290
case PCRel32Minus1Anon:
291
291
case PCRel32Minus2Anon:
292
292
case PCRel32Minus4Anon: {
293
- JITTargetAddress Delta = 1 << (*Kind - PCRel32Minus1Anon);
293
+ JITTargetAddress Delta =
294
+ static_cast <JITTargetAddress>(1 << (*Kind - PCRel32Minus1Anon));
294
295
JITTargetAddress TargetAddress =
295
296
FixupAddress + 4 + Delta + *(const ulittle32_t *)FixupContent;
296
297
if (auto TargetAtomOrErr = G.findAtomByAddress (TargetAddress))
You can’t perform that action at this time.
0 commit comments