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

A Small Mistake in lockfree_queue.md #2341

Open
StaRadian opened this issue Aug 28, 2024 · 4 comments
Open

A Small Mistake in lockfree_queue.md #2341

StaRadian opened this issue Aug 28, 2024 · 4 comments

Comments

@StaRadian
Copy link

There is a minor typo in the Pop Operation section of the iceoryx/doc/design/lockfree_queue.md document, where the state of the queue after a pop operation is incorrectly illustrated. Specifically, the positions of x and y are swapped.

Current Document:

Pop Operation

Pop reads the value at the index of head and returns it if the cycle matches Heads cycle and a CAS to increase head by 1 succeeds.

[ (c,?), (c,y), (c,x), (c-1,?) ]   H=(c,1)     T=(c,3)

pop returns y

[ (c,?), (c,x), (c,y), (c-1,?) ]   H=(c,2)     T=(c,3)

Corrected Document:

Pop reads the value at the index of head and returns it if the cycle matches Heads cycle and a CAS to increase head by 1 succeeds.

[ (c,?), (c,x), (c,y), (c-1,?) ]   H=(c,1)     T=(c,3)

pop returns y

[ (c,?), (c,x), (c,y), (c-1,?) ]   H=(c,2)     T=(c,3)

Thank you.

@elBoberido
Copy link
Member

@StaRadian do you want to create a PR to fix it. You would need to sign the Eclipse Contributor Agreement. If you don't want to run through all the hoops for this little change, I can also fix it in my next PR.

@StaRadian
Copy link
Author

@elBoberido I didn’t realize I could become a contributor, so thank you for letting me know!
I'm still a newbie as a programmer, I’ll give it a try. :D
Thanks!

@elBoberido
Copy link
Member

@StaRadian sure, go ahead. I'll reopen the issue since you need an issue number for your commit.

Please have a look at the 8 steps from the following link.
https://github.com/eclipse-iceoryx/iceoryx/blob/main/CONTRIBUTING.md#feature-request-and-bugs
Since iceoryx is used in safety-critical environments, we have to follow more strict rules like you might know from other projects. One of these rules is to ensure traceability, which we do by assigning issue numbers to commit, among other things.

@elBoberido elBoberido reopened this Aug 28, 2024
@StaRadian
Copy link
Author

Thanks for the information. I’m currently reviewing the 8 steps in the link you provided and will make sure to fully understand them before proceeding. I recognize the importance of following the strict rules, especially for a project like iceoryx.
Thanks

StaRadian added a commit to StaRadian/iceoryx that referenced this issue Aug 29, 2024
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

No branches or pull requests

2 participants