38#ifndef __MEM_CACHE_TAGS_PARTITIONING_POLICIES_MAX_CAPACITY_HH__
39#define __MEM_CACHE_TAGS_PARTITIONING_POLICIES_MAX_CAPACITY_HH__
41#include <unordered_map>
44#include "debug/PartitionPolicy.hh"
47#include "params/BasePartitioningPolicy.hh"
48#include "params/MaxCapacityPartitioningPolicy.hh"
53namespace partitioning_policy
70 (
const MaxCapacityPartitioningPolicyParams &
params);
74 const uint64_t partition_id)
const override;
Definitions of a simple cache block class.
A Partitioning Policy is a cache partitioning mechanism that limits the cache block allocations in a ...
A MaxCapacityPartitioningPolicy filters the cache blocks available to a memory requestor (identified ...
void notifyAcquire(const uint64_t partition_id) override
Notify of acquisition of ownership of a cache line.
const uint64_t blkSize
Cache block size in number of bytes.
void notifyRelease(const uint64_t partition_id) override
Notify of release of ownership of a cache line.
std::unordered_map< uint64_t, uint64_t > partitionIdMaxCapacity
Map of PartitionIDs and maximum allocatable cache block counts; On evictions full partitions are prio...
std::unordered_map< uint64_t, uint64_t > partitionIdCurCapacity
Map of PartitionIDs and currently allocated blck coutns.
const uint64_t cacheSize
Cache size in number of bytes.
const std::vector< uint64_t > partitionIDs
Vector of partitionIDs the policy operates on.
MaxCapacityPartitioningPolicy(const MaxCapacityPartitioningPolicyParams ¶ms)
const std::vector< double > capacities
Vector of capacity fractions to enforce on the policied partitionIDs.
void filterByPartition(std::vector< ReplaceableEntry * > &entries, const uint64_t partition_id) const override
Filters the allocatable cache blocks for a memory request based on its PartitionID and policy allocat...
const Params & params() const
Copyright (c) 2024 - Pranith Kumar Copyright (c) 2020 Inria All rights reserved.