-
-
Notifications
You must be signed in to change notification settings - Fork 1k
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
rpmalloc causes crash on exiting LMMS #5733
Comments
I think the rpmalloc submodule could be bisected to find the issue, before we report it to the rpmalloc team. |
OK. I'm going to bisect it. I did that yesterday but I may not have gone far back in time. |
@JohannesLorenz This is with the |
I needed to skip some parts of the bisect because I got compile errors so this is incomplete. I'll look into manually tweeking between the steps to see if I can get down to the last commit. In the meantime it's one of these:
|
The 'guilty' commit is mjansson/rpmalloc@68c6ae5
The crash is in an assert that was added in this very same commit so I guess it could be that the issue was there already and that adding the assert makes lmms take a dive in some cases on a debug build.
@JohannesLorenz Have you seen this crash on a non debug build? |
Good observation. The error does not occur in a non-debug build. |
@zonkmachine Do you want to report the issue to rpmalloc, so they can find out if it's their bug or ours? |
No thank you good sir. I'm not on top of this one at all. |
Tracked in rpmalloc now as mjansson/rpmalloc#202. |
rpmalloc confirmed that it's most likely a leak in LMMS, so our bug. So this needs to be analyzed by us. |
The reason for this is that I assume you only enable asserts in rpmalloc in debug builds? As I mentioned in mjansson/rpmalloc#202 you could if you don't care about the leak (since the OS will release pages anyway on process termination) just disable asserts in rpmalloc until you can track this down. |
Yes.
I tried to track the origin by setting breakpoints at |
Just a newbie developer here trying to provide some more insight on this issue. The thing is, as far as I can tell this leak is occurring right before if not at program termination instead of in the middle of runtime. Using the information from @PhysSong 's debug-fu, I made a little member function called
which does seem to at least soothe the rpmalloc assert, though I'm not sure if it's solving the issue or just hiding it. I have no idea how it works. I'm not suggesting this as a fix, but I do hope it provides a little more information on what's going on. |
@PauseForAffliction This seems like a valid fix. I would have used Can you please submit a pull request? |
@JohannesLorenz Gotcha, submitted. |
Edit: Not related to this issue... https://gist.github.com/zonkmachine/bcd7b134141ad17727ff9602514ca948 My rpmalloc is on:
|
The backtrace says you've got a SIGFPE first, and then got a assertion failure while |
Ah, then it's most likely an underflow since it's the FxMixerView::updateFaders(). I've seen a whole lot of those. Thanks! |
…MMS#5733) Hack to take care of the assertion sent by the rpmalloc memory manager. Creates a static "free" function for NotePlayHandleManager and then shoves it right before the program ends. Co-authored-by: Pause for Affliction <[email protected]>
…MMS#5733) Hack to take care of the assertion sent by the rpmalloc memory manager. Creates a static "free" function for NotePlayHandleManager and then shoves it right before the program ends. Co-authored-by: Pause for Affliction <[email protected]>
Bug Summary
On exiting LMMS, LMMS crashes with the following terminal output (see Logs for the backtrace):
Caused by rpmalloc update in c58c781. Might be not our fault.
Steps to reproduce
Compile current master. Start LMMS. Close LMMS (File->Quit).
Expected behavior
No crash.
Actual behavior
Crash.
Affected LMMS versions
Master is affected since c58c781.
stable-1.2 is not affected.
Logs
Click to expand
The text was updated successfully, but these errors were encountered: