tlb.hh (5358:e9acb84bbafb) | tlb.hh (5543:3af77710f397) |
---|---|
1/* 2 * Copyright (c) 2001-2005 The Regents of The University of Michigan 3 * Copyright (c) 2007 MIPS Technologies, Inc. 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions are 8 * met: redistributions of source code must retain the above copyright --- 70 unchanged lines hidden (view full) --- 79 } 80 81}; 82 83class TLB : public BaseTLB 84{ 85 protected: 86 typedef std::multimap<Addr, int> PageTable; | 1/* 2 * Copyright (c) 2001-2005 The Regents of The University of Michigan 3 * Copyright (c) 2007 MIPS Technologies, Inc. 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions are 8 * met: redistributions of source code must retain the above copyright --- 70 unchanged lines hidden (view full) --- 79 } 80 81}; 82 83class TLB : public BaseTLB 84{ 85 protected: 86 typedef std::multimap<Addr, int> PageTable; |
87 PageTable lookupTable; // Quick lookup into page table | 87 PageTable lookupTable; // Quick lookup into page table |
88 | 88 |
89 MipsISA::PTE *table; // the Page Table 90 int size; // TLB Size 91 int nlu; // not last used entry (for replacement) | 89 MipsISA::PTE *table; // the Page Table 90 int size; // TLB Size 91 int nlu; // not last used entry (for replacement) |
92 93 void nextnlu() { if (++nlu >= size) nlu = 0; } 94 MipsISA::PTE *lookup(Addr vpn, uint8_t asn) const; 95 96 mutable Stats::Scalar<> read_hits; 97 mutable Stats::Scalar<> read_misses; 98 mutable Stats::Scalar<> read_acv; 99 mutable Stats::Scalar<> read_accesses; --- 68 unchanged lines hidden --- | 92 93 void nextnlu() { if (++nlu >= size) nlu = 0; } 94 MipsISA::PTE *lookup(Addr vpn, uint8_t asn) const; 95 96 mutable Stats::Scalar<> read_hits; 97 mutable Stats::Scalar<> read_misses; 98 mutable Stats::Scalar<> read_acv; 99 mutable Stats::Scalar<> read_accesses; --- 68 unchanged lines hidden --- |