You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix stackwalker calculation of object displacement for Offheap
In walkJITFrameSlotsForInternalPointers(), a displacement of data is
calculated between an array object before and after it is moved.
Currently, when offheap is enabled, this displacement is calculated as the
difference between the dataAddr pointers of the new and old locations.
However, because the src object may be overwritten during sliding object
movement, it is not safe to read its contents, such as the dataAddr
pointer.
Thus, this contribution modifies how the stackwalker calculates
displacement when offheap allocation is enabled such that:
- if the array data is adjacent to the array header (i.e.: dataAddr ==
pinningArrayAddr + sizeofHeader), calculate the displacement as dst -
src
- otherwise, set displacement to 0
Signed-off-by: midronij <[email protected]>
0 commit comments