HackerTubewatch
Surprise me
Frame from "Outperforming Imperative with Pure Functional Languages" by Richard Feldman Plays via YouTube's privacy-enhanced embed

"Outperforming Imperative with Pure Functional Languages" by Richard Feldman

46 videos recommended on HN
YouTube
6 HN users recommended this talk6 months2021–2025 score 6
Years with an HN recommendation, 2007–2026

Recommended as the clearest explanation of why immutable data need not be slow, and as the introduction to Roc.

Richard Feldman explains how pure functional languages can match or beat imperative ones on performance. Compilers can turn immutable code into in-place mutation, avoiding naive copying. The talk draws on his work on the Roc language.

“As a starting point for those nitty grittys, this talk is probably as good as any” (HN, 2022)

7 recommendations · 1 citations · Talks · intermediate

8 Hacker News comments

From the HN archive; up to 20 kept per video, favoring different commenters. Recommendations first.

@memco Nov 2021 Recommends
on HN thread 4x Smaller, 50x Faster
> How would one optimize for immutability in this case, other than turning it back into mutability behind the scenes? Roc-lang, which is a functional, systems language in development uses something called opportunistic in-place mutation to do just that. Here's a video where the creator talks about it: [this video]
Creator explains opportunistic in-place mutation in functional language Roc.
@niels_bom Nov 2021 Recommends
on HN thread 4x Smaller, 50x Faster
This talk by Richard Feldman about Roc (a new language) goed into why immutable does not necessarily mean slow and given enough attention can mean higher performance in certain cases: [this video]
Explains why immutable data can be fast.
@Akronymus Jun 2022 Recommends
on HN thread Ask HN: Functional vs. Imperative Implementation of Algorithms
Read more
> Functional programming experts say that their code is efficient because the compiler translates it to an efficient representation on the CPU. They have TCO and other things. But they don't mutate data and hence every function call creates a new data in memory taking up space. How do they overcome that? By letting the compiler make assumptions. For example, consecutive map calls can be converted into a single one. If the data isn't shared with something else, the compiler can mutate it. MUCH easier to paralellize maps. As a starting point for those nitty grittys, this talk is probably as good as any [this video]
Explains how functional compilers achieve efficiency without naive copying.
@yashrk Nov 2023 Recommends
on HN thread Roc – A fast, friendly, functional language
Read more
If you are interested, «why yet another programming language?». The unique selling point of Roc is clever optimization to convert purely functional source code to deep-imperative fast machine code, while keeping all the correctness of functional algorithms. See this video of Richard Feldman for details — «Outperforming Imperative with Pure Functional Languages»: [this video] Among those clever optimizations: - static reference counting (no GC, like in Rust, but with no borrowing and borrow problems); - stack allocation of the data with no external links; - hidden («opportunistic») mutability even in the cases, where Haskell or Lisp will copy the value.
Explains how Roc turns pure functional code into fast imperative machine code.
@greener_grass Oct 2024 Recommends
on HN thread Serialization Is the Secret
1. Structural sharing - most data doesn't change so you create a copy that reuses much of the original structure 2. Garbage collection and lexical scopes - you clean up memory quickly and in batch 3. Compiler optimizations - you turn functional constructs into imperative ones that reuse and mutate memory at compile-time, where it is provably safe to do so Roc Lang might interest you: [this video]
Introduces Roc and how functional constructs become in-place mutation.
@greener_grass Feb 2025 Recommends
on HN thread Roc rewrites the compiler in Zig
We already have many great GC'd functional languages at that performance level. I first learned about Roc from this talk: [this video] That's a niche that is not currently filled (well, maybe MLTon) and that has me very excited! I'm sure I'm not alone here.
Introduces Roc, a fast functional language without GC.

Citations, criticism and jokes

@yewenjie Feb 2022 Cites it
on HN thread High-order Virtual Machine (HVM): Massively parallel, optimal functional runtime
So many new programming languages coming up with clever features that makes me wish I could mix and match their core features while using libraries from more popular languages. Up and coming Languages I am excited about - 1. Roc - [this video] 2. Zig - [link] 3. Scopes - [link] 4. Gleam - [link] 5. Odin - [link] 6. Koka - [link] 7. Unison - [link]
Talk about the Roc language, listed among exciting new languages.

Video list and Hacker News comment labels from HackerTube (prompted by @karpathy), released under ODC-By 1.0, built on the open-index/hacker-news archive. Hacker News data is provided by Y Combinator; comments remain the work of their authors. Video titles, channel names and thumbnails belong to their creators and are shown via YouTube. HackerTube Watch is an unofficial edition. Data export of 2026-10-31.

Keyboard shortcuts

/
Search
j k
Next / previous video
r
Surprise me
l
Like (video page)
w
Watch later (video page)
?
This help
Esc
Close