Skip to content

docs: add examples and documentation in the guide about HOCAP style logatom - #2619

Open
bsdinis wants to merge 2 commits into
mainfrom
bsdinis/wpo
Open

docs: add examples and documentation in the guide about HOCAP style logatom#2619
bsdinis wants to merge 2 commits into
mainfrom
bsdinis/wpo

Conversation

@bsdinis

@bsdinis bsdinis commented Jul 1, 2026

Copy link
Copy Markdown
Collaborator

By submitting this pull request, I confirm that my contribution is made under the terms of the MIT license.

@bsdinis
bsdinis requested review from ahuoguo and tjhance July 1, 2026 20:58
Comment thread source/docs/guide/src/logatom-hocap.md Outdated
@ahuoguo

ahuoguo commented Jul 2, 2026

Copy link
Copy Markdown
Collaborator

I think Travis might have mentioned this at the retreat, but maybe making this a module-level rustdoc for vstd::logatom makes more sense, and leaving a link to the rustdoc in the logical atomicity chapter. I think my process of going through this guide requires me to jump to the vstd::logatom code frequently.

@tjhance

tjhance commented Jul 3, 2026

Copy link
Copy Markdown
Collaborator

We should definitely have verusdoc style docs for logatom in vstd, but we also desperately need more "guide" material on the subject of concurrency verification, which should include an overview of logical atomicity approaches, among other topics. So I think this material, as written, is appropriate for the guide. It's probably fine as-is; we can organize it more later once we have more material.

Comment thread source/docs/guide/src/SUMMARY.md
Base automatically changed from bsdinis/skv to main July 13, 2026 17:17
@bsdinis
bsdinis force-pushed the bsdinis/wpo branch 2 times, most recently from be14319 to 67f39c7 Compare July 14, 2026 17:19

@parno parno left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks for working on this! I realize it's still work in progress, but I was curious to take a look.

Comment thread source/docs/guide/src/logatom-hocap.md Outdated
Comment thread source/docs/guide/src/logatom-hocap.md Outdated
Comment thread source/docs/guide/src/logatom-hocap.md Outdated
Comment thread source/docs/guide/src/logatom-hocap.md Outdated
Comment thread source/docs/guide/src/logatom-hocap.md Outdated
Comment thread source/docs/guide/src/logatom-hocap.md Outdated

## Calling `apply`

Consider the example of a monotonic counter (as seen in the examples dir).

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Ideally, the Guide examples should be readable in the guide, without having to refer to the Verus files elsewhere in the repo. Can you use some anchor tags to include relevant snippets from the file here instead?

@slerpyyy slerpyyy Jul 15, 2026

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

If the example is too large, we could also hide it behind an HTML <detail> element so it doesn't interrupt the flow of the explanation too much. The mdbook does seem to support this, but it would be the first time we do this in the guide.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I think the point here is to guide through the HOCAP parts of the example, and the reference to the guide is just for reference (pardon my tautology).

If we do want to insist on having the full thing, the way to go is the <detail>, but at the end of the example

Comment thread source/docs/guide/src/logatom-hocap.md
Comment thread source/docs/guide/src/logatom-hocap.md Outdated
Comment thread source/docs/guide/src/logatom-hocap.md Outdated
Comment thread source/docs/guide/src/logatom-hocap.md Outdated
Comment thread source/docs/guide/src/logatom-hocap.md Outdated
Comment thread source/docs/guide/src/logatom_hocap.md Outdated
Comment thread source/docs/guide/src/logatom-hocap.md Outdated
Comment thread source/docs/guide/src/logatom-hocap.md Outdated
@bsdinis
bsdinis force-pushed the bsdinis/wpo branch 3 times, most recently from 8d5814e to faaaed6 Compare July 18, 2026 03:15
@bsdinis
bsdinis requested a review from ahuoguo July 31, 2026 11:16
@bsdinis
bsdinis requested a review from parno August 12, 2026 15:13
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.

5 participants