[Bug] Show desktop in Windows 10 crashes the emulator

Discussion of development and patch submission.
aybe
Posts: 2
Joined: Fri 27 Mar, 2015 6:38 pm

[Bug] Show desktop in Windows 10 crashes the emulator

Postby aybe » Sun 19 Mar, 2017 11:57 pm

With PCem v12 running under Windows 10, if I click 'Show desktop' icon on bottom-right of the screen, the application will silently crash. :(

When I mean silently is that the window simply disappears, I don't see the usual small window that offers to either debug it or close it.

Let me know if you need more details.

Thanks !

EDIT: this actually happens only when using Direct3D
User avatar
omarsis81
Posts: 532
Joined: Thu 17 Dec, 2015 6:20 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby omarsis81 » Mon 20 Mar, 2017 12:13 am

Well, something similar happens to me in Windows 8.1
I didn't post it before because I don't exactly how to reproduce it, but sometimes I'm working with other applications and when I try to switch back to PCem I noticed it closed all of a sudden with no errors, it just disappears
User avatar
leilei
Posts: 421
Joined: Fri 25 Apr, 2014 4:47 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby leilei » Mon 20 Mar, 2017 1:47 am

This only happens to the Direct3D backend. Doesn't crash on Directdraw. Windows 7 x64

Similarly, locking the screen will crash for Direct3D

Code: Select all

onesec
LockRect failed
PIC1 : MASK B8 PEND 00 INS 00 VECTOR 08
PIC2 : MASK BF PEND 00 INS 00 VECTOR 70



I had a similar bug report earlier where it would've locked windows to it rather than crashing.
rootfather
Posts: 3
Joined: Thu 23 Mar, 2017 4:30 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby rootfather » Sat 01 Apr, 2017 3:58 pm

I can confirm this bug. Using the Direct3D and then switching to the Desktop crashes PCem. I'm running Windows 10 with the latest updates on an Intel Core i5 with HD Graphics 620 and no dedicated graphics hardware.

Using the DirectDraw renderer is no option for me, because it frequently crashes.
UPerschke
Posts: 31
Joined: Wed 25 May, 2016 7:43 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby UPerschke » Sat 01 Apr, 2017 4:34 pm

Same here, dedicated hardware (Core i5/GTX750Ti).
Battler
Posts: 793
Joined: Sun 06 Jul, 2014 7:05 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby Battler » Sat 01 Apr, 2017 4:38 pm

These problems have started since Sarah moved the renderer to its own thread. Evidently the rendering code is not thread-safe enough yet.
szadycbr
Posts: 181
Joined: Mon 21 Nov, 2016 6:23 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby szadycbr » Sat 01 Apr, 2017 9:56 pm

same here on win10 64bit. The change that Sarah made is for greater good, soon it will be thread-proof.
User avatar
gen_angry
Posts: 36
Joined: Sat 25 Feb, 2017 6:48 am

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby gen_angry » Sun 02 Apr, 2017 7:06 am

does it for me, I've just kept it on directdraw (cant tell if any performance penalty)

Win10 x64, GTX 1060
szadycbr
Posts: 181
Joined: Mon 21 Nov, 2016 6:23 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby szadycbr » Sun 02 Apr, 2017 9:40 am

Mr. Gen_angry, honestely i dont understand why people think performance on d3d could be faster?, it is only display inteface , it plays a role as a virtual monitor, it does not use any 3d or other complex instructions it only displays static image. as far as i remember ddraw was always much faster in displaying picture than d3d, simple interface using less resources, and if your emulated cpu runs at 90% and you got (example) 35fps in quake II or 40 in NFSIII then u can use Dshow as a display interface and it won be any faster or any slower. Now graphics cards are pretty fast, but back in the day i will use definetely ddraw cos it was much faster, today i dont think it makes any difference and soon or later ddraw will be obsolete.
User avatar
gen_angry
Posts: 36
Joined: Sat 25 Feb, 2017 6:48 am

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby gen_angry » Sun 02 Apr, 2017 6:00 pm

szadycbr wrote:Mr. Gen_angry, honestely i dont understand why people think performance on d3d could be faster?, it is only display inteface , it plays a role as a virtual monitor, it does not use any 3d or other complex instructions it only displays static image. as far as i remember ddraw was always much faster in displaying picture than d3d, simple interface using less resources, and if your emulated cpu runs at 90% and you got (example) 35fps in quake II or 40 in NFSIII then u can use Dshow as a display interface and it won be any faster or any slower. Now graphics cards are pretty fast, but back in the day i will use definetely ddraw cos it was much faster, today i dont think it makes any difference and soon or later ddraw will be obsolete.


erm, I said I couldn't tell if there was a penalty or not. So performance wise to me, they're pretty equal.
szadycbr
Posts: 181
Joined: Mon 21 Nov, 2016 6:23 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby szadycbr » Sun 02 Apr, 2017 6:12 pm

gen_angry , i know, i m just saying. no offence intended.
SarahWalker
Site Admin
Posts: 1310
Joined: Thu 24 Apr, 2014 4:18 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby SarahWalker » Sun 02 Apr, 2017 8:15 pm

D3D is noticeably faster on some machines (eg mine), DirectDraw is faster on some others, on some systems they're about the same speed. Mainly driver issues I think.
A. Naim
Posts: 75
Joined: Thu 09 Jul, 2015 5:06 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby A. Naim » Sun 02 Apr, 2017 8:54 pm

SarahWalker wrote:D3D is noticeably faster on some machines (eg mine), DirectDraw is faster on some others, on some systems they're about the same speed. Mainly driver issues I think.

My guess would be that later graphics cards emulate DirectDraw using Direct3D.

But that's just a guess.
User avatar
FredPJ
Posts: 31
Joined: Tue 15 Sep, 2015 1:55 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby FredPJ » Sun 02 Apr, 2017 9:25 pm

Actually, this is the same bug that I've reported many times since 2015:

viewtopic.php?f=2&t=289&p=2050#p2050

It is one of the main reasons why I rarely use PCem, I use the Show Desktop button A LOT and DirectDraw mode doesn't look/perform nearly as good.
rootfather
Posts: 3
Joined: Thu 23 Mar, 2017 4:30 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby rootfather » Sun 09 Jul, 2017 8:41 am

Hi Sarah,

may I bring this issue back to your attention? The bug still persists on the current codebase (I'm currently on 3145faba13c5). The DirectDraw renderer still crashes sometimes and is much slower on my system (hardly to reproduce, somewhat random). The Direct3D renderer always crashes when using the "back to desktop" button in the taskbar and somewhat frequently but also somewhat random when leaving the fullscreen using CTRL + ALT + PGDOWN. OS is WIndows 10, Intel HD Graphics 620. Latest updates and drivers.

I noticed that you made some changes to the direct3d/directdraw handling since v12. I have to mention that I don't really understand what you did there, I just can tell that you obviously did something to it.

Thanks in advance!
rootfather
Last edited by rootfather on Sun 09 Jul, 2017 8:59 am, edited 1 time in total.
JosepMa
Posts: 68
Joined: Tue 20 Jun, 2017 6:25 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby JosepMa » Sun 09 Jul, 2017 8:44 am

I didn't realize this was already reported. This is my fix for that: viewtopic.php?f=3&t=760 I really didn't thought that the bug was so old...
rootfather
Posts: 3
Joined: Thu 23 Mar, 2017 4:30 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby rootfather » Sun 09 Jul, 2017 10:45 am

JosepMa, thanks a lot!

I just run a few quick tests, and your fix actually works for me!
basic2004
Posts: 118
Joined: Sun 08 Jan, 2017 5:59 pm

Re: [Bug] Show desktop in Windows 10 crashes the emulator

Postby basic2004 » Sun 09 Jul, 2017 4:27 pm

Thanks to fix!
I often turning my Windows 10 to lockscreen, PCem was crash silently when locking but this fixed after your patch.

[EDIT] PCem freezes only screen instead crashing when lock Windows 10. minimize and restore PCem, screen working back.

Return to “Development”

Who is online

Users browsing this forum: Bing [Bot] and 2 guests