gem5
v22.0.0.1
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
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
l
m
n
o
p
q
r
s
t
u
v
w
x
Enumerations
_
a
b
c
d
e
f
g
h
i
k
l
m
o
p
q
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
n
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
k
l
m
n
o
p
q
r
s
t
u
v
w
x
Functions
a
b
c
d
e
f
g
h
i
l
m
n
o
p
s
t
v
Variables
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
Typedefs
a
b
c
d
g
h
i
l
m
r
s
t
u
w
Enumerations
b
h
i
o
p
Enumerator
h
i
o
Macros
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Modules
Pages
mem
cache
replacement_policies
second_chance_rp.hh
Go to the documentation of this file.
1
38
#ifndef __MEM_CACHE_REPLACEMENT_POLICIES_SECOND_CHANCE_RP_HH__
39
#define __MEM_CACHE_REPLACEMENT_POLICIES_SECOND_CHANCE_RP_HH__
40
41
#include "
mem/cache/replacement_policies/base.hh
"
42
#include "
mem/cache/replacement_policies/fifo_rp.hh
"
43
44
namespace
gem5
45
{
46
47
struct
SecondChanceRPParams;
48
49
GEM5_DEPRECATED_NAMESPACE
(ReplacementPolicy, replacement_policy);
50
namespace
replacement_policy
51
{
52
53
class
SecondChance
:
public
FIFO
54
{
55
protected
:
57
struct
SecondChanceReplData
:
public
FIFOReplData
58
{
64
bool
hasSecondChance
;
65
69
SecondChanceReplData
() :
FIFOReplData
(),
hasSecondChance
(false) {}
70
};
71
77
void
useSecondChance
(
78
const
std::shared_ptr<SecondChanceReplData>& replacement_data)
const
;
79
80
public
:
81
typedef
SecondChanceRPParams
Params
;
82
SecondChance
(
const
Params
&
p
);
83
~SecondChance
() =
default
;
84
92
void
invalidate
(
const
std::shared_ptr<ReplacementData>& replacement_data)
93
override
;
94
100
void
touch
(
const
std::shared_ptr<ReplacementData>& replacement_data)
const
101
override
;
102
110
void
reset
(
const
std::shared_ptr<ReplacementData>& replacement_data)
const
111
override
;
112
120
ReplaceableEntry
*
getVictim
(
const
ReplacementCandidates
& candidates)
const
121
override
;
122
128
std::shared_ptr<ReplacementData>
instantiateEntry
()
override
;
129
};
130
131
}
// namespace replacement_policy
132
}
// namespace gem5
133
134
#endif // __MEM_CACHE_REPLACEMENT_POLICIES_SECOND_CHANCE_RP_HH__
gem5::replacement_policy::SecondChance::touch
void touch(const std::shared_ptr< ReplacementData > &replacement_data) const override
Touch an entry to update its re-insertion tick and second chance bit.
Definition:
second_chance_rp.cc:70
fifo_rp.hh
Copyright (c) 2018-2020 Inria All rights reserved.
gem5::replacement_policy::SecondChance::SecondChanceReplData::SecondChanceReplData
SecondChanceReplData()
Default constructor.
Definition:
second_chance_rp.hh:69
gem5::replacement_policy::Base::Params
BaseReplacementPolicyParams Params
Definition:
base.hh:58
std::vector
STL vector class.
Definition:
stl.hh:37
gem5::replacement_policy::SecondChance::Params
SecondChanceRPParams Params
Definition:
second_chance_rp.hh:81
gem5::replacement_policy::SecondChance::SecondChanceReplData::hasSecondChance
bool hasSecondChance
This is different from isTouched because isTouched accounts only for insertion, while this bit is res...
Definition:
second_chance_rp.hh:64
gem5::VegaISA::p
Bitfield< 54 > p
Definition:
pagetable.hh:70
gem5::replacement_policy::SecondChance::SecondChance
SecondChance(const Params &p)
Definition:
second_chance_rp.cc:42
gem5::replacement_policy::SecondChance::instantiateEntry
std::shared_ptr< ReplacementData > instantiateEntry() override
Instantiate a replacement data entry.
Definition:
second_chance_rp.cc:136
gem5::replacement_policy::SecondChance::invalidate
void invalidate(const std::shared_ptr< ReplacementData > &replacement_data) override
Invalidate replacement data to set it as the next probable victim.
Definition:
second_chance_rp.cc:59
gem5::replacement_policy::SecondChance::SecondChanceReplData
Second-Chance-specific implementation of replacement data.
Definition:
second_chance_rp.hh:57
base.hh
gem5::GEM5_DEPRECATED_NAMESPACE
GEM5_DEPRECATED_NAMESPACE(GuestABI, guest_abi)
gem5::replacement_policy::SecondChance::getVictim
ReplaceableEntry * getVictim(const ReplacementCandidates &candidates) const override
Find replacement victim using insertion timestamps and second chance bit.
Definition:
second_chance_rp.cc:92
gem5::replacement_policy::FIFO
Definition:
fifo_rp.hh:51
gem5::replacement_policy::SecondChance::~SecondChance
~SecondChance()=default
gem5::replacement_policy::SecondChance::reset
void reset(const std::shared_ptr< ReplacementData > &replacement_data) const override
Reset replacement data.
Definition:
second_chance_rp.cc:81
gem5::replacement_policy::SecondChance::useSecondChance
void useSecondChance(const std::shared_ptr< SecondChanceReplData > &replacement_data) const
Use replacement data's second chance.
Definition:
second_chance_rp.cc:48
gem5::ReplaceableEntry
A replaceable entry is a basic entry in a 2d table-like structure that needs to have replacement func...
Definition:
replaceable_entry.hh:63
gem5::replacement_policy::SecondChance
Definition:
second_chance_rp.hh:53
gem5::replacement_policy::FIFO::FIFOReplData
FIFO-specific implementation of replacement data.
Definition:
fifo_rp.hh:55
gem5
Reference material can be found at the JEDEC website: UFS standard http://www.jedec....
Definition:
gpu_translation_state.hh:37
Generated on Wed Jul 13 2022 10:39:23 for gem5 by
doxygen
1.8.17