mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-04 14:08:37 +00:00
Memory cleanup, page flags implemented
RSXCMDMem, SPRXMem, MmaperMem removed MainMem range fixed
This commit is contained in:
parent
0eebfb0aaa
commit
267de68441
23 changed files with 259 additions and 260 deletions
|
|
@ -22,8 +22,6 @@ struct MemInfo
|
|||
|
||||
struct MemBlockInfo : public MemInfo
|
||||
{
|
||||
void *mem;
|
||||
|
||||
MemBlockInfo(u32 addr, u32 size);
|
||||
|
||||
void Free();
|
||||
|
|
@ -32,27 +30,26 @@ struct MemBlockInfo : public MemInfo
|
|||
|
||||
MemBlockInfo(MemBlockInfo &&other)
|
||||
: MemInfo(other.addr,other.size)
|
||||
, mem(other.mem)
|
||||
{
|
||||
other.mem = nullptr;
|
||||
other.addr = 0;
|
||||
other.size = 0;
|
||||
}
|
||||
|
||||
MemBlockInfo& operator =(MemBlockInfo &other) = delete;
|
||||
|
||||
MemBlockInfo& operator =(MemBlockInfo &&other)
|
||||
{
|
||||
this->Free();
|
||||
Free();
|
||||
this->addr = other.addr;
|
||||
this->size = other.size;
|
||||
this->mem = other.mem;
|
||||
other.mem = nullptr;
|
||||
other.addr = 0;
|
||||
other.size = 0;
|
||||
return *this;
|
||||
}
|
||||
|
||||
~MemBlockInfo()
|
||||
{
|
||||
Free();
|
||||
mem = nullptr;
|
||||
}
|
||||
};
|
||||
|
||||
|
|
@ -76,7 +73,6 @@ struct VirtualMemInfo : public MemInfo
|
|||
class MemoryBlock
|
||||
{
|
||||
protected:
|
||||
u8* mem;
|
||||
u32 range_start;
|
||||
u32 range_size;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue