MAMEWorld >> EmuChat
View all threads Index   Threaded Mode Threaded  

Pages: 1

RPOR6V
MAME Fan
Reged: 08/03/12
Posts: 45
Send PM


Could we have more discrete games in MAME?
#365755 - 05/05/17 09:10 PM


Dumb question: Since Pong is now available in MAME, could other discrete games from the bronze age be added? Would it matter whether or not DICE has tried to make them available?



Haze
Reged: 09/23/03
Posts: 5245
Send PM


Re: Could we have more discrete games in MAME? new [Re: RPOR6V]
#365756 - 05/05/17 09:13 PM


> Dumb question: Since Pong is now available in MAME, could other discrete games from
> the bronze age be added? Would it matter whether or not DICE has tried to make them
> available?

yes, but they're a lot of work and very few people are in a position to be able to do them.



MooglyGuy
Renegade MAME Dev
Reged: 09/01/05
Posts: 2261
Send PM


Re: Could we have more discrete games in MAME? new [Re: Haze]
#365762 - 05/05/17 09:39 PM


> yes, but they're a lot of work and very few people are in a position to be able to do
> them.

I have the capability, but not the time. I'm currently pursuing more consistent salaried work here in the Stockholm area, as working from home actually sucks and makes it hard to focus. For now though I still need to be crunching on the contracting gig I'm doing, at least through until mid to late June.

Once I have more free time, I'm planning on turning my sights back on Stunt Cycle. The one problem there is that there's a function generator used to generate certain basic signals related to the controls, and a couple of parts (including a specific transistor type) in addition to that one will also need to be emulated.

At least, that's my hope. I managed to get Stunt Cycle showing something on-screen while I was out in the western Swedish countryside for the holidays, with my partner and his family, so I accomplished my goal to that end, I "just" need to actually wrap it up. I would welcome anyone else taking a crack at it in the meantime, but I plan to get around to it.

In case anyone's keeping score, among other things, my to-do list includes:
- Write an ARM7TDMI JIT frontend, so things like 39in1 and gp32 have a snowball's chance in hell of running full-speed.
- Write an ARM32 JIT backend, so things like Killer Instinct and Seattle games can hopefully run full-speed on modern ARM chips.
- Write an ARM64 JIT backend, for similar future-looking reasons.
- Refactor the way screens are presented to the OSD, and refactor the way the OSD handles these screens. Ideally I want screens to simply be nodes in an overall scene graph, consumable by a standard scene issuing an orthographically-projected quad per window, showing the game content, but also potentially consumable by, say, a 3D model of an arcade cabinet which has its own material which has a shader effect that consumes the screen texture instead.
- Look into leveraging more of BGFX for things like compute shader jobs. The current bleeding-edge low-level N64 RDP emulation is more or less a brute-force approach, shoving angrylion's code as unmodified as possible into a compute shader. I'm positive that it's possible to simply emit a branch-flattened version of the pixel rendering loop for a given set of RDP state, and cache it for later use since games most likely don't use one-off RDP configurations, in order to be friendlier in terms of our GPU access patterns.
- Work on device-ifying more of the SGI Indy driver. It's pretty much the first driver that I wrote almost entirely on my own, with a hand from Arbee here and there, and I wrote it when I was still at university. With twelve years in the game industry under my belt, I look at my old code with a pretty jaded eye, and I know I can do better these days. With any luck, it may even make the driver more functional.
- Try to rally enough interest for people to look into making the sun4 driver actually chat more successfully with the SCSI controller. At this time I'm not sure if it's shortcomings with the 53C90 controller, or shortcomings with how the DMA controller is handled by the sun4 driver. I suspect the latter.
- Look into adding support for the R5900 "Emotion Engine" version of MIPS, at least enough to get the correct CPU type in the PS2-based drivers, and potentially running at least some actual boot code. Part of the problem is that I need someone to point me directly at some good solid PS2 hardware documentation, including that of the Emotion Engine and especially VU0/VU1. Previously, every time I've looked at the EE, I've spotted the various SIMD instructions it has, and gone, "Y'know what, leave it" in pretty short order.
- Cycle-accurate NES PPU. The documentation is out there on NESdev, and we have the cycle-accurate, interruptible CPU core. It's just a matter of time stopping anyone from doing it, the documentation is plentiful.
- Do more reverse-engineering of the 68HC05 "SERVO" MCU that we have a dump from, in the CD-i driver. Also start reverse-engineering the "SLAVE" MCU, as this will hopefully fix some input issues that the driver currently has. Since the Quizard games interfaced with the CD-i player through its serial port, which was in part managed by "SLAVE" in certain models, this could in fact result in additional arcade games in MAME being promoted to working, if I or anyone else put in the time.
- In the interim before GPU-accelerated RDP is production-ready, investigate using the DRC/JIT system to accelerate the RDP rendering instead, caching recompiled blocks based on a hash of the RDP state that affects rendering. There's no reason someone couldn't already make use of the DRC/JIT system to accelerate things other than CPUs, it's just nobody has bothered at this point.
- Look into emulating more discrete games, as well as get Stunt Cycle debugged and working.

Anyway, that's off the top of my head.



gregf
Ramtek's Trivia promoter
Reged: 09/21/03
Posts: 8612
Loc: southern CA, US
Send PM


Re: Could we have more discrete games in MAME? new [Re: RPOR6V]
#365777 - 05/06/17 03:23 AM


