Updated the cache initialization.
Moved around some constants.