mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-04-07 01:38:26 +00:00
[x86] Fix isOffsetSuitableForCodeModel kernel code model offset
Offset == 0 is a valid offset for kernel code model according to the x86_64 System V ABI. Found by inspection, no testcase. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@223383 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
1b77bb5628
commit
9eb2a386c7
@ -3673,7 +3673,7 @@ bool X86::isOffsetSuitableForCodeModel(int64_t Offset, CodeModel::Model M,
|
||||
// For kernel code model we know that all object resist in the negative half
|
||||
// of 32bits address space. We may not accept negative offsets, since they may
|
||||
// be just off and we may accept pretty large positive ones.
|
||||
if (M == CodeModel::Kernel && Offset > 0)
|
||||
if (M == CodeModel::Kernel && Offset >= 0)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
|
Loading…
x
Reference in New Issue
Block a user