- m5::hash_map<Addr,Addr>::iterator iter = pTable.find(vaddr);
-
- if (iter != pTable.end()) {
- // already mapped
- fatal("PageTable::allocate: address 0x%x already mapped", vaddr);
- }
-
- pTable[vaddr] = system->new_page();
- pTableCache[2].paddr = pTableCache[1].paddr;
- pTableCache[2].vaddr = pTableCache[1].vaddr;
- pTableCache[1].paddr = pTableCache[0].paddr;
- pTableCache[1].vaddr = pTableCache[0].vaddr;
- pTableCache[0].paddr = pTable[vaddr];
- pTableCache[0].vaddr = vaddr;