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

科技回声

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

GitHubTwitter

首页

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

资源链接

HackerNews API原版 HackerNewsNext.js

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

Simple, Fast and Safe Manual Memory Management (2017) [pdf]

60 点作者 palerdot大约 6 年前

6 条评论

Ace17大约 6 年前
&gt; we just add a delete operator to free memory explicitly and an exception which is thrown if the program dereferences a pointer to freed memory.<p>Is there any sensible thing to do when this exception is caught, appart from halting the program? If the answer is &quot;no&quot;, why have an exception at all?
评论 #19779675 未加载
评论 #19779470 未加载
nickpsecurity大约 6 年前
Here&#x27;s a video by one of the team members:<p><a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=C07s5LTuTmE" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=C07s5LTuTmE</a>
评论 #19782323 未加载
cryptonector大约 6 年前
Access to deleted objects is detected by marking objects deleted and not reclaiming their memory until the containing pages are mostly full of deleted objects, then they relocate still-live objects and unmap the pages. That is, they use MMU tricks but they amortize the MMU cost (otherwise performance would be absolutely abysmal).<p>Note that they still need to rewrite object references, which is a lot like a GC. EDIT: No, sorry, they lazy patch references, though this requires some overhead.<p>Also, this does nothing to protect against leaks.<p>Interesting idea, but too-little-too-late. I think Rust is the better answer for now.<p>EDIT: Great question from the Q&amp;A of the video, &quot;why are you not getting killed by TLB misses?&quot;, and the presenter did not know. This is a really important question.
saagarjha大约 6 年前
I just skimmed the paper since I should really get to bed, but:<p>&gt; We do not guarantee that all dereferences to deleted objects will throw an exception.<p>What happens in the case where the dereference doesn’t throw an exception? Execution proceeds as if the dangling pointer pointed to the “zombie” object?
评论 #19777911 未加载
hyperman1大约 6 年前
I wonder what would happen if you just keep on allocating and never free anything. The system would eventually swap out everything that should be freed. A 64-bit process has plenty of address space, and hard disks are huge.<p>Of course, there is probably some huge painfull punishment in store if you try this in real life. I just wonder which. Your average GUI process that shuts down every day or so maybe wouldn&#x27;t suffer too much.
评论 #19782335 未加载
gok大约 6 年前
I really like this paper. There&#x27;s a large class of problems where tracing GC is very suboptimal from a performance&#x2F;efficiency perspective but classic manual memory management is unacceptable from a security&#x2F;correctness perspective.