mirror of
https://git.eden-emu.dev/eden-emu/eden
synced 2026-11-10 17:00:33 +01:00
[shader_recompiler] Simplify translate loop and directly call (the now uniform functions); remove repetitive declarations on impl.h (#2972)
Function polymorphism where it wasn't needed? especially on tight code loops like translating code and whatnot? You may think the compiler was fine with this but nah, it just made codegen for all those paths; I didn't check LTO but I'd assume it behaves the same (since the "black box" from most walkers suck) - basically bunch of code that isn't longer used Also uniformly declaring all functions (i.e same args, return value) makes the entire switch statment way nicer Signed-off-by: lizzie lizzie@eden-emu.dev Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/2972 Reviewed-by: crueter <crueter@eden-emu.dev> Reviewed-by: MaranBr <maranbr@eden-emu.dev> Reviewed-by: CamilleLaVey <camillelavey99@gmail.com> Co-authored-by: lizzie <lizzie@eden-emu.dev> Co-committed-by: lizzie <lizzie@eden-emu.dev>
This commit is contained in:
parent
576c4e5f77
commit
312c1cc0f6
6 changed files with 30 additions and 321 deletions
|
|
@ -10,6 +10,7 @@
|
|||
#include <ranges>
|
||||
#include <string_view>
|
||||
|
||||
#include "common/assert.h"
|
||||
#include "common/common_types.h"
|
||||
#include "shader_recompiler/exception.h"
|
||||
#include "shader_recompiler/frontend/maxwell/decode.h"
|
||||
|
|
@ -45,7 +46,8 @@ Opcode Decode(u64 insn) {
|
|||
return Opcode::name;
|
||||
#include "maxwell.inc"
|
||||
#undef INST
|
||||
throw NotImplementedException("Invalid insn 0x{:016x}", insn);
|
||||
ASSERT_MSG(false, "Invalid insn 0x{:016x}", insn);
|
||||
return Opcode::NOP;
|
||||
}
|
||||
|
||||
} // namespace Shader::Maxwell
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue