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

Reasoning behavior of a lock #410

Closed
efenniht opened this issue Oct 20, 2019 · 2 comments
Closed

Reasoning behavior of a lock #410

efenniht opened this issue Oct 20, 2019 · 2 comments

Comments

@efenniht
Copy link
Contributor

I'm wondering how I prove a given program is a correct lock. Informally, I believe that a lock must provide two main features:

  1. Mutual exclusion: if thread A is holding a lock L, other threads cannot hold L.
  2. Acquire-release of thread-wise views: whenever thread A unlocks L, view of A is released to L; another thread to hold L acquires its view.

However I'm still curious about writing proper proof in (1) midterm exam and (2) formal reasoning. How can I do?

@jeehoonkang
Copy link
Member

  • Actually, 2. implies 1.
  • In the midterm exam, I'll not ask too difficult questions you cannot solve beyond the scope of the lectures.
  • For formal reasoning of locks and other concurrent programs, see Iris: https://iris-project.org/

@efenniht
Copy link
Contributor Author

Thanks for kind answer!

@kyeongmincho kyeongmincho transferred this issue from kaist-cp/helpdesk Oct 14, 2021
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