-
Notifications
You must be signed in to change notification settings - Fork 5k
[DRAFT] Write barrier without any RWX pages #114982
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
[DRAFT] Write barrier without any RWX pages #114982
Conversation
…rrier_WithoutCodegen
…east, somewhat close.
Tagging subscribers to this area: @mangod9 |
… If it does... I'll likely do this logic for all architectures
…as well. If it does... I'll likely do this logic for all architectures" This reverts commit a882fbf.
…_WRITE_WATCH_FOR_GC_HEAP
@@ -179,6 +179,10 @@ GLOBAL_LABEL RhpCheckedAssignRefAVLocation | |||
LEAF_END RhpCheckedAssignRef\EXPORT_REG_NAME, _TEXT | |||
.endm | |||
|
|||
LEAF_ENTRY RhpWriteBarriers, _TEXT |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FWIW this would not work anyway... we compile all code on Apple platforms as .subsections_via_symbols
and the Apple linker is free to reorder the functions (or discard unused ones if told to). Compiling without subsections_via_symbols
is not an option due to various bugs in different linker versions. The only other option to keep the desired order is to mark the successive symbols as .alt_entry
, which also happens to run into linker bugs if not done extremely carefully...
Add a new config switch DOTNET_UseGCWriteBarrierCopy to control whether or not to use a copy of the WriteBarrier code instead of assembly code embedded in the coreclr binary. Typically we do this to improve performance, but this change enables a new path where we just have the barrier as assembly code in the coreclr binary. Also, with this change, the 1 copy of the code which is used for this scenario is shared between NativeAOT and coreclr.
DRAFT Because...