深入 GIL: 如何寫出快速且 thread-safe 的 Python – Grok the GIL: How to write fast and thread-safe Python

本文將會探討 Python 內部的 Global Interpreter Lock,以及學習其如何影響 multi-threaded 程式。  原作者:A. Jesse,Twitter: @jessejiryudavis 原文:Grok the GIL: How to write fast and thread-safe Python Louie Lu 經作者同意[1][2]翻譯為正體中文。 當我6

Continue Reading

使用 C 來編寫 Python 模組 – 以 jump consistent hash 為例

Extending Python with C – Jump Consistent Hash 本文的目標是以 C 完成 Jump Consistent Hash 的主體,接著透過 Python-C-API 轉為 Python 可以使用的套件。也就是說,模組的本體將會以 C 語言寫成,接著透過 setuptools 編譯為 so 檔,如此編成的模組將可以讓 Python 無縫接軌使用。 參

Continue Reading