add path_cache and rewritten_ast_cache

speed up compilations between calls to `Riml.compile_files` by
caching more heavily.

TODO: make these new caches threadsafe