Skip to content
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

regions: add missing write-barrier plus refactoring #4172

Merged
merged 6 commits into from
Aug 18, 2023

Conversation

crusso
Copy link
Contributor

@crusso crusso commented Aug 16, 2023

  • add the missing write_barrier when initializing fields of a deserialized region (see Region::init_region)
  • as suggested by Luc, use RTS implemented alloc_region, init_region and field access functions to avoid duplication of logic in rts and compile.ml
  • render region implementation abstract to compile.ml

* meta_data::size::PAGES_IN_BLOCK
);
(*r).page_count = page_count;
write_with_barrier(mem, &mut (*r).vec_pages, vec_pages);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the barrier!

@crusso crusso marked this pull request as ready for review August 16, 2023 18:13
* repro for bug

* test output (broken)

* don't check tag on region field access for serialization

* delete repro, its just regions-pay-as-you-go.mo

* delete def of TAG_STABLE_SEEN

* Update rts/motoko-rts/src/types.rs
@crusso
Copy link
Contributor Author

crusso commented Aug 18, 2023

@luc-blaeser is this ok to merge?

@crusso crusso merged commit fef65b2 into multiple-stable-memory Aug 18, 2023
3 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant