Enable MHR support on OSX (dotnet/coreclr#25716)
authorJan Vorlicek <janvorli@microsoft.com>
Wed, 17 Jul 2019 10:14:42 +0000 (12:14 +0200)
committerGitHub <noreply@github.com>
Wed, 17 Jul 2019 10:14:42 +0000 (12:14 +0200)
commit736bf03a31aeae2c0f15e8231b5654ad2368e587
treebfda707bf341ba6e1742f0507123dbbbff975319
parentf1eab2c35a78529c4ffedcec34c2b83479a3b6dc
Enable MHR support on OSX (dotnet/coreclr#25716)

* Enable MHR support on OSX

* Move JIT_WriteBarrier that is modified at runtime to a dynamically
  allocated memory instead of making a page in libcoreclr.dylib RWX.

* Update PAL to add MEM_JIT flag for allocations and reservations of
  executable memory.

* Update native runtime in EH and stack unwinding areas so that it can
  unwind from the write barrier copy. That code has no unwind info, so
  without special handling, runtime would not be able to unwind from
  it.

Commit migrated from https://github.com/dotnet/coreclr/commit/7a970842ebd88686851af53edee689a3149737bf
12 files changed:
src/coreclr/clrdefinitions.cmake
src/coreclr/src/pal/src/include/pal/utils.h
src/coreclr/src/pal/src/map/map.cpp
src/coreclr/src/pal/src/map/virtual.cpp
src/coreclr/src/pal/src/misc/utils.cpp
src/coreclr/src/vm/amd64/jitinterfaceamd64.cpp
src/coreclr/src/vm/ceemain.cpp
src/coreclr/src/vm/excep.cpp
src/coreclr/src/vm/exceptionhandling.cpp
src/coreclr/src/vm/stackwalk.cpp
src/coreclr/src/vm/threads.cpp
src/coreclr/src/vm/threads.h