3 ms·
> I often wonder if it wouldn't be possible to compile MAME's source into some HDL and burn drivers into programmable hardware on demand. Like MiSTer FPGA? It
by musicale 4y ago
> I often wonder if it wouldn't be possible to compile MAME's source into some HDL and burn drivers into programmable hardware on demand.
Like MiSTer FPGA? It seems to provide FPGA implementations for a number of vintage microcomputer and game systems:
https://mister-devel.github.io/MkDocs_MiSTer/ https://mister-devel.github.io/MkDocs_MiSTer/
- rbanffy 4y agoKind of yes, but the MAME code is very structured with lots of macros and looks extremely declarative. Once you have HDL versions of the most common components (such as CPUs, CRTCs, memory, etc) most of the code is declaring how these are connected, what RAM and ROM goes where. To translate that kind of code to an HDL wouldn't be impossible.
- musicale 4y agoUsing an actual HDL implementation to begin with has been shown to be a very effective approach, and that's basically what MiSTer FPGA has done with great success. However, MAME probably supports more emulated platforms/systems (and some MiSTer platforms may not be supported by MAME.) That being said, what I think you might be suggesting is that the declarative structural and signaling specification (and possibly data types, etc.) could be shared between software emulators like MAME and FPGA emulators like MiSTer FPGA. I like the way Migen (for example) acts as an integration platform for multiple hardware models and makes it easier to specify a system from existing components.