HN 精选

CppCon 2015: Andrei Alexandrescu “std::allocator...”

CppCon
7 人推荐 · 跨 11 个月 · 2017–2025
系统编程语言(C/C++、Rust、Go)软件性能与系统优化
CppCon 2015: Andrei Alexandrescu “std::allocator...”

中文导读

C++ 大师 Andrei Alexandrescu 在 CppCon 2015 上的高能开炮。他直指标准库 std::allocator 架构设计的缺陷,并开创性地提出通过高度可组合的小模板组件,自底向上拼装出极致高性能分配器。

为什么 HN 推它

HN 上常年热议的硬核泛型架构讲座。幽默风趣却又极具杀伤力,把组合式泛型设计和内存分配器黑魔法玩出了新高度。

「它彻底刷新了我的认知,原来写出如此精妙、优雅且兼具极致性能的堆内存分配器竟能通过这种方式实现。」HN 网友原话:It really opened my eyes to how one could very elegantly make a very complex and high-performance heap allocator
英文原摘要(HackerTube / Claude 整理)

Andrei Alexandrescu's CppCon 2015 talk argues that std::allocator is badly designed. He proposes building high-performance allocators from small composable, templated pieces.

HN repeatedly recommends it as an entertaining, mind-opening talk on allocator design and composable generic programming.

HN 上的提及

reference aconz2 · 2017-04 · HN 原文
This work on composing allocators in D
reference p0nce · 2017-04 · HN 原文
I think D goes further in the Stepanov style
strong_rec nly · 2017-05 · HN 原文
gave a great, entertaining, and technically elegant talk on memory allocation in C and C++ at Cppcon 2015 that is well worth watching
rec badsectoracula · 2017-06 · HN 原文
Andrei Alexandrescu had a great talk about allocators in C++ a couple of years ago
strong_rec p0nce · 2018-12 · HN 原文
(mind bending stuff)

相关视频