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

Forder segfault #6111

Draft
wants to merge 8 commits into
base: master
Choose a base branch
from
Draft

Forder segfault #6111

wants to merge 8 commits into from

Conversation

ben-schwen
Copy link
Member

@ben-schwen ben-schwen commented Apr 30, 2024

Closes #4300

Changes recursive radix helper to an iterative version with a priority queue

  • fix
  • tests
  • news
  • timings

@ben-schwen ben-schwen marked this pull request as draft April 30, 2024 21:49
@MichaelChirico
Copy link
Member

Hey @ben-schwen what's the status here? If you think the fix is good and the PR just needs to be wrapped up with tests/docs, we could ask for extra help there. It would be nice to include with 1.17.0 if you think it's doable.

@MichaelChirico MichaelChirico added this to the 1.17.0 milestone Dec 11, 2024
@ben-schwen
Copy link
Member Author

ben-schwen commented Dec 15, 2024

Hey @ben-schwen what's the status here? If you think the fix is good and the PR just needs to be wrapped up with tests/docs, we could ask for extra help there. It would be nice to include with 1.17.0 if you think it's doable.

While it fixes the linked issues, the patch in this branch runs into memory issues on other test cases, so not a real fix yet. The mentioned workaround with ulimit works on Linux until the stack size becomes too big for the memory.

@MichaelChirico it seems that #6274 has fixed the appearing segfaults when rewriting from a recursive to an iterative version by explicitly using more variable length arrays. So this can be patched up for 1.17.0. We should still watch out not to run into a performance regression

Copy link

github-actions bot commented Dec 17, 2024

Comparison Plot

Generated via commit f566f5d

Download link for the artifact containing the test results: ↓ atime-results.zip

Task Duration
R setup and installing dependencies 4 minutes and 44 seconds
Installing different package versions 8 minutes and 6 seconds
Running and plotting the test cases 2 minutes and 27 seconds

@MichaelChirico
Copy link
Member

Hey @ben-schwen what's the status here? If you think the fix is good and the PR just needs to be wrapped up with tests/docs, we could ask for extra help there. It would be nice to include with 1.17.0 if you think it's doable.

While it fixes the linked issues, the patch in this branch runs into memory issues on other test cases, so not a real fix yet. The mentioned workaround with ulimit works on Linux until the stack size becomes too big for the memory.

@MichaelChirico it seems that #6274 has fixed the appearing segfaults when rewriting from a recursive to an iterative version by explicitly using more variable length arrays. So this can be patched up for 1.17.0. We should still watch out not to run into a performance regression

that means this PR is still needed, but earlier #6274 cleared the way for this not to affect the other tests you mentioned? Or this bug is already fixed, and we only need this PR for regression testing?

@ben-schwen
Copy link
Member Author

ben-schwen commented Dec 17, 2024

that means this PR is still needed, but earlier #6274 cleared the way for this not to affect the other tests you mentioned? Or this bug is already fixed, and we only need this PR for regression testing?

Yes and no. With #6274 we do not run into segfaults anymore. However, as shown in our GHA checks, forder can now fail because not enough memory can be allocated. This happens after multiple subsequent bmerge calls which could indicate that we have some memory leakage in forder

src/forder.c Outdated Show resolved Hide resolved
src/forder.c Outdated Show resolved Hide resolved
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.

unique gives segfault from C stack overflow
2 participants