Giter Site home page Giter Site logo

cache-replacement-algorithm-simulator's Introduction

Cache Simulator - CO262 Course Project

This project is a Cache Simulator designed specifically to analyze the performance of Advanced Cache Replacement Algorithms. The simulator is a cpp program which can simulate cache replacement algorithms like :

  1. SRRIP : Static Re-Reference Interval Prediction
  2. LRU : Least recently used
  3. NRU : Not recently used
  4. LFU : Least frequently used
  5. FIFO : First in first out
  6. PLRU : Pseudo Least recently used
  7. ARC : Adaptive replacement cache

Getting Started

Make sure you have the latest g++ compiler installed on your system.

Clone this github repository

git clone https://github.com/vybhavpai/Cache-Replacement-Algorithm-Simulator

Download the traces from here (Click on Link to download):

Trace - Row Major Matrix Multiplication

Trace - Tile

Trace - Regular Matrix Multiplication

After downloading the traces move them into the repository.

Simulate Cache Replacement Algorithm

To compile and run the simulator on traces:

Step 1 :

$ g++ simulator.cpp

Step 2:

$ gzip -dc (trace_name.gz) | ./a.out (replacement_algorithm in small) (no_of_ways) (block_size)

Step 3:

Wait for 15 - 20 minutes for each simulation. 

Example

$ g++ simulator.cpp
$ gzip -dc trace_tile.gz | ./a.out srrip 2 32

Now wait for some time.....

The result will appear something like this:

103284902 is number of hits 103745282 is total input
0.995562 is hit ratio
73678224 is number of reads 
30067058 number of writes 
456979487 is total number of clock cycles
That's all folks!!!

Authors

  • Vybhav Pai - 171CO252
  • Avakash Bhat - 171CO110
  • Shrinidhi Varna - 171CO145
  • Ankit Jain - 171CO208
  • Abhinav P Y - 171CO103
  • Arqum Shaikh - 171CO241
  • Chaitany Pandiya - 171CO112

Acknowledgments

  • Thanks to Dr. Basavaraj Talwar our course instructor for CO262 - Systems Programming for giving us a chance to do this project.
  • Thanks to Leslie Monis and Aditya Kamath for helping out with problems.

cache-replacement-algorithm-simulator's People

Contributors

ab261 avatar abhinavpy avatar chaitany10 avatar jain2anki avatar jainank2 avatar shrinidhi99 avatar vybhavpai avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.