mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-09 16:31:28 +12:00
Improved ID manager.
Improved MemoryBlock.
This commit is contained in:
parent
159b6ecea3
commit
ab41540064
27 changed files with 813 additions and 767 deletions
|
@ -3,22 +3,25 @@
|
|||
|
||||
RawSPUThread::RawSPUThread(u32 index, CPUThreadType type)
|
||||
: SPUThread(type)
|
||||
, MemoryBlock()
|
||||
, m_index(index)
|
||||
{
|
||||
Memory.MemoryBlocks.Add(MemoryBlock::SetRange(RAW_SPU_BASE_ADDR + RAW_SPU_OFFSET * index, RAW_SPU_OFFSET));
|
||||
Memory.MemoryBlocks.push_back(SetRange(RAW_SPU_BASE_ADDR + RAW_SPU_OFFSET * index, RAW_SPU_OFFSET));
|
||||
Reset();
|
||||
}
|
||||
|
||||
RawSPUThread::~RawSPUThread()
|
||||
{
|
||||
for(int i=0; i<Memory.MemoryBlocks.GetCount(); ++i)
|
||||
for(int i=0; i<Memory.MemoryBlocks.size(); ++i)
|
||||
{
|
||||
if(&Memory.MemoryBlocks[i] == this)
|
||||
if(Memory.MemoryBlocks[i]->GetStartAddr() == GetStartAddr())
|
||||
{
|
||||
Memory.MemoryBlocks.RemoveFAt(i);
|
||||
return;
|
||||
Memory.MemoryBlocks.erase(Memory.MemoryBlocks.begin() + i);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Close();
|
||||
}
|
||||
|
||||
bool RawSPUThread::Read8(const u64 addr, u8* value)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue