TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Faster CPython Ideas – Issue Tracker for Faster CPython Project

226 点作者 patrick91大约 4 年前

17 条评论

patrick91大约 4 年前
Presentation from Guido van Rossum at the Python Language Summit: <a href="https:&#x2F;&#x2F;github.com&#x2F;faster-cpython&#x2F;ideas&#x2F;blob&#x2F;main&#x2F;FasterCPythonDark.pdf" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;faster-cpython&#x2F;ideas&#x2F;blob&#x2F;main&#x2F;FasterCPyt...</a>
评论 #27140684 未加载
评论 #27145456 未加载
etaioinshrdlu大约 4 年前
I updated a large Django project from python2.7 to 3.9 recently. Afterward, I was pleased that the app was both faster and used less than half the memory. It was somewhat surprising that the new version was so much better - most software seems to typically get only heavier over time!<p>So, I take this as a good sign that progress will continue.
评论 #27143567 未加载
评论 #27149326 未加载
kzrdude大约 4 年前
This is exciting! So that we don&#x27;t miss the main point: Eric Snow, GvR and Mark Shannon will be working for Microsoft to improve Python performance.<p>In a way, it seems like Mark Shannon found someone to take him up on his offer on a plan for speeding up Python.
评论 #27141256 未加载
评论 #27141223 未加载
pca006132大约 4 年前
Just wondering, why is CPython a lot slower than JS? It seems to me that both languages are interpreted and comes with some reflection functionalities (like modifying object methods), but JS seems a lot faster in most of the benchmarks in <a href="https:&#x2F;&#x2F;benchmarksgame-team.pages.debian.net&#x2F;benchmarksgame&#x2F;fastest&#x2F;python.html" rel="nofollow">https:&#x2F;&#x2F;benchmarksgame-team.pages.debian.net&#x2F;benchmarksgame&#x2F;...</a><p>Edit: Why is this being downvoted? Is my statement incorrect or offensive to some people?
评论 #27143268 未加载
评论 #27142991 未加载
评论 #27142806 未加载
评论 #27142707 未加载
评论 #27147417 未加载
评论 #27143244 未加载
fdej大约 4 年前
I&#x27;d like to see optimizations targeting ctypes, or a successor to ctypes. I wish I could write elegant, performant C wrappers in pure Python. Right now the best choices are Cython, which is a hassle (separate, slow compilation, various warts), and ctypes, which is slow (and has some design problems of its own). Julia&#x27;s ccall alone is a major selling point over Python right now.
评论 #27141828 未加载
评论 #27141358 未加载
评论 #27147220 未加载
评论 #27145478 未加载
评论 #27142998 未加载
milliams大约 4 年前
I posted the link to the first PEP yesterday (<a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=27134290" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=27134290</a>) I think this looks like a very promising project.
评论 #27140760 未加载
The_rationalist大约 4 年前
The python JIT that promise to get the highest throughput once maturity reached is <a href="https:&#x2F;&#x2F;github.com&#x2F;oracle&#x2F;graalpython" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;oracle&#x2F;graalpython</a>
ForHackernews大约 4 年前
Is this going to incorporate the work done as part of <a href="https:&#x2F;&#x2F;blog.pyston.org&#x2F;2020&#x2F;10&#x2F;28&#x2F;pyston-v2-20-faster-python&#x2F;" rel="nofollow">https:&#x2F;&#x2F;blog.pyston.org&#x2F;2020&#x2F;10&#x2F;28&#x2F;pyston-v2-20-faster-pytho...</a> or <a href="https:&#x2F;&#x2F;github.com&#x2F;facebookincubator&#x2F;cinder" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;facebookincubator&#x2F;cinder</a> ?
bla3大约 4 年前
It&#x27;s good to see that python startup time is an explicit goal. Empty scripts taking 10-100ms is a problem if you use python in Makefiles, where you can have thousands of invocations in a build. This wasn&#x27;t considered a use case upstream cared about for quite some time. I&#x27;m glad to see this is changing. Here&#x27;s hoping the acknowledgement will result in concrete gains!
评论 #27144115 未加载
morelisp大约 4 年前
Stage 2 should&#x27;ve been the selling point of Python 3.<p>If there&#x27;s really a 50% general speed boost sitting around in &quot;normal&quot; bytecode optimization work (and having read a decent amount of CPython I believe there could be), that&#x27;s a criminal amount of energy over the past decade instead wasted dealing with what the type of a codepoint sequence should be named.
评论 #27153168 未加载
etskinner大约 4 年前
Why isn&#x27;t this hosted at <a href="https:&#x2F;&#x2F;github.com&#x2F;python&#x2F;cpython&#x2F;issues" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;python&#x2F;cpython&#x2F;issues</a> ?
评论 #27143906 未加载
guggle大约 4 年前
It really reminds me of this hilarious 2008 keynote by Cal Henderson: <a href="https:&#x2F;&#x2F;youtu.be&#x2F;i6Fr65PFqfk?t=2255" rel="nofollow">https:&#x2F;&#x2F;youtu.be&#x2F;i6Fr65PFqfk?t=2255</a><p>(relevant graphic: <a href="https:&#x2F;&#x2F;ibb.co&#x2F;yV6bN9H" rel="nofollow">https:&#x2F;&#x2F;ibb.co&#x2F;yV6bN9H</a> )
cpeterso大约 4 年前
Guido&#x27;s slides in the repo mention speedup targets, but there is no mention of benchmarks. What is measured gets optimized, but which benchmarks are important for Python users? I&#x27;m sure Django users and Numpy users have very different performance bottlenecks.
评论 #27181856 未加载
frankreyes大约 4 年前
This project is dead already. Lua is 4x faster out of the box compared to Python (without LuaJIT!). Lua got fast by having ints and floats at the local side of values, not as a reference. That&#x27;s in, the int and float value is in the variable itself, not as a reference with a pointer indirection. In Python, every time you do a=a+1 new memory allocation is made for the a+1 object. Java has the same performance issue with boxed types (new Integer), and this is why C# is faster in many benchmarks. (C# cheated with the hindsight advantage of knowing which were Java mistakes)
sergiomattei大约 4 年前
This is the most exciting development I&#x27;ve seen in the Python scene in years!<p>Thanks, Guido and team!
punnerud大约 4 年前
Deleted. Posted the wrong place. Thanks for the comments.
评论 #27140786 未加载
obviousbob大约 4 年前
CPython&#x27;s arcane constraints are holding it back - GIL, C API with a global interpreter instance, ref-counting, to name a few.<p>PyPy is already a drop-in replacement for CPython with JIT and using a fraction of the memory.<p><a href="https:&#x2F;&#x2F;dev.nextthought.com&#x2F;blog&#x2F;2018&#x2F;08&#x2F;cpython-vs-pypy-memory-usage.html" rel="nofollow">https:&#x2F;&#x2F;dev.nextthought.com&#x2F;blog&#x2F;2018&#x2F;08&#x2F;cpython-vs-pypy-mem...</a>
评论 #27145681 未加载