Live data from Hacker News

Playstation 2 GS emulation – the final frontier of Vulkan compute emulation

themaister.net

41–50 of 69 posts

Re: Playstation 2 GS emulation – the final frontier of Vulkan compute emulation

#41

[dead]

For anyone wondering: > A dynamic recompiler is a type of software that translates code from one instruction set architecture (ISA) to another at runtime, rather than ahead of time. This process allows programs written for one platform to be executed on another platform without needing to modify the original code. Dynamic recompilation is often used in emulators, virtual machines, and just-in-time (JIT) compilation s…

(Citra, Panda3DS, Vita3K, touchHLE, and unidbg and more ) use dynamic for ARM CPU Emulation but Dolphin/cemu use same concept to emulate PowerPC Chips too

PS4 emulators use different approach tho

Re: Playstation 2 GS emulation – the final frontier of Vulkan compute emulation

#42
post #35
post #19

Earlier quoted context omitted.

I believe the distinction from NVIDIA was that they considered their product as the first all in one graphics unit > a single-chip processor with integrated transform, lighting, triangle setup/clipping, and rendering engines that is capable of processing a minimum of 10 million polygons per second It’s kind of arbitrary, even when you take out the processing rate. But prior to that there was still a significant amoun…

TI chips for arcades are considered one of the first. "The TMS34010, developed by Texas Instruments and released in 1986, was the first programmable graphics processor integrated circuit. While specialized graphics hardware existed earlier, such as blitters, the TMS34010 chip is a microprocessor which includes graphics-oriented instructions, making it a combination of a CPU and what would later be called a GPU." http…

Yep, and I think perhaps that’s where folks are getting hung up.

NVIDIA didn’t invent the GPU. They coined the modern term “graphics processing unit”. Prior to that, various hardware existed but went by other expanded names or don’t fully match NVIDIAs arbitrary definition, which is what we use today.

Re: Playstation 2 GS emulation – the final frontier of Vulkan compute emulation

#43

> Pray you have programmable blending I prayed for programmable blending via "blending shaders" (and FWIW programmable texture decoding via "texture shaders" - useful for custom texture format/compression, texture synthesis, etc) since i first learned about pixel shaders waay back in early 2000s. Somehow GPUs got raytracing before programmable blending when the former felt like some summer night dream and the latter…

Mobile GPUs with any PowerVR heritage have it

https://medium.com/pocket-gems/programmable-blending-on-ios-...

https://developer.apple.com/videos/play/tech-talks/605

Re: Playstation 2 GS emulation – the final frontier of Vulkan compute emulation

#44
post #5

Earlier quoted context omitted.

Among the intended audience, it likely is. I think this article is here to equally amuse and traumatize folks familiar with the system. The Emotion Engine (CPU) to GS (GPU) link was what made the PS2 so impressive for the time, but it also made it somewhat hard to code for and immensely hard to emulate. If I recall correctly, the N64 has something like 4x the memory bandwidth (shared) of the PS1, and the PS2 had roug…

> However, the PS2's GS RAM clocked in at 48GB/s, more than the external memory bandwidth of the Cell (~25GB/s), which meant that PS3 emulation of PS2 games was actually done with embedded PS2 hardware. That's kinda overselling it, honestly. When you're talking about the GIF, only the VU1's vertex pipeline was able to achieve this speed directly. PATH2/PATH3 used the commodity RDRAM's bus (unless you utilized MFIFO t…

Growing up with the tech press in this era, “commodity RDRAM” is a funny phrase to read!

As I recall, the partnership between Intel and Rambus was pilloried as an attempt to re-proprieterize the PC RAM interface in a similar vein to IBM’s microchannel bus.

Re: Playstation 2 GS emulation – the final frontier of Vulkan compute emulation

#45
post #5

Earlier quoted context omitted.

Among the intended audience, it likely is. I think this article is here to equally amuse and traumatize folks familiar with the system. The Emotion Engine (CPU) to GS (GPU) link was what made the PS2 so impressive for the time, but it also made it somewhat hard to code for and immensely hard to emulate. If I recall correctly, the N64 has something like 4x the memory bandwidth (shared) of the PS1, and the PS2 had roug…

It’s hard to compare memory bandwidth of these systems because of the various differences (e.g. different RAM types). I know that the theoretical RAM bandwidth for the N64 is way higher than what you can practically achieve under typical conditions.

I totally agree, except when it comes to emulation. It is immensely hard to real-time emulate if some facet of your host hardware isn’t at least a little bit faster than the corresponding element in the emulated system. Then you have to lift the abstraction and often find that the rest of the system reflects this specificity.

At my last job, we had ASICs that allowed for single-sample audio latency with basic mixing/accumulation functions for pulling channels of audio off of a bus. It would have been tragically expensive to reproduce that in software, and the required hardware to support a pure software version of that would have been ridiculous.

We ended up launching a new platform with a different underlying architecture that made very different choices.

Re: Playstation 2 GS emulation – the final frontier of Vulkan compute emulation

#46
post #5

Earlier quoted context omitted.

Among the intended audience, it likely is. I think this article is here to equally amuse and traumatize folks familiar with the system. The Emotion Engine (CPU) to GS (GPU) link was what made the PS2 so impressive for the time, but it also made it somewhat hard to code for and immensely hard to emulate. If I recall correctly, the N64 has something like 4x the memory bandwidth (shared) of the PS1, and the PS2 had roug…

> However, the PS2's GS RAM clocked in at 48GB/s, more than the external memory bandwidth of the Cell (~25GB/s), which meant that PS3 emulation of PS2 games was actually done with embedded PS2 hardware. That's kinda overselling it, honestly. When you're talking about the GIF, only the VU1's vertex pipeline was able to achieve this speed directly. PATH2/PATH3 used the commodity RDRAM's bus (unless you utilized MFIFO t…

I think that’s fair. It was, in effect, a cache and DMA target. A similar scheme was present in the Cell, where the SPE’s had 256KB of embedded SRAM that really needed to be addressed via DMA to not drag performance to the ground. For low-level optimization junkies, it was an absolute playground of traps and gotchas.

Edit: if memory serves, SPE DMA list bandwidth was just north of 200GB/s. Good times.

Re: Playstation 2 GS emulation – the final frontier of Vulkan compute emulation

#47
post #7
post #5

Earlier quoted context omitted.

Among the intended audience, it likely is. I think this article is here to equally amuse and traumatize folks familiar with the system. The Emotion Engine (CPU) to GS (GPU) link was what made the PS2 so impressive for the time, but it also made it somewhat hard to code for and immensely hard to emulate. If I recall correctly, the N64 has something like 4x the memory bandwidth (shared) of the PS1, and the PS2 had roug…

Thanks for sharing! Back then the appeal of console games to me were that beyond a convenient factor, they were also very specialised hardware for one task - running games. I remember playing FF12 (IZJS) on a laptop in 2012 and it ran very stable granted that was 6 years post release but by then had the emulator issues been fully solved? Re. Wild time for low level programming I remember hearing that Crash Bandicoot…

Would programmers now be able to make God of War 2, FF12, Jak 2&3 and Ratchet and Clank 3&Deadlocked? PS2, slim especially, is an incredible machine. Scale the games up to 1080p or 1440/4k and they look great still.

Re: Playstation 2 GS emulation – the final frontier of Vulkan compute emulation

#48
post #35
post #19

Earlier quoted context omitted.

I believe the distinction from NVIDIA was that they considered their product as the first all in one graphics unit > a single-chip processor with integrated transform, lighting, triangle setup/clipping, and rendering engines that is capable of processing a minimum of 10 million polygons per second It’s kind of arbitrary, even when you take out the processing rate. But prior to that there was still a significant amoun…

TI chips for arcades are considered one of the first. "The TMS34010, developed by Texas Instruments and released in 1986, was the first programmable graphics processor integrated circuit. While specialized graphics hardware existed earlier, such as blitters, the TMS34010 chip is a microprocessor which includes graphics-oriented instructions, making it a combination of a CPU and what would later be called a GPU." http…

IBM's PGA card had an additional 8088 dedicated to graphics primitives: https://en.wikipedia.org/wiki/Professional_Graphics_Controll...

Re: Playstation 2 GS emulation – the final frontier of Vulkan compute emulation

#49

Earlier quoted context omitted.

> However, the PS2's GS RAM clocked in at 48GB/s, more than the external memory bandwidth of the Cell (~25GB/s), which meant that PS3 emulation of PS2 games was actually done with embedded PS2 hardware. That's kinda overselling it, honestly. When you're talking about the GIF, only the VU1's vertex pipeline was able to achieve this speed directly. PATH2/PATH3 used the commodity RDRAM's bus (unless you utilized MFIFO t…

Growing up with the tech press in this era, “commodity RDRAM” is a funny phrase to read! As I recall, the partnership between Intel and Rambus was pilloried as an attempt to re-proprieterize the PC RAM interface in a similar vein to IBM’s microchannel bus.

"Commodity" meaning "something that could be bought at the store".

Re: Playstation 2 GS emulation – the final frontier of Vulkan compute emulation

#50
post #29
post #20

How does this approach compare to Dolphin's ubershader?

Basically, not at all. Dolphin's ubershader does one thing; simulate fixed-function blending/texturing using modern flexible hardware. (It was already an old technique when Dolphin adopted it, by the way.) This project is a complete renderer, with the rasterizer and all, and as you can see from the text, it includes an ubershader for the blending. The shader doesn't draw triangles, it just gets called for each point…

> Dolphin's ubershader does one thing; simulate fixed-function blending/texturing using modern flexible hardware.

Just to clarify, Dolphin's specialized shaders simulate fixed-function blending/texturing too. What's different about ubershaders is that a single shader can handle a wide variety of fixed-function states whereas a specialized shader can only handle a single state.

Thus whereas specialized shaders have to be generated and compiled on-the-fly resulting in stutter; ubershaders can all be pre-compiled before running the game. Add to this the capability to asynchronously compile specialized shaders to replace ubershaders and the performance loss of ubershaders becomes negligible. A rare case of having your cake and eating it too.

Post reply on HN