Closed dimo414 closed 3 years ago
Original comment by Michael Diamond (Bitbucket: dimo414).
Given the existence of BC_CACHE_DIR
, and the potential for systems to configure their TMPDIR
or /tmp
directory to use tmpfs
, this is probably not as important as I initially thought.
We could experiment with heuristically using /dev/shm
if it's a tmpfs
(it's not on WSL) and the default cache directory is not, but it's not so bad for users to do this themselves.
Original report by Michael Diamond (Bitbucket: dimo414).
As suggested in https://codereview.stackexchange.com/q/170958/14237, having a tiered cache would make common cases much faster than the several reads from disk that are currently required.
One potentially easy option would be to use
/dev/smh
before/tmp
(but falling back to/tmp
if/dev/smh
is busted). Need to account for (and document?)/dev/smh
behavior better, since previously I'd seen files randomly disappearing from under me.