24 June 2016, 18:53 | #1 |
Registered User
Join Date: Aug 2004
Location:
Posts: 3,335
|
Reducing CPU usage when emulation window is inactive
A couple of suggestions for features which could allow WinUAE's CPU usage (but not the emulated machine speed) to be reduced when the window is inactive:
|
24 June 2016, 21:26 | #2 |
son of 68k
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,323
|
I second that.
In addition it would be good to detect whether the screen has changed or not, to prevent unneeded refreshing (i heard some mac emu on the amiga does this with the mmu). Seeing permanent 25% cpu use while the Amiga is totally idle isn't exactly sexy. |
24 June 2016, 21:54 | #3 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,505
|
It isn't that simple. When it is finally known that display has changed, about 2/3 of the display emulation is already done.. Final bit (planer to chunky, sprite merging and conversion to host color depth) is very simple part.
Don't ever try to compare Amiga with some basic system that does not have anything like a copper or hardware sprites. EDIT: RTG modes already use host MMU write detection trick. It can only work with RTG modes because they are 100% predictable, no copper tricks and splits. Last edited by Toni Wilen; 24 June 2016 at 22:06. |
24 June 2016, 22:15 | #4 |
Registered User
Join Date: Aug 2004
Location:
Posts: 3,335
|
A small addition: the ability to specify a very large frame skip value for when the window is inactive could be useful. E.g. user is installing Linux or NetBSD which takes a while, they might choose to only have the display refreshed once per second, which would be good enough to see when user input is needed.
|
24 June 2016, 22:18 | #5 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,505
|
Does it really make any noticeably difference? Static non-copper trick screen should be detected as nothing much changing and frame skip can't skip early parts of display emulation anyway because it would only break compatibility too bady.
|
24 June 2016, 22:32 | #6 |
Registered User
Join Date: Aug 2004
Location:
Posts: 3,335
|
Testing with a config which uses fastest possible CPU, JIT, CPU idle set to max (my usual config which I use with Workbench). Screenmode is HighGFX 1024×768. Workbench loaded, emulated system idle. On Linux/Wine, the WinUAE CPU% indicator reads 29%-33% at frame skip 0, 23-26% at frame skip 9.
Maybe some demo with lots of copper effects could show a larger difference? An A500-like config with cycle-exact unchecked, running CELTIC-MultiscrollerScroller demo. 27%-30% frame skip 9 43%-52% frame skip 0 (with my laptop's CPU locked to 800MHz) Large frameskip could be useful if user has demo running, listening to the music, but the demo waits for a mouseclick at the end of each part. |
24 June 2016, 23:16 | #7 |
son of 68k
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,323
|
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Strange CPU usage under Wine | mark_k | support.WinUAE | 0 | 05 December 2013 13:24 |
Is this Normal cpu usage? | exoticaga | support.WinUAE | 6 | 18 February 2008 09:22 |
Heavy cpu usage - again | abelthorne | support.WinUAE | 5 | 03 March 2004 11:32 |
WinUAE high CPU usage | DeCreator | support.WinUAE | 2 | 17 July 2003 02:12 |
WinUAE CPU usage at 100% argh | wakeupbomb | support.WinUAE | 4 | 23 January 2003 09:27 |
|
|