From 681c09f25c5e43b19594ad6e23b708def2843e2a Mon Sep 17 00:00:00 2001 From: Gregory Hainaut Date: Sun, 20 Nov 2016 12:58:07 +0100 Subject: [PATCH] gsdx sw: catch xbyak exception --- plugins/GSdx/GSDrawScanlineCodeGenerator.cpp | 6 +++++- plugins/GSdx/GSSetupPrimCodeGenerator.cpp | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/plugins/GSdx/GSDrawScanlineCodeGenerator.cpp b/plugins/GSdx/GSDrawScanlineCodeGenerator.cpp index 8307e9e99c..99d2935d38 100644 --- a/plugins/GSdx/GSDrawScanlineCodeGenerator.cpp +++ b/plugins/GSdx/GSDrawScanlineCodeGenerator.cpp @@ -114,7 +114,11 @@ GSDrawScanlineCodeGenerator::GSDrawScanlineCodeGenerator(void* param, uint64 key if(m_sel.breakpoint) int3(); - Generate(); + try { + Generate(); + } catch (std::exception& e) { + fprintf(stderr, "ERR:GSDrawScanlineCodeGenerator %s\n", e.what()); + } } #if _M_SSE >= 0x501 diff --git a/plugins/GSdx/GSSetupPrimCodeGenerator.cpp b/plugins/GSdx/GSSetupPrimCodeGenerator.cpp index 3735ec9a41..d69f52e535 100644 --- a/plugins/GSdx/GSSetupPrimCodeGenerator.cpp +++ b/plugins/GSdx/GSSetupPrimCodeGenerator.cpp @@ -75,7 +75,11 @@ GSSetupPrimCodeGenerator::GSSetupPrimCodeGenerator(void* param, uint64 key, void m_en.t = m_sel.fb && m_sel.tfx != TFX_NONE ? 1 : 0; m_en.c = m_sel.fb && !(m_sel.tfx == TFX_DECAL && m_sel.tcc) ? 1 : 0; - Generate(); + try { + Generate(); + } catch (std::exception& e) { + fprintf(stderr, "ERR:GSSetupPrimCodeGenerator %s\n", e.what()); + } } #if _M_SSE >= 0x501