Use long instead of int for max cache size.