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: segfault switching between read/write windows #1718

Merged
merged 2 commits into from
Oct 4, 2023
Merged

Conversation

heifner
Copy link
Member

@heifner heifner commented Oct 4, 2023

  • Always execute the lambda after pop()ing it from the queue. This is needed as the read_write queue is used to post the lambda that switches to the read window. The read window can then start and begin pushing future tasks to the read_write queue. This allows multiple threads to access the read_write at one time as the original call to switch to the read window is running unlocked, once it finishes it pops from the queue while other threads can access it.
  • Modify read_only_trx_test.py so it can run in non-debug mode. In debug mode it generates an excessive amount of logging slowing down the test. Running in non-debug allowed the test to more easily trigger the segfault. Also enhanced the test to provide better error output if it does fail.

This fix needs to be back-ported to 4.0.

Resolves #1716

…logging and report specific information when it does fail. Update the test to run without debug in ci/cd so that it can run faster and put more load on nodeos.
…only mode and spawn threads that access the queue.
@heifner
Copy link
Member Author

heifner commented Oct 4, 2023

@heifner heifner requested review from linh2931 and greg7mdp October 4, 2023 20:07
@heifner heifner added the OCI Work exclusive to OCI team label Oct 4, 2023
Copy link
Contributor

@ericpassmore ericpassmore left a comment

Choose a reason for hiding this comment

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

LGTM

@heifner heifner merged commit 42cf4b0 into main Oct 4, 2023
61 checks passed
@heifner heifner deleted the GH-1716-core branch October 4, 2023 22:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCI Work exclusive to OCI team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Test failure: read-only-trx-parallel-test
4 participants