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

Fix a deadlock associated with thread safe IO #601

Merged
merged 2 commits into from
Apr 19, 2024
Merged

Conversation

abensonca
Copy link
Collaborator

The numerical root finder code can be called recursively which lead to deadlocks in thread safe IO critical sections. This is now avoided by not doing function evaluations directly inside a write statement. Additionally, warning messages are not generated/output if the optional status parameter is present - this could have resulted in huge warning logs being produced.

Also adds reporting on reporting on acquisition/release of thread safe IO locks. This is useful for debugging deadlocks.

… safe IO locks

This is useful for debugging deadlocks.
The numerical root finder code can be called recursively which lead to deadlocks in thread safe IO critical sections. This is now avoided by not doing function evaluations directly inside a `write` statement. Additionally, warning messages are not generated/output if the optional `status` parameter is present - this could have resulted in huge warning logs being produced.
@abensonca abensonca self-assigned this Apr 18, 2024
@abensonca abensonca added bug Something isn't working IO Input/output labels Apr 18, 2024
Copy link

⚠️ Possible misspelled word 'fsolver' in file 'source/numerical.root_finder.F90'
⚠️ Possible misspelled word 'fdfsolver' in file 'source/numerical.root_finder.F90'

@abensonca abensonca added this pull request to the merge queue Apr 19, 2024
Merged via the queue into master with commit 1d8aee8 Apr 19, 2024
277 of 278 checks passed
@abensonca abensonca deleted the fixThreadSafeIO branch April 19, 2024 16:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working IO Input/output
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant