[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [MiNT] Re[2]: Re[2]: 68030 MMU crash course?
> Selon "George (HOL, IMAP)" <ggn@hol.gr>:
[...]
> That one is _very_ tricky to do with the 68 030 MMU.
I did it long ago! :) The name is STeADIER.
If you can read French, see
<http://removers.online.fr/spip/article.php?id_article=88> and
<http://removers.online.fr/spip/article.php?id_article=42>, or
http://www.yaronet.com/posts.php?s=82395 for current development.
(history summed up: I hacked it, it went to hibernation, I lost the
sources, I dissassembled and commented it with a friend --this message
BCCed to him-- which has now taken over development)
Direct download of the last (binary) version:
<http://removers.online.fr/spip/IMG/zip/stdi03b1.zip>
Its only advantage over other ST(e) "emulators" (there are still many
limitations compared to Backwards, in particular it is not configurable)
is that *it can use ST and MSA disk images*!!! but be warned it cannot yet
"boot" from them sadly...
> The minimal page size does not allow to map $xxFF8804 to $xxFF8800 for
> example, so you have to set the whole page as not readable nor writable.
> This way a bus error will be generated each time the code tries to access
Yeah, that's was Backward's "correct" mode (IIRC) and STeADIER do.
> the PSG (Or you may perhaps as well use those infamous limit fields...)
If you think of the translation registers (TTx), forget about them: they
can only cover an area which size is a 16MB multiple: a bit too coarse a
range!
Anyway the smallest page size is 512 bytes IIRC, so you must use [$8800.w,
$8a00.w[ for YM!
> Then, in the bus error handler, you have to decode the operation which
> caused the error, emulate the access and resume to next instruction.
>
> Of course this is _very_ slow. An original Falcon may have trouble running
> an ST Software at its original speed with such a trick if there are many
> access to the PSG (as you already know from Backward documentation).
If anyone are interested this is documented in the "Magi" article from the
French "ST-Magazine".
> Please also note 68 040 and 68 060 do not support emulation of access.
> This approach won't work on those processors... Or at least will need
> more tricks to pass this limitation.
Could you elaborate on that? Then how would you implement virtual memory:
you must call code on R/W accesses to illegal areas, mustn't you?
> Have fun with the MMU ! Best regards,
Same motto: MMU is vastly unused but much fun! :)
Cheers,
Guillaume
P.S. : Someone, make 68030 and 68040/060 mmap() for MiNT and SingleTOS!
Now I am on-topic again! ;)