ARM64: Fix for recording SP for handler.
authorKyungwoo Lee <kyulee@microsoft.com>
Tue, 12 Apr 2016 16:11:53 +0000 (09:11 -0700)
committerKyungwoo Lee <kyulee@microsoft.com>
Tue, 12 Apr 2016 16:12:15 +0000 (09:12 -0700)
commit63554209e89d38785f2a1241939c490370e3efed
tree6dfce29fc6277e813385aa8cb34b8ed58ffe083d
parentff26d6801b3ce0dec5918a5ad0d3ab90f9656e28
ARM64: Fix for recording SP for handler.

Fixes https://github.com/dotnet/coreclr/issues/3701.

When GC occurs in a catch handler, we compare the current frame with the one
saved before the funclet was invoked.
The recorded SP address was wrong (offset by 16 byte), which caused FindParentStackFrameForStackWalk to null frame.
So, we ended up with assert on `ExceptionTracker::HasFrameBeenUnwoundByAnyActiveException(&m_crawl)`.
The issue was assembly helper, CallEHFunclet records FP instead of SP while SP is adjusted in prolog.
src/vm/arm64/asmhelpers.asm
tests/arm64/Tests.lst