We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4655409 commit b050e7bCopy full SHA for b050e7b
src/coreclr/jit/emit.cpp
@@ -5049,9 +5049,11 @@ void emitter::emitJumpDistBind()
5049
nsd = B_DIST_SMALL_MAX_NEG;
5050
psd = B_DIST_SMALL_MAX_POS;
5051
5052
+ // 2 instructions: "reverse cmp-and-branch; jal offset;"
5053
+ // Move bounds to the right by 'ssz' to account for the reversed branch instruction size.
5054
msz = sizeof(code_t) * 2;
- nmd = J_DIST_SMALL_MAX_NEG;
- pmd = J_DIST_SMALL_MAX_POS;
5055
+ nmd = J_DIST_SMALL_MAX_NEG + ssz;
5056
+ pmd = J_DIST_SMALL_MAX_POS + ssz;
5057
}
5058
else if (emitIsUncondJump(jmp))
5059
{
0 commit comments