PCSX2 VU: Linux compilation fix and force 16 bytes alignement for VURegs

Spu2x: Use a standard destructor (POD safe stuff). Fix various segmentation faults (Issue 846)


git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3702 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
gregory.hainaut@gmail.com 2010-08-30 20:39:04 +00:00
parent a23c5e75b7
commit 393333456c
2 changed files with 5 additions and 4 deletions

View File

@ -116,7 +116,7 @@ struct ialuPipe {
u32 Cycle;
};
struct VURegs {
struct __aligned16 VURegs {
VECTOR VF[32]; // VF and VI need to be first in this struct for proper mapping
REG_VI VI[32]; // needs to be 128bit x 32 (cottonvibes)
@ -190,8 +190,9 @@ extern __aligned16 VURegs vuRegs[2];
static VURegs& VU0 = vuRegs[0];
static VURegs& VU1 = vuRegs[1];
__fi bool VURegs::IsVU1() const { return this == &vuRegs[1]; }
__fi bool VURegs::IsVU0() const { return this == &vuRegs[0]; }
// Do not use __fi here because it fires 'multiple definition' error in GCC
inline bool VURegs::IsVU1() const { return this == &vuRegs[1]; }
inline bool VURegs::IsVU0() const { return this == &vuRegs[0]; }
extern u32* GET_VU_MEM(VURegs* VU, u32 addr);

View File

@ -446,7 +446,7 @@ struct V_Core
// uninitialized constructor
V_Core() : Index( -1 ), DMAPtr( NULL ) {}
V_Core( int idx ); // our badass constructor
virtual ~V_Core() throw();
~V_Core() throw();
void Reset( int index );
void Init( int index );