devito icon indicating copy to clipboard operation
devito copied to clipboard

TODO for thread-safe Operator.apply

Open FabioLuporini opened this issue 3 years ago • 0 comments

The same Operator can be .apply concurrently by different threads, but there are certain non-functional objects attached to, or used by, it that aren't thread-safe yet:

  • The Profiler's py_timers dict needs to be turned into a thread-private dict (k -> v ---> k -> tid -> v)
  • The Timer object passed to C-land needs to be a per-thread object. Still unsure whether this is up to app or devito.
  • op._state to be made thread safe

FabioLuporini avatar Jun 18 '21 07:06 FabioLuporini