Python Garbage Collector

Hi :slight_smile:

I would like to find out how the Garbage Collector in CPython interacts with the Global Interpreter Lock. I would assume that the garbage collector runs inside of the interpreter, and not as a thread or process along the python interpreter. I would also assume that the GC acquires GIL when it wants to run the Cyclic Garbage collector. I looked at the documentation but i am afraid i did not find anything mentioning this. Is there some diagram which describes the runtime of Python?