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

科技回声

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

GitHubTwitter

首页

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

资源链接

HackerNews API原版 HackerNewsNext.js

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

Goless: Go-like semantics built on top of Stackless Python

50 点作者 im_dario将近 11 年前

5 条评论

sarnowski将近 11 年前
IIRC stackless python implemented microthreads and channels before go existed - thats the whole point of stackless python - so whats the benefit here on top of that?<p><a href="http://www.stackless.com/wiki/Tasklets" rel="nofollow">http:&#x2F;&#x2F;www.stackless.com&#x2F;wiki&#x2F;Tasklets</a> <a href="http://www.stackless.com/wiki/Channels" rel="nofollow">http:&#x2F;&#x2F;www.stackless.com&#x2F;wiki&#x2F;Channels</a>
评论 #8184288 未加载
评论 #8184945 未加载
评论 #8184208 未加载
评论 #8184040 未加载
评论 #8184240 未加载
评论 #8183966 未加载
jmoiron将近 11 年前
What tulip should have been.<p>Being a long time gevent user, I found goroutines pretty familiar and even unspectacular (no pool.map?!). What really converted me to Go was all of the other ways I found writing Go programs to be more pleasant and less error prone than Python programs:<p>* consistent formatting for all code<p>* superior distribution story<p>* compiler magnitudes faster and more effective than pylint<p>* programs run faster and use far less memory<p>* far simpler semantics make it easy to read<p>* higher quality standard components (net&#x2F;http, eg)<p>What I traded for this was a 10-20% drop in productivity, which I was fine with. I use Python for all sorts of quick &amp; dirty tasks still, including some batch processing where there&#x27;s a big discovery phase, but I write all my software in Go.
ceptorial将近 11 年前
The big question is whether this mimics the &quot;non-blocking&quot; behavior of goroutines - if you block in a goroutine with a select on a channel in Go (or rather, if you do ANY synchronous operation, including network calls, channel operations, etc.), Go will automatically context switch off the goroutine and run another one. But if you have a tasklet that selects on a channel, will Goless&#x2F;Stackless automatically run a different tasklet, or will that tasklet stall a thread (or worse, the GIL)? What if the tasklet is doing a synchronous HTTP call or waiting on a future to complete?
评论 #8184918 未加载
pritambaral将近 11 年前
I&#x27;m pleasantly surprised to see pypy beat go by an order of magnitude in the select_default benchmarks. Could it be a bug, or is it real?
评论 #8184966 未加载
评论 #8184931 未加载
kristjanvalur将近 11 年前
Hi, I didn&#x27;t realise this was where all the cool kids hang out. Google alerts 4tw