From 00ed02f8316ef0ea402ca22be101c27bd818a1d0 Mon Sep 17 00:00:00 2001 From: Gauvain 'GovanifY' Roussel-Tarbouriech Date: Wed, 12 May 2021 11:35:43 +0200 Subject: [PATCH] gs-merge: fix codegen scoping/xbyak misc things for our jit --- pcsx2/CMakeLists.txt | 1 + pcsx2/GS/GS.cpp | 2 ++ pcsx2/GS/GS.h | 21 -------------- pcsx2/GS/GS_codegen.h | 23 +++++++++++++++ pcsx2/GS/GS_types.h | 15 +++++----- pcsx2/GS/Renderers/Common/GSTexture.cpp | 5 ++-- pcsx2/GS/Renderers/Common/GSVertexTrace.cpp | 4 +-- pcsx2/GS/Renderers/HW/GSHwHack.cpp | 2 +- pcsx2/GS/Renderers/HW/GSTextureCache.cpp | 2 +- .../SW/GSDrawScanlineCodeGenerator.cpp | 28 +++++++++---------- .../GSDrawScanlineCodeGenerator.x64.avx.cpp | 3 ++ .../GSDrawScanlineCodeGenerator.x64.avx2.cpp | 3 ++ .../SW/GSDrawScanlineCodeGenerator.x64.cpp | 6 ++-- .../GSDrawScanlineCodeGenerator.x86.avx.cpp | 1 + .../GSDrawScanlineCodeGenerator.x86.avx2.cpp | 1 + .../SW/GSDrawScanlineCodeGenerator.x86.cpp | 1 + .../SW/GSSetupPrimCodeGenerator.x64.avx.cpp | 3 +- .../SW/GSSetupPrimCodeGenerator.x64.avx2.cpp | 3 +- .../SW/GSSetupPrimCodeGenerator.x64.cpp | 3 +- .../SW/GSSetupPrimCodeGenerator.x86.avx.cpp | 3 +- .../SW/GSSetupPrimCodeGenerator.x86.avx2.cpp | 3 +- .../SW/GSSetupPrimCodeGenerator.x86.cpp | 3 +- pcsx2/GS/Renderers/SW/GSTextureSW.cpp | 2 +- 23 files changed, 74 insertions(+), 64 deletions(-) create mode 100644 pcsx2/GS/GS_codegen.h diff --git a/pcsx2/CMakeLists.txt b/pcsx2/CMakeLists.txt index ade52cadda..8b5b959d58 100644 --- a/pcsx2/CMakeLists.txt +++ b/pcsx2/CMakeLists.txt @@ -662,6 +662,7 @@ set(pcsx2GSHeaders GS/GSDump.h GS/GS_res.h GS/GS_types.h + GS/GS_codegen.h GS/GS.h GS/GSLocalMemory.h GS/GSLzma.h diff --git a/pcsx2/GS/GS.cpp b/pcsx2/GS/GS.cpp index ba5a3dd6b7..00c3f956c1 100644 --- a/pcsx2/GS/GS.cpp +++ b/pcsx2/GS/GS.cpp @@ -53,6 +53,8 @@ extern bool RunLinuxDialog(); #endif +#include + // do NOT undefine this/put it above includes, as x11 people love to redefine // things that make obscure compiler bugs, unless you want to run around and // debug obscure compiler errors --govanify diff --git a/pcsx2/GS/GS.h b/pcsx2/GS/GS.h index 8ad0e9dfc3..b9a76be12f 100644 --- a/pcsx2/GS/GS.h +++ b/pcsx2/GS/GS.h @@ -188,27 +188,6 @@ #define ASSERT assert -/* -#ifdef _M_AMD64 - // Yeah let use mips naming ;) - #ifdef _WIN64 - #define a0 rcx - #define a1 rdx - #define a2 r8 - #define a3 r9 - #define t0 rdi - #define t1 rsi - #else - #define a0 rdi - #define a1 rsi - #define a2 rdx - #define a3 rcx - #define t0 r8 - #define t1 r9 - #endif -#endif -*/ - // sse #if defined(__GNUC__) diff --git a/pcsx2/GS/GS_codegen.h b/pcsx2/GS/GS_codegen.h new file mode 100644 index 0000000000..a370c2dc92 --- /dev/null +++ b/pcsx2/GS/GS_codegen.h @@ -0,0 +1,23 @@ +#pragma once + +using namespace Xbyak; + +#ifdef _M_AMD64 +// Yeah let use mips naming ;) + #ifdef _WIN64 + #define a0 rcx + #define a1 rdx + #define a2 r8 + #define a3 r9 + #define t0 rdi + #define t1 rsi + #else + #define a0 rdi + #define a1 rsi + #define a2 rdx + #define a3 rcx + #define t0 r8 + #define t1 r9 + #endif +#endif + diff --git a/pcsx2/GS/GS_types.h b/pcsx2/GS/GS_types.h index 20cb8d346a..46c8b08911 100644 --- a/pcsx2/GS/GS_types.h +++ b/pcsx2/GS/GS_types.h @@ -1,13 +1,6 @@ #pragma once -#include -#include -#define MIE_INTEGER_TYPE_DEFINED -#define XBYAK_ENABLE_OMITTED_OPERAND - -#include - typedef unsigned char uint8; typedef signed char int8; typedef unsigned short uint16; @@ -16,6 +9,14 @@ typedef unsigned int uint32; typedef signed int int32; typedef unsigned long long uint64; typedef signed long long int64; +typedef signed long long sint64; + +#define MIE_INTEGER_TYPE_DEFINED +#define XBYAK_ENABLE_OMITTED_OPERAND +#include +#include + +#include #ifndef RESTRICT diff --git a/pcsx2/GS/Renderers/Common/GSTexture.cpp b/pcsx2/GS/Renderers/Common/GSTexture.cpp index c7501d2136..b3a11b91e4 100644 --- a/pcsx2/GS/Renderers/Common/GSTexture.cpp +++ b/pcsx2/GS/Renderers/Common/GSTexture.cpp @@ -21,6 +21,7 @@ #include "PrecompiledHeader.h" #include "GSTexture.h" +#include GSTexture::GSTexture() : m_scale(1, 1) @@ -71,8 +72,8 @@ void GSTexture::Uncommit() void GSTexture::SetGpuPageSize(const GSVector2i& page_size) { - ASSERT(std::bitset<32>(page_size.x + 1).count() == 1); - ASSERT(std::bitset<32>(page_size.y + 1).count() == 1); + pxAssert(std::bitset<32>(page_size.x + 1).count() == 1); + pxAssert(std::bitset<32>(page_size.y + 1).count() == 1); m_gpu_page_size = page_size; } diff --git a/pcsx2/GS/Renderers/Common/GSVertexTrace.cpp b/pcsx2/GS/Renderers/Common/GSVertexTrace.cpp index 5f4cbc2d7a..5bf4f0b400 100644 --- a/pcsx2/GS/Renderers/Common/GSVertexTrace.cpp +++ b/pcsx2/GS/Renderers/Common/GSVertexTrace.cpp @@ -21,8 +21,8 @@ #include "PrecompiledHeader.h" #include "GSVertexTrace.h" -#include "GSUtil.h" -#include "GSState.h" +#include "../../GSUtil.h" +#include "../../GSState.h" CONSTINIT const GSVector4 GSVertexTrace::s_minmax = GSVector4::cxpr(FLT_MAX, -FLT_MAX, 0.f, 0.f); diff --git a/pcsx2/GS/Renderers/HW/GSHwHack.cpp b/pcsx2/GS/Renderers/HW/GSHwHack.cpp index 87b5c73248..751a63cc2f 100644 --- a/pcsx2/GS/Renderers/HW/GSHwHack.cpp +++ b/pcsx2/GS/Renderers/HW/GSHwHack.cpp @@ -20,7 +20,7 @@ */ #include "PrecompiledHeader.h" -#include "GSState.h" +#include "../../GSState.h" #include "GS.h" bool s_nativeres; diff --git a/pcsx2/GS/Renderers/HW/GSTextureCache.cpp b/pcsx2/GS/Renderers/HW/GSTextureCache.cpp index 0ae2cdea21..02c0ff1dc4 100644 --- a/pcsx2/GS/Renderers/HW/GSTextureCache.cpp +++ b/pcsx2/GS/Renderers/HW/GSTextureCache.cpp @@ -22,7 +22,7 @@ #include "PrecompiledHeader.h" #include "GSTextureCache.h" #include "GSRendererHW.h" -#include "GSUtil.h" +#include "../../GSUtil.h" bool GSTextureCache::m_disable_partial_invalidation = false; bool GSTextureCache::m_wrap_gs_mem = false; diff --git a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.cpp b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.cpp index 07e187d3a6..5f219c77fe 100644 --- a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.cpp +++ b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.cpp @@ -26,7 +26,7 @@ #else void GSDrawScanlineCodeGenerator::Generate() { - if (m_cpu.has(util::Cpu::tAVX)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX)) Generate_AVX(); else Generate_SSE(); @@ -55,7 +55,7 @@ GSDrawScanlineCodeGenerator::GSDrawScanlineCodeGenerator(void* param, uint64 key void GSDrawScanlineCodeGenerator::modulate16(const Xmm& a, const Operand& f, uint8 shift) { - if (m_cpu.has(util::Cpu::tAVX)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX)) { if (shift == 0) { @@ -69,7 +69,7 @@ void GSDrawScanlineCodeGenerator::modulate16(const Xmm& a, const Operand& f, uin } else { - if (shift == 0 && m_cpu.has(util::Cpu::tSSSE3)) + if (shift == 0 && m_cpu.has(Xbyak::util::Cpu::tSSSE3)) { pmulhrsw(a, f); } @@ -83,7 +83,7 @@ void GSDrawScanlineCodeGenerator::modulate16(const Xmm& a, const Operand& f, uin void GSDrawScanlineCodeGenerator::lerp16(const Xmm& a, const Xmm& b, const Xmm& f, uint8 shift) { - if (m_cpu.has(util::Cpu::tAVX)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX)) { vpsubw(a, b); modulate16(a, f, shift); @@ -99,7 +99,7 @@ void GSDrawScanlineCodeGenerator::lerp16(const Xmm& a, const Xmm& b, const Xmm& void GSDrawScanlineCodeGenerator::lerp16_4(const Xmm& a, const Xmm& b, const Xmm& f) { - if (m_cpu.has(util::Cpu::tAVX)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX)) { vpsubw(a, b); vpmullw(a, f); @@ -117,7 +117,7 @@ void GSDrawScanlineCodeGenerator::lerp16_4(const Xmm& a, const Xmm& b, const Xmm void GSDrawScanlineCodeGenerator::mix16(const Xmm& a, const Xmm& b, const Xmm& temp) { - if (m_cpu.has(util::Cpu::tAVX)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX)) { vpblendw(a, b, 0xaa); } @@ -129,13 +129,13 @@ void GSDrawScanlineCodeGenerator::mix16(const Xmm& a, const Xmm& b, const Xmm& t void GSDrawScanlineCodeGenerator::clamp16(const Xmm& a, const Xmm& temp) { - if (m_cpu.has(util::Cpu::tAVX)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX)) { vpackuswb(a, a); #if _M_SSE >= 0x501 // Greg: why ? - if (m_cpu.has(util::Cpu::tAVX2)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX2)) { ASSERT(a.isYMM()); vpermq(Ymm(a.getIdx()), Ymm(a.getIdx()), _MM_SHUFFLE(3, 1, 2, 0)); // this sucks @@ -155,7 +155,7 @@ void GSDrawScanlineCodeGenerator::alltrue(const Xmm& test) { uint32 mask = test.isYMM() ? 0xffffffff : 0xffff; - if (m_cpu.has(util::Cpu::tAVX)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX)) { vpmovmskb(eax, test); cmp(eax, mask); @@ -171,7 +171,7 @@ void GSDrawScanlineCodeGenerator::alltrue(const Xmm& test) void GSDrawScanlineCodeGenerator::blend(const Xmm& a, const Xmm& b, const Xmm& mask) { - if (m_cpu.has(util::Cpu::tAVX)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX)) { vpand(b, mask); vpandn(mask, a); @@ -188,7 +188,7 @@ void GSDrawScanlineCodeGenerator::blend(const Xmm& a, const Xmm& b, const Xmm& m void GSDrawScanlineCodeGenerator::blendr(const Xmm& b, const Xmm& a, const Xmm& mask) { - if (m_cpu.has(util::Cpu::tAVX)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX)) { vpand(b, mask); vpandn(mask, a); @@ -204,7 +204,7 @@ void GSDrawScanlineCodeGenerator::blendr(const Xmm& b, const Xmm& a, const Xmm& void GSDrawScanlineCodeGenerator::blend8(const Xmm& a, const Xmm& b) { - if (m_cpu.has(util::Cpu::tAVX)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX)) vpblendvb(a, a, b, xmm0); else pblendvb(a, b); @@ -212,7 +212,7 @@ void GSDrawScanlineCodeGenerator::blend8(const Xmm& a, const Xmm& b) void GSDrawScanlineCodeGenerator::blend8r(const Xmm& b, const Xmm& a) { - if (m_cpu.has(util::Cpu::tAVX)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX)) { vpblendvb(b, a, b, xmm0); } @@ -228,7 +228,7 @@ void GSDrawScanlineCodeGenerator::split16_2x8(const Xmm& l, const Xmm& h, const // l = src & 0xFF; (1 left shift + 1 right shift) // h = (src >> 8) & 0xFF; (1 right shift) - if (m_cpu.has(util::Cpu::tAVX)) + if (m_cpu.has(Xbyak::util::Cpu::tAVX)) { if (src == h) { diff --git a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x64.avx.cpp b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x64.avx.cpp index 3fcaf59f0b..b248e1d36c 100644 --- a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x64.avx.cpp +++ b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x64.avx.cpp @@ -22,6 +22,9 @@ #include "PrecompiledHeader.h" #include "GSDrawScanlineCodeGenerator.h" #include "GSVertexSW.h" +#include "../../GS_codegen.h" + +#undef _t #if _M_SSE < 0x501 && (defined(_M_AMD64) || defined(_WIN64)) diff --git a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x64.avx2.cpp b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x64.avx2.cpp index a83907bf5b..8450593338 100644 --- a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x64.avx2.cpp +++ b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x64.avx2.cpp @@ -22,6 +22,9 @@ #include "PrecompiledHeader.h" #include "GSDrawScanlineCodeGenerator.h" #include "GSVertexSW.h" +#include "../../GS_codegen.h" + +#undef _t #if _M_SSE >= 0x501 && (defined(_M_AMD64) || defined(_WIN64)) diff --git a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x64.cpp b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x64.cpp index 31ba623367..7210a6593a 100644 --- a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x64.cpp +++ b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x64.cpp @@ -99,17 +99,17 @@ void GSDrawScanlineCodeGenerator::WriteFrame_SSE() { } -void GSDrawScanlineCodeGenerator::ReadPixel_SSE(const Xmm& dst, const Reg64& addr) +void GSDrawScanlineCodeGenerator::ReadPixel_SSE(const Xmm& dst, const RegLong& addr) { } -void GSDrawScanlineCodeGenerator::WritePixel_SSE(const Xmm& src, const Reg64& addr, const Reg8& mask, bool fast, int psm, int fz) +void GSDrawScanlineCodeGenerator::WritePixel_SSE(const Xmm& src, const RegLong& addr, const Reg8& mask, bool fast, int psm, int fz) { } //static const int s_offsets[4] = {0, 2, 8, 10}; -void GSDrawScanlineCodeGenerator::WritePixel_SSE(const Xmm& src, const Reg64& addr, uint8 i, int psm) +void GSDrawScanlineCodeGenerator::WritePixel_SSE(const Xmm& src, const RegLong& addr, uint8 i, int psm) { } diff --git a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x86.avx.cpp b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x86.avx.cpp index 49cf9c219c..f43e97c5d6 100644 --- a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x86.avx.cpp +++ b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x86.avx.cpp @@ -22,6 +22,7 @@ #include "PrecompiledHeader.h" #include "GSDrawScanlineCodeGenerator.h" #include "GSVertexSW.h" +#include "../../GS_codegen.h" #if _M_SSE < 0x501 && !(defined(_M_AMD64) || defined(_WIN64)) diff --git a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x86.avx2.cpp b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x86.avx2.cpp index a34a03f792..24bae9e7aa 100644 --- a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x86.avx2.cpp +++ b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x86.avx2.cpp @@ -22,6 +22,7 @@ #include "PrecompiledHeader.h" #include "GSDrawScanlineCodeGenerator.h" #include "GSVertexSW.h" +#include "../../GS_codegen.h" #if _M_SSE >= 0x501 && !(defined(_M_AMD64) || defined(_WIN64)) diff --git a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x86.cpp b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x86.cpp index 1a49c6e4f7..10b897cd5b 100644 --- a/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x86.cpp +++ b/pcsx2/GS/Renderers/SW/GSDrawScanlineCodeGenerator.x86.cpp @@ -22,6 +22,7 @@ #include "PrecompiledHeader.h" #include "GSDrawScanlineCodeGenerator.h" #include "GSVertexSW.h" +#include "../../GS_codegen.h" #if _M_SSE < 0x501 && !(defined(_M_AMD64) || defined(_WIN64)) diff --git a/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x64.avx.cpp b/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x64.avx.cpp index b69fb12328..151eec6fd1 100644 --- a/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x64.avx.cpp +++ b/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x64.avx.cpp @@ -23,11 +23,10 @@ #include "PrecompiledHeader.h" #include "GSSetupPrimCodeGenerator.h" #include "GSVertexSW.h" +#include "../../GS_codegen.h" #if _M_SSE < 0x501 && (defined(_M_AMD64) || defined(_WIN64)) -using namespace Xbyak; - #define _rip_local(field) (m_rip ? ptr[rip + &m_local.field] : ptr[t0 + offsetof(GSScanlineLocalData, field)]) #define _rip_local_v(field, offset) (m_rip ? ptr[rip + &m_local.field] : ptr[t0 + offset]) diff --git a/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x64.avx2.cpp b/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x64.avx2.cpp index ab3d82b143..8a982454ce 100644 --- a/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x64.avx2.cpp +++ b/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x64.avx2.cpp @@ -23,11 +23,10 @@ #include "PrecompiledHeader.h" #include "GSSetupPrimCodeGenerator.h" #include "GSVertexSW.h" +#include "../../GS_codegen.h" #if _M_SSE >= 0x501 && (defined(_M_AMD64) || defined(_WIN64)) -using namespace Xbyak; - #define _rip_local(field) (m_rip ? ptr[rip + &m_local.field] : ptr[t0 + offsetof(GSScanlineLocalData, field)]) #define _rip_local_v(field, offset) (m_rip ? ptr[rip + &m_local.field] : ptr[t0 + offset]) diff --git a/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x64.cpp b/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x64.cpp index 619a935c96..5a90d81409 100644 --- a/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x64.cpp +++ b/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x64.cpp @@ -22,11 +22,10 @@ #include "PrecompiledHeader.h" #include "GSSetupPrimCodeGenerator.h" #include "GSVertexSW.h" +#include "../../GS_codegen.h" #if _M_SSE < 0x501 && (defined(_M_AMD64) || defined(_WIN64)) -using namespace Xbyak; - void GSSetupPrimCodeGenerator::Generate_SSE() { #ifdef _WIN64 diff --git a/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x86.avx.cpp b/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x86.avx.cpp index b307a65358..40281c2f62 100644 --- a/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x86.avx.cpp +++ b/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x86.avx.cpp @@ -22,11 +22,10 @@ #include "PrecompiledHeader.h" #include "GSSetupPrimCodeGenerator.h" #include "GSVertexSW.h" +#include "../../GS_codegen.h" #if _M_SSE < 0x501 && !(defined(_M_AMD64) || defined(_WIN64)) -using namespace Xbyak; - static const int _args = 0; static const int _vertex = _args + 4; static const int _index = _args + 8; diff --git a/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x86.avx2.cpp b/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x86.avx2.cpp index 3a38cd76aa..a8fd0c2da4 100644 --- a/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x86.avx2.cpp +++ b/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x86.avx2.cpp @@ -22,11 +22,10 @@ #include "PrecompiledHeader.h" #include "GSSetupPrimCodeGenerator.h" #include "GSVertexSW.h" +#include "../../GS_codegen.h" #if _M_SSE >= 0x501 && !(defined(_M_AMD64) || defined(_WIN64)) -using namespace Xbyak; - static const int _args = 0; static const int _vertex = _args + 4; static const int _index = _args + 8; diff --git a/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x86.cpp b/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x86.cpp index d4006482c1..3b517406ae 100644 --- a/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x86.cpp +++ b/pcsx2/GS/Renderers/SW/GSSetupPrimCodeGenerator.x86.cpp @@ -22,11 +22,10 @@ #include "PrecompiledHeader.h" #include "GSSetupPrimCodeGenerator.h" #include "GSVertexSW.h" +#include "../../GS_codegen.h" #if _M_SSE < 0x501 && !(defined(_M_AMD64) || defined(_WIN64)) -using namespace Xbyak; - static const int _args = 0; static const int _vertex = _args + 4; static const int _index = _args + 8; diff --git a/pcsx2/GS/Renderers/SW/GSTextureSW.cpp b/pcsx2/GS/Renderers/SW/GSTextureSW.cpp index 9e06ae9fac..d053e6a946 100644 --- a/pcsx2/GS/Renderers/SW/GSTextureSW.cpp +++ b/pcsx2/GS/Renderers/SW/GSTextureSW.cpp @@ -21,7 +21,7 @@ #include "PrecompiledHeader.h" #include "GSTextureSW.h" -#include "GSPng.h" +#include "../../GSPng.h" GSTextureSW::GSTextureSW(int type, int width, int height) {