/cusec_workshop

Workshop that I gave on behalf of Yelp at CUSEC 2019: learn how to write Python extensions with C!

Primary LanguageC

Hack your Python

This workshop was given at CUSEC 2019 in Montreal, Canada.

Abstract

In this workshop, we're getting our hands dirty and using C to build an extension for the Python interpreter. Why would we do this? Writing critical parts of our software in a high-performance language has enabled us to supercharge our backend and allowed us to access parts of the interpreter we wouldn't have been able to access in plain Python. This workshop runs in two parts: we'll first build a small "classic" extension; then we'll dive right in and tweak the behaviour of Python's garbage collector.

Slides

In file SLIDES.pdf.

Solution

Please check out branch solution for a completed extension. The extension should build under all versions of CPython 3.x.