[NativeAOT] correctly initalize CONTEXT before failing fast (#81010)
authorAustin Wise <AustinWise@gmail.com>
Mon, 6 Feb 2023 02:51:48 +0000 (18:51 -0800)
committerGitHub <noreply@github.com>
Mon, 6 Feb 2023 02:51:48 +0000 (18:51 -0800)
commit29b6a51dead90d3c76631700799fc34d1432f241
tree3acb851e68b07756912ce4d252a6b1c1dc4dcdc0
parentf0894ee4edbfad52bc3b3af0c7e2fdcc58475cc9
[NativeAOT] correctly initalize CONTEXT before failing fast (#81010)

* [NativeAOT] correctly initalize CONTEXT before failing fast

* Switch from using GetThreadContext to RtlCaptureContext.

* Add a better explination of why the function is unimplmented on Unix.

* Update src/coreclr/nativeaot/Runtime/PalRedhawk.h

Co-authored-by: Vladimir Sadov <vsadov@microsoft.com>
* Respond to feedback: unconditionally set CONTEXT_CONTROL

* Respond to feedback: consolidate setting of ContextFlags.

* On second thought, don't add a second layer of ifdef nesting.

---------

Co-authored-by: Vladimir Sadov <vsadov@microsoft.com>
src/coreclr/nativeaot/Runtime/EHHelpers.cpp
src/coreclr/nativeaot/Runtime/PalRedhawk.h
src/coreclr/nativeaot/Runtime/unix/PalRedhawkUnix.cpp
src/coreclr/nativeaot/Runtime/windows/PalRedhawkMinWin.cpp