From 90d551e0d120542fab003e8b4b978b01e07c155c Mon Sep 17 00:00:00 2001 From: degasus Date: Wed, 3 May 2017 22:45:15 +0200 Subject: [PATCH 1/3] JitArm64: Drop ps_res. The accuracy doesn't match ppc, and worse, it doesn't set the error flags if the input is zero. Lets stop to ship broken instructions, so right now, the interpreter is the closest one. --- Source/Core/Core/PowerPC/JitArm64/Jit.h | 1 - .../Core/PowerPC/JitArm64/JitArm64_Paired.cpp | 23 ------------------- .../Core/PowerPC/JitArm64/JitArm64_Tables.cpp | 2 +- 3 files changed, 1 insertion(+), 25 deletions(-) diff --git a/Source/Core/Core/PowerPC/JitArm64/Jit.h b/Source/Core/Core/PowerPC/JitArm64/Jit.h index 192a0203a9..98f4510bbf 100644 --- a/Source/Core/Core/PowerPC/JitArm64/Jit.h +++ b/Source/Core/Core/PowerPC/JitArm64/Jit.h @@ -142,7 +142,6 @@ public: void ps_maddXX(UGeckoInstruction inst); void ps_mergeXX(UGeckoInstruction inst); void ps_mulsX(UGeckoInstruction inst); - void ps_res(UGeckoInstruction inst); void ps_sel(UGeckoInstruction inst); void ps_sumX(UGeckoInstruction inst); diff --git a/Source/Core/Core/PowerPC/JitArm64/JitArm64_Paired.cpp b/Source/Core/Core/PowerPC/JitArm64/JitArm64_Paired.cpp index 93306bf5a4..3aba8aae4b 100644 --- a/Source/Core/Core/PowerPC/JitArm64/JitArm64_Paired.cpp +++ b/Source/Core/Core/PowerPC/JitArm64/JitArm64_Paired.cpp @@ -152,29 +152,6 @@ void JitArm64::ps_maddXX(UGeckoInstruction inst) fpr.Unlock(V0Q); } -void JitArm64::ps_res(UGeckoInstruction inst) -{ - INSTRUCTION_START - JITDISABLE(bJITPairedOff); - FALLBACK_IF(inst.Rc); - FALLBACK_IF(SConfig::GetInstance().bFPRF && js.op->wantsFPRF); - - u32 b = inst.FB, d = inst.FD; - - bool singles = fpr.IsSingle(b); - RegType type = singles ? REG_REG_SINGLE : REG_REG; - u8 size = singles ? 32 : 64; - ARM64Reg (*reg_encoder)(ARM64Reg) = singles ? EncodeRegToDouble : EncodeRegToQuad; - - ARM64Reg VB = fpr.R(b, type); - ARM64Reg VD = fpr.RW(d, type); - - // FIXME: implement the same LUT as in the interpreter - m_float_emit.FRECPE(size, reg_encoder(VD), reg_encoder(VB)); - - fpr.FixSinglePrecision(d); -} - void JitArm64::ps_sel(UGeckoInstruction inst) { INSTRUCTION_START diff --git a/Source/Core/Core/PowerPC/JitArm64/JitArm64_Tables.cpp b/Source/Core/Core/PowerPC/JitArm64/JitArm64_Tables.cpp index e6141476ab..7e9696a339 100644 --- a/Source/Core/Core/PowerPC/JitArm64/JitArm64_Tables.cpp +++ b/Source/Core/Core/PowerPC/JitArm64/JitArm64_Tables.cpp @@ -145,7 +145,7 @@ constexpr GekkoOPTemplate table4_2[] = { {20, &JitArm64::fp_arith}, // ps_sub {21, &JitArm64::fp_arith}, // ps_add {23, &JitArm64::ps_sel}, // ps_sel - {24, &JitArm64::ps_res}, // ps_res + {24, &JitArm64::FallBackToInterpreter}, // ps_res {25, &JitArm64::fp_arith}, // ps_mul {26, &JitArm64::FallBackToInterpreter}, // ps_rsqrte {28, &JitArm64::ps_maddXX}, // ps_msub From afb0beb9ab7872ea402906af69704cbb3a4d6eaa Mon Sep 17 00:00:00 2001 From: degasus Date: Thu, 27 Apr 2017 19:59:25 +0200 Subject: [PATCH 2/3] OpenGL: Mute nvidia performance warning about stalling the GPU. They are right, our perf query implementation is terrible. But raising a warning makes it just even slower. --- Source/Core/VideoBackends/OGL/Render.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Source/Core/VideoBackends/OGL/Render.cpp b/Source/Core/VideoBackends/OGL/Render.cpp index 360bc76a70..d9edb74327 100644 --- a/Source/Core/VideoBackends/OGL/Render.cpp +++ b/Source/Core/VideoBackends/OGL/Render.cpp @@ -84,6 +84,11 @@ static void APIENTRY ErrorCallback(GLenum source, GLenum type, GLuint id, GLenum const char* s_source; const char* s_type; + // Performance - DualCore driver performance warning: + // DualCore application thread syncing with server thread + if (id == 0x200b0) + return; + switch (source) { case GL_DEBUG_SOURCE_API_ARB: From 7389f0f55e160e9b0299bbae0c217457fdc4f1de Mon Sep 17 00:00:00 2001 From: degasus Date: Sat, 29 Apr 2017 09:29:52 +0200 Subject: [PATCH 3/3] Analytics: Set proper thread name. --- Source/Core/Common/Analytics.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Source/Core/Common/Analytics.cpp b/Source/Core/Common/Analytics.cpp index 233badebd2..ed9f8cf112 100644 --- a/Source/Core/Common/Analytics.cpp +++ b/Source/Core/Common/Analytics.cpp @@ -10,6 +10,7 @@ #include "Common/Analytics.h" #include "Common/CommonTypes.h" #include "Common/StringUtil.h" +#include "Common/Thread.h" namespace Common { @@ -147,6 +148,7 @@ void AnalyticsReporter::Send(AnalyticsReportBuilder&& report) void AnalyticsReporter::ThreadProc() { + Common::SetCurrentThreadName("Analytics"); while (true) { m_reporter_event.Wait();