LWN: Comments on "Python subinterpreters and free-threading" https://lwn.net/Articles/985041/ This is a special feed containing comments posted to the individual LWN article titled "Python subinterpreters and free-threading". en-us Fri, 19 Sep 2025 08:34:43 +0000 Fri, 19 Sep 2025 08:34:43 +0000 https://www.rssboard.org/rss-specification lwn@lwn.net 2 threads or 100 threads? https://lwn.net/Articles/987082/ https://lwn.net/Articles/987082/ wujj123456 <div class="FormattedComment"> Got it. Somehow I missed the link to video. I agree with you given Anthony was just stating that the threads couldn't run in parallel. Thanks for the continued coverage on this interesting topic. <br> </div> Sat, 24 Aug 2024 06:37:45 +0000 Garbage Collector changes https://lwn.net/Articles/986953/ https://lwn.net/Articles/986953/ bluss <div class="FormattedComment"> See the relevant PEP-703 for an explanation of this <a href="https://peps.python.org/pep-0703/#reference-counting">https://peps.python.org/pep-0703/#reference-counting</a><br> </div> Fri, 23 Aug 2024 08:00:05 +0000 Garbage Collector changes https://lwn.net/Articles/986912/ https://lwn.net/Articles/986912/ StandingPad <div class="FormattedComment"> The article mentions that part of removing the GIL involves changing the garbage collector. I'm aware at the moment, CPython uses reference counting (which isn't parallel friendly), so does the free-threading build use a different method like mark-and-sweep, or does it use some variant of reference counting that is parallel friendly? <br> </div> Thu, 22 Aug 2024 20:21:04 +0000 2 threads or 100 threads? https://lwn.net/Articles/986885/ https://lwn.net/Articles/986885/ jake <div class="FormattedComment"> I think Anthony was just making a general statement about what *would* happen if he were to do that. I checked the video and the quote is correct, though I think he misstates what he means ... the part that he showed in his slides is just the upper "Crude sample" part from that link. Now that you point it out, though, I suspect he did not actually mean that it took twice as long, just that it would take the same amount of time as the simple non-threaded version because the GIL would not be released so (any number of) threads would serialize.<br> <p> jake<br> </div> Thu, 22 Aug 2024 16:11:44 +0000 2 threads or 100 threads? https://lwn.net/Articles/986744/ https://lwn.net/Articles/986744/ wujj123456 <div class="FormattedComment"> The context is in the article, and there is only one link that could plausibly be the one I'm referring to in the paragraph containing the sentence I quoted: <a href="https://gist.github.com/tonybaloney/24d545ed855a3c90f844209152835f07#threading-benchmark">https://gist.github.com/tonybaloney/24d545ed855a3c90f8442...</a><br> <p> You don't need to understand the code snippet either, because it was commented with "Split array into blocks of 100 and start a thread for each", which is in conflict with the quoted sentence in the article. My question is just asking to confirm whether it's 2 thread or 100 threads causing the 2x slowdown, because that points to very different per-thread synchronization overhead from the GIL lock. <br> </div> Thu, 22 Aug 2024 07:20:19 +0000 2 threads or 100 threads? https://lwn.net/Articles/986730/ https://lwn.net/Articles/986730/ kenmoffat <div class="FormattedComment"> You have not clarified which of the links you are commenting on, and I find some of them hard to read. But if you split something into threads and it takes longer, then what is the point ?<br> <p> I assume whatever you commented on illustrated a problem which either has now been , or needs to be, fixed. But for those of us who have little experience in an area, context is always useful. <br> </div> Thu, 22 Aug 2024 03:10:45 +0000 2 threads or 100 threads? https://lwn.net/Articles/986564/ https://lwn.net/Articles/986564/ wujj123456 <div class="FormattedComment"> <span class="QuotedText">&gt; "if I split that in half and executed between two threads in Python 3.12, it would take twice as long"</span><br> <p> The code and comment indicates it's splitting into 100 threads to get 2x slower. This kind of overhead is more plausible than having only 2 threads but 2x slower. <br> </div> Wed, 21 Aug 2024 03:30:30 +0000 Python & Guido https://lwn.net/Articles/986562/ https://lwn.net/Articles/986562/ Paf <div class="FormattedComment"> I’m not really a Python person, but I am always really charmed by articles talking about that community and especially Guido’s continuing role in it. They(we?) are lucky to have him.<br> </div> Wed, 21 Aug 2024 02:51:23 +0000