Re: [hatari-devel] Adding cache support for the MegaSTE

[ Thread Index | Date Index | More lists.tuxfamily.org/hatari-devel Archives ]


Le 12/07/2024 à 18:46, Christian Zietz a écrit :
Christian Zietz schrieb:

Please change your program as I suggested in my previous post; and we'll
have the confirmation for my hypothesis.

Or, I have patched your program (see attachment) to read from a
different address that it writes to, to ensure cache misses on the data.
The results are also attached. As you can see, the "write words, read
words" case suffers. The others remain unchanged, because those were
cache misses before, too. (Or the cache was off to begin with.)

The speedup you see with cache on is now entirely caused by the caching
of the code.


thanks for the preliminary results :)

megaSTE cache is not very well documented, I think I read somewhere that cache was only updated on write and not on read, which is why I assumed code would not be in cache. Unfortunately, I can't find where I read this, so ... :(

Anyway, updated version of cache test is now doing more tests to check for filling cache on read and not just on write :

- "16 MHz, cache flush - R words" : this will flush the cache and read from the test region, giving only cache misses on this region. but code should be cached. Compared with "16 MHz no cache" this should show a speedup due only to caching code.

- "16 MHz, cache R words - R words" : similar as above, but read test region a second time, which should give cache hits this time.

Others tests were not changed (write then read)

Nicolas

Attachment: mste_cac.prg
Description: Binary data



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/