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

Add clarification on why we must take GuestSharedMemory::lock #178

Merged
merged 1 commit into from
Jan 28, 2025

Conversation

syntactically
Copy link
Contributor

Previously, the code comments were not sufficiently clear as to why apparently-useless locks during the execution of the guest are necessary for the invariants of the GuestSharedMemory/HostSharedMemory split. This led to confusion as to whether it would be a good idea to remove them, so this commit clarifies that there is a good reason for them to be there.

@syntactically syntactically requested review from ludfjig, simongdavies, dblnz and danbugs and removed request for ludfjig January 28, 2025 20:21
@syntactically syntactically added the area/documentation Related to documentation label Jan 28, 2025
Copy link
Contributor

@ludfjig ludfjig left a comment

Choose a reason for hiding this comment

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

LGTM. I feel like there should exist a way to have the type system help with this...

Previously, the code comments were not sufficiently clear as to why
apparently-useless locks during the execution of the guest are
necessary for the invariants of the GuestSharedMemory/HostSharedMemory
split.  This led to confusion as to whether it would be a good idea to
remove them, so this commit clarifies that there is a good reason for
them to be there.

Signed-off-by: Lucy Menon <168595099+syntactically@users.noreply.github.com>
@syntactically syntactically merged commit b9c67fb into main Jan 28, 2025
17 checks passed
@syntactically syntactically deleted the lm/shmem-comments branch January 28, 2025 21:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/documentation Related to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants