12

我发现了几个 SO 问题以一种或另一种方式询问这个问题,但实际上他们都没有给出一个列表或参考一个。

这个问题指的是一个 wiki 页面,但是虽然 wiki 页面讨论GIL 和多线程,但它没有给出 GIL 发布函数的列表。

此邮件列表帖子表明找出答案的唯一方法是阅读 numpy 源代码。真的吗?

4

1 回答 1

2

It's not guaranteed to catch everything, but I just ran:

git grep nogil

in my clone of the numpy repository. It turns up 82 usages in 2 files:

  • random/mtrand/mtrand.pyx
  • random/mtrand/numpy.pxd
于 2014-06-03T20:48:57.190 回答