This is motivated by:
- code completion: nice to do no i/o on the request path
- background index: deciding whether to enqueue each file would stat the config file thousands of times in quick succession.
Currently it's applied uniformly to all requests though.
This gives up on performing stat() outside the lock, all this achieves is
letting multiple threads stat concurrently (and thus finish without contention
for nonexistent files).
The ability to finish without IO (just mutex lock + integer check) should
outweigh this, and is less sensitive to platform IO characteristics.
i would've suggested storing a duration here instead of time point, but as discussed offline this is only done once in the clangdserver and storing a time point might help with invalidating the cache based on filewatcher events easily.