[7a1274a] Hideous Destructor crash on startup

Bugs that have been investigated and resolved somehow.

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.
User avatar
Matt
Posts: 9696
Joined: Sun Jan 04, 2004 5:37 pm
Preferred Pronouns: They/Them
Operating System Version (Optional): Debian Bullseye
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Contact:

[7a1274a] Hideous Destructor crash on startup

Post by Matt »

To replicate:
this version of HD

Code: Select all

gzdoom -file [path to HD] -nomusic -noautoload +map range
It seems to be completely random, with long streaks (maybe 5-10 in a row?) of crashes and similar streaks of non-crashes.

3.1.0 does not do this at all.

Compiled GZDoom as "Debug".
User avatar
Matt
Posts: 9696
Joined: Sun Jan 04, 2004 5:37 pm
Preferred Pronouns: They/Them
Operating System Version (Optional): Debian Bullseye
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Contact:

Re: [7a1274a] Hideous Destructor crash on startup

Post by Matt »

I can get neither of the following to crash:

Code: Select all

gzdoom -file [path to HD] -nomusic -noautoload +map range +set playerclass "enforcer"
gzdoom -file [path to HD] -nomusic -noautoload +map range +set playerclass "marksman"
which respectively have the player start with the shotgun and the marksman rifle. Of these two only the latter uses the cameratexture scope.

"specialist" giving the plasma rifle ends up crashing on exit.

Commenting out the rifle zoomed crosshair code does not affect the crash, so it's not some weird thing I'm doing only with the ZM scope and not the Boss scope.
User avatar
Matt
Posts: 9696
Joined: Sun Jan 04, 2004 5:37 pm
Preferred Pronouns: They/Them
Operating System Version (Optional): Debian Bullseye
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Contact:

Re: [7a1274a] Hideous Destructor crash on startup

Post by Matt »

Vaecrius wrote:Compiled GZDoom as "Debug".
This crash no longer happens if I compile as Release rather than Debug, but another crash happens that is even more totally random.

To replicate this other crash:

spawn as medic
IDCLEV01 (have not been able to replicate this crash without this)
IDDQD
switch to chainsaw
start killing everything with chainsaw (and maybe sprint and jump around a lot)
if you clear the entire brown room and courtyard, you probably didn't get the crash, though you might exit with a crash or something like:

Code: Select all

