From 89001accd8543bb1d752f542f8398e166d213558 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Thu, 30 Jan 2014 22:11:39 -0500 Subject: [PATCH] Move two macros that literally doesn't change across all JIT platforms (JITDISABLE and INSTRUCTION_START) and simply have it in the JitBase.h source file. This way the macro is just located in one spot rather than 6 places. --- Source/Core/Core/PowerPC/Jit64/Jit.h | 10 ---------- Source/Core/Core/PowerPC/Jit64IL/JitIL.h | 9 --------- Source/Core/Core/PowerPC/JitArm32/Jit.h | 8 -------- Source/Core/Core/PowerPC/JitArmIL/JitIL.h | 5 ----- Source/Core/Core/PowerPC/JitCommon/JitBase.h | 10 ++++++++++ Source/Core/Core/PowerPC/JitILCommon/JitILBase.h | 7 ------- 6 files changed, 10 insertions(+), 39 deletions(-) diff --git a/Source/Core/Core/PowerPC/Jit64/Jit.h b/Source/Core/Core/PowerPC/Jit64/Jit.h index 3fd9c41b61..0c8132e823 100644 --- a/Source/Core/Core/PowerPC/Jit64/Jit.h +++ b/Source/Core/Core/PowerPC/Jit64/Jit.h @@ -37,16 +37,6 @@ #include "x64Analyzer.h" #include "x64Emitter.h" -// Use these to control the instruction selection -// #define INSTRUCTION_START Default(inst); return; -// #define INSTRUCTION_START PPCTables::CountInstruction(inst); -#define INSTRUCTION_START - -#define JITDISABLE(setting) \ - if (Core::g_CoreStartupParameter.bJITOff || \ - Core::g_CoreStartupParameter.setting) \ - {Default(inst); return;} - class Jit64 : public Jitx86Base { private: diff --git a/Source/Core/Core/PowerPC/Jit64IL/JitIL.h b/Source/Core/Core/PowerPC/Jit64IL/JitIL.h index e56a56c815..f22d4202cc 100644 --- a/Source/Core/Core/PowerPC/Jit64IL/JitIL.h +++ b/Source/Core/Core/PowerPC/Jit64IL/JitIL.h @@ -36,15 +36,6 @@ #include "../../HW/Memmap.h" #include "../../HW/GPFifo.h" -// #define INSTRUCTION_START Default(inst); return; -// #define INSTRUCTION_START PPCTables::CountInstruction(inst); -#define INSTRUCTION_START - -#define JITDISABLE(setting) \ - if (Core::g_CoreStartupParameter.bJITOff || \ - Core::g_CoreStartupParameter.setting) \ - {Default(inst); return;} - #ifdef _M_X64 #define DISABLE64 \ {Default(inst); return;} diff --git a/Source/Core/Core/PowerPC/JitArm32/Jit.h b/Source/Core/Core/PowerPC/JitArm32/Jit.h index b245a38952..9655ae73a8 100644 --- a/Source/Core/Core/PowerPC/JitArm32/Jit.h +++ b/Source/Core/Core/PowerPC/JitArm32/Jit.h @@ -39,14 +39,6 @@ #include "JitAsm.h" #include "../JitCommon/JitBase.h" -// Use these to control the instruction selection -// #define INSTRUCTION_START Default(inst); return; -// #define INSTRUCTION_START PPCTables::CountInstruction(inst); -#define INSTRUCTION_START -#define JITDISABLE(setting) \ - if (Core::g_CoreStartupParameter.bJITOff || \ - Core::g_CoreStartupParameter.setting) \ - {Default(inst); return;} #define PPCSTATE_OFF(elem) ((s32)STRUCT_OFF(PowerPC::ppcState, elem) - (s32)STRUCT_OFF(PowerPC::ppcState, spr[0])) class JitArm : public JitBase, public ArmGen::ARMXCodeBlock { diff --git a/Source/Core/Core/PowerPC/JitArmIL/JitIL.h b/Source/Core/Core/PowerPC/JitArmIL/JitIL.h index 4dec87ddeb..5aaa7c583e 100644 --- a/Source/Core/Core/PowerPC/JitArmIL/JitIL.h +++ b/Source/Core/Core/PowerPC/JitArmIL/JitIL.h @@ -13,11 +13,6 @@ #include "../JitCommon/JitBase.h" #include "JitILAsm.h" -#define JITDISABLE(setting) \ - if (Core::g_CoreStartupParameter.bJITOff || \ - Core::g_CoreStartupParameter.setting) \ - {Default(inst); return;} - #define PPCSTATE_OFF(elem) ((s32)STRUCT_OFF(PowerPC::ppcState, elem) - (s32)STRUCT_OFF(PowerPC::ppcState, spr[0])) class JitArmIL : public JitILBase, public ArmGen::ARMXCodeBlock { diff --git a/Source/Core/Core/PowerPC/JitCommon/JitBase.h b/Source/Core/Core/PowerPC/JitCommon/JitBase.h index b133da0fdd..05c877df6f 100644 --- a/Source/Core/Core/PowerPC/JitCommon/JitBase.h +++ b/Source/Core/Core/PowerPC/JitCommon/JitBase.h @@ -27,6 +27,16 @@ #include +// Use these to control the instruction selection +// #define INSTRUCTION_START Default(inst); return; +// #define INSTRUCTION_START PPCTables::CountInstruction(inst); +#define INSTRUCTION_START + +#define JITDISABLE(setting) \ + if (Core::g_CoreStartupParameter.bJITOff || \ + Core::g_CoreStartupParameter.setting) \ + { Default(inst); return; } + class JitBase : public CPUCoreBase { protected: diff --git a/Source/Core/Core/PowerPC/JitILCommon/JitILBase.h b/Source/Core/Core/PowerPC/JitILCommon/JitILBase.h index ee5d08a4fd..37529c1613 100644 --- a/Source/Core/Core/PowerPC/JitILCommon/JitILBase.h +++ b/Source/Core/Core/PowerPC/JitILCommon/JitILBase.h @@ -16,13 +16,6 @@ #include "../../HW/GPFifo.h" #include "../../HW/Memmap.h" -#define INSTRUCTION_START - -#define JITDISABLE(setting) \ - if (Core::g_CoreStartupParameter.bJITOff || \ - Core::g_CoreStartupParameter.setting) \ - {Default(inst); return;} - class JitILBase : public JitBase { protected: