Crash when switching renderers
Moderator: GZDoom Developers
Forum rules
Please don't bump threads here if you have a problem - it will often be forgotten about if you do. Instead, make a new thread here.
Please don't bump threads here if you have a problem - it will often be forgotten about if you do. Instead, make a new thread here.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49056
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Crash when switching renderers
It now happened multiple times to me that when I switched from software to hardware I got a crash in MemcpyCommand::Execute.
Apparently some worker thread is left hanging, even after the software renderer has been taken down.
Apparently some worker thread is left hanging, even after the software renderer has been taken down.
Re: Crash when switching renderers
I'm not able to reproduce this on master. Is this on some branch?
If the source of the problem is what you're describing, then the call stack of the main thread should be past the DrawerThreads::WaitForWorkers function when it crashes.
If the source of the problem is what you're describing, then the call stack of the main thread should be past the DrawerThreads::WaitForWorkers function when it crashes.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49056
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Crash when switching renderers
I had it happen once on Master and today 3 times altogether on Texture_Cleanup, but those might be related to broken texture data having trashed some memory.
But the one time on Master was totally out of the blue.
But the one time on Master was totally out of the blue.
Re: Crash when switching renderers
I've had this happen to me before. The crash was so random, and I have experience with random crashes enough that I really didn't want to try and track down the exact cause of the issue to make a report.
Re: Crash when switching renderers
I need a call stack from the main thread next time someone experiences it. It could also be crashing due to it going out of bounds somehow, which overall is more likely as the variables controlling the worker threads are guarded by std::mutex and std::condition_variable.
- drfrag
- Vintage GZDoom Developer
- Posts: 3141
- Joined: Fri Apr 23, 2004 3:51 am
- Location: Spain
- Contact:
Re: Crash when switching renderers
Has happened to me several times with the legacy build and MinGW debug builds.
Unrelated but vid_rendermode can take weird values which causes funny effects when looking up and down.
Pushed a fix here:
https://github.com/drfrag666/gzdoom/com ... a2b7d37956
Unrelated but vid_rendermode can take weird values which causes funny effects when looking up and down.
Pushed a fix here:
https://github.com/drfrag666/gzdoom/com ... a2b7d37956
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49056
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Crash when switching renderers
Can you please make a PR from that commit? It's not that easy to cherry pick it out of another repository.
Re: Crash when switching renderers
Code: Select all
git fetch https://github.com/drfrag/gzdoom legacy
git cherry-pick 3993aca50808d3e9156764a02d9c3ca2b7d37956
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49056
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Crash when switching renderers
The problem is the fetch, it'd pollute the local data with everything from that other repo which I do not want in my local copy, especially if it's just go get access to a single commit.
- drfrag
- Vintage GZDoom Developer
- Posts: 3141
- Joined: Fri Apr 23, 2004 3:51 am
- Location: Spain
- Contact:
Re: Crash when switching renderers
Thanks.Rachael wrote:Cherry-picked
With the command line that Rachael posted one should be able to fetch only one branch and there are other methods explained at Stack Overflow but i don't know if it's possible with TortoiseGit.
Re: Crash when switching renderers
drfrag wrote:With the command line that Rachael posted one should be able to fetch only one branch and there are other methods explained at Stack Overflow but i don't know if it's possible with TortoiseGit.
Don't ask me. ¯\_(ツ)_/¯Graf Zahl wrote:The problem is the fetch, it'd pollute the local data with everything from that other repo which I do not want in my local copy, especially if it's just go get access to a single commit.
I know what he's saying, but this is why you consolidate repositories if you're really worried about such things. Git is designed from the ground up to handle multiple workflows like this seamlessly. Unless your disk space is really really tight, this shouldn't even be a problem, and eventually Git cleans it up anyway.