>Since Pong is now available in MAME, could other discrete games from the bronze age be
>added? Would it matter whether or not DICE has tried to make them available?

Haze's post sums it best.


Although no newly supported working games, some significant updates over past few months includes prom support by Moogly which is needed for many of the non-cpu games that do use proms.

-netlist: Added 2716 16 Kbit (2 Kbit x 8 ) UV EPROM.
-netlist: Added 82S126 1K-bit bipolar PROM device.
-netlist: Added 82S126 4kbit (512x8) TTL bipolar PROM.
-netlist: Added 82S123 256-bit (32x8) TTL bipolar PROM.


Couriersud has also made lots of various improvements over past 5 months with one recent one in April.

https://git.redump.net/mame/log/?qt=author&q=couriersud

-
2017-04-09

Netlist code refactoring:
- more use of c++ features
- some CRTP in pfmtlog
- demangled code for truthtables
- use more constexpr
- rewrite main loop
- use default constructors and assignment operators were applicable.
- optimized 7448 and 9316

All of this has decreased startup time by approx. 25% to 30%. Complex
netlists like pong or kidniki are parsed, analyzed and constructed in
around 15 ms. Run performance has increased by about 5%.

All in all not to bad. A game like pong uses a clock of 7 MHz (after
division by 2). Thats 14 MHz clock invocations. Running at over 200%, 28
MHz. On a 3.9 GHz Machine about 140 cycles/clock change. [Couriersud]
-



A lot more ttl devices and more various prom support still needed before more complex non-cpu games can be supported and also some of the current ttl chips support still being improved along the way before other discrete based (audio hardware or video hardware) is emulated.



StilettoAdministrator
They're always after me Lucky ROMS!
Reged: 03/07/04
Posts: 6472
Send PM


Re: Could we have more discrete games in MAME? new [Re: RPOR6V]
#365781 - 05/06/17 06:11 AM


> Dumb question: Since Pong is now available in MAME, could other discrete games from
> the bronze age be added?

Absolutely.

In theory, Gotcha, Quadrapong and Rebound could be added to MAME without any new TTL devices required to be simulated. All someone would need to do is create the "netlist" schematic description for each game, plus the glue code that connects it into a typical MAME driver. And the bar may have been lowered to the point that even a less talented dev like myself might be able to give it a try. (see below)

Any other game from DICE would require anything from minimal to substantial work to model the additional devices they require.

> Would it matter whether or not DICE has tried to make them
> available?

That doesn't necessarily help or hurt, but code from DICE can't be directly dropped in. But it needs only modest amounts of adaptation.

Two issues which were conquered, as I understand it: sourcecode licensing and code compatibility:

a. Prior to the MAME relicensing project, MAME and DICE had incompatible licenses. However, eventually MAME and DICE developers made a gentleman's agreement to permit sharing relevant code between the two projects. DICE's code, while licensed GPLv3, had permission to be used under the GPLv2 license when bundled with MAME. MAME reaped the benefits with this when Pong Doubles was added. Meanwhile, MAME's relevant netlist/game code would be permitted to be transferred to DICE's license. Or something like that.

Ever since MAME was relicensed to overall GPLv2 or greater (and more than 90% of the code 3-clause BSD licensed), this is not any more an issue.

b. MAME's schematics description language ("netlist"), developed for Pong, was not compatible with DICE's description language. However, couriersud later made some changes and wrote a library to simplify compatibility.

According to couriersud, if MAME had all the same TTL devices modeled that DICE had, you'd be able to largely port over DICE's drivers, replacing terminology for terminology, but approximately 10% of the code would need to be changed due to the design differences between MAME and DICE.

Excerpt from an email from couriersud from late 2013:

Quote:


Migrating DICE netlists should be pretty easy. There's some work needed though

a) DICE works on physical pin assignments, i.e. connect some pin to pin 12. I prefer "connect something to CLK" - assuming pin 12 is the CLK signal. However, with the netlist design you can take an existing chip and just write a wrapper which adds the necessary aliases.
b) For the connections DICE uses preprocessor macros as well. We'll just need to redefine the macro.

Manual work is needed for the "analog" parts like e.g. NE555. But this is only 10% of the work.

Some examples if somebody already wants to start ...

DICE: CHIP("D8", 7410),
Netlist: netlist.register_dev(NET_NEW(7410), "D8");


DICE: CONNECTION("F8", 11, "F9", 14),
Netlist: netlist.register_link("F8" "." "11" , "F9" "." "14");

Pretty straightforward to derive macros CHIP and CONNECTION here.

This would also mean, that we could leave a lot of the DICE work untouched (e.g. copy+paste) and give appropriate credit for the hard work the colleagues from the DICE project did.



Note that MAME's netlist syntax may have changed a little since 2013.

... all that said, in general MAMEdevs enjoy reinventing the wheel, ie. "Not Invented Here" syndrome.

I made this pastebin to compare the two systems in terms of devices simulated and what's still required for each game in DICE several months ago. It's possible it's not as simple as this, either.
https://pastebin.com/Q4xsWAR8
I would not recommend reading this without being passing familiar with both MAME netlist and DICE systems and/or TTL devices.

- Stiletto


Pages: 1

MAMEWorld >> EmuChat
View all threads Index   Threaded Mode Threaded  

Extra information Permissions
Moderator:  Robbbert, Tafoid 
0 registered and 717 anonymous users are browsing this forum.
You cannot start new topics
You cannot reply to topics
HTML is enabled
UBBCode is enabled
Thread views: 1461