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

科技回声

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

GitHubTwitter

首页

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

资源链接

HackerNews API原版 HackerNewsNext.js

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

Writing Multithreaded Code Is Like Juggling Chainsaws

16 点作者 davidblair超过 15 年前

4 条评论

jws超过 15 年前
Apropos <i>Juggling Chainsaws</i>, (but not this post) From an article about "Mad Chad"…<p><i>Tim Newman, a commercial director and cousin of Grammy-winning musician Randy Newman, asked if I could juggle chainsaws? In my naïve enthusiasm I said sure. I had opened my big mouth and the clock was ticking, with only 10 days to figure out how to juggle a live chainsaw without seriously injuring or killing myself. The first four days I was so nervous that I wouldn’t even start the chainsaw. Finally I pulled the cord and on my first attempt, I missed. The chainsaw hit the ground and went crazy, buzzing at full speed. Two policemen ran up and asked, “What the hell are you doing, kid?” I explained my dire situation and they thought it was cool. They began cheering me on. They wanted to see me do it!<p>On shoot day I show up for the commercial and get prepared. I fire up the chainsaw and Tim Newman says, “Whoa, what are you doing?” Long story short, after 10 days of practice, I find out they didn’t want the chainsaw running during the commercial (insurance won’t cover a stunt like that). The plan was to just add the sound effect in post-production. I felt a little stupid but it turned out to be the best mistake I ever made. The seed had been planted and soon I was juggling three saws at the same time. No one in Venice was doing a more extreme act.</i><p>There is a lesson about requirements gathering in there somewhere, and probably one about stepping outside your comfort zone.<p>Whole article: <a href="http://www.venicebeachbook.com/vbb2c.html" rel="nofollow">http://www.venicebeachbook.com/vbb2c.html</a>
motters超过 15 年前
Indeed. And this is why I think the current multithreading paradigm isn't going to scale well when we start getting into tens and hundreds of CPU cores. Something is going to have to change.
drtse4超过 15 年前
Completely agree, i've dealt myself with an access bottleneck as the one he describes. But i found multi-threaded code debugging quite entertaining (sometimes ;)).
评论 #1084375 未加载
DanielBMarkham超过 15 年前
I agree.<p>I'd like to point out that the use of immutable data structures solves some threading issues. Unfortunately, as in this example, it's easy to get hung up somewhere in your technology stack without realizing what's going on.