38#ifndef __DEV_ARM_SMMU_V3_CACHES_HH__
39#define __DEV_ARM_SMMU_V3_CACHES_HH__
52#define WALK_CACHE_LEVELS 4
75 const std::string &
name);
130 SMMUTLB(
unsigned numEntries,
unsigned _associativity,
132 const std::string &
name);
136 const Entry *
lookup(uint32_t sid, uint32_t ssid,
Addr va,
138 const Entry *
lookupAnyVA(uint32_t sid, uint32_t ssid,
156 size_t pickSetIdx(uint32_t sid, uint32_t ssid)
const;
180 ARMArchTLB(
unsigned numEntries,
unsigned _associativity,
187 void store(
const Entry &incoming);
223 IPACache(
unsigned numEntries,
unsigned _associativity,
227 const Entry *
lookup(
Addr ipa, uint16_t vmid,
bool updStats=
true);
228 void store(
const Entry &incoming);
271 ConfigCache(
unsigned numEntries,
unsigned _associativity,
275 const Entry *
lookup(uint32_t sid, uint32_t ssid,
bool updStats=
true);
276 void store(
const Entry &incoming);
288 size_t pickSetIdx(uint32_t sid, uint32_t ssid)
const;
314 WalkCache(
const std::array<unsigned, 2*WALK_CACHE_LEVELS> &_sizes,
315 unsigned _associativity,
const std::string &policy,
320 unsigned stage,
unsigned level,
bool updStats=
true);
321 void store(
const Entry &incoming);
324 const bool leaf_only);
354 std::array<unsigned, 2*WALK_CACHE_LEVELS>
sizes;
355 std::array<unsigned, 2*WALK_CACHE_LEVELS>
offsets;
358 unsigned stage,
unsigned level)
const;
361 unsigned stage,
unsigned level);
Defines global host-dependent types: Counter, Tick, and (indirectly) {int,uint}{8,...
void invalidateVAA(Addr va, uint16_t vmid)
size_t pickEntryIdxToReplace(const Set &set)
void invalidateVA(Addr va, uint16_t asid, uint16_t vmid)
void store(const Entry &incoming)
size_t pickSetIdx(Addr va, uint16_t asid, uint16_t vmid) const
ARMArchTLB(unsigned numEntries, unsigned _associativity, const std::string &policy, statistics::Group *parent)
void invalidateVMID(uint16_t vmid)
void invalidateASID(uint16_t asid, uint16_t vmid)
const Entry * lookup(Addr va, uint16_t asid, uint16_t vmid, bool updStats=true)
size_t pickSetIdx(uint32_t sid, uint32_t ssid) const
void invalidateSID(uint32_t sid)
const Entry * lookup(uint32_t sid, uint32_t ssid, bool updStats=true)
ConfigCache(unsigned numEntries, unsigned _associativity, const std::string &policy, statistics::Group *parent)
void store(const Entry &incoming)
void invalidateSSID(uint32_t sid, uint32_t ssid)
size_t pickEntryIdxToReplace(const Set &set)
void store(const Entry &incoming)
const Entry * lookup(Addr ipa, uint16_t vmid, bool updStats=true)
void invalidateIPAA(Addr ipa)
IPACache(unsigned numEntries, unsigned _associativity, const std::string &policy, statistics::Group *parent)
size_t pickSetIdx(Addr ipa, uint16_t vmid) const
size_t pickEntryIdxToReplace(const Set &set)
void invalidateVMID(uint16_t vmid)
void invalidateIPA(Addr ipa, uint16_t vmid)
void invalidateSID(uint32_t sid)
SMMUTLB(unsigned numEntries, unsigned _associativity, const std::string &policy, statistics::Group *parent, const std::string &name)
const Entry * lookupAnyVA(uint32_t sid, uint32_t ssid, bool updStats=true)
void invalidateVAA(Addr va, uint16_t vmid)
void invalidateASID(uint16_t asid, uint16_t vmid)
void store(const Entry &incoming, AllocPolicy alloc)
const Entry * lookup(uint32_t sid, uint32_t ssid, Addr va, bool updStats=true)
size_t pickSetIdx(uint32_t sid, uint32_t ssid) const
void invalidateVMID(uint16_t vmid)
SMMUTLB(const SMMUTLB &tlb)=delete
size_t pickEntryIdxToReplace(const Set &set, AllocPolicy alloc)
void invalidateVA(Addr va, uint16_t asid, uint16_t vmid)
void invalidateSSID(uint32_t sid, uint32_t ssid)
static int decodePolicyName(const std::string &policy_name)
SMMUv3BaseCache(const std::string &policy_name, uint32_t seed, statistics::Group *parent, const std::string &name)
gem5::SMMUv3BaseCache::SMMUv3BaseCacheStats baseCacheStats
virtual ~SMMUv3BaseCache()
void store(const Entry &incoming)
const Entry * lookup(Addr va, Addr vaMask, uint16_t asid, uint16_t vmid, unsigned stage, unsigned level, bool updStats=true)
void invalidateVAA(Addr va, uint16_t vmid, const bool leaf_only)
size_t pickEntryIdxToReplace(const Set &set, unsigned stage, unsigned level)
void invalidateVMID(uint16_t vmid)
void invalidateASID(uint16_t asid, uint16_t vmid)
size_t pickSetIdx(Addr va, Addr vaMask, unsigned stage, unsigned level) const
std::array< unsigned, 2 *WALK_CACHE_LEVELS > sizes
gem5::WalkCache::WalkCacheStats walkCacheStats
std::array< unsigned, 2 *WALK_CACHE_LEVELS > offsets
void invalidateVA(Addr va, uint16_t asid, uint16_t vmid, const bool leaf_only)
WalkCache(const std::array< unsigned, 2 *WALK_CACHE_LEVELS > &_sizes, unsigned _associativity, const std::string &policy, statistics::Group *parent)
This is a simple scalar statistic, like a counter.
A 2-Dimensional vecto of scalar stats.
Copyright (c) 2024 - Pranith Kumar Copyright (c) 2020 Inria All rights reserved.
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
@ SMMU_CACHE_REPL_ROUND_ROBIN
Declaration of Statistics objects.
statistics::Formula averageLookups
statistics::Formula averageHitRate
statistics::Scalar insertions
statistics::Scalar totalMisses
statistics::Formula averageUpdates
statistics::Scalar totalUpdates
statistics::Scalar totalLookups
statistics::Formula averageMisses
SMMUv3BaseCacheStats(statistics::Group *parent, const std::string &name)
statistics::Vector2d totalLookupsByStageLevel
statistics::Vector2d totalMissesByStageLevel
WalkCacheStats(statistics::Group *parent)
std::vector< statistics::Formula * > averageMissesByStageLevel
statistics::Vector2d insertionsByStageLevel
std::vector< statistics::Formula * > averageHitRateByStageLevel
std::vector< statistics::Formula * > averageUpdatesByStageLevel
std::vector< statistics::Formula * > averageLookupsByStageLevel
statistics::Vector2d totalUpdatesByStageLevel
const std::string & name()