mirror of https://github.com/PCSX2/pcsx2.git
GS: Work around clang-cl issues
"error: inheritance model does not match definition" really means "Classes with virtual methods need to be compiled differently from those without in ms-abi, and you declared a pointer to member function, which needs to know what type of pointer to use, before clang knew about any virtual methods, so it guessed the wrong type".
This commit is contained in:
parent
3bb6eb16de
commit
b0e911ad7f
|
@ -22,7 +22,7 @@
|
|||
|
||||
class GSLocalMemory;
|
||||
|
||||
class alignas(32) GSClut : public GSAlignedClass<32>
|
||||
class alignas(32) GSClut final : public GSAlignedClass<32>
|
||||
{
|
||||
static const GSVector4i m_bm;
|
||||
static const GSVector4i m_gm;
|
||||
|
@ -99,7 +99,7 @@ private:
|
|||
|
||||
public:
|
||||
GSClut(GSLocalMemory* mem);
|
||||
virtual ~GSClut();
|
||||
~GSClut();
|
||||
|
||||
bool InvalidateRange(u32 start_block, u32 end_block, bool is_draw = false);
|
||||
u8 IsInvalid();
|
||||
|
|
|
@ -438,7 +438,7 @@ class GSLocalMemory;
|
|||
MULTI_ISA_DEF(class GSLocalMemoryFunctions;)
|
||||
MULTI_ISA_DEF(void GSLocalMemoryPopulateFunctions(GSLocalMemory& mem);)
|
||||
|
||||
class GSLocalMemory : public GSAlignedClass<32>
|
||||
class GSLocalMemory final : public GSAlignedClass<32>
|
||||
{
|
||||
MULTI_ISA_FRIEND(GSLocalMemoryFunctions)
|
||||
|
||||
|
@ -523,7 +523,7 @@ protected:
|
|||
|
||||
public:
|
||||
GSLocalMemory();
|
||||
virtual ~GSLocalMemory();
|
||||
~GSLocalMemory();
|
||||
|
||||
__forceinline u16* vm16() const { return reinterpret_cast<u16*>(m_vm8); }
|
||||
__forceinline u32* vm32() const { return reinterpret_cast<u32*>(m_vm8); }
|
||||
|
|
|
@ -44,6 +44,11 @@ typedef bool (*GetSkipCount)(const GSFrameInfo& fi, int& skip);
|
|||
|
||||
class GSState : public GSAlignedClass<32>
|
||||
{
|
||||
public:
|
||||
GSState();
|
||||
virtual ~GSState();
|
||||
|
||||
private:
|
||||
// RESTRICT prevents multiple loads of the same part of the register when accessing its bitfields (the compiler is happy to know that memory writes in-between will not go there)
|
||||
|
||||
typedef void (GSState::*GIFPackedRegHandler)(const GIFPackedReg* RESTRICT r);
|
||||
|
@ -331,9 +336,6 @@ public:
|
|||
};
|
||||
|
||||
public:
|
||||
GSState();
|
||||
virtual ~GSState();
|
||||
|
||||
/// Returns the appropriate directory for draw dumping.
|
||||
static std::string GetDrawDumpPath(const char* format, ...);
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@ class GSVertexTrace;
|
|||
MULTI_ISA_DEF(class GSVertexTraceFMM;)
|
||||
MULTI_ISA_DEF(void GSVertexTracePopulateFunctions(GSVertexTrace& vt, bool provoking_vertex_first);)
|
||||
|
||||
class alignas(32) GSVertexTrace : public GSAlignedClass<32>
|
||||
class alignas(32) GSVertexTrace final : public GSAlignedClass<32>
|
||||
{
|
||||
MULTI_ISA_FRIEND(GSVertexTraceFMM)
|
||||
|
||||
|
@ -76,7 +76,6 @@ public:
|
|||
|
||||
public:
|
||||
GSVertexTrace(const GSState* state, bool provoking_vertex_first);
|
||||
virtual ~GSVertexTrace() {}
|
||||
|
||||
void Update(const void* vertex, const u32* index, int v_count, int i_count, GS_PRIM_CLASS primclass);
|
||||
|
||||
|
|
|
@ -71,6 +71,15 @@ public:
|
|||
class IDrawScanline : public GSAlignedClass<32>
|
||||
{
|
||||
public:
|
||||
IDrawScanline()
|
||||
: m_sp(NULL)
|
||||
, m_ds(NULL)
|
||||
, m_de(NULL)
|
||||
, m_dr(NULL)
|
||||
{
|
||||
}
|
||||
virtual ~IDrawScanline() {}
|
||||
|
||||
typedef void (*SetupPrimPtr)(const GSVertexSW* vertex, const u32* index, const GSVertexSW& dscan);
|
||||
typedef void (*DrawScanlinePtr)(int pixels, int left, int top, const GSVertexSW& scan);
|
||||
typedef void (IDrawScanline::*DrawRectPtr)(const GSVector4i& r, const GSVertexSW& v); // TODO: jit
|
||||
|
@ -82,15 +91,6 @@ protected:
|
|||
DrawRectPtr m_dr;
|
||||
|
||||
public:
|
||||
IDrawScanline()
|
||||
: m_sp(NULL)
|
||||
, m_ds(NULL)
|
||||
, m_de(NULL)
|
||||
, m_dr(NULL)
|
||||
{
|
||||
}
|
||||
virtual ~IDrawScanline() {}
|
||||
|
||||
virtual void BeginDraw(const GSRasterizerData* data) = 0;
|
||||
virtual void EndDraw(u64 frame, u64 ticks, int actual, int total, int prims) = 0;
|
||||
|
||||
|
|
Loading…
Reference in New Issue