How Python was Shaped by leaky Internals, Armin Ronacher, Flask framework
Channel:Видео с мероприятий {speach! · Length:49:55 · Published:2016-07-13 · Views:20211
Summary
Armin Ronacher, creator of Flask, explains how CPython's internals and C API leak into the language's semantics. Using examples like the complexity of the add operation, he shows why Python is hard to optimize or reimplement.
Why HN recommends it
It is HN's standard answer to why Python cannot easily get much faster, and is recommended by people who work on JITs and alternative runtimes.
This excellent talk describes how the semantics of the "add" operation are much more complex than generally described. — HN, 2021
Programming language design · Python, Ruby & scripting languages · Software performance & optimization
Subtitles (excerpt)
um so this talk is about python inside the virtual machine and how that actually affects python is a language and because there's a lot of potentially boring stuff in there I would really welcome if people would just ask questions or anything of that sort along the way to spice it up a little bit um what's interesting about I think python as a language is that we all use it and we are sort of we like it I think for the most part at least people don't seem to mind it too much um but it's actually surprising how nitty-gritty uh The Interpreter internally is and how much it sort of restricts Us in in what we can do but also how much it enables Us in other ways um so this is basically um so I should give a little prease for this um I've been doing python since so the first version of python I used was 2.0 but it wasn't like I wasn't programming when 2.0 came out um I think the first one I actually used was 2.2 but I had an interest in trying to figure out how it goes back to to see how um how the language evolved and how The Interpreter evolved um and then just recently I think last year I already gave a talk similar to this one and for that one I decided to see how it is to compile python 1.3 I think so it's
On Hacker News
I thought this presentation by Armin Ronacher (the creator of Flask and Jinja) was very enlightening: How Python was Shaped by leaky Internals(2016): [VIDEO] See also this HN post (Attempts to make Python fast): [LINK] — fault1, 2022-01
I think "a + b" is a good example. I really recommend the talk I linked ( [VIDEO] ), it gets deep into this stuff. I don't think anyone benefits from "a + b" having so many special cases. — haberman, 2021-11
Python is difficult to optimize due to complex language semantics. This excellent talk describes how the semantics of the "add" operation are much more complex than generally described. a+b is not just a.__add__(b), you have to read 200+ lines of CPython interpreter code to fully resolve its semantics: [VIDEO] Not saying it's impossible, but it's more of an uphill battle than optimizing other lan… — haberman, 2021-09
As the OP states: > mutable interpreter frames, global interpreter locks, shared global state, type slots On top of this, Python is extremely dynamic and nothing can be assured without running through the code. So this leads to needing JITs to improve performance which then give a slow start up time and increased complexity. Even with JIT, Python is just not fast thanks to the above issues and it… — arc776, 2020-10
I highly recommend this talk by Armin Ronacher as an accompaniment (or prologue, or epilogue) to the article: "How Python was shaped by leaky internals", [VIDEO] — nerdponx, 2020-09
Related videos
- Armin Ronacher - A Python for Future Generations · EuroPython Conference · 42:43
- The Unreasonable Effectiveness of Multiple Dispatch | Stefan Karpinski | JuliaCon 2019 · The Julia Programming Language · 35:24
- How Wrong Is VERITASIUM? A Lamp and Power Line Story · ElectroBOOM · 19:17
- Casey Muratori – The Big OOPs: Anatomy of a Thirty-five-year Mistake – BSC 2025 · Better Software Conference · 2:27:33
- ADHD: Essential Ideas for Parents - Dr. Russell Barkely · ADHDtips · 2:51:43
- Chris Urmson: How a driverless car sees the road · TED · 15:29
- USENIX ATC '21/OSDI '21 Joint Keynote Address-It's Time for Operating Systems to Rediscover Hardware · USENIX · 1:06:19
- "Unison: a new distributed programming language" by Paul Chiusano · Strange Loop Conference · 41:05
- The Tragedy of systemd · linux.conf.au · 47:18
- Maybe Not - Rich Hickey · ClojureTV · 1:03:28
- Keynote. Professor Steven G. Johnson | JuliaCon 2019 · The Julia Programming Language · 52:40
- JuliaRobotics: Making robots walk with Julia | Robin Deits · The Julia Programming Language · 39:46
- Guarding Against Physical Attacks: The Xbox One Story — Tony Chen, Microsoft · Platform Security Summit · 58:05
- A new way to visualize General Relativity · ScienceClic English · 11:33
- What is the Ultraviolet Catastrophe? · Physics Explained · 40:28
- Analogy as the Core of Cognition · Stanford · 1:08:37
- “What is Success?” by Evan Czaplicki · Elm Europe · 47:52
- Steve Jobs on privacy, Steve Jobs at the D8 Conference (Video) · iwasjojo · 3:19
- Ali Rahimi's talk at NIPS(NIPS 2017 Test-of-time award presentation) · ObservantVids · 23:19
- Making R run Fast - Jan Vitek · John O'Neill · 1:21:38