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

科技回声

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

GitHubTwitter

首页

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

资源链接

HackerNews API原版 HackerNewsNext.js

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

Finding a Bug in Chromium

65 点作者 bouk20 天前

5 条评论

charcircuit17 天前
My first guess would be that this early return is always happening after entering the bugged state. The one cleanup task could get stuck or not cleanup after itself properly.<p><pre><code> &#x2F;&#x2F; Only one cleanup task is posted at a time. if (!HasDirtyJSFinalizationRegistries() || is_finalization_registry_cleanup_task_posted_) { return; } </code></pre> <a href="https:&#x2F;&#x2F;source.chromium.org&#x2F;chromium&#x2F;chromium&#x2F;src&#x2F;+&#x2F;main:v8&#x2F;src&#x2F;heap&#x2F;heap.cc;l=6884;drc=467a8e68f685f9cfa47ee3fbfca20c22f7f6e893" rel="nofollow">https:&#x2F;&#x2F;source.chromium.org&#x2F;chromium&#x2F;chromium&#x2F;src&#x2F;+&#x2F;main:v8&#x2F;...</a>
评论 #43934861 未加载
评论 #43940488 未加载
tester75616 天前
&gt;FinalizationRegistry<p>&gt;Avoid where possible<p>&gt;Correct use of FinalizationRegistry takes careful thought, and it&#x27;s best avoided if possible. It&#x27;s also important to avoid relying on any specific behaviors not guaranteed by the specification. When, how, and whether garbage collection occurs is down to the implementation of any given JavaScript engine. Any behavior you observe in one engine may be different in another engine, in another version of the same engine, or even in a slightly different situation with the same version of the same engine. Garbage collection is a hard problem that JavaScript engine implementers are constantly refining and improving their solutions to.<p>Kinda tricky API
评论 #43941586 未加载
donatj16 天前
Hey! I too just filed my first Chromium bug[1]! They changed a behavior that broke opening new windows with tabs, and thus broke my advanced tab search extension Tabasco[2].<p>I was frankly impressed by the experience. They had me create a minimal extension illustrating the issue and were very quickly able automate a bisection that found its root, a security fix somewhat bluntly resolved. They&#x27;ve supposedly fixed the issue in an upcoming release I await with bated breath.<p>- [1] <a href="https:&#x2F;&#x2F;issues.chromium.org&#x2F;issues&#x2F;405283740" rel="nofollow">https:&#x2F;&#x2F;issues.chromium.org&#x2F;issues&#x2F;405283740</a><p>- [2] <a href="https:&#x2F;&#x2F;chromewebstore.google.com&#x2F;detail&#x2F;tabasco-advanced-tab-sear&#x2F;apnefdpgaignkblccanndkelkjabjgjh" rel="nofollow">https:&#x2F;&#x2F;chromewebstore.google.com&#x2F;detail&#x2F;tabasco-advanced-ta...</a>
panstromek16 天前
Hm.. I would honestly try to avoid relying on finalization mechanism of a garbage collector like this. It sounds brittle from the start. Even without the bug, I can imagine you can get into a situation where some unused JS object holds a reference to a giant thing in wasm memory, but engine doesn&#x27;t run the GC, because it technically doesn&#x27;t know that, it only sees the little pointer object which seems small.<p>I think WASM had historically had some problem with freeing memory, so I&#x27;d probably rather rely on some pooling or arena with explicit memory size limit (for the whole allocated wasm memory).
rvz17 天前
Great technical post, however:<p>&gt; At Monumental we’ve building robots to automate construction, starting with masonry.<p>If you thought running to construction jobs was safe, well thanks to Monumental, it soon won&#x27;t be.<p>The end goal is to achieve a 10% increase of global unemployment by the latest 2035 and 40% of employers anticipate reducing their workforce where AI can automate tasks by the 2030 deadline according to the WEF 2025 Future of Jobs report. [0]<p>Worse if earlier.<p>[0] <a href="https:&#x2F;&#x2F;www.weforum.org&#x2F;publications&#x2F;the-future-of-jobs-report-2025&#x2F;digest&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.weforum.org&#x2F;publications&#x2F;the-future-of-jobs-repo...</a>
评论 #43934625 未加载
评论 #43934630 未加载
评论 #43934783 未加载