HackerTube
HomeLongsLikedHistoryWatch laterCategoriesPlaylistsSettings

"Outperforming Imperative with Pure Functional Languages" by Richard Feldman

Strange Loop Conference6 HN recommenders · recommended in 6 months, 2021-2025
YouTube
98K views · 5 years ago · talk · evergreen

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.

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

Functional programmingSoftware performance & optimizationCompilers, interpreters & program analysis#roc#functionalprogramming#immutability#compilers#in-placemutation

8 comments from Hacker News

@greener_grass2025 · in “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.

RecommendsView on HN
@greener_grass2024 · in “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

RecommendsView on HN
@yashrk2023 · in “Roc – A fast, friendly, functional language”

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.

RecommendsView on HN
@Akronymus2022 · in “Ask HN: Functional vs. Imperative Implementation of Algorithms”

> 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

RecommendsView on HN
@aquadrop2022 · in “Haskell2020 Is Dead, but All Hope Is Not Lost (2019)”

Maybe link ? It's not production ready, I just saw nice talk by Richard Feldman [1] about it and it's inspired by Elm. [1] ▶ this video

RecommendsView on HN
@yewenjie2022 · in “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

CitesView on HN
@niels_bom2021 · in “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

RecommendsView on HN
@memco2021 · in “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

RecommendsView on HN
Why Isn't Functional Programming the Norm? – Richard Feldman46:09

Why Isn't Functional Programming the Norm? – Richard Feldman

Metosin
1.6M views • 7 years ago
Ron Pressler - Pull Push: Please stop polluting our imperative languages with pure concepts-Curry On44:43

Ron Pressler - Pull Push: Please stop polluting our imperative languages with pure concepts-Curry On

Curry On!
25K views • 11 years ago
"Agility & Robustness: Clojure spec" by Stuart Halloway40:00

"Agility & Robustness: Clojure spec" by Stuart Halloway

Strange Loop Conference
25K views • 10 years ago
Analyzing Programs with Z343:31

Analyzing Programs with Z3

Compose Conference
24K views • 10 years ago
Lecture 1A: Overview and Introduction to Lisp1:12:56

Lecture 1A: Overview and Introduction to Lisp

MIT OpenCourseWare
420K views • 7 years ago
Lecture 1B | MIT 6.001 Structure and Interpretation, 198658:22

Lecture 1B | MIT 6.001 Structure and Interpretation, 1986

MIT OpenCourseWare
116K views • 17 years ago
Lecture 7A: Metacircular Evaluator, Part 11:24:38

Lecture 7A: Metacircular Evaluator, Part 1

MIT OpenCourseWare
32K views • 7 years ago
Brian Beckman: Don't fear the Monad1:07:10

Brian Beckman: Don't fear the Monad

jasonofthel33t
415K views • 13 years ago
Keynote: The Last Hope for Scala's Infinity War - John A. De Goes45:03

Keynote: The Last Hope for Scala's Infinity War - John A. De Goes

Scalapeño
36K views • 8 years ago
"Datafun: a functional query language" by Michael Arntzenius42:31

"Datafun: a functional query language" by Michael Arntzenius

Strange Loop Conference
9K views • 9 years ago
"Pixie - A Lightweight Lisp with 'Magical' Powers" by Timothy Baldridge33:13

"Pixie - A Lightweight Lisp with 'Magical' Powers" by Timothy Baldridge

Strange Loop Conference
30K views • 11 years ago
Effective Programs - 10 Years of Clojure - Rich Hickey1:14:52

Effective Programs - 10 Years of Clojure - Rich Hickey

ClojureTV
176K views • 9 years ago
Clojure in a nutshell by James Trunk32:44

Clojure in a nutshell by James Trunk

Func Prog Sweden
104K views • 5 years ago
"Controlling Time and Space: understanding the many formulations of FRP" by Evan Czaplicki40:55

"Controlling Time and Space: understanding the many formulations of FRP" by Evan Czaplicki

Strange Loop Conference
69K views • 12 years ago
Effective ML1:09:24

Effective ML

Jane Street
30K views • 10 years ago
Simon Peyton Jones: Data Parallel Haskell1:19:57

Simon Peyton Jones: Data Parallel Haskell

nuACM
28K views • 16 years ago
2013 Keynote: Chandler Carruth: Optimizing the Emergent Structures of C++1:33:02

2013 Keynote: Chandler Carruth: Optimizing the Emergent Structures of C++

CppNow
34K views • 13 years ago
Are We There Yet - Rich Hickey1:10:05

Are We There Yet - Rich Hickey

Zhang Jian
24K views • 7 years ago
Hey Underscore, You're Doing It Wrong!36:31

Hey Underscore, You're Doing It Wrong!

InfoQ
141K views • 13 years ago
The Functional Programmer's Toolkit - Scott Wlaschin1:05:51

The Functional Programmer's Toolkit - Scott Wlaschin

NDC Conferences
79K views • 7 years ago