inducer / pyopencl

OpenCL integration for Python, plus shiny features
http://mathema.tician.de/software/pyopencl
Other
1.06k stars 241 forks source link

cache: better locking #503

Open matthiasdiener opened 3 years ago

matthiasdiener commented 3 years ago

Background: this code is part of the reason for the CI slowdowns in mirgecom (especially with profiling).

matthiasdiener commented 3 years ago

Thanks! I think it's probably better to add this as a dependency instead. (https://github.com/conda-forge/filelock-feedstock also already exists.)

The main reason I didn't use the package is that https://github.com/benediktschmitt/py-filelock/blob/master/filelock.py logs a lot of debug messages.

Out of curiosity: What prompted this change? Were their any specific failure modes?

https://github.com/illinois-ceesd/mirgecom/pull/418 fixed the immediate issue we had seen in mirgecom, so this PR isn't a priority at the moment. However, I still think a 1 sec timeout is a bit much, maybe we should reduce it to 0.05s (like in the filelock package)?

inducer commented 3 years ago

I'm open to reducing the timeout.