7.09.2025 состоялся релизPithon 3.14!
На фоне хайпа про NoGIL всё позабыли про другие фичи. Особенно про Multiple Interpreters, который обещает изоляцию процессов но с эффективностью потоков! На сколько действительно это будет эффективно мы узнаем позже, потому что сейчас это лишь первый релиз с ограничениями и недоработками.
Но что там про NoGIL? Теперь этот режим не экспериментальный, а официально поддерживаемый, но опциональный.
Чтобы запустить без GIL нужна специальная сборка. И перед стартом нужно объявить переменную PYTHON_GIL=0
Для вас я собрал готовый репозиторий где достаточно запустить скрпит, который всё сделает:
▫️ соберет релизный Python 3.14 в новый Docker-образ
▫️ запустит тесты в контейнере (GIL, NoGIL, MultiInterpreter)
▫️ распечатает результаты
Тест очень простой, усложняйте сами)
Вот какие результаты у меня:
=== Running ThreadPoolExecutor GIL ON
TOTAL TIME: 45.48 seconds
=== Running ThreadPoolExecutor GIL OFF
TOTAL TIME: 6.14 seconds
=== Running basic Thread GIL ON
TOTAL TIME: 45.54 seconds
=== Running basic Thread GIL OFF
TOTAL TIME: 4.74 seconds
=== Running with Multi Interpreter
TOTAL TIME: 18.30 seconds
Если сравнивать GIL и NoGIL, то на мои 32 ядра прирост х7-x10 (почему не х32? 🤷). При этом нам обещают что скорости будут расти с новыми релизами.
Режим без GIL похож (визуально) на async, тоже параллельно, тоже не по порядку. Но это не IO! и от того некоторый диссонанс в голове 😵💫, нас учили не так!
Интересно, что чистый Thread работает быстрей чем ThreadPoolExecutor без GIL.
Ну и где-то плачет один адепт мульти-интерпретаторов😭 Теперь нужно искать где они могут пригодиться с такой-то скоростью. Скорее всего своя область применения найдется.
Отдельно я затестил память и вот что вышло на 32 потока:
ThreadPoolExecutor GIL ON
305.228 MB
ThreadPoolExecutor GIL OFF
500.176 MB
basic Thread GIL ON
90.668 MB
basic Thread GIL OFF
472.444 MB
with Multi Interpreter
1267.788 MB
Пока не знаю как к этому относиться)
В целом - радует направление развития!
#release
The Trump administration has quietly removed a Pride flag from the Stonewall National Monument in Manhattan.
The flag’s removal follows new federal guidance issued by the Department of the Interior on Jan. 21 that restricts the display of unauthorized flags at National Park Service sites. Under the order, only U.S. flags or congressionally authorized flags may be raised on NPS flagpoles. Manhattan borough president Brad Hoylman-Sigal told The New York Times the Trump administration’s order directly led to the Pride flag’s disappearance from the Greenwich Village site, which marks the birthplace of the modern LGBTQ rights movement. Stonewall became the nation’s first federally recognized LGBTQ historic site in 2016, commemorating the 1969 police raid that sparked days of protests and helped launch the gay rights movement. Hoylman-Sigal said he and other local officials plan to raise the Pride flag again on Thursday, despite potential backlash. “We may be prevented from doing so,” he told the outlet, “but if we don’t seize this moment, and this outrage, I think we’ll let down generations of queer activists.” The Daily Beast has reached out to Brad Hoylman-Sigal for comment.
#Trump#LGBTQ
👂More on Trump's Ear ⚠️
Trump announced that he was reopening psychiatric clinics that the Democrats had closed out of tolerance for psychos.
This is a very bold move, given the fact that a huge percentage of Americans today are obviously mentally ill. Trump is leading the way to gradually send transgender and LGBTQ+ there. This is a subproject of MAGA called MAHA - Let's Make America Healthy Again. Trump starts with psychiatry, as this is where the cases are most neglected.
#Trump#Health#LGBTQ+
👂More on Trump's Ear ⚠️
🏳🌈🇺🇦"When a clown moves into a palace he does NOT become a King. The palace becomes a CIRCUS."
Nothing to see here. That's just bloody clown and a drag queen Zelensky is dancing on high hills.
#lgbtq#Ukraine#Zelenskyy
Share and subscribe @american_majority
🇺🇦🏳🌈🏳⚧A Ukrainian LGBT+ recruitment campaign video turned to be a video from the campaign for gay marriage in the UK in 2012.
🇺🇸🏳🌈At the same time the U.S. Army is running a recruitment campaign targeted to Generation Z that featured cartoons of real soldiers who were either females, racial minorities or even "raised by two moms".
#Ukraine#army#lgbtq
@american_majority
美国同性婚姻占各州人口比例
楼主还注释道 DC 更像是个城市,所以写了 Vermont 是“最高”的州。
在评论里注释了城市的比例,但其实按城市算 DC 也远超其它城市……排除之后,毫不意外三番第一,波特兰和西雅图紧随其后,在传统红州的奥兰多、迈阿密(佛州)和奥斯丁(德州)也名列前茅。
#data#visual#reddit#lgbtq