Skip to content

Java simulators for testing various page replacement schemes. Which one is the best?

License

Notifications You must be signed in to change notification settings

jrquick17/java-page-replacement-strategies

Repository files navigation

java-page-replacement-strategies

Index

About

Java simulators for testing various page replacement schemes. Which one is the best?

Process

The program uses three different types of reference strings to test the strategies against varying input. The first type is the random which randomly chooses the next page in memory, then there is the loop which takes in pages in a cyclical pattern with a few random pages thrown in to closer mimic reality. To calculate efficiency I measured the program measures both the time it takes to simulate and the number of page faults occurred.

Run

Clone

  • Clone the repository

    git clone git@github.com:jrquick17/java-page-replacement-strategies.git

Compile

  • Compile project

    javac src/*.java -d target/

Run

  • Run Simulator

    java -cp target/ Simulator

  • Run First In First Out (FIFO)

    java -cp target/ FIFO

  • Run Least Recently Used (LRU))

    java -cp target/ LRU

  • Run LRUa

    java -cp target/ LRUa

  • Run Most Used

    java -cp target/ MostUsed

  • Run Optimal

    java -cp target/ Optimal

  • Run Random

    java -cp target/ Random

Contributing

To contribute, submit any pull request and I will have look.

Issues

If you find any issues feel free to open a request in the Issues tab. If I have the time I will try to solve any issues but cannot make any guarantees. Feel free to contribute yourself.

Thanks

Future Plans

  • Run using Java 8
  • Add Adaptive Replacement Cache (ARC)
  • Add Belady's Algorith
  • Add Clock with Adaptive Replacement (CAR)
  • Add Last In First Out (LIFO)
  • Add Least Frequently Used (LFU)
  • Add LFU with Dynamic Aging (LFUDA)
  • Add Low Inter-Reference Recency Set (LIRS)
  • Add Most Recently Used (MRU)
  • Add Multi Queue (MQ)
  • Add Panier
  • Add Psuedo-LRU)
  • Add Segmented Least Recently Used (SLRU)
  • Add Time Aware Least Recently Used (TLRU)

About

Java simulators for testing various page replacement schemes. Which one is the best?

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages