[hatari-devel] Blitter interrupt CPU usage (was: Timer-D CPU usage in latest Hatari)

Eero Tamminen eerot at users.berlios.de
Sun Jul 19 12:06:49 CEST 2009


Hi,

On Sunday 12 July 2009, Eero Tamminen wrote:
> [1]: Using the "Patch Timer-D" option nearly halves the Clown screen CPU
> usage to ~29% and nearly reduces the "colorshock" screen CPU usage to
> 1/3 (to ~28%).  SureTrip goes to 5-20%.  This is because without this
> optimization in these cases by far most of the time is spent in handling
> the MFP Timer-D interrupts. According to Valgrind/Callgrind/Kcachegrind
> 1/2 CPU goes to MFP Timer-D, 1/3 to sound handling (mainly SDL_mixer
> thread + ALSA), 1/6 to m68k emulation and Spec512 conversion/palette
> routines etc.

Actually, although handling of Timer-D interrupts is a common issue, it's
not the only interrupt that can cause huge CPU usage.  I noticed that in
the STE mode, the Blitter emulation can cause Hatari to take 76% of CPU on
my  machine when running the "Tribute to Rainbow TOS"  demo from
http://atari.freemind-tobe.com/.

This is with sound & zooming disabled and Timer-D already patched out.

2/3 of the Hatari CPU usage goes to Blitter interrupt handling (see the
attached picture) and large part of the remaining 1/3 CPU usage goes to
Spec512 handling.


Btw. Would there be any chance of / would it make any sense to have
an option for a "dummy" STE Blitter similarly to DSP?  (As I don't see how
we could optimize the interrupt handling more than by couple of % while
making the code less readable without somehow minimizing the number
of interrupts that need to be handled)


	- Eero
-------------- next part --------------
A non-text attachment was scrubbed...
Name: blitter-interrupts.png
Type: image/png
Size: 28404 bytes
Desc: not available
URL: <https://lists.berlios.de/pipermail/hatari-devel/attachments/20090719/74e96f88/attachment.png>


More information about the hatari-devel mailing list