simulator: Reworked stack cache, fixing latencies

* Moved code into .cc file
* Split stack cache update into EX and MW stage
* Fixed latencies of s5,s6
* Added stack cache spill test