http://bugs.winehq.org/show_bug.cgi?id=23522
Summary: Planescape Torment crashes when resting. Product: Wine Version: unspecified Platform: x86 OS/Version: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: -unknown AssignedTo: wine-bugs@winehq.org ReportedBy: i30817@gmail.com
I have not found the cause myself, but this thread http://www.shsforums.net/topic/44714-resting-causing-freezecrash/
seems to indicate that the cause is generated code by recent gcc.
I have no idea the primary cause, so i thought to punt it to the pros, so you could find it and report to gcc and/or workaround the bug.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #1 from Dmitry Timoshkov dmitry@codeweavers.com 2010-07-05 04:31:43 --- Wine version? Please attach full terminal output including a backtrace.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #2 from Dmitry Timoshkov dmitry@codeweavers.com 2010-07-05 04:35:45 --- Probably duplicate of the bug 22316.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #3 from paulo i30817@gmail.com 2010-07-05 12:27:13 --- Ummm, it's likely that the gcc devs don't think it's their problem since they closed it.
What kind of output command do you want?
wine Torment.exe 2> output.txt
just spams:
And actually the game doesn't crash. Seems like a infinite cycle or deadlock after the movie.
fixme:win:EnumDisplayDevicesW ((null),0,0x32a598,0x00000000), stub! fixme:mixer:ALSA_MixerInit No master control found on HDA ATI HDMI, disabling mixer err:gdi:alloc_gdi_handle out of GDI object handles, expect a crash err:gdi:alloc_gdi_handle out of GDI object handles, expect a crash err:gdi:alloc_gdi_handle out of GDI object handles, expect a crash err:d3d_surface:IWineD3DBaseSurfaceImpl_CreateDIBSection CreateDIBSection failed! err:gdi:alloc_gdi_handle out of GDI object handles, expect a crash err:d3d_surface:IWineD3DBaseSurfaceImpl_CreateDIBSection CreateDIBSection failed! ..... And eventually only err:gdi:alloc_gdi_handle out of GDI object handles, expect a crash err:gdi:alloc_gdi_handle out of GDI object handles, expect a crash ... (forever)
If you'd post the useful WINEDEBUG config and the correct redirect i can post a more complete file.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #4 from paulo i30817@gmail.com 2010-07-05 12:29:55 --- I'm using the wine repository wine. As for the Torment version, it is patched with the official, unoficial and resolution tweaks, just like here: http://thunderpeel2001.blogspot.com/2009/01/planescape-torment-fully-modded....
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #5 from paulo i30817@gmail.com 2010-07-05 12:31:47 --- wine-1.2-rc6 Sorry thought you were talking about gcc compiled version duh.
http://bugs.winehq.org/show_bug.cgi?id=23522
Dmitry Timoshkov dmitry@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Version|unspecified |1.2-rc6
--- Comment #6 from Dmitry Timoshkov dmitry@codeweavers.com 2010-07-06 00:54:07 --- Did you compile Wine on your own? If yes, with which gcc version?
Attach (DO NOT PASTE) full terminal output according to http://wiki.winehq.org/FAQ#get_log
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #7 from paulo i30817@gmail.com 2010-07-06 10:23:59 --- Created an attachment (id=29402) --> (http://bugs.winehq.org/attachment.cgi?id=29402) log with wine Torment.exe &> output.txt
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #8 from paulo i30817@gmail.com 2010-07-06 10:25:57 --- Attached. I didn't compile wine, i got it from the wine ubuntu repository.
Also you will see that the log isn't very informative, that is why i asked about WINEDEBUG settings.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #9 from paulo i30817@gmail.com 2010-07-06 11:50:56 --- BTW i had to CTRL-C the process. As i said it hangs after playing the movie that plays after resting ingame.
http://bugs.winehq.org/show_bug.cgi?id=23522
Konstantin s0676011@sms.ed.ac.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |s0676011@sms.ed.ac.uk
--- Comment #10 from Konstantin s0676011@sms.ed.ac.uk 2010-08-25 05:14:17 --- Seems like the bug has something to do with 64 bit distros (did anyone have the same issue on 32 bit installation?). I have Kubuntu 10.04 Lucid, 64 bit and only building 32-bit Wine 1.1.38 with gcc-4.3 (used this guide) fixed the problem for me. Trying to either build later version of Wine (tried 1.2 and 1.3) or use later version of gcc (tried 4.4) or even to make a "normal" (64-bit) install of Wine leads to freezing any time your characters rest.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #11 from Konstantin s0676011@sms.ed.ac.uk 2010-08-26 03:25:45 --- Sorry, forgot to paste the link to the guide I mentioned: http://wiki.winehq.org/WineOn64bit#head-f6a7d1b561fe7ce26bb3a061d96d16380d90...
http://bugs.winehq.org/show_bug.cgi?id=23522
Joanne Smith e06h214@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |e06h214@gmail.com
--- Comment #12 from Joanne Smith e06h214@gmail.com 2010-10-24 06:12:42 CDT --- I can confirm that on Wine 1.3.5 on Ubuntu 10.04 32bit (from Wine PPA) resting causes the game to freeze after the movie is done playing or is interrupted.
Interestingly, this did not happen when only the official patch was applied, only when patched with Qwinn's fix pack.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #13 from paulo i30817@gmail.com 2010-12-29 04:32:13 CST --- Can someone compile wine with gcc 4.5.X with the new "-mstackrealign" argument and see if this continues?
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #14 from paulo i30817@gmail.com 2010-12-29 04:33:16 CST --- Also, someone with rights to do so should mark it confirmed, per comment 12
http://bugs.winehq.org/show_bug.cgi?id=23522
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever Confirmed|0 |1
--- Comment #15 from Austin English austinenglish@gmail.com 2010-12-29 19:38:11 CST --- Confirming.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #16 from paulo i30817@gmail.com 2011-01-31 19:31:33 CST --- Err, i was trying to use gcc 4.5 to verify if the root cause of the problem is the expected one. I did: CC=gcc-4.5 ./configure -m32 on my git dir And it told me: "checking whether gcc-4.5 -m32 works... no configure: error: Cannot build a 32-bit program, you need to install 32-bit development libraries."
Though i do have them otherwise i couldn't compile under gcc 4.4 as i did just yesterday (since i use a 64 bit machine)
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #17 from paulo i30817@gmail.com 2011-01-31 23:51:03 CST --- Ugh never mind. Had a outdated repository (using maverick when i'm on natty) so was missing a dependency.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #18 from paulo i30817@gmail.com 2011-02-01 00:29:46 CST --- Compiled and tested. Indeed, compiling wine with -mstackrealign fixes this bug.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #19 from paulo i30817@gmail.com 2011-02-01 00:57:22 CST --- Halt there! I just compiled with gcc 4.5 and without the option (make clean between of course). It still worked (the repositories wine crashes).
So now i'm self compiling with gcc 4.4 to see if compiling without optimizations makes a difference to the repository wine. If it doesn't, just the new gcc 4.5 (and when wine repos start using it) will be enough to fix this (and the problem should be another weird ASM thing than the SSE alignment bug)
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #20 from paulo i30817@gmail.com 2011-02-01 01:02:52 CST --- It still works with gcc 4.4 compiled wine :/
but it doesn't with the repositories wine.
Time to bust out the optimizations to try to reproduce i guess.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #21 from paulo i30817@gmail.com 2011-02-01 01:09:08 CST --- What are the compile flags of the wine ubuntu repository?
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #22 from paulo i30817@gmail.com 2011-02-01 01:11:22 CST --- and what version of gcc is used?
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #23 from paulo i30817@gmail.com 2011-02-01 10:02:46 CST --- Ok, resuming: CC="gcc-4.4 -m32" LDFLFLAGS="-L./lib32" CFLAGS="-g -O0" ./configure --verbose --disable-tests && make depend -j 3 && make -j 3
(works)
make clean
CC="gcc-4.5 -m32" LDFLFLAGS="-L./lib32" CFLAGS="-g -O0" ./configure --verbose --disable-tests && make depend -j 3 && make -j 3
(works)
make clean
CC="gcc-4.5 -m32" LDFLFLAGS="-L./lib32" CFLAGS="-g -mstackrealign -O0" ./configure --verbose --disable-tests && make depend -j 3 && make -j 3
(works)
make clean
CC="gcc-4.4 -m32" LDFLFLAGS="-L./lib32" CFLAGS="-g -O3" ./configure --verbose --disable-tests && make depend -j 3 && make -j 3
(crashes)
make clean
CC="gcc-4.5 -m32" LDFLFLAGS="-L./lib32" CFLAGS="-g -O3" ./configure --verbose --disable-tests && make depend -j 3 && make -j 3
(crashes)
make clean
CC="gcc-4.5 -m32" LDFLFLAGS="-L./lib32" CFLAGS="-g -mstackrealign -O3" ./configure --verbose --disable-tests && make depend -j 3 && make -j 3
(crashes)
So the new mstackrealign option doesn't solve it and it is a bug associated to the optimization level. How can i pin point it?
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #24 from paulo i30817@gmail.com 2011-02-03 00:00:01 CST --- Don't forget that to even run this game, you must (or at least, I had to) use "Emulation" and "Use a virtual desktop" on winecfg.
I meanwhile tested a O2 compile, still crashed, so either O1 works and it's a O2 optimization, or O1 fails and it is a O1 optimization.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #25 from paulo i30817@gmail.com 2011-02-03 00:19:27 CST --- O1 works, it happens on a O2 optimization.
http://bugs.winehq.org/show_bug.cgi?id=23522
Nils Larsson nisselarsson@home.se changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |nisselarsson@home.se
--- Comment #26 from Nils Larsson nisselarsson@home.se 2011-03-17 08:01:45 CDT --- I'm seeing this in 1.3.15 compiled with -march=atom -O0 -ggdb using gcc-4.5.2. Also this is with the GOG version of PST.
http://bugs.winehq.org/show_bug.cgi?id=23522
maluco q3tr1gger@googlemail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |q3tr1gger@googlemail.com
--- Comment #27 from maluco q3tr1gger@googlemail.com 2011-06-20 01:37:09 CDT --- (In reply to comment #25)
O1 works, it happens on a O2 optimization.
paulo, could you please give a quick workaround what to do exactly for running pst under wine without crashing while resting?
a quick workaround for less-experienced users (like me) would help me.
thanks
http://bugs.winehq.org/show_bug.cgi?id=23522
Wouter De Borger w.deborger@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |w.deborger@gmail.com
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #28 from paulo i30817@gmail.com 2011-06-30 08:59:16 CDT --- It has been narrowed down to a ASM hack part of the fixpack that crashes in wine but not on windows:
On [game folder]/pst-fix/tph/enginefixes.tph Comment (/* ... */) the 4g patch
LAUNCH_PATCH_MACRO Q_Pattern_Maker LAUNCH_PATCH_MACRO Q_Engine_Patcher
to
/* LAUNCH_PATCH_MACRO Q_Pattern_Maker LAUNCH_PATCH_MACRO Q_Engine_Patcher */
This patch fixed a original bug that reset morale of companions on rest so you won't be able to see certain parts in the game (when their morale gets really low or high).
*shrug*
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #29 from paulo i30817@gmail.com 2011-06-30 09:04:32 CDT --- Comment above is slightly misleading, find the 4g part and comment the part that follows with those engine macros don't just find replace all those strings or just the first. The macro is used more than once and you only want to comment the 4g part.
http://bugs.winehq.org/show_bug.cgi?id=23522
Alex Bradbury asb@asbradbury.org changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |asb@asbradbury.org
--- Comment #30 from Alex Bradbury asb@asbradbury.org 2011-06-30 09:58:59 CDT --- (In reply to comment #28)
It has been narrowed down to a ASM hack part of the fixpack that crashes in wine but not on windows
Is this your analysis or do you have a link to where this analysis was done? Was it on a PS:Torment forum?
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #31 from maluco q3tr1gger@googlemail.com 2011-06-30 10:02:35 CDT --- see here: http://www.shsforums.net/topic/47064-qwinn-is-retire/page__view__findpost__p...
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #32 from paulo i30817@gmail.com 2011-07-15 01:34:01 CDT --- Ok the cause has been found (a stack mishandling corrupted the ESP register) and the fixpack will be corrected eventually in the next minor version (i'd expect soon).
So as it is a fixpack bug and unless you want to figure out why it is crashing with wine but not with windows, or why wine compiled with O2 crashes but not O1, i'd guess this can be closed.
http://bugs.winehq.org/show_bug.cgi?id=23522
Xavier Vachon xvachon@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |xvachon@gmail.com
--- Comment #33 from Xavier Vachon xvachon@gmail.com 2012-02-01 19:43:37 CST --- Are we clear about the fact that this bug is not related to Wine? If so, it should be marked as invalid.
http://bugs.winehq.org/show_bug.cgi?id=23522
--- Comment #34 from paulo i30817@gmail.com 2012-02-06 01:27:14 CST --- It's pretty strange that it crashed in wine but not on windows i guess. And it's a bit important that people are able to see it while a "official" new version of the fixpack doesn't come out. But i suppose that a comment on the description linking to the instructions to edit the relevant file would work as well. If you do close it, i just ask you to do that.
http://bugs.winehq.org/show_bug.cgi?id=23522
David Nuñez auledoom@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |auledoom@gmail.com
--- Comment #35 from David Nuñez auledoom@gmail.com 2012-09-25 16:30:27 CDT --- Months ago I have the same problem, it seems related to the "PS:T Ultimate WeiDU Fixpack mod" incompatibility with wine, but recently i installed a new version (4.13) that deals with the problem as stated on the mod's summary: ... VERSION 4.12: This is a minor release to fix a bug with an existing morale engine patch related to NPC's and party resting. This includes some general clean up of affected function that prevents a crash when playing game under Wine. Also added updated Russian translation. ... here's the link: http://www.shsforums.net/files/file/647-pst-ultimate-weidu-fixpack-v413/
I made a new clean install of the game on a Kubuntu 12.04 64bit pc, and installed the followed mods: WideScreen Mod, GhostDog's PS:T UI mod, PS:T Ultimate WeiDU Fixpack, PS:T Unfinished Business, Qwinn's PS:T Tweak Pack
Now the game runs fine, no problems of any kind, i was able to play the game this last weekend and "rest" on different places without issues. :)
Please test this, it seems this bug should be closed
http://bugs.winehq.org/show_bug.cgi?id=23522
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED CC| |focht@gmx.net Resolution| |INVALID
--- Comment #36 from Anastasius Focht focht@gmx.net 2013-10-04 09:47:51 CDT --- Hello folks,
marking this bug invalid as per last comments (app bug exposed by Wine, got corrected in app).
Regards
http://bugs.winehq.org/show_bug.cgi?id=23522
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #37 from Austin English austinenglish@gmail.com 2013-10-22 04:42:33 CDT --- Closing.