RSSAmplifier

Blog

Antonio Cuni's blog

Antonio Cuni's blog

antocuni.euRSS feed ↗20 posts

Latest posts

Why Python Is Slow: Talking about SPy on the Behind the Commit Podcast

Why Python Is Slow: Talking about SPy on the Behind the Commit Podcast During EuroPython 2025 I had the pleasure to talk to Mia Bajić for her podcast Behind The Commit . In the chat we mainly talk about Python performance and how SPy tries to improve them. Now the full episode is live: you can watch it on Youtube or listen on Spotify

Inside SPy, part 2: Language semantics

Inside SPy 🥸, part 2: Language semantics This is the second post of the Inside SPy series. The firstpost was mostly about motivations andgoals of SPy . This post will cover in more detail thesemantics of SPy, including the parts which make it different from CPython. We will talk about phases of execution, colors , redshifting, the very peculiar waySPy implements static typing, and we will start…

My first OSS commit turns 20 today

My first OSS commit turns 20 today Some time ago I realized that it was 20 years since I started to contribute toOpen Source. It's easy to remember, because I started to work on PyPy as part of mymaster's thesis and I graduated in 2006. So, I did a bit of archeology to find the first commit : $ cd ~/pypy/pypy && git show 1a086d45d9 --no-patch commit 1a086d45d9 Author: Antonio Cuni…

Inside SPy, part 1: Motivations and Goals

Inside SPy 🥸, part 1: Motivations and Goals This is the first of a series of posts in which I will try to give a deep explanation of SPy , including motivations, goals, rules of thelanguage, differences with Python and implementation details. This post focuses primarily on the problem space : why Python is fundamentally hardto optimize, what trade-offs existing solutions require, and where…

Tracing JITs in the real world @ CPython Core Dev Sprint

Tracing JITs in the real world @ CPython Core Dev Sprint Last week I got to take part in the CPython Core Developer Sprint inCambridge, hosted by ARM and brilliantly organized by Diego Russo -- about ~50 core devs and guests were there, and I was excited to join as oneof the guests. I had three main areas of focus: C API : this was a follow up of what we discussed at the C API summit at EuroPython…

Inside CPython's attribute lookup

Inside CPython's attribute lookup Python's attribute lookup logic seems pretty simple at a first glance: 'firstlook in the instance __dict__ , then look in its type'. However, the actual logic is much more complex because it needs to take intoaccount the descriptor protocol, the difference between lookups on instancesvs types, and what happens in presence of metaclasses. Recently I implemented…

Slides for my EuroPython 2025 talks

EuroPython 2025 slides Here are the slides for the three speeches which I gave at EuroPython 2025 :

Claude code modified my .bashrc without asking?

Claude code modified my .bashrc without asking? !!! note 'Note' This is not the classical post about running claude in YOLO mode and then complaining that it damaged the system. I have reasons to think that claude automatically modified my .bashrc to remove a line alias claude=... without asking my permission and without notifying me of the change.

SPy @ PyCon IT 2025

SPy @ PyCon IT 2025 Yesterday I talked about SPy at PyCon Italy . Thanks to Hugo van Kemenade for the picture. Slides are available here . The edited video is not available yet, but in the meantime it's possible towatch unedited version available inside the live stream at minute 05:44:05.

Tales with claude code: how to make it behave?

Tales with claude code: how to make it behave? In the past weeks, I have been experimenting with using claude code to speedup development, in particular of SPy . My experience so far reveals a clear pattern: claude excels at simple,one-shot tasks that follow existing patterns, producing commit-readycode. However, for complex tasks requiring multiple iterations, qualitydeteriorates significantly…

Over the clouds: CPython, Pyodide and SPy

Over the clouds: CPython, Pyodide and SPy The Python community is awesome. It is full of great people and minds, and interacting with people atconferences is always nice and stimulating. But one of my favorite things isthat over time, after many conferences, talks, pull requests and beers, thepersonal relationship with some of them strengthen and they become friends. I am fortunate enough that two…

hpy 0.0.2: First public release

!!! note '' Originally published on the HPy blog . HPy 0.0.2 is out! This is the first version which is officially released andmade available on PyPI. The major highlight of this release is that it is supported by three differentPython implementations: CPython, PyPy and GraalPython.

HPy @ Python Language Summit

!!! note '' Originally published on the HPy blog . Yesterday I had the privilege to give a talk about HPy( sildes ) at the Python Language Summit 2021 . The organizers of the summit will soon publish a full report about the event(edit: now available here ),but for the HPy-specificpart ,we got generally good feedback. Someone has a few concerns that if CPython isto change the API, HPy might not be…

Hello, HPy

!!! note '' Originally published on the HPy blog . HPy has been around for a while now. The initial discussion started duringEuroPython 2019, in the good old times when we could still go to conferencesand have real-life meetings. Since then, HPy progressed a lot from thepoint of view of the actual code, but we have been a bit too silentw.r.t. communicating what we are doing to the external world…

HPy kick-off sprint report

!!! note '' Originally published on the PyPy blog . Recently Antonio, Armin and Ronan had a small internal sprint in the beautifulcity of Gdańsk to kick-off the development of HPy. Here is a brief report ofwhat was accomplished during the sprint.

PyPy v7.0.0: triple release of 2.7, 3.5 and 3.6-alpha

!!! note '' Originally published on the PyPy blog .

PyPy for low-latency systems

!!! note '' Originally published on the PyPy blog . PyPy for low-latency systems Recently I have merged the gc-disable branch, introducing a couple of featureswhich are useful when you need to respond to certain events with the lowestpossible latency. This work has been kindly sponsored by Gambit Research (which, by the way, is a very cool and geeky place where to work , in case youare…

Inside cpyext: Why emulating CPython C API is so Hard

!!! note '' Originally published on the PyPy blog .

How to ignore the annoying Cython warnings in PyPy 6.0

!!! note '' Originally published on the PyPy blog . If you install any Cython-based module in PyPy 6.0.0, it is very likely that you get a warning like this: >>>> import numpy/data/extra/pypy/6.0.0/site-packages/numpy/random/__init__.py:99: UserWarning: __builtin__.type size changed, may indicate binary incompatibility. Expected 888, got 408 from .mtrand import * The TL;DR version is: the warning…

How to make your code 80 times faster

!!! note '' Originally published on the PyPy blog . I often hear people who are happy because PyPy makes their code 2 times fasteror so. Here is a short personal story which shows PyPy can go well beyondthat.