1

Windows Terminal 的性能有多烂

 2 years ago
source link: https://www.v2ex.com/t/787595
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

V2EX  ›  Windows

Windows Terminal 的性能有多烂

  h404bi · 3 小时 38 分钟前 · 1707 次点击

Casey Muratori 最近在 Windows Terminal 的 GitHub issue tracker 发了一个反馈—— Extremely slow performance when processing virtual terminal sequences,表达了对 WT 性能的关注,他还写了一个 benchmark 程序 TermBench 来测试 WT 的渲染性能具体有多差(根据 Casey 表述,达到了惊人的 2 fps)。

issue 中 WT 的 member 们不断回复讨论“说明解释”运行慢的理由,后来为了避免讨论失控,给出了有意思的「 because we've made it hard, not because of some intrinsic quality of the universe. 」结论。不过还是未能说服 Casey,进一步激烈的讨论后 Casey 得到了「 what you’re doing is describing something that might be considered an entire doctoral research project in performant terminal emulation as “extremely simple” somewhat combatively. 」的论断,被认为把事情看得过于简单,因为终端性能这件事能作为 PhD 项目了。

Casey 当然不服,但 issue 已经被锁了。于是他在他的 Handmade Hero 频道上“罕见地”发布了一名为 How fast should an unoptimized terminal run? 的与 HandmadeHero 无关的视频(还调侃地写上了 Terminal PhD Dissertation )来论述 WT 到底有多慢,它能有多快:

https://www.youtube.com/watch?v=hxM8QmyZXtg

除了视频,还给出了相应的参考实现 RefTerm: https://github.com/cmuratori/refterm 作为对比。

Hacknernews 上也有对此的讨论串 https://news.ycombinator.com/item?id=27725133,虽然并没有太多讨论,但也有些挺有意思的,比如「 ... if your team lacks anyone with that intuitions, your team will spend their time finding “explanations” for the bad performance instead of fixing it. 」。

整个事件看下来,我对最近发布的 Windows 11 也有了新的感慨——无论再怎么更新,它依旧是一座大屎山,有些东西就是长年无法改变的,看看这个回复回复就知道。(逃)


Casey Muratori 是谁?

Casey Muratori 是一名经验丰富的游戏引擎开发者,参与过多款知名游戏的研发。他也是 Handmade Hero 项目的作者,如果你不了解 Handmade Hero,可以去搜索了解下。这个非常硬核的教学向项目发起于 2014 年,目标是不使用任何引擎,从头手写每一行代码来学习做出一款游戏。每周进行更新,至今已坚持近 7 年之久,超过 600 集视频,还衍生出如 4coder 等实际生产可用的项目。


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK