Skip to content

Commit

Permalink
[LoongArch64] revert the modification about the LA64's PageSize by #8…
Browse files Browse the repository at this point in the history
…3632. (#84960)

* [LoongArch64] revert the modification about
the LA64's PageSize by #83632.

* keep the comment by CR.
  • Loading branch information
shushanhf authored Apr 20, 2023
1 parent 4fe223f commit 890d6e3
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/coreclr/vm/loongarch64/thunktemplates.S
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@
#include "unixasmmacros.inc"
#include "asmconstants.h"

; Note that the offsets specified in pcaddi must match the behavior of GetStubCodePageSize() on this architecture/os.
// Note that the offsets specified in pcaddi must match the behavior of GetStubCodePageSize() on this architecture/os.

LEAF_ENTRY StubPrecodeCode
pcaddi $r21, 0x4004 //4, for Type encoding.
pcaddi $r21, 0x1004 //4, for Type encoding.
ld.d $t2,$r21, (StubPrecodeData__MethodDesc - 4*4)
ld.d $r21,$r21, (StubPrecodeData__Target - 4*4)
jirl $r0,$r21,0
LEAF_END_MARKED StubPrecodeCode

LEAF_ENTRY FixupPrecodeCode
pcaddi $r21, 0x4003 //3, for Type encoding.
pcaddi $r21, 0x1003 //3, for Type encoding.
ld.d $r21,$r21, (FixupPrecodeData__Target - 4*3)
jirl $r0,$r21,0
pcaddi $r21, 0x4003
pcaddi $r21, 0x1003
ld.d $t2,$r21, (FixupPrecodeData__MethodDesc - 4*3 -4*3)
ld.d $r21,$r21, (FixupPrecodeData__PrecodeFixupThunk - 4*3 - 4*3)
jirl $r0,$r21,0
Expand All @@ -26,7 +26,7 @@ LEAF_END_MARKED FixupPrecodeCode
// NOTE: For LoongArch64 `CallCountingStubData__RemainingCallCountCell` must be zero !!!
// Because the stub-identifying token is $t1 within the `OnCallCountThresholdReachedStub`.
LEAF_ENTRY CallCountingStubCode
pcaddi $t2, 0x4000
pcaddi $t2, 0x1000
ld.d $t1, $t2, CallCountingStubData__RemainingCallCountCell
ld.h $r21, $t1, 0
addi.w $r21, $r21, -1
Expand Down

0 comments on commit 890d6e3

Please sign in to comment.