A scala cache simulator