mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-02-05 09:39:58 +00:00
Slightly cleaner, allows DSP accelerator behaviour to be added to both HLE and LLE pretty easily, and makes the accelerator easier to unit test. I chose to include all accelerator state as private members, and to expose state that is accessible via registers with getters/setters. It's more verbose, yes, but it makes it very clear what is part of the accelerator state and what isn't (e.g. coefs). This works quite well for registers, since the accelerator can do whatever it wants internally. For example, the start/end/current addresses are masked -- having a getter/setter makes it easier to enforce the mask.