CacheSim/set.h

22 lines
426 B
C++

#include "block.h"
#include <vector>
using std::vector;
using CacheSim::Block;
namespace CacheSim{
class Set
{
private:
short waySize;
short emptySize;
short replacePolicy;
vector<Block> blocks;
public:
Set(short waySize, short tagSize, short replacePolicy);
bool read(vector<bool> tag, short offset);
void countAccess(short baseAccessTime);
};
}