*** Error in `/home/mchan223/doom/./gzdoom': free(): invalid next size (normal): 0x0000000003e8e090 ***
/home/mchan223/bin/gzdoom: line 2: 20818 Aborted                 ~/doom/./gzdoom $*
This crash does not necessarily happen while the chainsaw is out, though I have gotten it both while sprinting (in which case the chainsaw isn't even the player's readyweapon) and while sawing something. The crash seems to just happen whenever within that general context of chainsaw + imps + IDCLEV01 + brown room.

This other crash does also happen in 3.1.0.
_mental_
 
 
Posts: 3812
Joined: Sun Aug 07, 2011 4:32 am

Re: [7a1274a] Hideous Destructor crash on startup

Post by _mental_ »

In attempt to reproduce startup crash I launched GZDoom at least twenty times with particular player classes and with random one. It never crashed for me.

If you can reproduce it more or less regularly please run the game under GDB and when it will crash check values of f->Func->PrintableName and call->PrintableName variables:

Code: Select all

p f->Func->PrintableName
p call->PrintableName
I assume crash location will be in VMExec_Checked::Exec() function at line 697.
User avatar
Matt
Posts: 9696
Joined: Sun Jan 04, 2004 5:37 pm
Preferred Pronouns: They/Them
Operating System Version (Optional): Debian Bullseye
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Contact:

Re: [7a1274a] Hideous Destructor crash on startup

Post by Matt »

...how do I run GZDoom under GDB? The GDB manual is startlingly unhelpful on this point.

(as for # of tries, with rifleman I can usually get this startup crash in well under 10, but only if I compile as debug not release)
_mental_
 
 
Posts: 3812
Joined: Sun Aug 07, 2011 4:32 am

Re: [7a1274a] Hideous Destructor crash on startup

Post by _mental_ »

Run the following command in Terminal:

Code: Select all

gdb --args ./gzdoom -iwad doom2 -file hd <add any other command line options>
When it will load execute run command (or simply press r and Enter).
User avatar
Matt
Posts: 9696
Joined: Sun Jan 04, 2004 5:37 pm
Preferred Pronouns: They/Them
Operating System Version (Optional): Debian Bullseye
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Contact:

Re: [7a1274a] Hideous Destructor crash on startup

Post by Matt »

Got it.

When it's not crashing it seems to load fine, but where I'd normally get that momentary hiccup before the crash it just freezes indefinitely instead, with a window up and nothing drawn on it, and responds to nothing but the kill command, after which I see this:

Code: Select all

...
[New Thread 0x7fffd3fff700 (LWP 31600)]
[Thread 0x7fffd3fff700 (LWP 31600) exited]
[New Thread 0x7fffd3fff700 (LWP 31603)]
[Thread 0x7fffd3fff700 (LWP 31603) exited]
Resolution: 1280 x 720
10 bots read from bots.cfg


map01 - entryway

[New Thread 0x7fffd3fff700 (LWP 31604)]
[Thread 0x7fffd3fff700 (LWP 31604) exited]
[New Thread 0x7fffd3fff700 (LWP 31605)]
[Thread 0x7fffd3fff700 (LWP 31605) exited]
[New Thread 0x7fffd3fff700 (LWP 31606)]
[Thread 0x7fffd3fff700 (LWP 31606) exited]

Program received signal SIGSEGV, Segmentation fault.
0x0000000000f9205e in VMExec_Checked::Exec (stack=0x7ffff7fbe728, 
    pc=0x589c888, ret=0x7fffffffc760, numret=0)
    at /home/mchan223/doom/gzdoom-7a1274ab768e2883da4ff988fc1f75604a6756c6/src/scripting/vm/vmexec.h:697
697				if (call->VarFlags & VARF_Native)
Then (and I have no idea if I did this right)

Code: Select all

(gdb) p f->Func->PrintableName
Cannot access memory at address 0x2b415f8
(gdb) p call->PrintableName
Cannot access memory at address 0x7fffffffbd88


EDIT: Tried looking at the console before killing:

Code: Select all

[New Thread 0x7fffd3fff700 (LWP 5258)]
[Thread 0x7fffd3fff700 (LWP 5258) exited]
Resolution: 1280 x 720
10 bots read from bots.cfg


map01 - entryway

[New Thread 0x7fffd3fff700 (LWP 5261)]
[Thread 0x7fffd3fff700 (LWP 5261) exited]
[New Thread 0x7fffd3fff700 (LWP 5262)]
[Thread 0x7fffd3fff700 (LWP 5262) exited]
[New Thread 0x7fffd3fff700 (LWP 5263)]
[Thread 0x7fffd3fff700 (LWP 5263) exited]

Program received signal SIGSEGV, Segmentation fault.
FName::operator== (this=0x103279988, other=...)
    at /home/mchan223/doom/gzdoom-7a1274ab768e2883da4ff988fc1f75604a6756c6/src/./name.h:75
75		bool operator == (const FName &other) const { return Index == other.Index; }
(gdb) p f->Func->PrintableName
No symbol "f" in current context.
(gdb) p call->PrintableName
No symbol "call" in current context.
User avatar
Matt
Posts: 9696
Joined: Sun Jan 04, 2004 5:37 pm
Preferred Pronouns: They/Them
Operating System Version (Optional): Debian Bullseye
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Contact:

Re: [7a1274a] Hideous Destructor crash on startup

Post by Matt »

For the much less predictable chainsaw crash (which took me like 10 tries to even get once in GDB and I haven't managed to get it since all this morning):

Code: Select all

[Thread 0x7fffd3fff700 (LWP 6298) exited]
[New Thread 0x7fffd3fff700 (LWP 6301)]
[Thread 0x7fffd3fff700 (LWP 6301) exited]

Program received signal SIGSEGV, Segmentation fault.
0x0000000000835ae8 in GC::Mark(DObject**) ()
I couldn't see my cursor at this time and decided not to risk being forced to reboot, so no attempt to call those p commands yet.
_mental_
 
 
Posts: 3812
Joined: Sun Aug 07, 2011 4:32 am

Re: [7a1274a] Hideous Destructor crash on startup

Post by _mental_ »

Print commands won't help with any other case except the very first one. Crash after killing isn't quite interesting but freeze before it is.
Try to reproduce it again and when it hangs on black screen switch to GDB and press Ctrl+C there. Execute thread 1 and bt commands and post the output.

EDIT: What is the compiler you are using? And its version please.
Edward-san
Posts: 1774
Joined: Sat Oct 17, 2009 9:40 am

Re: [7a1274a] Hideous Destructor crash on startup

Post by Edward-san »

Vaecrius wrote:I couldn't see my cursor at this time and decided not to risk being forced to reboot, so no attempt to call those p commands yet.
Try to disable completely the mouse in the menu. You should be able to see the cursor when you get a crash.
User avatar
Matt
Posts: 9696
Joined: Sun Jan 04, 2004 5:37 pm
Preferred Pronouns: They/Them
Operating System Version (Optional): Debian Bullseye
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Contact:

Re: [7a1274a] Hideous Destructor crash on startup

Post by Matt »

_mental_ wrote:EDIT: What is the compiler you are using? And its version please.
CLANG 3.5.0-10

Also, here's what I'm using to compile:

Code: Select all

cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ ..;make -j 4
_mental_ wrote:Try to reproduce it again and when it hangs on black screen switch to GDB and press Ctrl+C there. Execute thread 1 and bt commands and post the output
Spoiler:
Last edited by Matt on Fri Sep 08, 2017 12:00 am, edited 3 times in total.
User avatar
Matt
Posts: 9696
Joined: Sun Jan 04, 2004 5:37 pm
Preferred Pronouns: They/Them
Operating System Version (Optional): Debian Bullseye
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Contact:

Re: [7a1274a] Hideous Destructor crash on startup

Post by Matt »

And, for what it's worth, the chainsaw imp crash (which was very easy to replicate when, for other reasons, I had the chainsaw altfire spawn imps to test how +friendly and master relationships worked in deathmatch):
Spoiler:
EDIT: For this one (which I'll call the "chainsaw crash" to distinguish it from the one in the OP) I can replace the imp in that summon with a vanilla Doom imp or demon and the crash still happens. It seems to happen much more frequently if I run GZDoom after making a change, then it crashes many times in a row before after a while I get a very long streak in which the crash doesn't happen at all.

...is this a sign that my RAM is dying?
_mental_
 
 
Posts: 3812
Joined: Sun Aug 07, 2011 4:32 am

Re: [7a1274a] Hideous Destructor crash on startup

Post by _mental_ »

Vaecrius wrote:...is this a sign that my RAM is dying?
Not necessarily, despite my inability to reproduce the crashes with the same compiler most likely it's a software bug.
With faulty RAM you will have various fairly random issues with any software including OS itself.
User avatar
Matt
Posts: 9696
Joined: Sun Jan 04, 2004 5:37 pm
Preferred Pronouns: They/Them
Operating System Version (Optional): Debian Bullseye
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Contact:

Re: [7a1274a] Hideous Destructor crash on startup

Post by Matt »

Everything else works without a hitch, so yes definitely software.

But I've just gone through the packages and none of the dependencies appear to be corrupt or downloaded from some sketchy source or anything...
User avatar
Matt
Posts: 9696
Joined: Sun Jan 04, 2004 5:37 pm
Preferred Pronouns: They/Them
Operating System Version (Optional): Debian Bullseye
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Contact:

Re: [7a1274a] Hideous Destructor crash on startup

Post by Matt »

I strongly suspect this and my other problem are one and the same. Requesting that this be closed as a duplicate.
Post Reply

Return to “Closed Bugs [GZDoom]”