gem5
v19.0.0.0
Main Page
Related Pages
Modules
+
Namespaces
Namespace List
+
Namespace Members
+
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Functions
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
+
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Typedefs
a
b
c
d
e
f
g
h
i
m
n
o
p
r
s
t
u
v
w
x
+
Enumerations
a
b
c
d
e
f
i
l
m
o
p
r
s
t
v
x
+
Enumerator
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
+
Classes
Class List
Class Index
Class Hierarchy
+
Class Members
+
All
:
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
+
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Typedefs
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
y
+
Enumerations
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
w
+
Enumerator
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
+
Related Functions
:
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
+
Files
File List
+
File Members
+
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
+
Functions
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
z
+
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
z
+
Typedefs
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
+
Enumerations
a
b
c
d
e
f
g
i
l
m
o
p
r
s
t
v
w
+
Enumerator
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
u
v
w
x
+
Macros
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Modules
Pages
mem
cache
replacement_policies
lru_rp.hh
Go to the documentation of this file.
1
37
#ifndef __MEM_CACHE_REPLACEMENT_POLICIES_LRU_RP_HH__
38
#define __MEM_CACHE_REPLACEMENT_POLICIES_LRU_RP_HH__
39
40
#include "
mem/cache/replacement_policies/base.hh
"
41
42
struct
LRURPParams;
43
44
class
LRURP
:
public
BaseReplacementPolicy
45
{
46
protected
:
48
struct
LRUReplData
:
ReplacementData
49
{
51
Tick
lastTouchTick
;
52
56
LRUReplData
() : lastTouchTick(0) {}
57
};
58
59
public
:
61
typedef
LRURPParams
Params
;
62
66
LRURP
(
const
Params *
p
);
67
71
~LRURP
() {}
72
79
void
invalidate
(
const
std::shared_ptr<ReplacementData>& replacement_data)
80
const override
;
81
88
void
touch
(
const
std::shared_ptr<ReplacementData>& replacement_data)
const
89
override
;
90
97
void
reset
(
const
std::shared_ptr<ReplacementData>& replacement_data)
const
98
override
;
99
106
ReplaceableEntry
*
getVictim
(
const
ReplacementCandidates
& candidates)
const
107
override
;
108
114
std::shared_ptr<ReplacementData>
instantiateEntry
()
override
;
115
};
116
117
#endif // __MEM_CACHE_REPLACEMENT_POLICIES_LRU_RP_HH__
LRURP::invalidate
void invalidate(const std::shared_ptr< ReplacementData > &replacement_data) const override
Invalidate replacement data to set it as the next probable victim.
Definition:
lru_rp.cc:44
LRURP::LRURP
LRURP(const Params *p)
Construct and initiliaze this replacement policy.
Definition:
lru_rp.cc:38
LRURP::LRUReplData::LRUReplData
LRUReplData()
Default constructor.
Definition:
lru_rp.hh:56
BaseReplacementPolicy
A common base class of cache replacement policy objects.
Definition:
base.hh:48
std::vector
STL vector class.
Definition:
stl.hh:40
LRURP::LRUReplData
LRU-specific implementation of replacement data.
Definition:
lru_rp.hh:48
ReplacementData
Copyright (c) 2018 Inria All rights reserved.
Definition:
replaceable_entry.hh:43
Tick
uint64_t Tick
Tick count type.
Definition:
types.hh:63
LRURP::Params
LRURPParams Params
Convenience typedef.
Definition:
lru_rp.hh:61
LRURP
Definition:
lru_rp.hh:44
LRURP::reset
void reset(const std::shared_ptr< ReplacementData > &replacement_data) const override
Reset replacement data.
Definition:
lru_rp.cc:61
LRURP::getVictim
ReplaceableEntry * getVictim(const ReplacementCandidates &candidates) const override
Find replacement victim using LRU timestamps.
Definition:
lru_rp.cc:69
LRURP::~LRURP
~LRURP()
Destructor.
Definition:
lru_rp.hh:71
LRURP::instantiateEntry
std::shared_ptr< ReplacementData > instantiateEntry() override
Instantiate a replacement data entry.
Definition:
lru_rp.cc:90
ReplaceableEntry
A replaceable entry is a basic entry in a 2d table-like structure that needs to have replacement func...
Definition:
replaceable_entry.hh:55
LRURP::touch
void touch(const std::shared_ptr< ReplacementData > &replacement_data) const override
Touch an entry to update its replacement data.
Definition:
lru_rp.cc:53
base.hh
LRURP::LRUReplData::lastTouchTick
Tick lastTouchTick
Tick on which the entry was last touched.
Definition:
lru_rp.hh:51
MipsISA::p
Bitfield< 0 > p
Definition:
pra_constants.hh:325
Generated on Fri Feb 28 2020 16:27:02 for gem5 by
doxygen
1.8.13