-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
[mono][interp] Add missing GC wbarriers for static field stores with hotreload enabled #100775
Conversation
24be801
to
7c1398e
Compare
@srxqds If you could double check that this also fixed the issue, it would be great. |
yeah, thank, lgtm |
but hope you can fix |
@lambdageek How would this check look in order to handle also static data from collectible assemblies ? |
when enable collectiable alc, the static variable will be reference in LoaderAlloc, the ref link will be : ALC -> LoaderAlloc -> Object[] -> static variable. |
7c1398e
to
af0d6eb
Compare
…treload By default, static fields are stored in malloced memory that is registered and always scanned as roots. With hotreload, new static data is allocated inside newly created objects, so storing into it will require write barriers. In order to avoid slowing the normal execution, for fields from metadata updates, we will store into them via ldflda + stobj instead.
…llectible assemblies
af0d6eb
to
9f16297
Compare
…hotreload enabled (dotnet#100775) * [mono][interp] Add missing GC wbarriers for static field stores in hotreload By default, static fields are stored in malloced memory that is registered and always scanned as roots. With hotreload, new static data is allocated inside newly created objects, so storing into it will require write barriers. In order to avoid slowing the normal execution, for fields from metadata updates, we will store into them via ldflda + stobj instead. * [mono][interp] Add missing GC wbarriers for static field stores in collectible assemblies
By default, static fields are stored in malloced memory that is registered and always scanned as roots. With hotreload, new static data is allocated inside newly created objects, so storing into it will require write barriers. In order to avoid slowing the normal execution, for fields from metadata updates, we will store into them via ldflda + stobj instead.
Fixes #100065