← Lex Fridman

Chris Lattner: The Future of Computing and Programming Languages

Episode 1312020-10-19English

Guests: Chris Lattner

Listen to this episode00:00 / 2:47:38
Reading settings
Reading preferences
Text size
Download in-depth read
Read offline

In-depth read pending

Downloads are not available yet.

§01Transcript · 00:00–08:39

00:00The following is a conversation with Chris Latner,

00:02his second time on the podcast.

00:04He's one of the most brilliant engineers

00:06in modern computing, having created

00:08LLVM compiler infrastructure project,

00:11the Clang compiler, the Swift programming language,

00:14a lot of key contributions to TensorFlow and TPUs

00:17as part of Google.

00:19He served as vice president of autopilot software at Tesla,

00:23was a software innovator and leader at Apple,

00:26and now is at SciFive as senior vice president

00:29of platform engineering, looking to revolutionize

00:32chip design to make it faster, better, and cheaper.

00:36Quick mention of each sponsor, followed by some thoughts

00:39related to the episode.

00:40First sponsor is Blinkist, an app that summarizes

00:43key ideas from thousands of books.

00:45I use it almost every day to learn new things

00:48or to pick which books I want to read or listen to next.

00:52Second is Neuro, the maker of functional sugar free gum

00:55and mints that I use to supercharge my mind

00:58with caffeine, altheanine, and B vitamins.

01:01Third is Masterclass, online courses from the best people

01:05in the world on each of the topics covered,

01:08from rockets, to game design, to poker,

01:11to writing, and to guitar.

01:13And finally, Cash App, the app I use to send money

01:16to friends for food, drinks, and unfortunately, lost bets.

01:21Please check out the sponsors in the description

01:23to get a discount and to support this podcast.

01:27As a side note, let me say that Chris has been

01:29an inspiration to me on a human level

01:32because he is so damn good as an engineer

01:35and leader of engineers, and yet he's able to stay humble,

01:38especially humble enough to hear the voices

01:41of disagreement and to learn from them.

01:43He was supportive of me and this podcast

01:46from the early days, and for that, I'm forever grateful.

01:49To be honest, most of my life, no one really believed

01:52that I would amount to much.

01:53So when another human being looks at me,

01:56it makes me feel like I might be someone special,

01:58it can be truly inspiring.

02:00That's a lesson for educators.

02:02The weird kid in the corner with a dream

02:05is someone who might need your love and support

02:08in order for that dream to flourish.

02:10If you enjoy this thing, subscribe on YouTube,

02:13review it with five stars on Apple Podcast,

02:15follow on Spotify, support on Patreon,

02:17or connect with me on Twitter at Lex Friedman.

02:21And now, here's my conversation with Chris Latner.

02:24What are the strongest qualities of Steve Jobs,

02:28Elon Musk, and the great and powerful Jeff Dean

02:32since you've gotten the chance to work with each?

02:36You're starting with an easy question there.

02:38These are three very different people.

02:40I guess you could do maybe a pairwise comparison

02:43between them instead of a group comparison.

02:45So if you look at Steve Jobs and Elon,

02:48I worked a lot more with Elon than I did with Steve.

02:51They have a lot of commonality.

02:52They're both visionary in their own way.

02:55They're both very demanding in their own way.

02:58My sense is Steve is much more human factor focused

03:02where Elon is more technology focused.

03:04What does human factor mean?

03:05Steve's trying to build things that feel good,

03:08that people love, that affect people's lives, how they live.

03:11He's looking into the future a little bit

03:14in terms of what people want.

03:17Where I think that Elon focuses more on

03:20learning how exponentials work and predicting

03:22the development of those.

03:24Steve worked with a lot of engineers.

03:26That was one of the things that are reading the biography.

03:29How can a designer essentially talk to engineers

03:33and get their respect?

03:35I think, so I did not work very closely with Steve.

03:37I'm not an expert at all.

03:38My sense is that he pushed people really hard,

03:41but then when he got an explanation that made sense to him,

03:44then he would let go.

03:45And he did actually have a lot of respect for engineering,

03:49but he also knew when to push.

03:51And when you can read people well,

03:54you can know when they're holding back

03:56and when you can get a little bit more out of them.

03:58And I think he was very good at that.

04:01I mean, if you compare the other folks,

04:03so Jeff Dean, right?

04:05Jeff Dean's an amazing guy.

04:06He's super smart, as are the other guys.

04:10Jeff is a really, really, really nice guy, well meaning.

04:13He's a classic Googler.

04:15He wants people to be happy.

04:17He combines it with brilliance

04:19so he can pull people together in a really great way.

04:22He's definitely not a CEO type.

04:24I don't think he would even want to be that.

04:28Do you know if he still programs?

04:29Oh yeah, he definitely programs.

04:30Jeff is an amazing engineer today, right?

04:32And that has never changed.

04:34So it's really hard to compare Jeff to either of those two.

04:40I think that Jeff leads through technology

04:43and building it himself and then pulling people in

04:45and inspiring them.

04:46And so I think that that's one of the amazing things

04:50about Jeff.

04:50But each of these people, with their pros and cons,

04:53all are really inspirational

04:55and have achieved amazing things.

04:56So I've been very fortunate to get to work with these guys.

05:00For yourself, you've led large teams,

05:03you've done so many incredible,

05:06difficult technical challenges.

05:08Is there something you've picked up from them

05:10about how to lead?

05:12Yeah, so I mean, I think leadership is really hard.

05:14It really depends on what you're looking for there.

05:17I think you really need to know what you're talking about.

05:20So being grounded on the product, on the technology,

05:23on the business, on the mission is really important.

05:28Understanding what people are looking for,

05:29why they're there.

05:30One of the most amazing things about Tesla

05:32is the unifying vision, right?

05:34People are there because they believe in clean energy

05:37and electrification, all these kinds of things.

05:39The other is to understand what really motivates people,

05:42how to get the best people,

05:43how to build a plan that actually can be executed, right?

05:46There's so many different aspects of leadership

05:48and it really depends on the time, the place, the problems.

05:52There's a lot of issues that don't need to be solved.

05:54And so if you focus on the right things and prioritize well,

05:57that can really help move things.

05:59Two interesting things you mentioned.

06:01One is you really have to know what you're talking about.

06:03How you've worked on your business,

06:08you've worked on a lot of very challenging technical things.

06:12So I kind of assume you were born technically savvy,

06:18but assuming that's not the case,

06:20how did you develop technical expertise?

06:24Like even at Google you worked on,

06:27I don't know how many projects,

06:28but really challenging, very varied.

06:32Compilers, TPUs, hardware, cloud stuff,

06:34bunch of different things.

06:36The thing that I've become comfortable

06:37as I've more comfortable with as I've gained experience

06:42is being okay with not knowing.

06:45And so a major part of leadership is actually,

06:49it's not about having the right answer,

06:50it's about getting the right answer.

06:52And so if you're working in a team of amazing people, right?

06:56And many of these places, many of these companies

06:58all have amazing people.

07:00It's the question of how do you get people together?

07:02How do you build trust?

07:04How do you get people to open up?

07:05How do you get people to be vulnerable sometimes

07:10with an idea that maybe isn't good enough,

07:11but it's the start of something beautiful?

07:13How do you provide an environment

07:17where you're not just like top down,

07:18thou shalt do the thing that I tell you to do, right?

07:21But you're encouraging people to be part of the solution

07:23and providing a safe space

07:26where if you're not doing the right thing,

07:27they're willing to tell you about it, right?

07:29So you're asking dumb questions?

07:31Yeah, dumb questions are my specialty, yeah.

07:33Well, so I've been in the hardware realm recently

07:35and I don't know much at all about how chips are designed.

07:39I know a lot about using them.

07:40I know some of the principles

07:41and the art's technical level of this,

07:43but it turns out that if you ask a lot of dumb questions,

07:47you get smarter really, really quick.

07:48And when you're surrounded by people that want to teach

07:51and learn themselves, it can be a beautiful thing.

07:56So let's talk about programming languages, if it's okay.

07:58Sure, sure.

07:59At the highest absurd philosophical level,

08:01because I...

08:02Don't get romantic on me, Lex.

08:03I will forever get romantic and torture you, I apologize.

08:09Why do programming languages even matter?

08:14Okay, well, thank you very much.

08:15You're saying why should you care

08:17about any one programming language

08:18or why do we care about programming computers or?

08:20No, why do we care about programming language design,

08:25creating effective programming languages,

08:30choosing one programming languages

08:32such as another programming language,

08:34why we keep struggling and improving

08:37through the evolution of these programming languages.

§02Transcript · 08:39–16:55

08:39Sure, sure, sure.

08:40Okay, so I mean, I think you have to come back

08:42to what are we trying to do here, right?

08:43So we have these beasts called computers

08:47that are very good at specific kinds of things

08:48and we think it's useful to have them do it for us, right?

08:52Now you have this question of how best to express that

08:55because you have a human brain still

08:57that has an idea in its head

08:58and you want to achieve something, right?

09:00So, well, there's lots of ways of doing this.

09:03You can go directly to the machine

09:04and speak assembly language

09:06and then you can express directly

09:07what the computer understands, that's fine.

09:10You can then have higher and higher and higher levels

09:12of abstraction up until machine learning

09:14and you're designing a neural net to do the work for you.

09:18The question is where along this way do you want to stop

09:21and what benefits do you get out of doing so?

09:23And so programming languages in general,

09:25you have C, you have Fortran, Java and Ada, Pascal, Swift,

09:31you have lots of different things.

09:33They'll have different trade offs

09:34and they're tackling different parts of the problems.

09:36Now, one of the things that most programming languages do

09:39is they're trying to make it

09:40so that you have pretty basic things

09:42like portability across different hardware.

09:45So you've got, I'm gonna run on an Intel PC,

09:47I'm gonna run on a RISC 5 PC,

09:49I'm gonna run on a ARM phone or something like that, fine.

09:53I wanna write one program and have it portable.

09:55And this is something that assembly doesn't do.

09:57Now, when you start looking

09:59at the space of programming languages,

10:00this is where I think it's fun

10:02because programming languages all have trade offs

10:06and most people will walk up to them

10:07and they look at the surface level of syntax and say,

10:11oh, I like curly braces or I like tabs

10:13or I like semi colons or not or whatever, right?

10:17Subjective, fairly subjective, very shallow things.

10:21But programming languages when done right

10:23can actually be very powerful.

10:24And the benefit they bring is expression.

10:30Okay, and if you look at programming languages,

10:32there's really kind of two different levels to them.

10:34One is the down in the dirt, nuts and bolts

10:37of how do you get the computer to be efficient,

10:39stuff like that, how they work,

10:40type systems, compiler stuff, things like that.

10:43The other is the UI.

10:45And the UI for programming language

10:47is really a design problem

10:48and a lot of people don't think about it that way.

10:50And the UI, you mean all that stuff with the braces and?

10:53Yeah, all that stuff's the UI and what it is

10:55and UI means user interface.

10:58And so what's really going on is

11:00it's the interface between the guts and the human.

11:04And humans are hard, right?

11:05Humans have feelings, they have things they like,

11:09they have things they don't like.

11:10And a lot of people treat programming languages

11:12as though humans are just kind of abstract creatures

11:16that cannot be predicted.

11:17But it turns out that actually there is better and worse.

11:21Like people can tell when a programming language is good

11:24or when it was an accident, right?

11:26And one of the things with Swift in particular

11:29is that a tremendous amount of time

11:30by a tremendous number of people

11:33have been put into really polishing and making it feel good.

11:36But it also has really good nuts and bolts underneath it.

11:39You said that Swift makes a lot of people feel good.

11:42How do you get to that point?

11:45So how do you predict that tens of thousands,

11:51hundreds of thousands of people are going to enjoy

11:53using this user experience of this programming language?

11:57Well, you can look at it in terms of better and worse, right?

11:59So if you have to write lots of boilerplate

12:01or something like that, you will feel unproductive.

12:03And so that's a bad thing.

12:05You can look at it in terms of safety.

12:06If like C for example,

12:08is what's called a memory unsafe language.

12:10And so you get dangling pointers

12:11and you get all these kinds of bugs

12:13that then you have spent tons of time debugging

12:15and it's a real pain in the butt and you feel unproductive.

12:17And so by subtracting these things from the experience,

12:19you get happier people.

12:22But again, keep interrupting.

12:25I'm sorry, but so hard to deal with.

12:29If you look at the people that are most productive

12:31on Stack Overflow, they have a set of priorities

12:37that may not always correlate perfectly

12:39with the experience of the majority of users.

12:43If you look at the most upvoted,

12:46quote unquote, correct answer on Stack Overflow,

12:49it usually really sort of prioritizes

12:55like safe code, proper code, stable code,

13:00you know, that kind of stuff.

13:01As opposed to like,

13:02if I wanna use go to statements in my basic, right?

13:08I wanna use go to statements.

13:09Like what if 99% of people wanna use go to statements?

13:12So you use completely improper, you know, unsafe syntax.

13:16I don't think that people actually,

13:17like if you boil it down and you get below

13:19the surface level, people don't actually care

13:21about go tos or if statements or things like this.

13:24They care about achieving a goal, right?

13:26So the real question is I wanna set up a web server

13:30and I wanna do a thing, whatever.

13:32Like how quickly can I achieve that, right?

13:34And so from a programming language perspective,

13:36there's really two things that matter there.

13:39One is what libraries exist

13:41and then how quickly can you put it together

13:44and what are the tools around that look like, right?

13:47And when you wanna build a library that's missing,

13:49what do you do?

13:50Okay, now this is where you see huge divergence

13:53in the force between worlds, okay?

13:55And so you look at Python, for example.

13:57Python is really good at assembling things,

13:59but it's not so great at building all the libraries.

14:02And so what you get because of performance reasons,

14:04other things like this,

14:05is you get Python layered on top of C, for example,

14:09and that means that doing certain kinds of things

14:11well, it doesn't really make sense to do in Python.

14:13Instead you do it in C and then you wrap it

14:15and then you have, you're living in two worlds

14:17and two worlds never is really great

14:19because tooling and the debugger doesn't work right

14:21and like all these kinds of things.

14:23Can you clarify a little bit what you mean

14:25by Python is not good at building libraries,

14:28meaning it doesn't make it conducive.

14:30Certain kinds of libraries.

14:31No, but just the actual meaning of the sentence,

14:35meaning like it's not conducive to developers

14:38to come in and add libraries

14:40or is it the duality of the,

14:44it's a dance between Python and C and...

14:48Well, so Python's amazing.

14:49Python's a great language.

14:50I did not mean to say that Python is bad for libraries.

14:53What I meant to say is there are libraries

14:56that Python's really good at that you can write in Python,

15:00but there are other things,

15:01like if you wanna build a machine learning framework,

15:03you're not gonna build a machine learning framework

15:05in Python because of performance, for example,

15:07or you want GPU acceleration or things like this.

15:10Instead, what you do is you write a bunch of C

15:13or C++ code or something like that,

15:15and then you talk to it from Python, right?

15:18And so this is because of decisions

15:21that were made in the Python design

15:23and those decisions have other counterbalancing forces.

15:27But the trick when you start looking at this

15:29from a programming language perspective,

15:31you start to say, okay, cool.

15:33How do I build this catalog of libraries

15:36that are really powerful?

15:37And how do I make it so that then they can be assembled

15:40into ways that feel good

15:42and they generally work the first time?

15:44Because when you're talking about building a thing,

15:46you have to include the debugging, the fixing,

15:50the turnaround cycle, the development cycle,

15:51all that kind of stuff

15:53into the process of building the thing.

15:56It's not just about pounding out the code.

15:58And so this is where things like catching bugs

16:01at compile time is valuable, for example.

16:04But if you dive into the details in this,

16:07Swift, for example, has certain things like value semantics,

16:10which is this fancy way of saying

16:11that when you treat a variable like a value,

16:18it acts like a mathematical object would.

16:21Okay, so you have used PyTorch a little bit.

16:25In PyTorch, you have tensors.

16:26Tensors are n dimensional grid of numbers, very simple.

16:31You can do plus and other operators on them.

16:34It's all totally fine.

16:35But why do you need to clone a tensor sometimes?

16:39Have you ever run into that?

16:40Yeah.

16:41Okay, and so why is that?

16:42Why do you need to clone a tensor?

16:43It's the usual object thing that's in Python.

16:46So in Python, and just like with Java

16:49and many other languages, this isn't unique to Python.

16:51In Python, it has a thing called reference semantics,

16:53which is the nerdy way of explaining this.

§03Transcript · 16:55–24:43

16:55And what that means is you actually have a pointer

16:58do a thing instead of the thing, okay?

17:01Now, this is due to a bunch of implementation details

17:05that you don't want to go into.

17:06But in Swift, you have this thing called value semantics.

17:09And so when you have a tensor in Swift, it is a value.

17:12If you copy it, it looks like you have a unique copy.

17:15And if you go change one of those copies,

17:16then it doesn't update the other one

17:19because you just made a copy of this thing, right?

17:21So that's like highly error prone

17:24in at least computer science, math centric disciplines

17:29about Python, that like the thing you would expect

17:33to behave like math.

17:35Like math, it doesn't behave like math.

17:38And in fact, quietly it doesn't behave like math

17:41and then can ruin the entirety of your math thing.

17:43Exactly.

17:44Well, and then it puts you in debugging land again.

17:45Yeah.

17:46Right now, you just want to get something done

17:48and you're like, wait a second, where do I need to put clone?

17:51And what level of the stack, which is very complicated,

17:54which I thought I was reusing somebody's library

17:56and now I need to understand it

17:57to know where to clone a thing, right?

17:59And hard to debug, by the way.

18:01Exactly, right.

18:02And so this is where programming languages really matter.

18:04Right, and so in Swift having value semantics

18:06so that both you get the benefit of math,

18:10working like math, right?

18:12But also the efficiency that comes with certain advantages

18:15there, certain implementation details there

18:17really benefit you as a programmer, right?

18:18Can you clarify the value semantics?

18:20Like how do you know that a thing should be treated

18:22like a value?

18:23Yeah, so Swift has a pretty strong culture

18:27and good language support for defining values.

18:30And so if you have an array,

18:31so tensors are one example that the machine learning folks

18:34are very used to.

18:36Just think about arrays, same thing,

18:38where you have an array, you create an array,

18:41you put two or three or four things into it,

18:43and then you pass it off to another function.

18:46What happens if that function adds some more things to it?

18:51Well, you'll see it on the side that you pass it in, right?

18:54This is called reference semantics.

18:56Now, what if you pass an array off to a function,

19:01it scrolls it away in some dictionary

19:02or some other data structure somewhere, right?

19:04Well, it thought that you just handed it that array,

19:07then you return back and that reference to that array

19:10still exists in the caller,

19:12and they go and put more stuff in it, right?

19:15The person you handed it off to

19:17may have thought they had the only reference to that,

19:20and so they didn't know that this was gonna change

19:22underneath the covers.

19:23And so this is where you end up having to do clone.

19:26So like I was passed a thing,

19:27I'm not sure if I have the only version of it,

19:30so now I have to clone it.

19:32So what value semantics does is it allows you to say,

19:34hey, I have a, so in Swift, it defaults to value semantics.

19:38Oh, so it defaults to value semantics,

19:40and then because most things

19:42should end up being like values,

19:44then it makes sense for that to be the default.

19:46And one of the important things about that

19:47is that arrays and dictionaries

19:48and all these other collections

19:49that are aggregations of other things

19:51also have value semantics.

19:53And so when you pass this around

19:55to different parts of your program,

19:56you don't have to do these defensive copies.

19:59And so this is great for two sides, right?

20:01It's great because you define away the bug,

20:04which is a big deal for productivity,

20:05the number one thing most people care about,

20:08but it's also good for performance

20:09because when you're doing a clone,

20:11so you pass the array down to the thing,

20:13it's like, I don't know if anybody else has it,

20:15I have to clone it.

20:16Well, you just did a copy of a bunch of data.

20:18It could be big.

20:19And then it could be that the thing that called you

20:21is not keeping track of the old thing.

20:24So you just made a copy of it,

20:25and you may not have had to.

20:27And so the way the value semantics work in Swift

20:30is it uses this thing called copy on write,

20:32which means that you get the benefit of safety

20:35and performance.

20:36And it has another special trick

20:38because if you think certain languages like Java,

20:41for example, they have immutable strings.

20:43And so what they're trying to do

20:44is they provide value semantics

20:46by having pure immutability.

20:48Functional languages have pure immutability

20:51in lots of different places,

20:52and this provides a much safer model

20:53and it provides value semantics.

20:56The problem with this is if you have immutability,

20:58everything is expensive.

20:59Everything requires a copy.

21:02For example, in Java, if you have a string X

21:05and a string Y, you append them together,

21:07we have to allocate a new string to hold X, Y.

21:12If they're immutable.

21:13Well, strings in Java are immutable.

21:16And if there's optimizations for short ones,

21:19it's complicated, but generally think about them

21:22as a separate allocation.

21:24And so when you append them together,

21:26you have to go allocate a third thing

21:28because somebody might have a pointer

21:29to either of the other ones, right?

21:31And you can't go change them.

21:32So you have to go allocate a third thing.

21:34Because of the beauty of how the Swift value semantics

21:36system works out, if you have a string in Swift

21:38and you say, hey, put in X, right?

21:40And they say, append on Y, Z, W,

21:44it knows that there's only one reference to that.

21:47And so it can do an in place update.

21:50And so you're not allocating tons of stuff on the side.

21:53You don't have all those problems.

21:54When you pass it off,

21:56you can know you have the only reference.

21:57If you pass it off to multiple different people,

21:59but nobody changes it, they can all share the same thing.

22:02So you get a lot of the benefit of purely immutable design.

22:05And so you get a really nice sweet spot

22:07that I haven't seen in other languages.

22:09Yeah, that's interesting.

22:10I thought there was going to be a philosophical narrative

22:15here that you're gonna have to pay a cost for it.

22:19Cause it sounds like, I think value semantics

22:24is beneficial for easing of debugging

22:27or minimizing the risk of errors,

22:30like bringing the errors closer to the source,

22:35bringing the symptom of the error closer

22:38to the source of the error, however you say that.

22:40But you're saying there's not a performance cost either

22:44if you implement it correctly.

22:46Well, so there's trade offs with everything.

22:48And so if you are doing very low level stuff,

22:51then sometimes you can notice a cost,

22:53but then what you're doing is you're saying,

22:54what is the right default?

22:56So coming back to user interface,

22:59when you talk about programming languages,

23:00one of the major things that Swift does

23:03that makes people love it,

23:04that is not obvious when it comes to designing a language

23:08is this UI principle of progressive disclosure

23:11of complexity.

23:12Okay, so Swift, like many languages is very powerful.

23:16The question is, when do you have to learn

23:18the power as a user?

23:20So Swift, like Python, allows you to start with like,

23:22print hello world, right?

23:24Certain other languages start with like,

23:26public static void main class,

23:30like all the ceremony, right?

23:32And so you go to teach a new person,

23:34hey, welcome to this new thing.

23:36Let's talk about public access control classes.

23:40Wait, what's that?

23:41String system.out.println, like packages,

23:44like, God, right?

23:46And so instead, if you take this and you say,

23:48hey, we need packages, modules,

23:51we need powerful things like classes,

23:54we need data structures, we need like all these things.

23:57The question is, how do you factor the complexity?

23:59And how do you make it so that the normal case scenario

24:02is you're dealing with things that work the right way

24:05in the right way, give you good performance

24:07by default, but then as a power user,

24:11if you want to dive down to it,

24:12you have full C performance, full control

24:15over low level pointers.

24:15You can call malloc if you want to call malloc.

24:18This is not recommended on the first page of every tutorial,

24:20but it's actually really important

24:22when you want to get work done, right?

24:23And so being able to have that is really the design

24:27in programming language design,

24:28and design is really, really hard.

24:31It's something that I think a lot of people kind of,

24:34outside of UI, again, a lot of people just think

24:37is subjective, like there's nothing,

24:40you know, it's just like curly braces or whatever.

§04Transcript · 24:43–32:42

24:43It's just like somebody's preference,

24:45but actually good design is something that you can feel.

24:48And how many people are involved with good design?

24:52So if we looked at Swift, but look at historically,

24:54I mean, this might touch like,

24:57it's almost like a Steve Jobs question too,

24:59like how much dictatorial decision making is required

25:04versus collaborative, and we'll talk about

25:09how all that can go wrong or right, but.

25:11Yeah, well, Swift, so I can't speak to in general,

25:14all design everywhere.

25:15So the way it works with Swift is that there's a core team,

25:19and so a core team is six or seven people ish,

25:22something like that, that is people that have been working

25:25with Swift since very early days, and so.

25:27And by early days is not that long ago.

25:30Okay, yeah, so it became public in 2014,

25:33so it's been six years public now,

25:35but so that's enough time that there's a story arc there.

25:38Okay, yeah, and there's mistakes have been made

25:41that then get fixed, and you learn something,

25:43and then you, you know, and so what the core team does

25:46is it provides continuity, and so you wanna have a,

25:50okay, well, there's a big hole that we wanna fill.

25:54We know we wanna fill it, so don't do other things

25:56that invade that space until we fill the hole, right?

25:59There's a boulder that's missing here,

26:01we wanna do, we will do that boulder,

26:03even though it's not today, keep out of that space.

26:06And the whole team remembers the myth of the boulder

26:10that's there.

26:11Yeah, yeah, there's a general sense

26:12of what the future looks like in broad strokes,

26:14and a shared understanding of that,

26:16combined with a shared understanding of what has happened

26:18in the past that worked out well and didn't work out well.

26:22The next level out is you have the,

26:24what's called the Swift evolution community,

26:25and you've got, in that case, hundreds of people

26:27that really care passionately about the way Swift evolves,

26:30and that's like an amazing thing to, again,

26:33the core team doesn't necessarily need to come up

26:35with all the good ideas.

26:36You got hundreds of people out there

26:38that care about something,

26:39and they come up with really good ideas too,

26:41and that provides this rock tumbler for ideas.

26:45And so the evolution process is,

26:48a lot of people in a discourse forum,

26:50they're like hashing it out and trying to talk about,

26:52okay, well, should we go left or right,

26:54or if we did this, what would be good?

26:55And here you're talking about hundreds of people,

26:57so you're not gonna get consensus, necessarily,

27:00not obvious consensus, and so there's a proposal process

27:04that then allows the core team and the community

27:07to work this out, and what the core team does

27:10is it aims to get consensus out of the community

27:12and provide guardrails, but also provide long term,

27:17make sure we're going the right direction kind of things.

27:20So does that group represent like the,

27:23how much people will love the user interface?

27:27Like, do you think they're able to capture that?

27:29Well, I mean, it's something we talk about a lot,

27:31it's something we care about.

27:32How well we do that's up for debate,

27:34but I think that we've done pretty well so far.

27:36Is the beginner in mind?

27:38Yeah. Like, because you said

27:39the progressive disclosure complexity.

27:40Yeah, so we care a lot about that,

27:44a lot about power, a lot about efficiency,

27:46a lot about, there are many factors to good design,

27:48and you have to figure out a way

27:50to kind of work your way through that, and.

27:53So if you think about, like the language I love is Lisp,

27:57probably still because I use Emacs,

27:59but I haven't done anything, any serious work in Lisp,

28:02but it has a ridiculous amount of parentheses.

28:05Yeah.

28:06I've also, you know, with Java and C++, the braces,

28:14you know, I like, I enjoyed the comfort

28:17of being between braces, you know?

28:20Yeah, yeah, well, let's talk.

28:21And then Python is, sorry to interrupt,

28:23just like, and last thing to me, as a designer,

28:25if I was a language designer, God forbid,

28:28is I would be very surprised that Python with no braces

28:34would nevertheless somehow be comforting also.

28:38So like, I could see arguments for all of this.

28:40But look at this, this is evidence

28:41that it's not about braces versus tabs.

28:44Right, exactly, you're good, that's a good point.

28:47Right, so like, you know, there's evidence that.

28:50But see, like, it's one of the most argued about things.

28:52Oh yeah, of course, just like tabs and spaces,

28:54which it doesn't, I mean, there's one obvious right answer,

28:57but it doesn't actually matter.

28:59What's that?

28:59Let's not, like, come on, we're friends.

29:01Like, come on, what are you trying to do to me here?

29:03People are gonna, yeah, half the people are gonna tune out.

29:05Yeah, so these, so you're able to identify things

29:09that don't really matter for the experience.

29:12Well, no, no, no, it's always a really hard,

29:14so the easy decisions are easy, right?

29:16I mean, fine, those are not the interesting ones.

29:19The hard ones are the ones that are most interesting, right?

29:21The hard ones are the places where,

29:23hey, we wanna do a thing, everybody agrees we should do it,

29:27there's one proposal on the table,

29:28but it has all these bad things associated with it.

29:31Well, okay, what are we gonna do about that?

29:33Do we just take it?

29:34Do we delay it?

29:36Do we say, hey, well, maybe there's this other feature

29:38that if we do that first, this will work out better.

29:41How does this, if we do this,

29:44are we paying ourselves into a corner, right?

29:46And so this is where, again,

29:47you're having that core team of people

29:48that has some continuity and has perspective,

29:51has some of the historical understanding,

29:53is really valuable because you get,

29:56it's not just like one brain,

29:57you get the power of multiple people coming together

29:59to make good decisions,

30:00and then you get the best out of all these people,

30:02and you also can harness the community around it.

30:06And what about the decision of whether in Python

30:09having one type or having strict typing?

30:14Yeah, okay.

30:15Yeah, let's talk about this.

30:16So I like how you put that, by the way.

30:19So many people would say that Python doesn't have types.

30:21Doesn't have types, yeah.

30:22But you're right.

30:23I haven't listened to you enough to where,

30:26I'm a fan of yours and I've listened to way too many

30:29podcasts and videos of you talking about this stuff.

30:32Oh yeah, so I would argue that Python has one type.

30:34And so like when you import Python into Swift,

30:38which by the way works really well,

30:39you have everything comes in as a Python object.

30:41Now here are their trade offs because

30:46it depends on what you're optimizing for.

30:47And Python is a super successful language

30:49for a really good reason.

30:51Because it has one type,

30:52you get duck typing for free and things like this.

30:55But also you're pushing,

30:56you're making it very easy to pound out code on one hand,

31:00but you're also making it very easy to introduce

31:03complicated bugs that you have to debug.

31:05And you pass a string into something that expects an integer

31:08and it doesn't immediately die.

31:10It goes all the way down the stack trace

31:12and you find yourself in the middle of some code

31:13that you really didn't want to know anything about.

31:14And it blows up and you're just saying,

31:16well, what did I do wrong, right?

31:18And so types are good and bad and they have trade offs.

31:21They're good for performance and certain other things

31:23depending on where you're coming from,

31:24but it's all about trade offs.

31:26And so this is what design is, right?

31:28Design is about weighing trade offs

31:30and trying to understand the ramifications

31:32of the things that you're weighing,

31:34like types or not, or one type or many types.

31:38But also within many types,

31:39how powerful do you make that type system

31:41is another very complicated question

31:44with lots of trade offs.

31:45It's very interesting by the way,

31:47but that's like one dimension and there's a bunch

31:52of other dimensions, JIT compiled versus static compiled,

31:55garbage collected versus reference counted

31:57versus manual memory management versus,

32:00like in like all these different trade offs

32:02and how you balance them

32:03are what make a program language good.

32:05Concurrency.

32:06Yeah.

32:07So in all those things, I guess,

32:09when you're designing the language,

32:11you also have to think of how that's gonna get

32:13all compiled down to.

32:15If you care about performance, yeah.

32:17Well, and go back to Lisp, right?

32:18So Lisp also, I would say JavaScript

32:20is another example of a very simple language, right?

32:24And so one of the, so I also love Lisp.

32:27I don't use it as much as maybe you do or you did.

32:29No, I think we're both, everyone who loves Lisp,

32:32it's like, you love, it's like, I don't know,

32:35I love Frank Sinatra,

32:36but like how often do I seriously listen to Frank Sinatra?

32:39Sure, sure.

32:40But you look at that or you look at JavaScript,

§05Transcript · 32:42–40:28

32:42which is another very different,

32:44but relatively simple language.

32:45And there are certain things that don't exist

32:47in the language,

32:49but there is inherent complexity to the problems

32:51that we're trying to model.

32:53And so what happens to the complexity?

32:54In the case of both of them, for example,

32:57you say, well, what about large scale software development?

33:00Okay, well, you need something like packages.

33:02Neither language has a language affordance for packages.

33:05And so what you get is patterns.

33:07You get things like NPN.

33:08You get things like these ecosystems that get built around.

33:12And I'm a believer that if you don't model

33:15at least the most important inherent complexity

33:17in the language,

33:18then what ends up happening

33:19is that complexity gets pushed elsewhere.

33:22And when it gets pushed elsewhere,

33:24sometimes that's great because often building things

33:26as libraries is very flexible and very powerful

33:28and allows you to evolve and things like that.

33:30But often it leads to a lot of unnecessary divergence

33:34in the force and fragmentation.

33:35And when that happens, you just get kind of a mess.

33:39And so the question is, how do you balance that?

33:42Don't put too much stuff in the language

33:44because that's really expensive

33:45and it makes things complicated.

33:46But how do you model enough of the inherent complexity

33:49of the problem that you provide the framework

33:52and the structure for people to think about?

33:54Well, so the key thing to think about

33:57with programming languages,

33:59and you think about what a programming language is therefore,

34:01is it's about making a human more productive, right?

34:04And so there's an old, I think it's Steve Jobs quote

34:07about it's a bicycle for the mind, right?

34:10You can definitely walk,

34:13but you'll get there a lot faster

34:15if you can bicycle on your way.

34:17And...

34:18A programming language is a bicycle for the mind?

34:20Yeah.

34:20Is it basically, wow,

34:22that's really interesting way to think about it.

34:23By raising the level of abstraction,

34:25now you can fit more things in your head.

34:27By being able to just directly leverage somebody's library,

34:30you can now get something done quickly.

34:33In the case of Swift, Swift UI is this new framework

34:36that Apple has released recently for doing UI programming.

34:39And it has this declarative programming model,

34:42which defines away entire classes of bugs.

34:45It builds on value semantics and many other nice Swift things.

34:48And what this does is it allows you to just get way more done

34:51with way less code.

34:53And now your productivity as a developer is much higher,

34:56right?

34:57And so that's really what programming languages

34:59should be about,

35:00is it's not about tabs versus spaces

35:01or curly braces or whatever.

35:03It's about how productive do you make the person.

35:05And you can only see that when you have libraries

35:08that were built with the right intention

35:11that the language was designed for.

35:13And with Swift, I think we're still a little bit early,

35:16but Swift UI and many other things that are coming out now

35:19are really showing that.

35:20And I think that they're opening people's eyes.

35:22It's kind of interesting to think about like how

35:26that the knowledge of something,

35:29of how good the bicycle is,

35:31how people learn about that.

35:33So I've used C++,

35:36now this is not going to be a trash talking session

35:38about C++, but I used C++ for a really long time.

35:41You can go there if you want, I have the scars.

35:45I feel like I spent many years without realizing

35:49like there's languages that could,

35:51for my particular lifestyle, brain style, thinking style,

35:56there's languages that could make me a lot more productive

36:00in the debugging stage, in just the development stage

36:04and thinking like the bicycle for the mind

36:05that I can fit more stuff into my...

36:07Python's a great example of that, right?

36:09I mean, a machine learning framework in Python

36:10is a great example of that.

36:12It's just very high abstraction level.

36:14And so you can be thinking about things

36:15on a like very high level algorithmic level

36:19instead of thinking about, okay, well,

36:20am I copying this tensor to a GPU or not, right?

36:23It's not what you want to be thinking about.

36:25And as I was telling you, I mean,

36:26I guess the question I had is,

36:29how does a person like me or in general people

36:31discover more productive languages?

36:36Like how I was, as I've been telling you offline,

36:39I've been looking for like a project to work on in Swift

36:43so I can really try it out.

36:45I mean, my intuition was like doing a hello world

36:48is not going to get me there

36:50to get me to experience the power of language.

36:54You need a few weeks to change your metabolism.

36:55Exactly, beautifully put.

36:59That's one of the problems with people with diets,

37:01like I'm actually currently, to go in parallel,

37:05but in a small tangent is I've been recently

37:07eating only meat, okay?

37:10And okay, so most people are like,

37:14they think that's horribly unhealthy or whatever,

37:16you have like a million, whatever the science is,

37:20it just doesn't sound right.

37:22Well, so back when I was in college,

37:24we did the Atkins diet, that was a thing.

37:26Similar, but you have to always give these things a chance.

37:30I mean, with dieting, I was not dieting,

37:33but it's just the things that you like.

37:35If I eat, personally, if I eat meat,

37:38just everything, I can be super focused

37:40or more focused than usual.

37:42I just feel great.

37:43I mean, I've been running a lot,

37:46doing pushups and pull ups and so on.

37:47I mean, Python is similar in that sense for me.

37:50Where are you going with this?

37:53I mean, literally, I just felt I had like a stupid smile

37:57on my face when I first started using Python.

38:00I could code up really quick things.

38:02Like I would see the world,

38:05I would be empowered to write a script

38:07to do some basic data processing,

38:11to rename files on my computer.

38:14Like Perl didn't do that for me,

38:18a little bit.

38:19And again, none of these are about which is best

38:22or something like that,

38:23but there's definitely better and worse here.

38:25But it clicks, right?

38:26Well, yeah.

38:27If you look at Perl, for example,

38:29you get bogged down in scalars versus arrays

38:32versus hashes versus type globs

38:34and like all that kind of stuff.

38:35And Python's like, yeah, let's not do this.

38:38And some of it is debugging.

38:39Like everyone has different priorities.

38:41But for me, it's, can I create systems for myself

38:44that empower me to debug quickly?

38:47Like I've always been a big fan,

38:50even just crude like asserts,

38:52like always stating things that should be true,

38:57which in Python, I found in myself doing more

38:59because of type, all these kinds of stuff.

39:02Well, you could think of types in a programming language

39:04as being kind of assert.

39:05Yeah.

39:06They could check the compile time, right?

39:08So how do you learn a new thing?

39:10Well, so this, or how do people learn new things, right?

39:13This is hard.

39:15People don't like to change.

39:17People generally don't like change around them either.

39:19And so we're all very slow to adapt and change.

39:22And usually there's a catalyst that's required

39:25to force yourself over this.

39:27So for learning a programming language,

39:29it really comes down to finding an excuse,

39:32like build a thing that the language is actually good for,

39:36that the ecosystem's ready for.

39:38And so if you were to write an iOS app, for example,

39:42that'd be the easy case.

39:44Obviously you would use Swift for that, right?

39:46There are other...

39:47Android.

39:48So Swift runs on Android.

39:50Oh, does it?

39:51Oh yeah.

39:52Yeah, Swift runs in lots of places.

39:53How does that work?

39:54So...

39:55Okay, so Swift is built on top of LLVM.

39:58LLVM runs everywhere.

40:00LLVM, for example, builds the Android kernel.

40:03Oh, okay.

40:04So yeah.

40:05I didn't realize this.

40:06Yeah, so Swift is very portable, runs on Windows.

40:09There's, it runs on lots of different things.

40:12And Swift, sorry to interrupt, Swift UI,

40:15and then there's a thing called UI Kit.

40:17So can I build an app with Swift?

40:21Well, so that's the thing,

40:22is the ecosystem is what matters there.

40:23So Swift UI and UI Kit are Apple technologies.

40:27Okay, got it.

40:27And so they happen to,

§06Transcript · 40:28–48:12

40:28like Swift UI happens to be written in Swift,

40:30but it's an Apple proprietary framework

40:32that Apple loves and wants to keep on its platform,

40:35which makes total sense.

40:36You go to Android and you don't have that library, right?

40:39And so Android has a different ecosystem of things

40:42that hasn't been built out

40:44and doesn't work as well with Swift.

40:45And so you can totally use Swift to do like arithmetic

40:48and things like this,

40:49but building UI with Swift on Android

40:51is not a great experience right now.

40:54So if I wanted to learn Swift, what's the,

40:58I mean, the one practical different version of that

41:01is Swift for TensorFlow, for example.

41:05And one of the inspiring things for me

41:08with both TensorFlow and PyTorch

41:10is how quickly the community can like switch

41:13from different libraries, like you could see

41:16some of the communities switching to PyTorch now,

41:19but it's very easy to see.

41:21And then TensorFlow is really stepping up its game.

41:24And then there's no reason why,

41:26I think the way it works is basically

41:27it has to be one GitHub repo,

41:29like one paper steps up.

41:31It gets people excited.

41:32It gets people excited and they're like,

41:33ah, I have to learn this Swift for,

41:37what's Swift again?

41:39And then they learn and they fall in love with it.

41:41I mean, that's what happened, PyTorch has it.

41:43There has to be a reason, a catalyst.

41:44Yeah.

41:45And so, and there, I mean, people don't like change,

41:48but it turns out that once you've worked

41:50with one or two programming languages,

41:52the basics are pretty similar.

41:54And so one of the fun things

41:55about learning programming languages,

41:57even maybe Lisp, I don't know if you agree with this,

41:59is that when you start doing that,

42:01you start learning new things.

42:04Cause you have a new way to do things

42:05and you're forced to do them.

42:06And that forces you to explore

42:09and it puts you in learning mode.

42:10And when you get in learning mode,

42:11your mind kind of opens a little bit

42:12and you can see things in a new way,

42:15even when you go back to the old place.

42:17Right.

42:17Yeah, it's totally, well Lisp is functional.

42:19Yeah.

42:21But yeah, I wish there was a kind of window,

42:23maybe you can tell me if there is, there you go.

42:26This is a question to ask,

42:28what is the most beautiful feature

42:29in a programming language?

42:30Before I ask it, let me say like with Python,

42:33I remember I saw Lisp comprehensions.

42:36Yeah.

42:37Was like, when I like really took it in.

42:40Yeah.

42:41I don't know, I just loved it.

42:43It was like fun to do, like it was fun to do that kind of,

42:49something about it to be able to filter through a list

42:52and to create a new list all in a single line was elegant.

42:56I could all get into my head

42:58and it just made me fall in love with the language.

43:01Yeah.

43:02So is there, let me ask you a question.

43:04Is there, what do you use the most beautiful feature

43:07in a programming languages that you've ever encountered

43:11in Swift maybe and then outside of Swift?

43:15I think the thing that I like the most

43:17from a programming language.

43:18So I think the thing you have to think about

43:21with the programming language, again, what is the goal?

43:23You're trying to get people to get things done quickly.

43:27And so you need libraries, you need high quality libraries

43:30and then you need a user base around them

43:32that can assemble them and do cool things with them, right?

43:35And so to me, the question is

43:36what enables high quality libraries?

43:39Okay.

43:40Yeah.

43:41And there's a huge divide in the world

43:43between libraries who enable high quality libraries

43:48versus the ones that put special stuff in the language.

43:52So programming languages that enable high quality libraries?

43:56Got it.

43:57So, and what I mean by that is expressive libraries

44:00that then feel like a natural integrated part

44:03of the language itself.

44:05So an example of this in Swift is that int and float

44:09and also array and string, things like this,

44:12these are all part of the library.

44:13Like int is not hard coded into Swift.

44:17And so what that means is that

44:19because int is just a library thing

44:21defined in the standard library,

44:22along with strings and arrays and all the other things

44:24that come with the standard library.

44:27Well, hopefully you do like int,

44:29but anything that any language features

44:31that you needed to define int,

44:33you can also use in your own types.

44:36So if you wanted to find a quaternion

44:39or something like this, right?

44:41Well, it doesn't come in the standard library.

44:43There's a very special set of people

44:45that care a lot about this,

44:47but those people are also important.

44:49It's not about classism, right?

44:51It's not about the people who care about ints and floats

44:53are more important than the people who care about quaternions.

44:55And so to me, the beautiful things

44:56about programming languages is when you allow

44:58those communities to build high quality libraries,

45:02they feel native.

45:03They feel like they're built into the compiler

45:05without having to be.

45:08What does it mean for the int to be part

45:11of not hard coded in?

45:13So is it like how, so what is an int?

45:18Okay, int is just a integer.

45:20In this case, it's like a 64 bit integer

45:23or something like this.

45:24But so like the 64 bit is hard coded or no?

45:28No, none of that's hard coded.

45:29So int, if you go look at how it's implemented,

45:32it's just a struct in Swift.

45:34And so it's a struct.

45:35And then how do you add two structs?

45:37Well, you define plus.

45:39And so you can define plus on int.

45:41Well, you can define plus on your thing too.

45:43You can define, int is an odd method

45:46or something like that on it.

45:47And so yeah, you can add methods on the things.

45:50Yeah.

45:51So you can define operators, like how it behaves.

45:55That's just beautiful when there's something

45:57about the language which enables others

46:00to create libraries which are not hacky.

46:05Yeah, they feel native.

46:07And so one of the best examples of this is Lisp, right?

46:10Because in Lisp, like all the libraries

46:13are basically part of the language, right?

46:15You write, turn, rewrite systems and things like this.

46:17And so.

46:18Can you as a counter example provide

46:20what makes it difficult to write a library that's native?

46:23Is it the Python C?

46:25Well, so one example, I'll give you two examples.

46:29Java and C++, there's Java and C.

46:33They both allow you to define your own types,

46:35but int is hard code in the language.

46:38Okay, well, why?

46:39Well, in Java, for example, coming back

46:41to this whole reference semantic value semantic thing,

46:45int gets passed around by value.

46:48Yeah.

46:49But if you make like a pair or something like that,

46:53a complex number, right, it's a class in Java.

46:56And now it gets passed around by reference, by pointer.

46:59And so now you lose value semantics, right?

47:02You lost math, okay.

47:04Well, that's not great, right?

47:06If you can do something with int,

47:08why can't I do it with my type, right?

47:10So that's the negative side of the thing I find beautiful

47:15is when you can solve that,

47:17when you can have full expressivity,

47:19where you as a user of the language

47:21have as much or almost as much power

47:24as the people who implemented

47:25all the standard built in stuff,

47:27because what that enables

47:28is that enables truly beautiful libraries.

47:31You know, it's kind of weird

47:32because I've gotten used to that.

47:36That's one, I guess, other aspect

47:37of program language design.

47:39You have to think, you know,

47:41the old first principles thinking,

47:43like, why are we doing it this way?

47:45By the way, I mean, I remember,

47:47because I was thinking about the walrus operator

47:50and I'll ask you about it later,

47:53but it hit me that like the equal sign for assignment.

47:57Yeah.

47:58Like, why are we using the equal sign for assignment?

48:00It's wrong, yeah.

48:02And that's not the only solution, right?

48:04So if you look at Pascal,

48:05they use colon equals for assignment

48:07and equals for equality.

48:11And they use like less than greater than

§07Transcript · 48:12–55:53

48:12instead of the not equal thing.

48:14Yeah.

48:15Like, there are other answers here.

48:16So, but like, and yeah, like I ask you all,

48:19but how do you then decide to break convention

48:24to say, you know what, everybody's doing it wrong.

48:29We're gonna do it right.

48:30Yeah.

48:31So it's like an ROI,

48:33like return on investment trade off, right?

48:35So if you do something weird,

48:37let's just say like not like colon equal

48:39instead of equal for assignment,

48:40that would be weird with today's aesthetic, right?

48:44And so you'd say, cool, this is theoretically better,

48:47but is it better in which ways?

48:49Like, what do I get out of that?

48:50Do I define away class of bugs?

48:52Well, one of the class of bugs that C has

48:54is that you can use like, you know,

48:55if X equals without equals equals X equals Y, right?

49:01Well, turns out you can solve that problem in lots of ways.

49:05Clang, for example, GCC, all these compilers

49:07will detect that as a likely bug, produce a warning.

49:10Do they?

49:11Yeah.

49:12I feel like they didn't.

49:13Oh, Clang does.

49:14They didn't.

49:14GCC didn't.

49:15It's like one of the important things

49:17about programming language design is like,

49:19you're literally creating suffering in the world.

49:22Okay.

49:23Like, I feel like, I mean, one way to see it

49:27is the bicycle for the mind,

49:29but the other way is to like minimizing suffering.

49:32Well, you have to decide if it's worth it, right?

49:33And so let's come back to that.

49:35Okay.

49:36But if you look at this, and again,

49:38this is where there's a lot of detail

49:40that goes into each of these things.

49:42Equal and C returns a value.

49:46Yep.

49:47Is it messed up?

49:48That allows you to say X equals Y equals Z,

49:51like that works in C.

49:52Yeah.

49:53Is it messed up?

49:54You know, most people think it's messed up, I think.

49:57It is very, by messed up, what I mean is

50:00it is very rarely used for good,

50:03and it's often used for bugs.

50:05Yeah.

50:06Right, and so.

50:07That's a good definition of messed up, yeah.

50:09You could use, you know, in hindsight,

50:12this was not such a great idea, right?

50:13No.

50:14One of the things with Swift that is really powerful

50:16and one of the reasons it's actually good

50:18versus it being full of good ideas

50:20is that when we launched Swift 1,

50:23we announced that it was public,

50:26people could use it, people could build apps,

50:27but it was gonna change and break, okay?

50:30When Swift 2 came out, we said, hey, it's open source,

50:33and there's this open process

50:34which people can help evolve and direct the language.

50:37So the community at large, like Swift users,

50:40can now help shape the language as it is.

50:43And what happened as part of that process is

50:46a lot of really bad mistakes got taken out.

50:49So for example, Swift used to have the C style plus plus

50:53and minus minus operators.

50:55Like, what does it mean when you put it before

50:56versus after, right?

50:59Well, that got cargo culted from C into Swift early on.

51:02What's cargo culted?

51:03Cargo culted means brought forward

51:05without really considering it.

51:07Okay.

51:08This is maybe not the most PC term, but.

51:12You have to look it up in Urban Dictionary, yeah.

51:13Yeah, so it got pulled into C without,

51:17or it got pulled into Swift

51:18without very good consideration.

51:20And we went through this process,

51:22and one of the first things got ripped out

51:23was plus plus and minus minus,

51:25because they lead to confusion.

51:27They have very low value over saying x plus equals one,

51:31and x plus equals one is way more clear.

51:34And so when you're optimizing for teachability and clarity

51:36and bugs and this multidimensional space

51:39that you're looking at,

51:40things like that really matter.

51:42And so being first principles on where you're coming from

51:45and what you're trying to achieve

51:46and being anchored on the objective is really important.

51:50Well, let me ask you about the most,

51:54sort of this podcast isn't about information,

51:58it's about drama.

51:59Okay.

52:00Let me talk to you about some drama.

52:01So you mentioned Pascal and colon equals,

52:06there's something that's called the Walrus operator.

52:08Okay.

52:09And Python in Python 3.8 added the Walrus operator.

52:15And the reason I think it's interesting

52:19is not just because of the feature,

52:21it has the same kind of expression feature

52:23you can mention to see that it returns

52:25the value of the assignment.

52:27And then maybe you can comment on that in general,

52:29but on the other side of it,

52:31it's also the thing that toppled the dictator.

52:36So it finally drove Guido

52:39to step down from BDFL, the toxicity of the community.

52:42So maybe what do you think about the Walrus operator

52:46in Python?

52:47Is there an equivalent thing in Swift

52:50that really stress tested the community?

52:54And then on the flip side,

52:56what do you think about Guido stepping down over it?

52:58Yeah, well, if I look past the details

53:01of the Walrus operator,

53:02one of the things that makes it most polarizing

53:04is that it's syntactic sugar.

53:06Okay.

53:07What do you mean by syntactic sugar?

53:09It means you can take something

53:10that already exists in the language

53:11and you can express it in a more concise way.

53:14So, okay, I'm going to play dollars advocate.

53:15So this is great.

53:18Is that a objective or subjective statement?

53:21Like, can you argue that basically anything

53:24isn't syntactic sugar or not?

53:27No, not everything is syntactic sugar.

53:30So for example, the type system,

53:32like can you have classes versus,

53:35like, do you have types or not, right?

53:37So one type versus many types

53:40is not something that affects syntactic sugar.

53:42And so if you say,

53:43I want to have the ability to define types,

53:46I have to have all this like language mechanics

53:47to define classes.

53:49And oh, now I have to have inheritance.

53:51And I have like, I have all this stuff

53:52that's just making the language more complicated.

53:54That's not about sugaring it.

53:58Swift has the sugar.

54:00So like Swift has this thing called if let,

54:02and it has a lot of different types

54:04and it has various operators

54:06that are used to concisify specific use cases.

54:10So the problem with syntactic sugar,

54:12when you're talking about,

54:14hey, I have a thing that takes a lot to write

54:16and I have a new way to write it.

54:17You have this like horrible trade off,

54:19which becomes almost completely subjective,

54:22which is how often does this happen and does it matter?

54:26And one of the things that is true about human psychology,

54:28particularly when you're talking about introducing

54:29a new thing is that people overestimate

54:34the burden of learning something.

54:36And so it looks foreign when you haven't gotten used to it.

54:38But if it was there from the beginning,

54:40of course it's just part of Python.

54:42Like unquestionably, like this is just the thing I know.

54:45And it's not a new thing that you're worried about learning.

54:47It's just part of the deal.

54:49Now with Guido, I don't know Guido well.

54:55Yeah, have you passed cross much?

54:56Yeah, I've met him a couple of times,

54:58but I don't know Guido well.

55:00But the sense that I got out of that whole dynamic

55:03was that he had put the,

55:04not just the decision maker weight on his shoulders,

55:08but it was so tied to his personal identity

55:11that he took it personally and he felt the need

55:15and he kind of put himself in the situation

55:16of being the person,

55:18instead of building a base of support around him.

55:20I mean, this is probably not quite literally true,

55:23but by too much concentrated on him, right?

55:29And that can wear you down.

55:31Well, yeah, particularly because people then say,

55:33Guido, you're a horrible person.

55:35I hate this thing, blah, blah, blah, blah, blah, blah, blah.

55:37And sure, it's like maybe 1% of the community

55:40that's doing that, but Python's got a big community.

55:43And 1% of millions of people is a lot of hate mail.

55:46And that just from human factor will just wear on you.

55:49Well, to clarify, it looked from just what I saw

55:52in the messaging for the,

§08Transcript · 55:53–1:03:41

55:53let's not look at the million Python users,

55:55but at the Python core developers,

55:58it feels like the majority, the big majority

56:01on a vote were opposed to it.

56:03Okay, I'm not that close to it, so I don't know.

56:06Okay, so the situation is like literally,

56:10yeah, I mean, the majority of the core developers

56:13are against it.

56:13Were opposed to it.

56:14So, and they weren't even like against it.

56:20It was, there was a few, well, they were against it,

56:23but the against it wasn't like, this is a bad idea.

56:27They were more like, we don't see why this is a good idea.

56:31And what that results in is there's a stalling feeling,

56:35like you just slow things down.

56:37Now, from my perspective, that you could argue this,

56:41and I think it's very interesting

56:44if we look at politics today and the way Congress works,

56:47it's slowed down everything.

56:49It's a dampener.

56:50Yeah, it's a dampener, but like,

56:51that's a dangerous thing too,

56:53because if it dampens things like, you know,

56:57if the dampening results.

56:58What are you talking about?

56:59Like, it's a low pass filter,

57:00but if you need billions of dollars

57:02injected into the economy or trillions of dollars,

57:05then suddenly stuff happens, right?

57:06And so.

57:07For sure.

57:09So you're talking about.

57:10I'm not defending our political situation,

57:11just to be clear.

57:13But you're talking about like a global pandemic.

57:16Well.

57:17I was hoping we could fix like the healthcare system

57:20and the education system, like, you know.

57:22I'm not a politics person.

57:24I don't know.

57:26When it comes to languages,

57:28the community's kind of right in terms of,

57:30it's a very high burden to add something to a language.

57:33So as soon as you add something,

57:34you have a community of people building on it

57:35and you can't remove it, okay?

57:38And if there's a community of people

57:39that feel really uncomfortable with it,

57:41then taking it slow, I think, is an important thing to do.

57:45And there's no rush, particularly if it was something

57:48that's 25 years old and is very established.

57:50And, you know, it's not like coming into its own.

57:54What about features?

57:55Well, so I think that the issue with Guido

57:58is that maybe this is a case

58:00where he realized it had outgrown him

58:03and it went from being the language.

58:06So Python, I mean, Guido's amazing,

58:09but Python isn't about Guido anymore.

58:12It's about the users.

58:13And to a certain extent, the users own it.

58:15And, you know, Guido spent years of his life,

58:19a significant fraction of his career on Python.

58:22And from his perspective, I imagine he's like,

58:24well, this is my thing.

58:25I should be able to do the thing I think is right.

58:28But you can also understand the users

58:30where they feel like, you know, this is my thing.

58:33I use this, like, and I don't know, it's a hard thing.

58:38But what, if we could talk about leadership in this,

58:41because it's so interesting to me.

58:42I'm gonna make, I'm gonna work.

58:44Hopefully somebody makes it.

58:45If not, I'll make it a Walrus Operator shirt,

58:47because I think it represents, to me,

58:50maybe it's my Russian roots or something.

58:52But, you know, it's the burden of leadership.

58:56Like, I feel like to push back,

59:01I feel like progress can only,

59:02like most difficult decisions, just like you said,

59:06there'll be a lot of divisiveness over,

59:09especially in a passionate community.

59:12It just feels like leaders need to take

59:14those risky decisions that if you like listen,

59:19that with some nonzero probability,

59:23maybe even a high probability would be the wrong decision.

59:26But they have to use their gut and make that decision.

59:29Well, this is like one of the things

59:30where you see amazing founders.

59:34The founders understand exactly what's happened

59:36and how the company got there and are willing to say,

59:39we have been doing thing X the last 20 years,

59:42but today we're gonna do thing Y.

59:45And they make a major pivot for the whole company.

59:47The company lines up behind them,

59:48they move and it's the right thing.

59:50But then when the founder dies,

59:52the successor doesn't always feel that agency

59:57to be able to make those kinds of decisions.

59:59Even though they're a CEO,

60:00they could theoretically do whatever.

60:02There's two reasons for that, in my opinion,

60:04or in many cases, it's always different.

60:07But one of which is they weren't there

60:09for all the decisions that were made.

60:11And so they don't know the principles

60:13in which those decisions were made.

60:15And once the principles change,

60:17you should be obligated to change what you're doing

60:20and change direction, right?

60:22And so if you don't know how you got to where you are,

60:25it just seems like gospel

60:27and you're not gonna question it.

60:29You may not understand

60:30that it really is the right thing to do,

60:32so you just may not see it.

60:33That's so brilliant.

60:34I never thought of it that way.

60:35Like it's so much higher burden

60:38when as a leader you step into a thing

60:40that's already worked for a long time.

60:41Yeah, yeah.

60:42Well, and if you change it and it doesn't work out,

60:44now you're the person who screwed it up.

60:46People always second guess it.

60:47Yeah.

60:48And the second thing is that

60:49even if you decide to make a change,

60:51even if you're theoretically in charge,

60:53you're just a person that thinks they're in charge.

60:57Meanwhile, you have to motivate the troops.

60:58You have to explain it to them

60:59in terms they'll understand.

61:00You have to get them to buy into it and believe in it,

61:02because if they don't,

61:03then they're not gonna be able to make the turn

61:05even if you tell them their bonuses are gonna be curtailed.

61:08They're just not gonna like buy into it, you know?

61:10And so there's only so much power you have as a leader,

61:12and you have to understand what those limitations are.

61:16Are you still BDFL?

61:18You've been a BDFL of some stuff.

61:21You're very heavy on the B,

61:24the benevolent, benevolent dictator for life.

61:27I guess LLVM?

61:29Yeah, so I still lead the LLVM world.

61:32I mean, what's the role of,

61:35so then on Swift you said that there's a group of people.

61:38Yeah, so if you contrast Python with Swift, right,

61:41one of the reasons,

61:43so everybody on the core team takes the role

61:45really seriously, and I think we all really care

61:47about where Swift goes,

61:49but you're almost delegating the final decision making

61:52to the wisdom of the group,

61:54and so it doesn't become personal.

61:57And also, when you're talking with the community,

61:59so yeah, some people are very annoyed

62:02as certain decisions get made.

62:04There's a certain faith in the process,

62:06because it's a very transparent process,

62:08and when a decision gets made,

62:09a full rationale is provided, things like this.

62:12These are almost defense mechanisms

62:14to help both guide future discussions

62:16and provide case law, kind of like Supreme Court does

62:18about this decision was made for this reason,

62:20and here's the rationale

62:21and what we want to see more of or less of.

62:25But it's also a way to provide a defense mechanism,

62:27so that when somebody's griping about it,

62:28they're not saying that person did the wrong thing.

62:31They're saying, well, this thing sucks,

62:33and later they move on and they get over it.

62:38Yeah, the analogy of the Supreme Court,

62:40I think, is really good.

62:42But then, okay, not to get personal on the SWIFT team,

62:45but it just seems like it's impossible

62:50for division not to emerge.

62:52Well, each of the humans on the SWIFT Core Team,

62:55for example, are different,

62:56and the membership of the SWIFT Core Team

62:58changes slowly over time, which is, I think, a healthy thing.

63:02And so each of these different humans

63:04have different opinions.

63:05Trust me, it's not a singular consciousness

63:09by any stretch of the imagination.

63:11You've got three major organizations,

63:12including Apple, Google, and SciFive,

63:14all kind of working together.

63:16And it's a small group of people, but you need high trust.

63:20You need, again, it comes back to the principles

63:21of what you're trying to achieve

63:23and understanding what you're optimizing for.

63:27And I think that starting with strong principles

63:30and working towards decisions

63:32is always a good way to both make wise decisions in general

63:36but then be able to communicate them to people

63:37so that they can buy into them.

63:39And that is hard.

§09Transcript · 1:03:41–1:11:35

63:41And so you mentioned LLVM.

63:42LLVM is gonna be 20 years old this December,

63:46so it's showing its own age.

63:49Do you have like a dragon cake plan?

63:53No, I should definitely do that.

63:54Yeah, if we can have a pandemic cake.

63:57Pandemic cake.

63:58Everybody gets a slice of cake

64:00and it gets sent through email.

64:04But LLVM has had tons of its own challenges

64:08over time too, right?

64:09And one of the challenges that the LLVM community has,

64:12in my opinion, is that it has a whole bunch of people

64:15that have been working on LLVM for 10 years, right?

64:19Because this happens somehow.

64:20And LLVM has always been one way,

64:22but it needs to be a different way, right?

64:25And they've worked on it for like 10 years.

64:26It's a long time to work on something.

64:28And you suddenly can't see the faults

64:32in the thing that you're working on.

64:33And LLVM has lots of problems and we need to address them

64:35and we need to make it better.

64:36And if we don't make it better,

64:37then somebody else will come up with a better idea, right?

64:40And so it's just kind of of that age

64:42where the community is like in danger

64:45of getting too calcified.

64:46And so I'm happy to see new projects joining

64:50and new things mixing it up.

64:51Fortran is now a new thing in the LLVM community,

64:54which is hilarious and good.

64:56I've been trying to find, on a little tangent,

64:58find people who program in Cobalt or Fortran,

65:02Fortran especially, to talk to, they're hard to find.

65:06Yeah, look to the scientific community.

65:09They still use Fortran quite a bit.

65:11Well, interesting thing you kind of mentioned with LLVM,

65:14or just in general, that as something evolves,

65:16you're not able to see the faults.

65:19So do you fall in love with the thing over time?

65:23Or do you start hating everything

65:24about the thing over time?

65:26Well, so my personal folly is that I see,

65:31maybe not all, but many of the faults,

65:33and they grate on me, and I don't have time to go fix them.

65:35Yeah, and they get magnified over time.

65:37Well, and they may not get magnified,

65:38but they never get fixed.

65:39And it's like sand underneath,

65:41you know, it's just like grating against you.

65:43And it's like sand underneath your fingernails or something.

65:45It's just like, you know it's there,

65:46you can't get rid of it.

65:49And so the problem is that if other people don't see it,

65:52like I don't have time to go write the code

65:56and fix it anymore,

65:58but then people are resistant to change.

66:01And so you say, hey, we should go fix this thing.

66:03They're like, oh yeah, that sounds risky.

66:05It's like, well, is it the right thing or not?

66:07Are the challenges the group dynamics,

66:10or is it also just technical?

66:11I mean, some of these features like,

66:14I think as an observer, it's almost like a fan

66:17in the, you know, as a spectator of the whole thing,

66:21I don't often think about, you know,

66:23some things might actually be

66:24technically difficult to implement.

66:27An example of this is we built this new compiler framework

66:30called MLIR.

66:31Yes.

66:32MLIR is a whole new framework.

66:34It's not, many people think it's about machine learning.

66:37The ML stands for multi level

66:39because compiler people can't name things very well,

66:41I guess.

66:42Do we dig into what MLIR is?

66:45Yeah, so when you look at compilers,

66:47compilers have historically been solutions for a given space.

66:51So LLVM is a, it's really good for dealing with CPUs,

66:56let's just say, at a high level.

66:58You look at Java, Java has a JVM.

67:01The JVM is very good for garbage collected languages

67:04that need dynamic compilation,

67:05and it's very optimized for a specific space.

67:08And so hotspot is one of the compilers

67:09that gets used in that space,

67:11and that compiler is really good at that kind of stuff.

67:14Usually when you build these domain specific compilers,

67:16you end up building the whole thing from scratch

67:19for each domain.

67:22What's a domain?

67:23So what's the scope of a domain?

67:26Well, so here I would say, like, if you look at Swift,

67:29there's several different parts to the Swift compiler,

67:31one of which is covered by the LLVM part of it.

67:36There's also a high level piece that's specific to Swift,

67:39and there's a huge amount of redundancy

67:41between those two different infrastructures

67:44and a lot of re implemented stuff

67:46that is similar but different.

67:48What does LLVM define?

67:49LLVM is effectively an infrastructure.

67:53So you can mix and match it in different ways.

67:55It's built out of libraries.

67:56You can use it for different things,

67:57but it's really good at CPUs and GPUs.

67:59CPUs and like the tip of the iceberg on GPUs.

68:02It's not really great at GPUs.

68:04Okay.

68:05But it turns out. A bunch of languages that.

68:07That then use it to talk to CPUs.

68:10Got it.

68:11And so it turns out there's a lot of hardware out there

68:13that is custom accelerators.

68:14So machine learning, for example.

68:16There are a lot of matrix multiply accelerators

68:18and things like this.

68:20There's a whole world of hardware synthesis.

68:22So we're using MLIR to build circuits.

68:26Okay.

68:27And so you're compiling for a domain of transistors.

68:30And so what MLIR does is it provides

68:32a tremendous amount of compiler infrastructure

68:34that allows you to build these domain specific compilers

68:37in a much faster way and have the result be good.

68:41If we're thinking about the future,

68:44now we're talking about like ASICs.

68:45So anything.

68:46Yeah, yeah.

68:47So if we project into the future,

68:50it's very possible that the number of these kinds of ASICs,

68:54very specific infrastructure architecture things

69:02like multiplies exponentially.

69:05I hope so.

69:06So that's MLIR.

69:08So what MLIR does is it allows you

69:10to build these compilers very efficiently.

69:13Right now, one of the things that coming back

69:15to the LLVM thing, and then we'll go to hardware,

69:17is LLVM is a specific compiler for a specific domain.

69:23MLIR is now this very general, very flexible thing

69:26that can solve lots of different kinds of problems.

69:29So LLVM is a subset of what MLIR does.

69:32So MLIR is, I mean, it's an ambitious project then.

69:35Yeah, it's a very ambitious project, yeah.

69:36And so to make it even more confusing,

69:39MLIR has joined the LLVM Umbrella Project.

69:42So it's part of the LLVM family.

69:44Right.

69:45But where this comes full circle is now folks

69:47that work on the LLVM part,

69:49the classic part that's 20 years old,

69:51aren't aware of all the cool new things

69:54that have been done in the new thing,

69:56that MLIR was built by me and many other people

69:59that knew a lot about LLVM,

70:01and so we fixed a lot of the mistakes that lived in LLVM.

70:05And so now you have this community dynamic

70:07where it's like, well, there's this new thing,

70:08but it's not familiar, nobody knows it,

70:10it feels like it's new, and so let's not trust it.

70:12And so it's just really interesting

70:13to see the cultural social dynamic that comes out of that.

70:16And I think it's super healthy

70:19because we're seeing the ideas percolate

70:21and we're seeing the technology diffusion happen

70:24as people get more comfortable with it,

70:25they start to understand things in their own terms.

70:27And this just gets to the,

70:28it takes a while for ideas to propagate,

70:31even though they may be very different

70:33than what people are used to.

70:35So maybe let's talk about that a little bit,

70:37the world of Asics.

70:38Yeah.

70:39Actually, you have a new role at SciFive.

70:45What's that place about?

70:47What is the vision for their vision

70:50for, I would say, the future of computer?

70:52Yeah, so I lead the engineering and product teams at SciFive.

70:55SciFive is a company who was founded

70:59with this architecture called RISC5.

71:02RISC5 is a new instruction set.

71:04Instruction sets are the things inside of your computer

71:06that tell it how to run things.

71:08X86 from Intel and ARM from the ARM company

71:12and things like this are other instruction sets.

71:13I've talked to, sorry to interrupt,

71:15I've talked to Dave Patterson,

71:15who's super excited about RISC5.

71:17Dave is awesome.

71:18Yeah, he's brilliant, yeah.

71:20The RISC5 is distinguished by not being proprietary.

71:24And so X86 can only be made by Intel and AMD.

71:28ARM can only be made by ARM.

71:30They sell licenses to build ARM chips to other companies,

71:33things like this.

71:34MIPS is another instruction set

§10Transcript · 1:11:35–1:19:45

71:35that is owned by the MIPS company, now Wave.

71:38And then it gets licensed out, things like that.

71:40And so RISC5 is an open standard

71:43that anybody can build chips for.

71:45And so SciFive was founded by three of the founders

71:48of RISC5 that designed and built it in Berkeley,

71:51working with Dave.

71:52And so that was the genesis of the company.

71:56SciFive today has some of the world's best RISC5 cores

71:59and we're selling them and that's really great.

72:01They're going to tons of products, it's very exciting.

72:04So they're taking this thing that's open source

72:06and just trying to be or are the best in the world

72:09at building these things.

72:10Yeah, so here it's the specifications open source.

72:13It's like saying TCP IP is an open standard

72:15or C is an open standard,

72:18but then you have to build an implementation

72:19of the standard.

72:20And so SciFive, on the one hand, pushes forward

72:23and defined and pushes forward the standard.

72:26On the other hand, we have implementations

72:28that are best in class for different points in the space,

72:30depending on if you want a really tiny CPU

72:33or if you want a really big, beefy one that is faster,

72:36but it uses more area and things like this.

72:38What about the actual manufacturer chips?

72:41So like, where does that all fit?

72:43I'm going to ask a bunch of dumb questions.

72:45That's okay, this is how we learn, right?

72:48And so the way this works is that there's generally

72:52a separation of the people who designed the circuits

72:55and then people who manufacture them.

72:56And so you'll hear about fabs like TSMC and Samsung

73:00and things like this that actually produce the chips,

73:03but they take a design coming in

73:05and that design specifies how the,

73:09you turn code for the chip into little rectangles

73:16that then use photolithography to make mask sets

73:20and then burn transistors onto a chip

73:22or onto a, onto silicon rather.

73:24So, and we're talking about mass manufacturing, so.

73:28Yeah, they're talking about making hundreds of millions

73:29of parts and things like that, yeah.

73:31And so the fab handles the volume production,

73:33things like that.

73:34But when you look at this problem,

73:37the interesting thing about the space when you look at it

73:39is that these, the steps that you go from designing a chip

73:44and writing the quote unquote code for it

73:46and things like Verilog and languages like that,

73:49down to what you hand off to the fab

73:51is a really well studied, really old problem, okay?

73:56Tons of people have worked on it.

73:57Lots of smart people have built systems and tools.

74:00These tools then have generally gone through acquisitions.

74:03And so they've ended up at three different major companies

74:06that build and sell these tools.

74:07They're called the EDA tools

74:08like for electronic design automation.

74:11The problem with this is you have huge amounts

74:13of fragmentation, you have loose standards

74:17and the tools don't really work together.

74:20So you have tons of duct tape

74:21and you have tons of loss productivity.

74:24Now these are, these are tools for designing.

74:26So the RISC 5 is a instruction.

74:30Like what is RISC 5?

74:32Like how deep does it go?

74:33How much does it touch the hardware?

74:35How much does it define how much of the hardware is?

74:38Yeah, so RISC 5 is all about given a CPU.

74:41So the processor and your computer,

74:44how does the compiler like Swift compiler,

74:47the C compiler, things like this, how does it make it work?

74:50So it's, what is the assembly code?

74:52And so you write RISC 5 assembly

74:54instead of XA6 assembly, for example.

74:57But it's a set of instructions

74:58as opposed to instructions.

75:00Why do you say it tells you how the compiler works?

75:03Sorry, it's what the compiler talks to.

75:05Okay. Yeah.

75:06And then the tooling you mentioned

75:08that the disparate tools are for what?

75:10For when you're building a specific chip.

75:13So RISC 5. In hardware.

75:14In hardware, yeah.

75:15So RISC 5, you can buy a RISC 5 core from SciFive

75:19and say, hey, I want to have a certain number of,

75:21run a certain number of gigahertz.

75:23I want it to be this big.

75:24I want it to be, have these features.

75:26I want to have like, I want floating point or not,

75:29for example.

75:31And then what you get is you get a description

75:34of a CPU with those characteristics.

75:36Now, if you want to make a chip,

75:38you want to build like an iPhone chip

75:39or something like that, right?

75:41You have to take both the CPU,

75:42but then you have to talk to memory.

75:44You have to have timers, IOs, a GPU, other components.

75:49And so you need to pull all those things together

75:51into what's called an ASIC,

75:53an Application Specific Integrated Circuit.

75:55So a custom chip.

75:56And then you take that design

75:58and then you have to transform it into something

76:00that the fabs, like TSMC, for example,

76:03know how to take to production.

76:06Got it.

76:07So, but yeah, okay.

76:08And so that process, I will,

76:11I can't help but see it as, is a big compiler.

76:15Yeah, yeah.

76:16It's a whole bunch of compilers written

76:18without thinking about it through that lens.

76:21Isn't the universe a compiler?

76:23Yeah, compilers do two things.

76:26They represent things and transform them.

76:29And so there's a lot of things that end up being compilers.

76:31But this is a space where we're talking about design

76:34and usability and the way you think about things,

76:37the way things compose correctly, it matters a lot.

76:40And so SciFi is investing a lot into that space.

76:43And we think that there's a lot of benefit

76:45that can be made by allowing people to design chips faster,

76:48get them to market quicker and scale out

76:52because at the alleged end of Moore's law,

76:56you've got this problem of you're not getting

76:59free performance just by waiting another year

77:01for a faster CPU.

77:03And so you have to find performance in other ways.

77:06And one of the ways to do that is with custom accelerators

77:09and other things and hardware.

77:11And so, well, we'll talk a little more about ASICs,

77:17but do you see that a lot of people,

77:21a lot of companies will try to have

77:25different sets of requirements

77:26that this whole process to go for?

77:28So like almost different car companies might use different

77:32and like different PC manufacturers.

77:35So is RISC 5 in this whole process,

77:40is it potentially the future of all computing devices?

77:44Yeah, I think that, so if you look at RISC 5

77:47and step back from the Silicon side of things,

77:49RISC 5 is an open standard.

77:51And one of the things that has happened

77:53over the course of decades,

77:55if you look over the long arc of computing,

77:57somehow became decades old.

77:59Yeah.

78:00Is that you have companies that come and go

78:02and you have instruction sets that come and go.

78:04Like one example of this out of many is Sun with Spark.

78:09Yeah, it's on one way.

78:11Spark still lives on at Fujitsu,

78:12but we have HP had this instruction set called PA RISC.

78:18So PA RISC was this big server business

78:21and had tons of customers.

78:22They decided to move to this architecture

78:25called Itanium from Intel.

78:27Yeah.

78:27This didn't work out so well.

78:29Yeah.

78:30Right, and so you have this issue of

78:32you're making many billion dollar investments

78:35on instruction sets that are owned by a company.

78:38And even companies as big as Intel

78:39don't always execute as well as they could.

78:42They even have their own issues.

78:44HP, for example, decided that it wasn't

78:46in their best interest to continue investing in the space

78:48because it was very expensive.

78:49And so they make technology decisions

78:52or they make their own business decisions.

78:54And this means that as a customer, what do you do?

78:57You've sunk all this time, all this engineering,

78:59all this software work, all these,

79:01you've built other products around them

79:02and now you're stuck, right?

79:05What RISC 5 does is provide you more optionality

79:07in the space because if you buy an implementation

79:10of RISC 5 from SciFive, and you should,

79:13they're the best ones.

79:14Yeah.

79:16But if something bad happens to SciFive in 20 years, right?

79:19Well, great, you can turn around

79:21and buy a RISC 5 core from somebody else.

79:23And there's an ecosystem of people

79:25that are all making different RISC 5 cores

79:26with different trade offs, which means that

79:29if you have more than one requirement,

79:30if you have a family of products,

79:31you can probably find something in the RISC 5 space

79:34that fits your needs.

79:36Whereas with, if you're talking about XA6, for example,

79:39it's Intel's only gonna bother

79:41to make certain classes of devices, right?

§11Transcript · 1:19:45–1:27:55

79:45I see, so maybe a weird question,

79:47but like if SciFive is like infinitely successful

79:54in the next 20, 30 years, what does the world look like?

79:58So like how does the world of computing change?

80:01So too much diversity in hardware instruction sets,

80:05I think is bad.

80:06Like we have a lot of people that are using

80:09lots of different instruction sets,

80:10particularly in the embedded,

80:12the like very tiny microcontroller space,

80:14the thing in your toaster that are just weird

80:19and different for historical reasons.

80:21And so the compilers and the tool chains

80:23and the languages on top of them aren't there.

80:27And so the developers for that software

80:29have to use really weird tools

80:31because the ecosystem that supports is not big enough.

80:34So I expect that will change, right?

80:35People will have better tools and better languages,

80:38better features everywhere

80:39that then can serve as many different points in the space.

80:43And I think RISC5 will progressively

80:46eat more of the ecosystem because it can scale up,

80:49it can scale down, sideways, left, right.

80:51It's very flexible and very well considered

80:53and well designed instruction set.

80:56I think when you look at SciFive tackling silicon

80:58and how people build chips,

81:00which is a very different space,

81:03that's where you say,

81:05I think we'll see a lot more custom chips.

81:07And that means that you get much more battery life,

81:09you get better tuned solutions for your IoT thingy.

81:16You get people that move faster,

81:18you get the ability to have faster time to market,

81:20for example.

81:21So how many custom...

81:22So first of all, on the IoT side of things,

81:25do you see the number of smart toasters

81:29increasing exponentially?

81:30So, and if you do,

81:35like how much customization per toaster is there?

81:38Do all toasters in the world run the same silicon,

81:42like the same design,

81:44or is it different companies have different design?

81:46Like how much customization is possible here?

81:49Well, a lot of it comes down to cost, right?

81:52And so the way that chips work is you end up paying by the...

81:56One of the factors is the size of the chip.

81:58And so what ends up happening

82:01just from an economic perspective is

82:03there's only so many chips that get made in a year

82:06of a given design.

82:07And so often what customers end up having to do

82:10is they end up having to pick up a chip that exists

82:12that was built for somebody else

82:14so that they can then ship their product.

82:16And the reason for that

82:17is they don't have the volume of the iPhone.

82:19They can't afford to build a custom chip.

82:21However, what that means is they're now buying

82:23an off the shelf chip that isn't really good,

82:26isn't a perfect fit for their needs.

82:28And so they're paying a lot of money for it

82:30because they're buying silicon that they're not using.

82:33Well, if you now reduce the cost of designing the chip,

82:36now you get a lot more chips.

82:37And the more you reduce it,

82:39the easier it is to design chips.

82:42The more the world keeps evolving

82:44and we get more AI accelerators,

82:45we get more other things,

82:46we get more standards to talk to,

82:48we get 6G, right?

82:50You get changes in the world

82:53that you wanna be able to talk to these different things.

82:54There's more diversity in the cross product of features

82:57that people want.

82:58And that drives differentiated chips

83:02in another direction.

83:03And so nobody really knows what the future looks like,

83:05but I think that there's a lot of silicon in the future.

83:09Speaking of the future,

83:11you said Moore's law allegedly is dead.

83:13So do you agree with Dave Patterson and many folks

83:20that Moore's law is dead?

83:22Or do you agree with Jim Keller,

83:23who's standing at the helm of the pirate ship

83:28saying it's still alive?

83:31Yeah.

83:32Well, so I agree with what they're saying

83:35and different people are interpreting

83:37the end of Moore's law in different ways.

83:39Yeah.

83:40So Jim would say,

83:41there's another thousand X left in physics

83:44and we can continue to squeeze the stone

83:46and make it faster and smaller and smaller geometries

83:50and all that kind of stuff.

83:52He's right.

83:53So Jim is absolutely right

83:55that there's a ton of progress left

83:57and we're not at the limit of physics yet.

84:01That's not really what Moore's law is though.

84:04If you look at what Moore's law is,

84:06is that it's a very simple evaluation of,

84:10okay, well you look at the cost per,

84:13I think it was cost per area

84:14and the most economic point in that space.

84:17And if you go look at the now quite old paper

84:20that describes this,

84:21Moore's law has a specific economic aspect to it

84:25and I think this is something

84:26that Dave and others often point out.

84:28And so on a technicality, that's right.

84:31I look at it from,

84:33so I can acknowledge both of those viewpoints.

84:34They're both right.

84:35They're both right.

84:36I'll give you a third wrong viewpoint

84:39that may be right in its own way,

84:40which is single threaded performance

84:44doesn't improve like it used to.

84:46And it used to be back when you got a,

84:48you know, a Pentium 66 or something

84:50and the year before you had a Pentium 33

84:53and now it's twice as fast, right?

84:56Well, it was twice as fast at doing exactly the same thing.

85:00Okay, like literally the same program ran twice as fast.

85:03You just wrote a check and waited a year, year and a half.

85:07Well, so that's what a lot of people think about Moore's law

85:10and I think that is dead.

85:11And so what we're seeing instead is we're pushing,

85:15we're pushing people to write software in different ways.

85:17And so we're pushing people to write CUDA

85:19so they can get GPU compute

85:20and the thousands of cores on GPU.

85:23We're talking about C programmers having to use P threads

85:26because they now have, you know,

85:27a hundred threads or 50 cores in a machine

85:30or something like that.

85:31You're now talking about machine learning accelerators

85:33that are now domain specific.

85:35And when you look at these kinds of use cases,

85:38you can still get performance

85:40and Jim will come up with cool things

85:42that utilize the silicon in new ways for sure,

85:45but you're also gonna change the programming model.

85:48Right.

85:49And now when you start talking about changing

85:50the programming model,

85:50that's when you come back to languages

85:53and things like this too,

85:54because often what you see is like you take

85:58the C programming language, right?

85:59The C programming language is designed for CPUs.

86:03And so if you want to talk to a GPU,

86:04now you're talking to its cousin CUDA, okay?

86:08CUDA is a different thing with a different set of tools,

86:11a different world, a different way of thinking.

86:14And we don't have one world that scales.

86:16And I think that we can get there.

86:18We can have one world that scales in a much better way.

86:21And a small tangent then,

86:22I think most programming languages are designed for CPUs,

86:25for single core, even just in their spirit,

86:28even if they allow for parallelization.

86:30So what does it look like for a programming language

86:34to have parallelization or massive parallelization

86:38as it's like first principle?

86:41So the canonical example of this

86:43is the hardware design world.

86:46So Verilog, VHDL, these kinds of languages,

86:50they're what's called a high level synthesis language.

86:53This is the thing people design chips in.

86:56And when you're designing a chip,

86:58it's kind of like a brain where you have infinite parallelism.

87:02Like you're like laying down transistors.

87:05Transistors are always running, okay?

87:08And so you're not saying run this transistor,

87:10then this transistor, then this transistor.

87:12It's like your brain,

87:13like your neurons are always just doing something.

87:15They're not clocked, right?

87:16They're just doing their thing.

87:20And so when you design a chip or when you design a CPU,

87:23when you design a GPU, when you design,

87:25when you're laying down the transistors,

87:27similarly, you're talking about,

87:28well, okay, well, how do these things communicate?

87:31And so these languages exist.

87:32Verilog is a kind of mixed example of that.

87:36None of these languages are really great.

87:37You have a very low level, yeah.

87:39Yeah, they're very low level

87:40and abstraction is necessary here.

87:42And there's different approaches with that.

87:44And it's itself a very complicated world,

87:47but it's implicitly parallel.

87:50And so having that as the domain that you program towards

§12Transcript · 1:27:56–1:35:54

87:56makes it so that by default, you get parallel systems.

87:59If you look at CUDA,

88:00CUDA is a point halfway in the space where in CUDA,

88:03when you write a CUDA kernel for your GPU,

88:05it feels like you're writing a scalar program.

88:08So you're like, you have ifs, you have for loops,

88:10stuff like this, you're just writing normal code.

88:12But what happens outside of that in your driver

88:14is that it actually is running you

88:16on like a thousand things at once, right?

88:18And so it's parallel,

88:20but it has pulled it out of the programming model.

88:23And so now you as a programmer are working in a simpler world

88:28and it's solved that for you, right?

88:31How do you take the language like Swift?

88:36If we think about GPUs, but also ASICs,

88:39maybe if we can dance back and forth

88:40between hardware and software.

88:42How do you design for these features

88:46to be able to program and get a first class citizen

88:50to be able to do like Swift for TensorFlow

88:53to be able to do machine learning on current hardware,

88:56but also future hardware like TPUs

88:59and all kinds of ASICs

89:00that I'm sure will be popping up more and more.

89:02Yeah, well, so a lot of this comes down

89:04to this whole idea of having the nuts and bolts

89:06underneath the covers that work really well.

89:08So you need, if you're talking to TPUs,

89:10you need MLIR or XLA or one of these compilers

89:13that talks to TPUs to build on top of, okay?

89:17And if you're talking to circuits,

89:19you need to figure out how to lay down the transistors

89:21and how to organize it and how to set up clocking

89:23and like all the domain problems

89:24that you get with circuits.

89:27Then you have to decide how to explain it to a human.

89:29What is ZY, right?

89:31And if you do it right, that's a library problem,

89:34not a language problem.

89:36And that works if you have a library or a language

89:39which allows your library to write things

89:42that feel native in the language by implementing libraries,

89:45because then you can innovate in programming models

89:49without having to change your syntax again.

89:51Like you have to invent new code formatting tools

89:54and like all the other things that languages come with.

89:57And this gets really interesting.

89:59And so if you look at the space,

90:02the interesting thing once you separate out syntax

90:05becomes what is that programming model?

90:07And so do you want the CUDA style?

90:10I write one program and it runs many places.

90:14Do you want the implicitly parallel model?

90:16How do you reason about that?

90:17How do you give developers, chip architects,

90:20the ability to express their intent?

90:24And that comes into this whole design question

90:26of how do you detect bugs quickly?

90:29So you don't have to tape out a chip

90:30to find out it's wrong, ideally, right?

90:32How do you, and this is a spectrum,

90:35how do you make it so that people feel productive?

90:38So their turnaround time is very quick.

90:40All these things are really hard problems.

90:42And in this world, I think that not a lot of effort

90:46has been put into that design problem

90:48and thinking about the layering in other pieces.

90:51Well, you've, on the topic of concurrency,

90:53you've written the Swift concurrency manifest.

90:55I think it's kind of interesting.

90:57Anything that has the word manifest on it

91:00is very interesting.

91:02Can you summarize the key ideas of each of the five parts

91:06you've written about?

91:07So what is a manifesto?

91:08Yes.

91:09How about, we start there.

91:11So in the Swift community, we have this problem,

91:15which is on the one hand,

91:16you wanna have relatively small proposals

91:19that you can kind of fit in your head,

91:21you can understand the details at a very fine grain level

91:24that move the world forward.

91:26But then you also have these big arcs, okay?

91:28And often when you're working on something

91:30that is a big arc, but you're tackling it in small pieces,

91:34you have this question of,

91:35how do I know I'm not doing a random walk?

91:37Where are we going?

91:38How does this add up?

91:39Furthermore, when you start the first small step,

91:43what terminology do you use?

91:45How do we think about it?

91:46What is better and worse in the space?

91:47What are the principles?

91:48What are we trying to achieve?

91:50And so what a manifesto in the Swift community does

91:52is it starts to say,

91:53hey, well, let's step back from the details of everything.

91:56Let's paint a broad picture to talk about

91:58what we're trying to achieve.

92:01Let's give an example design point.

92:02Let's try to paint the big picture

92:05so that then we can zero in on the individual steps

92:07and make sure that we're making good progress.

92:09And so the Swift concurrency manifesto

92:11is something I wrote three years ago.

92:13It's been a while, maybe more.

92:16Trying to do that for Swift and concurrency.

92:19It starts with some fairly simple things

92:22like making the observation that

92:25when you have multiple different computers

92:26and multiple different threads that are communicating,

92:28it's best for them to be asynchronous.

92:32And so you need things to be able to run separately

92:34and then communicate with each other.

92:35And this means asynchrony.

92:37And this means that you need a way

92:38to modeling asynchronous communication.

92:41Many languages have features like this.

92:43Async await is a popular one.

92:45And so that's what I think is very likely in Swift.

92:49But as you start building this tower of abstractions,

92:51it's not just about how do you write this,

92:53you then reach into the how do you get memory safety

92:57because you want correctness,

92:58you want debuggability and sanity for developers.

93:01And how do you get that memory safety into the language?

93:06So if you take a language like Go or C

93:09or any of these languages,

93:10you get what's called a race condition

93:11when two different threads or Go routines or whatever

93:14touch the same point in memory, right?

93:17This is a huge like maddening problem to debug

93:21because it's not reproducible generally.

93:24And so there's tools,

93:25there's a whole ecosystem of solutions

93:27that built up around this,

93:28but it's a huge problem

93:29when you're writing concurrent code.

93:31And so with Swift,

93:33this whole value semantics thing is really powerful there

93:35because it turns out that math and copies actually work

93:39even in concurrent worlds.

93:40And so you get a lot of safety just out of the box,

93:43but there are also some hard problems.

93:44And it talks about some of that.

93:47When you start building up to the next level up

93:48and you start talking beyond memory safety,

93:50you have to talk about what is the programmer model?

93:53How does a human think about this?

93:54So a developer that's trying to build a program

93:56think about this,

93:57and it proposes a really old model with a new spin

94:01called Actors.

94:02Actors are about saying,

94:03we have islands of single threadedness logically.

94:08So you write something that feels like

94:09it's one program running in a unit,

94:13and then it communicates asynchronously with other things.

94:16And so making that expressive and natural feel good

94:19be the first thing you reach for and being safe by default

94:22is a big part of the design of that proposal.

94:25When you start going beyond that,

94:26now you start to say, cool,

94:27well, these things that communicate asynchronously,

94:30they don't have to share memory.

94:32Well, if they don't have to share memory

94:33and they're sending messages to each other,

94:35why do they have to be in the same process?

94:38These things should be able to be in different processes

94:40on your machine.

94:41And why just processes?

94:43Well, why not different machines?

94:44And so now you have a very nice gradual transition

94:47towards distributed programming.

94:49And of course, when you start talking about the big future,

94:53the manifesto doesn't go into it,

94:55but accelerators are things you talk to asynchronously

95:00by sending messages to them.

95:01And how do you program those?

95:03Well, that gets very interesting.

95:05That's not in the proposal.

95:07And how much do you wanna make that explicit

95:12like the control of that whole process

95:14explicit to the program?

95:15Yeah, good question.

95:16So when you're designing any of these kinds of features

95:20or language features or even libraries,

95:22you have this really hard trade off you have to make,

95:25which is how much is it magic

95:27or how much is it in the human's control?

95:29How much can they predict and control it?

95:32What do you do when the default case is the wrong case?

95:37And so when you're designing a system,

95:39and so when you're designing a system, I won't name names,

95:45but there are systems where it's really easy to get started

95:50and then you jump.

95:52So let's pick like logo.

§13Transcript · 1:35:54–1:43:49

95:54Okay, so something like this.

95:55So it's really easy to get started.

95:57It's really designed for teaching kids,

95:59but as you get into it, you hit a ceiling

96:02and then you can't go any higher.

96:03And then what do you do?

96:04Well, you have to go switch to a different world

96:05and rewrite all your code.

96:07And this logo is a silly example here.

96:09This exists in many other languages.

96:11With Python, you would say like concurrency, right?

96:15So Python has the global interpreter block.

96:17So threading is challenging in Python.

96:19And so if you start writing a large scale application

96:22in Python, and then suddenly you need concurrency,

96:25you're kind of stuck with a series of bad trade offs, right?

96:30There's other ways to go where you say like,

96:32foist all the complexity on the user all at once, right?

96:37And that's also bad in a different way.

96:38And so what I prefer is building a simple model

96:43that you can explain that then has an escape hatch.

96:46So you get in, you have guardrails,

96:50memory safety works like this in Swift,

96:52where you can start with, like by default,

96:54if you use all the standard things, it's memory safe,

96:57you're not gonna shoot your foot off.

96:58But if you wanna get a C level pointer to something,

97:02you can explicitly do that.

97:04But by default, there's guardrails.

97:07There's guardrails.

97:08Okay, so but like, whose job is it to figure out

97:14which part of the code is parallelizable?

97:17So in the case of the proposal, it is the human's job.

97:21So they decide how to architect their application.

97:24And then the runtime in the compiler is very predictable.

97:29And so this is in contrast to like,

97:31there's a long body of work, including on Fortran

97:34for auto parallelizing compilers.

97:36And this is an example of a bad thing in my,

97:39so as a compiler person, I can drag on compiler people.

97:42Often compiler people will say,

97:45cool, since I can't change the code,

97:46I'm gonna write my compiler that then takes

97:48this unmodified code and makes go way faster on this machine.

97:52Okay, application, and so it does pattern matching.

97:55It does like really deep analysis.

97:57Compiler people are really smart.

97:58And so they like wanna like do something

98:00really clever and tricky.

98:01And you get like 10X speed up by taking

98:04like an array of structures and turn it

98:06into a structure of arrays or something,

98:08because it's so much better for memory.

98:09Like there's bodies, like tons of tricks.

98:12They love optimization.

98:13Yeah, you love optimization.

98:14Everyone loves optimization.

98:15Everyone loves it.

98:16Well, and it's this promise of build with my compiler

98:19and your thing goes fast, right?

98:20But here's the problem, Lex, you write a program,

98:24you run it with my compiler, it goes fast.

98:26You're very happy.

98:27Wow, it's so much faster than the other compiler.

98:29Then you go and you add a feature to your program

98:31or you refactor some code.

98:32And suddenly you got a 10X loss in performance.

98:35Well, why?

98:36What just happened there?

98:37What just happened there is the heuristic,

98:39the pattern matching, the compiler,

98:41whatever analysis it was doing just got defeated

98:43because you didn't inline a function or something, right?

98:48As a user, you don't know, you don't wanna know.

98:50That was the whole point.

98:51You don't wanna know how the compiler works.

98:52You don't wanna know how the memory hierarchy works.

98:54You don't wanna know how it got parallelized

98:56across all these things.

98:57You wanted that abstracted away from you,

98:59but then the magic is lost as soon as you did something

99:02and you fall off a performance cliff.

99:05And now you're in this funny position

99:06where what do I do?

99:08I don't change my code.

99:09I don't fix that bug.

99:10It costs 10X performance.

99:12Now what do I do?

99:13Well, this is the problem with unpredictable performance.

99:16If you care about performance,

99:17predictability is a very important thing.

99:19And so what the proposal does is it provides

99:23architectural patterns for being able to lay out your code,

99:26gives you full control over that,

99:28makes it really simple so you can explain it.

99:30And then if you wanna scale out in different ways,

99:34you have full control over that.

99:36So in your sense, the intuition is for a compiler,

99:39it's too hard to do automated parallelization.

99:43Cause the compilers do stuff automatically

99:47that's incredibly impressive for other things,

99:50but for parallelization, we're not close to there.

99:54Well, it depends on the programming model.

99:56So there's many different kinds of compilers.

99:58And so if you talk about like a C compiler

100:00or Swift compiler or something like that,

100:01where you're writing imperative code,

100:04parallelizing that and reasoning about all the pointers

100:07and stuff like that is a very difficult problem.

100:10Now, if you switch domains,

100:12so there's this cool thing called machine learning, right?

100:15So machine learning nerds among other endearing things

100:18like solving cat detectors and other things like that

100:23have done this amazing breakthrough

100:25of producing a programming model,

100:27operations that you compose together

100:30that has raised levels of abstraction high enough

100:33that suddenly you can have auto parallelizing compilers.

100:36You can write a model using a TensorFlow

100:39and have it run on 1024 nodes of a TPU.

100:43Yeah, that's true.

100:44I didn't even think about like,

100:46cause there's so much flexibility

100:48in the design of architectures that ultimately boil down

100:50to a graph that's parallelized for you.

100:54And if you think about it, that's pretty cool.

100:56That's pretty cool, yeah.

100:57And you think about batching, for example,

100:59as a way of being able to exploit more parallelism.

101:02Like that's a very simple thing that now is very powerful.

101:05That didn't come out of the programming language nerds,

101:08those people, like that came out of people

101:10that are just looking to solve a problem

101:11and use a few GPUs and organically developed

101:14by the community of people focusing on machine learning.

101:16And it's an incredibly powerful abstraction layer

101:19that enables the compiler people to go and exploit that.

101:22And now you can drive supercomputers from Python.

101:26Well, that's pretty cool.

101:27That's amazing.

101:28So just to pause on that,

101:30cause I'm not sufficiently low level,

101:32I forget to admire the beauty and power of that,

101:35but maybe just to linger on it,

101:38like what does it take to run a neural network fast?

101:42Like how hard is that compilation?

101:44It's really hard.

101:45So we just skipped,

101:46you said like, it's amazing that that's a thing,

101:49but yeah, how hard is that of a thing?

101:51It's hard and I would say that not all of the systems

101:55are really great, including the ones I helped build.

101:58So there's a lot of work left to be done there.

102:00Is it the compiler nerds working on that

102:02or is it a whole new group of people?

102:04Well, it's a full stack problem,

102:05including compiler people, including APIs,

102:09so like Keras and the module API and PyTorch and Jax.

102:14And there's a bunch of people pushing

102:15on all the different parts of these things,

102:17because when you look at it as it's both,

102:19how do I express the computation?

102:21Do I stack up layers?

102:22Well, cool, like setting up a linear sequence of layers

102:25is great for the simple case,

102:26but how do I do the hard case?

102:28How do I do reinforcement learning?

102:29Well, now I need to integrate my application logic in this.

102:32Then it's the next level down of,

102:34how do you represent that for the runtime?

102:36How do you get hardware abstraction?

102:39And then you get to the next level down of saying like,

102:40forget about abstraction,

102:41how do I get the peak performance out of my TPU

102:44or my iPhone accelerator or whatever, right?

102:47And all these different things.

102:48And so this is a layered problem

102:50with a lot of really interesting design and work

102:53going on in the space

102:54and a lot of really smart people working on it.

102:56Machine learning is a very well funded area

102:59of investment right now.

103:00And so there's a lot of progress being made.

103:02So how much innovation is there on the lower level,

103:05so closer to the ASIC,

103:08so redesigning the hardware

103:09or redesigning concurrently compilers with that hardware?

103:13Is that like, if you were to predict the biggest,

103:16the equivalent of Moore's law improvements

103:20in the inference and the training of neural networks

103:24and just all of that,

103:25where is that gonna come from, you think?

103:26Sure, you get scalability of different things.

103:28And so you get Jim Keller shrinking process technology,

103:33you get three nanometer instead of five or seven or 10

103:36or 28 or whatever.

103:38And so that marches forward and that provides improvements.

103:41You get architectural level performance.

103:44And so the TPU with a matrix multiply unit

103:47and a systolic array is much more efficient

§14Transcript · 1:43:49–1:52:07

103:49than having a scalar core doing multiplies and adds

103:53and things like that.

103:54You then get system level improvements.

103:58So how you talk to memory,

103:59how you talk across a cluster of machines,

104:02how you scale out,

104:03how you have fast interconnects between machines.

104:06You then get system level programming models.

104:08So now that you have all this hardware, how to utilize it.

104:11You then have algorithmic breakthroughs where you say,

104:13hey, wow, cool.

104:14Instead of training in a resonant 50 in a week,

104:18I'm now training it in 25 seconds.

104:21And it's a combination of new optimizers

104:26and new just training regimens

104:29and different approaches to train.

104:32And all of these things come together

104:33to push the world forward.

104:36That was a beautiful exposition.

104:39But if you were to force to bet all your money

104:42on one of these.

104:45Why do we have to?

104:48Unfortunately, we have people working on all this.

104:50It's an exciting time, right?

104:52So, I mean, OpenAI did this little paper

104:56showing the algorithmic improvement you can get.

104:58It's been improving exponentially.

105:00I haven't quite seen the same kind of analysis

105:04on other layers of the stack.

105:06I'm sure it's also improving significantly.

105:09I just, it's a nice intuition builder.

105:12I mean, there's a reason why Moore's Law,

105:16that's the beauty of Moore's Law is

105:18somebody writes a paper that makes a ridiculous prediction.

105:22And it becomes reality in a sense.

105:27There's something about these narratives

105:28when you, when Chris Ladner on a silly little podcast

105:33makes, bets all his money on a particular thing,

105:37somehow it can have a ripple effect

105:39of actually becoming real.

105:40That's an interesting aspect of it.

105:43Cause like it might've been,

105:45we focus with Moore's Law,

105:47most of the computing industry

105:49really, really focused on the hardware.

105:53I mean, software innovation,

105:55I don't know how much software innovation

105:56there was in terms of efficient.

105:57What Intel Giveth Bill takes away, right?

106:00Yeah, I mean, compilers improved significantly also.

106:04Well, not really.

106:04So actually, I mean, so I'm joking

106:06about how software has gotten slower

106:08pretty much as fast as hardware got better,

106:11at least through the nineties.

106:13There's another joke, another law in compilers,

106:15which is called, I think it's called Probstine's Law,

106:18which is compilers double the performance

106:21of any given code every 18 years.

106:26So they move slowly.

106:27Yeah, also.

106:28Well, yeah, it's exponential also.

106:30Yeah, you're making progress,

106:32but there again, it's not about,

106:35the power of compilers is not just about

106:37how do you make the same thing go faster?

106:39It's how do you unlock the new hardware?

106:41A new chip came out, how do you utilize it?

106:43You say, oh, the programming model,

106:45how do we make people more productive?

106:46How do we have better error messages?

106:51Even such mundane things like how do I generate

106:55a very specific error message about your code

106:58actually makes people happy

106:59because then they know how to fix it, right?

107:01And it comes back to how do you help people

107:03get their job done.

107:04Yeah, and yeah, and then in this world

107:06of exponentially increasing smart toasters,

107:10how do you expand computing to all these kinds of devices?

107:16Do you see this world where just everything

107:18is a computing surface?

107:20You see that possibility?

107:22Just everything is a computer?

107:23Yeah, I don't see any reason

107:25that that couldn't be achieved.

107:26It turns out that sand goes into glass

107:30and glass is pretty useful too.

107:32And why not?

107:35Why not?

107:35So very important question then,

107:39if we're living in a simulation

107:44and the simulation is running a computer,

107:47like what's the architecture of that computer, do you think?

107:51So you're saying is it a quantum system?

107:54Yeah, like this whole quantum discussion, is it needed?

107:57Or can we run it with a RISC 5 architecture,

108:03a bunch of CPUs?

108:05I think it comes down to the right tool for the job.

108:07Yeah, and so.

108:08And what's the compiler?

108:10Yeah, exactly, that's my question.

108:12Did I get that job?

108:13Feed the universe compiler.

108:16And so there, as far as we know,

108:19quantum systems are the bottom of the pile of turtles

108:23so far.

108:24Yeah.

108:25And so we don't know efficient ways

108:28to implement quantum systems without using quantum computers.

108:32Yeah, and that's totally outside

108:33of everything we've talked about.

108:35But who runs that quantum computer?

108:37Yeah.

108:37Right, so if we really are living in a simulation,

108:41then is it bigger quantum computers?

108:44Is it different ones?

108:45Like how does that work out?

108:46How does that scale?

108:47Well, it's the same size.

108:49It's the same size.

108:50But then the thought of the simulation

108:52is that you don't have to run the whole thing,

108:54that we humans are cognitively very limited.

108:56We do checkpoints.

108:57We do checkpoints, yeah.

108:59And if we, the point at which we human,

109:03so you basically do minimal amount of,

109:06what is it, Swift does on right, copy on right.

109:12So you only adjust the simulation.

109:15Parallel universe theories, right?

109:17And so every time a decision's made,

109:20somebody opens the short end of your box,

109:22then there's a fork.

109:23And then this could happen.

109:24And then, thank you for considering the possibility.

109:29But yeah, so it may not require the entirety

109:32of the universe to simulate it.

109:34But it's interesting to think about

109:38as we create this higher and higher fidelity systems.

109:42But I do wanna ask on the quantum computer side,

109:46because everything we've talked about,

109:47whether you work with SciFive, with compilers,

109:51none of that includes quantum computers, right?

109:54That's true.

109:55So have you ever thought about this whole

110:03serious engineering work of quantum computers

110:06looks like of compilers, of architectures,

110:09all of that kind of stuff?

110:10So I've looked at it a little bit.

110:11I know almost nothing about it,

110:14which means that at some point,

110:15I will have to find an excuse to get involved,

110:17because that's how it works.

110:18But do you think that's a thing to be,

110:21like with your little tingly senses of the timing

110:24of when to be involved, is it not yet?

110:26Well, so the thing I do really well

110:28is I jump into messy systems

110:31and figure out how to make them,

110:33figure out what the truth in the situation is,

110:35try to figure out what the unifying theory is,

110:39how to like factor the complexity,

110:40how to find a beautiful answer to a problem

110:42that has been well studied

110:44and lots of people have bashed their heads against it.

110:47I don't know that quantum computers are mature enough

110:49and accessible enough to be figured out yet, right?

110:53And I think the open question with quantum computers is,

110:58is there a useful problem

111:00that gets solved with a quantum computer

111:02that makes it worth the economic cost

111:05of like having one of these things

111:06and having legions of people that set it up?

111:11You go back to the fifties, right?

111:12And there's the projections

111:13of the world will only need seven computers, right?

111:18Well, and part of that was that people hadn't figured out

111:20what they're useful for.

111:21What are the algorithms we wanna run?

111:23What are the problems that get solved?

111:24And this comes back to how do we make the world better,

111:27either economically or making somebody's life better

111:29or like solving a problem that wasn't solved before,

111:31things like this.

111:33And I think that just we're a little bit too early

111:36in that development cycle

111:36because it's still like literally a science project,

111:39not a negative connotation, right?

111:41It's literally a science project

111:42and the progress there is amazing.

111:45And so I don't know if it's 10 years away,

111:48if it's two years away,

111:50exactly where that breakthrough happens,

111:51but you look at machine learning,

111:56we went through a few winners

111:58before the AlexNet transition

112:00and then suddenly it had its breakout moment.

112:02And that was the catalyst

112:04that then drove the talent flocking into it.

§15Transcript · 1:52:07–2:00:18

112:07That's what drove the economic applications of it.

112:10That's what drove the technology to go faster

112:13because you now have more minds thrown at the problem.

112:15This is what caused like a serious knee in deep learning

112:20and the algorithms that we're using.

112:21And so I think that's what quantum needs to go through.

112:25And so right now it's in that formidable finding itself,

112:28getting the like literally the physics figured out.

112:32And then it has to figure out the application

112:36that makes this useful.

112:37Yeah, but I'm not skeptical that I think that will happen.

112:40I think it's just 10 years away, something like that.

112:43I forgot to ask,

112:44what programming language do you think

112:46the simulation is written in?

112:48Ooh, probably Lisp.

112:50So not Swift.

112:52Like if you're a Tibet, I'll just leave it at that.

112:58So, I mean, we've mentioned that you worked

113:00with all these companies,

113:01we've talked about all these projects.

113:03It's kind of like if we just step back and zoom out

113:07about the way you did that work.

113:10And we look at COVID times,

113:12this pandemic we're living through that may,

113:14if I look at the way Silicon Valley folks

113:17are talking about it, the way MIT is talking about it,

113:19this might last for a long time.

113:23Not just the virus, but the remote nature.

113:28The economic impact.

113:29I mean, all of it, yeah.

113:30Yeah, it's gonna be a mess.

113:32Do you think, what's your prediction?

113:34I mean, from sci fi to Google,

113:36to just all the places you worked in,

113:42just Silicon Valley, you're in the middle of it.

113:44What do you think is,

113:45how is this whole place gonna change?

113:46Yeah, so, I mean, I really can only speak

113:49to the tech perspective.

113:50I am in that bubble.

113:54I think it's gonna be really interesting

113:55because the Zoom culture of being remote

113:58and on video chat all the time

114:00has really interesting effects on people.

114:01So on the one hand, it's a great normalizer.

114:05It's a normalizer that I think will help communities

114:09of people that have traditionally been underrepresented

114:12because now you're taking, in some cases, a face off

114:16because you don't have to have a camera going, right?

114:18And so you can have conversations

114:20without physical appearance being part of the dynamic,

114:22which is pretty powerful.

114:24You're taking remote employees

114:25that have already been remote,

114:27and you're saying you're now on the same level

114:29and footing as everybody else.

114:31Nobody gets whiteboards.

114:33You're not gonna be the one person

114:34that doesn't get to be participating

114:36in the whiteboard conversation,

114:37and that's pretty powerful.

114:39You've got, you're forcing people to think asynchronously

114:44in some cases because it's harder to just get people

114:47physically together, and the bumping into each other

114:49forces people to find new ways to solve those problems.

114:52And I think that that leads to more inclusive behavior,

114:55which is good.

114:56On the other hand, it's also, it just sucks, right?

115:00And so the actual communication just sucks

115:05being not with people on a daily basis

115:09and collaborating with them.

115:11Yeah, all of that, right?

115:13I mean, everything, this whole situation is terrible.

115:15What I meant primarily was the,

115:19I think that most humans

115:20like working physically with humans.

115:22I think this is something that not everybody,

115:24but many people are programmed to do.

115:27And I think that we get something out of that

115:29that is very hard to express, at least for me.

115:31And so maybe this isn't true of everybody.

115:33But, and so the question to me is,

115:36when you get through that time of adaptation,

115:40you get out of March and April,

115:41and you get into December,

115:43you get into next March, if it's not changed, right?

115:46It's already terrifying.

115:47Well, you think about that,

115:49and you think about what is the nature of work?

115:51And how do we adapt?

115:52And humans are very adaptable species, right?

115:55We can learn things when we're forced to,

115:58and there's a catalyst to make that happen.

116:00And so what is it that comes out of this,

116:02and are we better or worse off?

116:04I think that you look at the Bay Area,

116:07housing prices are insane.

116:08Well, why?

116:09Well, there's a high incentive to be physically located,

116:12because if you don't have proximity,

116:14you end up paying for it and commute, right?

116:18And there has been huge social pressure

116:21in terms of you will be there for the meeting, right?

116:24Or whatever scenario it is.

116:26And I think that's gonna be way better.

116:28I think it's gonna be much more the norm

116:30to have remote employees,

116:31and I think this is gonna be really great.

116:33Do you have friends, or do you hear of people moving?

116:37I know one family friend that moved.

116:40They moved back to Michigan,

116:41and they were a family with three kids

116:45living in a small apartment,

116:46and we're going insane, right?

116:50And they're in tech, husband works for Google.

116:54So first of all, friends of mine

116:57are in the process of, or have already lost the business.

117:00The thing that represents their passion, their dream,

117:03it could be small entrepreneurial projects,

117:05but it could be large businesses,

117:06like people that run gyms.

117:08Restaurants, tons of things, yeah.

117:10But also, people look at themselves in the mirror

117:14and ask the question of, what do I wanna do in life?

117:17For some reason, they haven't done it until COVID.

117:20They really ask that question,

117:22and that results often in moving or leaving the company

117:26with starting your own business

117:28or transitioning to a different company.

117:30Do you think we're gonna see that a lot?

117:33Well, I can't speak to that.

117:36I mean, we're definitely gonna see it

117:37at a higher frequency than we did before,

117:39just because I think what you're trying to say

117:41is there are decisions that you make yourself,

117:45big life decisions that you make yourself,

117:47and I'm gonna quit my job and start a new thing.

117:49There's also decisions that get made for you.

117:52I got fired from my job, what am I gonna do, right?

117:55And that's not a decision that you think about,

117:58but you're forced to act, okay?

118:00And so I think that those, you're forced to act

118:02kind of moments where global pandemic

118:05comes and wipes out the economy,

118:06and now your business doesn't exist.

118:09I think that does lead to more reflection, right?

118:11Because you're less anchored on what you have,

118:14and it's not a, what do I have to lose

118:17versus what do I have to gain, A, B, comparison.

118:19It's more of a fresh slate.

118:21Cool, I could do anything now.

118:23Do I wanna do the same thing I was doing?

118:26Did that make me happy?

118:27Is this now time to go back to college

118:29and take a class and learn a new skill?

118:33Is this a time to spend time with family

118:36if you can afford to do that?

118:37Is this time to literally move in with parents, right?

118:40I mean, all these things that were not normative before

118:43suddenly become, I think, very, the value systems change.

118:49And I think that's actually a good thing

118:50in the short term, at least, because it leads to,

118:56there's kind of been an overoptimization

118:58along one set of priorities for the world,

119:01and now maybe we'll get to a more balanced

119:03and more interesting world

119:05where people are doing different things.

119:06I think it could be good.

119:07I think there could be more innovation

119:08that comes out of it, for example.

119:10What do you think about all the social chaos

119:12we're in the middle of?

119:13It sucks.

119:14You think it's, let me ask you a whole,

119:18you think it's all gonna be okay?

119:21Well, I think humanity will survive.

119:23The, from an existential,

119:25like we're not all gonna kill, yeah, well.

119:27Yeah, I don't think the virus is gonna kill all the humans.

119:30I don't think all the humans are gonna kill all the humans.

119:31I think that's unlikely.

119:32But I look at it as progress requires a catalyst, right?

119:42So you need a reason for people to be willing

119:45to do things that are uncomfortable.

119:47I think that the US, at least,

119:50but I think the world in general

119:51is a pretty unoptimal place to live in for a lot of people.

119:56And I think that what we're seeing right now

119:58is we're seeing a lot of unhappiness.

120:00And because of all the pressure,

120:03because of all the badness in the world

120:05that's coming together,

120:06it's really kind of igniting some of that debate

120:07that should have happened a long time ago, right?

120:10I mean, I think that we'll see more progress.

120:11You're asking about, offline you're asking about politics

120:14and wouldn't it be great if politics moved faster

120:15because there's all these problems in the world

120:16and we can move it.

§16Transcript · 2:00:18–2:08:52

120:18Well, people are intentionally, are inherently conservative.

120:22And so if you're talking about conservative people,

120:25particularly if they have heavy burdens on their shoulders

120:27because they represent literally thousands of people,

120:31it makes sense to be conservative.

120:33But on the other hand, when you need change,

120:35how do you get it?

120:37The global pandemic will probably lead to some change.

120:40And it's not a directed, it's not a directed plan,

120:44but I think that it leads to people

120:45asking really interesting questions.

120:47And some of those questions

120:48should have been asked a long time ago.

120:50Well, let me know if you've observed this as well.

120:53Something that's bothered me in the machine learning

120:55community, I'm guessing it might be prevalent

120:58in other places, is something that feels like in 2020

121:02increase the level of toxicity.

121:05Like people are just quicker to pile on,

121:09to just be, they're just harsh on each other,

121:13to like mob, pick a person that screwed up

121:19and like make it a big thing.

121:22And is there something that we can like,

121:26yeah, have you observed that in other places?

121:28Is there some way out of this?

121:30I think there's an inherent thing in humanity

121:32that's kind of an us versus them thing,

121:34which is that you wanna succeed and how do you succeed?

121:37Well, it's relative to somebody else.

121:39And so what's happening in, at least in some part

121:43is that with the internet and with online communication,

121:47the world's getting smaller, right?

121:49And so we're having some of the social ties

121:53of like my town versus your town's football team, right?

121:57Turn into much larger and yet shallower problems.

122:02And people don't have time, the incentives,

122:06the clickbait and like all these things

122:08kind of really feed into this machine.

122:10And I don't know where that goes.

122:12Yeah, I mean, the reason I think about that,

122:15I mentioned to you this offline a little bit,

122:17but I have a few difficult conversations scheduled,

122:23some of them political related,

122:25some of them within the community,

122:28difficult personalities that went through some stuff.

122:30I mean, one of them I've talked before,

122:32I will talk again is Yann LeCun.

122:34He got a little bit of crap on Twitter

122:38for talking about a particular paper

122:40and the bias within a data set.

122:42And then there's been a huge, in my view,

122:45and I'm willing, comfortable saying it,

122:49irrational, over exaggerated pile on his comments

122:54because he made pretty basic comments about the fact that

122:58if there's bias in the data,

122:59there's going to be bias in the results.

123:02So we should not have bias in the data,

123:04but people piled on to him because he said

123:07he trivialized the problem of bias.

123:10Like it's a lot more than just bias in the data,

123:13but like, yes, that's a very good point,

123:16but that's not what he was saying.

123:18That's not what he was saying.

123:19And the response, like the implied response

123:23that he's basically sexist and racist

123:27is something that completely drives away

123:30the possibility of nuanced discussion.

123:32One nice thing about like a pocket long form of conversation

123:37is you can talk it out.

123:40You can lay your reasoning out.

123:42And even if you're wrong,

123:44you can still show that you're a good human being

123:47underneath it.

123:48You know, your point about

123:49you can't have a productive discussion.

123:50Well, how do you get to the point where people can turn?

123:53They can learn, they can listen, they can think,

123:56they can engage versus just being a shallow like,

124:00and then keep moving, right?

124:02And I don't think that progress really comes from that,

124:06right?

124:07And I don't think that one should expect that.

124:09I think that you'd see that as reinforcing

124:12individual circles and the us versus them thing.

124:14And I think that's fairly divisive.

124:17Yeah, I think there's a big role in,

124:20like the people that bother me most on Twitter

124:24when I observe things is not the people

124:26who get very emotional, angry, like over the top.

124:30It's the people who like prop them up.

124:33It's all the, it's this,

124:36I think what should be the,

124:37we should teach each other is to be sort of empathetic.

124:42The thing that it's really easy to forget,

124:44particularly on like Twitter or the internet or an email,

124:47is that sometimes people just have a bad day, right?

124:50You have a bad day or you're like,

124:53I've been in the situation where it's like between meetings,

124:55like fire off a quick response to an email

124:57because I want to like help get something unblocked,

125:00phrase it really objectively wrong.

125:03I screwed up.

125:04And suddenly this is now something that sticks with people.

125:08And it's not because they're bad.

125:10It's not because you're bad.

125:11Just psychology of like, you said a thing,

125:15it sticks with you.

125:16You didn't mean it that way,

125:16but it really impacted somebody

125:18because the way they interpret it.

125:20And this is just an aspect of working together as humans.

125:23And I have a lot of optimism in the long term,

125:26the very long term about what we as humanity can do.

125:29But I think that's going to be,

125:29it's just always a rough ride.

125:31And you came into this by saying like,

125:33what does COVID and all the social strife

125:36that's happening right now mean?

125:38And I think that it's really bad in the short term,

125:40but I think it'll lead to progress.

125:42And for that, I'm very thankful.

125:45Yeah, painful in the short term though.

125:47Well, yeah.

125:48I mean, people are out of jobs.

125:49Like some people can't eat.

125:50Like it's horrible.

125:52And, but you know, it's progress.

125:56So we'll see what happens.

125:58I mean, the real question is when you look back 10 years,

126:0120 years, a hundred years from now,

126:03how do we evaluate the decisions are being made right now?

126:06I think that's really the way you can frame that

126:09and look at it.

126:10And you say, you know,

126:11you integrate across all the short term horribleness

126:14that's happening and you look at what that means

126:17and is the improvement across the world

126:19or the regression across the world significant enough

126:22to make it a good or a bad thing?

126:24I think that's the question.

126:26Yeah.

126:27And for that, it's good to study history.

126:29I mean, one of the big problems for me right now

126:32is I'm reading The Rise and Fall of the Third Reich.

126:36Light reading?

126:37So it's everything is just,

126:39I just see parallels and it means it's,

126:42you have to be really careful not to overstep it,

126:45but just the thing that worries me the most

126:48is the pain that people feel when a few things combine,

126:54which is like economic depression,

126:55which is quite possible in this country.

126:57And then just being disrespected in some kind of way,

127:02which the German people were really disrespected

127:05by most of the world, like in a way that's over the top,

127:10that something can build up

127:12and then all you need is a charismatic leader

127:15to go either positive or negative and both work

127:19as long as they're charismatic.

127:21And there's...

127:22It's taking advantage of, again,

127:23that inflection point that the world's in

127:26and what they do with it could be good or bad.

127:29And so it's a good way to think about times now,

127:32like on an individual level,

127:34what we decide to do is when history is written,

127:3830 years from now, what happened in 2020,

127:40probably history is gonna remember 2020.

127:43Yeah, I think so.

127:43Either for good or bad,

127:46and it's up to us to write it so it's good.

127:49Well, one of the things I've observed

127:50that I find fascinating is most people act

127:54as though the world doesn't change.

127:56You make decision knowingly, right?

127:59You make a decision where you're predicting the future

128:02based on what you've seen in the recent past.

128:04And so if something's always been,

128:06it's rained every single day,

128:07then of course you expect it to rain today too, right?

128:10On the other hand, the world changes all the time.

128:13Yeah.

128:14Constantly, like for better and for worse.

128:16And so the question is,

128:17if you're interested in something that's not right,

128:20what is the inflection point that led to a change?

128:22And you can look to history for this.

128:24Like what is the catalyst that led to that explosion

128:27that led to that bill that led to the,

128:30like you can kind of work your way backwards from that.

128:33And maybe if you pull together the right people

128:35and you get the right ideas together,

128:36you can actually start driving that change

128:38and doing it in a way that's productive

128:40and hurts fewer people.

128:41Yeah, like a single person,

128:43a single event can turn all of history.

128:44Absolutely, everything starts somewhere.

128:46And often it's a combination of multiple factors,

128:48but yeah, these things can be engineered.

§17Transcript · 2:08:52–2:17:13

128:52That's actually the optimistic view that.

128:54I'm a longterm optimist on pretty much everything

128:57and human nature.

128:59We can look to all the negative things

129:00that humanity has, all the pettiness

129:03and all the like self servingness

129:05and the just the cruelty, right?

129:09The biases, the just humans can be very horrible.

129:13But on the other hand, we're capable of amazing things.

129:17And the progress across 100 year chunks

129:21is striking.

129:23And even across decades, we've come a long ways

129:26and there's still a long ways to go,

129:27but that doesn't mean that we've stopped.

129:29Yeah, the kind of stuff we've done in the last 100 years

129:33is unbelievable.

129:34It's kind of scary to think what's gonna happen

129:36in this 100 years.

129:37It's scary, like exciting.

129:39Like scary in a sense that it's kind of sad

129:41that the kind of technology is gonna come out

129:43in 10, 20, 30 years.

129:45We're probably too old to really appreciate

129:47if you don't grow up with it.

129:49It'll be like kids these days with their virtual reality

129:51and their TikToks and stuff like this.

129:54Like, how does this thing and like,

129:56come on, give me my static photo.

130:00My Commodore 64.

130:02Yeah, exactly.

130:03Okay, sorry, we kind of skipped over.

130:05Let me ask on, the machine learning world

130:11has been kind of inspired, their imagination captivated

130:15with GPT3 and these language models.

130:18I thought it'd be cool to get your opinion on it.

130:21What's your thoughts on this exciting world of,

130:27it connects to computation actually,

130:29is of language models that are huge

130:33and take many, many computers, not just to train,

130:37but to also do inference on.

130:39Sure.

130:40Well, I mean, it depends on what you're speaking to there.

130:43But I mean, I think that there's been

130:45a pretty well understood maximum in deep learning

130:48that if you make the model bigger

130:49and you shove more data into it,

130:51assuming you train it right

130:52and you have a good model architecture,

130:54that you'll get a better model out.

130:55And so on one hand, GPT3 was not that surprising.

130:59On the other hand, a tremendous amount of engineering

131:02went into making it possible.

131:04The implications of it are pretty huge.

131:07I think that when GPT2 came out,

131:08there was a very provocative blog post from OpenAI

131:11talking about, we're not gonna release it

131:13because of the social damage it could cause

131:15if it's misused.

131:18I think that's still a concern.

131:20I think that we need to look at how technology is applied

131:23and well meaning tools can be applied in very horrible ways

131:26and they can have very profound impact on that.

131:30I think that GPT3 is a huge technical achievement.

131:34And what will GPT4 be?

131:35Well, it'll probably be bigger, more expensive to train.

131:38Really cool architectural tricks.

131:42What do you think, is there,

131:43I don't know how much thought you've done

131:46on distributed computing.

131:48Is there some technical challenges that are interesting

131:52that you're hopeful about exploring

131:54in terms of a system that,

131:57like a piece of code that with GPT4 that might have,

132:05I don't know, hundreds of trillions of parameters

132:09which have to run on thousands of computers.

132:11Is there some hope that we can make that happen?

132:15Yeah, well, I mean, today you can write a check

132:18and get access to a thousand TPU cores

132:21and do really interesting large scale training

132:23and inference and things like that in Google Cloud,

132:26for example, right?

132:27And so I don't think it's a question about scale,

132:31it's a question about utility.

132:33And when I look at the transformer series of architectures

132:36that the GPT series is based on,

132:38it's really interesting to look at that

132:39because they're actually very simple designs.

132:42They're not recurrent.

132:44The training regimens are pretty simple.

132:47And so they don't really reflect like human brains, right?

132:51But they're really good at learning language models

132:54and they're unrolled enough

132:55that you can simulate some recurrence, right?

132:59And so the question I think about is,

133:02where does this take us?

133:03Like, so we can just keep scaling it,

133:05have more parameters, more data, more things,

133:07we'll get a better result for sure.

133:09But are there architectural techniques

133:11that can lead to progress at a faster pace, right?

133:15This is when, you know, how do you get,

133:17instead of just like making it a constant time bigger,

133:20how do you get like an algorithmic improvement

133:23out of this, right?

133:24And whether it be a new training regimen,

133:25if it becomes sparse networks, for example,

133:30the human brain is sparse, all these networks are dense.

133:33The connectivity patterns can be very different.

133:36I think this is where I get very interested

133:38and I'm way out of my league

133:39on the deep learning side of this.

133:41But I think that could lead to big breakthroughs.

133:43When you talk about large scale networks,

133:46one of the things that Jeff Dean likes to talk about

133:47and he's given a few talks on

133:50is this idea of having a sparsely gated mixture of experts

133:54kind of a model where you have, you know,

133:57different nets that are trained

133:59and are really good at certain kinds of tasks.

134:02And so you have this distributor across a cluster

134:04and so you have a lot of different computers

134:06that end up being kind of locally specialized

134:08in different demands.

134:09And then when a query comes in,

134:11you gate it and you use learn techniques

134:13to route to different parts of the network.

134:15And then you utilize the compute resources

134:18of the entire cluster by having specialization within it.

134:20And I don't know where that goes

134:23or when it starts to work,

134:25but I think things like that

134:26could be really interesting as well.

134:28And on the data side too,

134:30if you can think of data selection

134:33as a kind of programming.

134:35Yeah.

134:36I mean, essentially, if you look at it,

134:37like Karpathy talked about software 2.0,

134:40I mean, in a sense, data is the program.

134:44Yeah, yeah.

134:44So let me try to summarize Andre's position really quick

134:48before I disagree with it.

134:50Yeah.

134:51So Andre Karpathy is amazing.

134:53So this is nothing personal with him.

134:55He's an amazing engineer.

134:57And also a good blog post writer.

134:59Yeah, well, he's a great communicator.

135:01You know, he's just an amazing person.

135:02He's also really sweet.

135:03So his basic premise is that software is suboptimal.

135:09I think we can all agree to that.

135:11He also points out that deep learning

135:14and other learning based techniques are really great

135:16because you can solve problems

135:17in more structured ways with less like ad hoc code

135:22that people write out and don't write test cases for

135:24in some cases.

135:25And so they don't even know if it works in the first place.

135:27And so if you start replacing systems of imperative code

135:32with deep learning models, then you get a better result.

135:37Okay.

135:38And I think that he argues that software 2.0

135:40is a pervasively learned set of models

135:44and you get away from writing code.

135:45And he's given talks where he talks about, you know,

135:49swapping over more and more and more parts of the code

135:50to being learned and driven that way.

135:54I think that works.

135:56And if you're predisposed to liking machine learning,

135:59then I think that that's definitely a good thing.

136:01I think this is also good for accessibility in many ways

136:04because certain people are not gonna write C code

136:06or something.

136:07And so having a data driven approach to do

136:10this kind of stuff, I think can be very valuable.

136:12On the other hand, there are huge trade offs.

136:14It's not clear to me that software 2.0 is the answer.

136:19And probably Andre wouldn't argue that it's the answer

136:21for every problem either.

136:22But I look at machine learning as not a replacement

136:26for software 1.0.

136:27I look at it as a new programming paradigm.

136:30And so programming paradigms, when you look across demands,

136:35is structured programming where you go from go tos

136:38to if, then, else, or functional programming from Lisp.

136:42And you start talking about higher order functions

136:44and values and things like this.

136:45Or you talk about object oriented programming.

136:48You're talking about encapsulation,

136:49subclassing, inheritance.

136:50You start talking about generic programming

136:52where you start talking about code reuse

136:54through specialization and different type instantiations.

136:59When you start talking about differentiable programming,

137:01something that I am very excited about

137:04in the context of machine learning,

137:05talking about taking functions and generating variants,

137:09like the derivative of another function.

137:11Like that's a programming paradigm that's very useful

§18Transcript · 2:17:13–2:24:58

137:13for solving certain classes of problems.

137:16Machine learning is amazing

137:17at solving certain classes of problems.

137:19Like you're not gonna write a cat detector

137:21or even a language translation system by writing C code.

137:25That's not a very productive way to do things anymore.

137:28And so machine learning is absolutely

137:31the right way to do that.

137:31In fact, I would say that learned models

137:34are really one of the best ways to work

137:35with the human world in general.

137:38And so anytime you're talking about sensory input

137:40of different modalities,

137:41anytime that you're talking about generating things

137:44in a way that makes sense to a human,

137:45I think that learned models are really, really useful.

137:48And that's because humans are very difficult

137:50to characterize, okay?

137:52And so this is a very powerful paradigm

137:55for solving classes of problems.

137:57But on the other hand, imperative code is too.

137:59You're not gonna write a bootloader for your computer

138:03with a deep learning model.

138:04Deep learning models are very hardware intensive.

138:07They're very energy intensive

138:08because you have a lot of parameters

138:11and you can provably implement any function

138:14with a learned model, like this has been shown,

138:17but that doesn't make it efficient.

138:20And so if you're talking about caring about a few orders

138:22of magnitudes worth of energy usage,

138:24then it's useful to have other tools in the toolbox.

138:26There's also robustness too.

138:28I mean, as a...

138:29Yeah, exactly.

138:30All the problems of dealing with data and bias in data,

138:32all the problems of software 2.0.

138:35And one of the great things that Andre is arguing towards,

138:39which I completely agree with him,

138:40is that when you start implementing things

138:43with deep learning, you need to learn from software 1.0

138:46in terms of testing, continuous integration,

138:49how you deploy, how do you validate,

138:51all these things and building systems around that

138:53so that you're not just saying like,

138:55oh, it seems like it's good, ship it, right?

138:58Well, what happens when I regress something?

138:59What happens when I make a classification that's wrong

139:02and now I hurt somebody, right?

139:05I mean, all these things you have to reason about.

139:07Yeah, but at the same time,

139:08the bootloader that works for us humans

139:12looks awfully a lot like a neural network, right?

139:15Yeah.

139:16It's messy and you can cut out

139:18different parts of the brain.

139:19There's a lot of this neuroplasticity work

139:22that shows that it's gonna adjust.

139:24It's a really interesting question,

139:26how much of the world's programming

139:29could be replaced by software 2.0?

139:31Like with...

139:32Oh, well, I mean, it's provably true

139:35that you could replace all of it.

139:37Right, so then it's a question of the trade offs.

139:39Anything that's a function, you can.

139:40So it's not a question about if.

139:42I think it's a economic question.

139:44It's a, what kind of talent can you get?

139:47What kind of trade offs in terms of maintenance, right?

139:50Those kinds of questions, I think.

139:51What kind of data can you collect?

139:53I think one of the reasons that I'm most interested

139:55in machine learning as a programming paradigm

139:58is that one of the things that we've seen

140:00across computing in general is that

140:02being laser focused on one paradigm

140:04often puts you in a box that's not super great.

140:07And so you look at object oriented programming,

140:10like it was all the rage in the early 80s

140:12and like everything has to be objects.

140:13And people forgot about functional programming

140:15even though it came first.

140:17And then people rediscovered that,

140:19hey, if you mix functional and object oriented

140:21in structure, like you mix these things together,

140:24you can provide very interesting tools

140:25that are good at solving different problems.

140:28And so the question there is how do you get

140:30the best way to solve the problems?

140:32It's not about whose tribe should win, right?

140:36It's not about, you know, that shouldn't be the question.

140:38The question is how do you make it

140:40so that people can solve those problems the fastest

140:42and they have the right tools in their box

140:44to build good libraries and they can solve these problems.

140:47And when you look at that, that's like, you know,

140:49you look at reinforcement learning

140:50as one really interesting subdomain of this.

140:52Reinforcement learning, often you have to have

140:55the integration of a learned model

140:57combined with your Atari or whatever the other scenario

141:00it is that you're working in.

141:02You have to combine that thing with the robot control

141:05for the arm, right?

141:07And so now it's not just about that one paradigm,

141:11it's about integrating that with all the other systems

141:14that you have, including often legacy systems

141:17and things like this, right?

141:18And so to me, I think that the interesting thing to say

141:21is like, how do you get the best out of this domain

141:23and how do you enable people to achieve things

141:25that they otherwise couldn't do

141:27without excluding all the good things

141:29we already know how to do?

141:31Right, but okay, this is a crazy question,

141:35but we talked a little bit about GPT3,

141:38but do you think it's possible that these language models

141:42that in essence, in the language domain,

141:47Software 2.0 could replace some aspect of compilation,

141:51for example, or do program synthesis,

141:54replace some aspect of programming?

141:56Yeah, absolutely.

141:57So I think that learned models in general

142:00are extremely powerful,

142:01and I think that people underestimate them.

142:04Maybe you can suggest what I should do.

142:07So if I have access to the GPT3 API,

142:11would I be able to generate Swift code, for example?

142:14Do you think that could do something interesting

142:16and would work?

142:17So GPT3 is probably not trained on the right corpus,

142:21so it probably has the ability to generate some Swift.

142:23I bet it does.

142:25It's probably not gonna generate a large enough body

142:27of Swift to be useful,

142:28but take it a next step further.

142:30Like if you had the goal of training something like GPT3

142:33and you wanted to train it to generate source code, right?

142:38It could definitely do that.

142:39Now the question is, how do you express the intent

142:42of what you want filled in?

142:44You can definitely write scaffolding of code

142:47and say, fill in the hole,

142:48and sort of put in some for loops,

142:50or put in some classes or whatever.

142:51And the power of these models is impressive,

142:53but there's an unsolved question, at least unsolved to me,

142:56which is, how do I express the intent of what to fill in?

142:59Right?

143:01And kind of what you'd really want to have,

143:03and I don't know that these models are up to the task,

143:06is you wanna be able to say,

143:08here's the scaffolding,

143:09and here are the assertions at the end.

143:12And the assertions always pass.

143:14And so you want a generative model on the one hand, yes.

143:16Oh, that's fascinating, yeah.

143:17Right, but you also want some loop back,

143:20some reinforcement learning system or something,

143:23where you're actually saying like,

143:24I need to hill climb towards something

143:26that is more correct.

143:28And I don't know that we have that.

143:29So it would generate not only a bunch of the code,

143:33but like the checks that do the testing.

143:35It would generate the tests.

143:37I think the humans would generate the tests, right?

143:38Oh, okay.

143:39But it would be fascinating if...

143:41Well, the tests are the requirements.

143:43Yes, but the, okay, so...

143:44Because you have to express to the model

143:45what you want to...

143:47You don't just want gibberish code.

143:49Look at how compelling this code looks.

143:51You want a story about four horned unicorns or something.

143:54Well, okay, so exactly.

143:55But that's human requirements.

143:57But then I thought it's a compelling idea

144:00that the GPT4 model could generate checks

144:06that are more high fidelity that check for correctness.

144:11Because the code it generates,

144:14like say I ask it to generate a function

144:18that gives me the Fibonacci sequence.

144:21Sure.

144:22I don't like...

144:24So decompose the problem, right?

144:25So you have two things.

144:26You have, you need the ability to generate

144:29syntactically correct Swift code that's interesting, right?

144:33I think GPT series of model architectures can do that.

144:37But then you need the ability to add the requirements.

144:41So generate Fibonacci.

144:43The human needs to express that goal.

144:46We don't have that language that I know of.

144:49No, I mean, it can generate stuff.

144:50Have you seen what GPT3 can generate?

144:52You can say, I mean, there's a interface stuff

144:55like it can generate HTML.

§19Transcript · 2:24:58–2:32:32

144:58It can generate basic for loops that give you like...

145:02Right, but pick HTML.

145:02How do I say I want google.com?

145:06Well, no, you could say...

145:07Or not literally google.com.

145:09How do I say I want a webpage

145:10that's got a shopping cart and this and that?

145:13It does that.

145:14I mean, so, okay.

145:14So just, I don't know if you've seen these demonstrations

145:17but you type in, I want a red button

145:20with the text that says hello.

145:22And you type that in natural language

145:24and it generates the correct HTML.

145:26I've done this demo.

145:27It's kind of compelling.

145:29So you have to prompt it with similar kinds of mappings.

145:33Of course, it's probably handpicked.

145:35I got to experiment that probably,

145:37but the fact that you can do that once

145:39even out of like 20 is quite impressive.

145:43Again, that's very basic.

145:45Like the HTML is kind of messy and bad.

145:48But yes, the intent is...

145:49The idea is the intent is specified in natural language.

145:53Yeah, so I have not seen that.

145:54That's really cool.

145:55Yeah.

145:56Yeah, but the question is the correctness of that.

145:59Like visually you can check, oh, the button is red,

146:02but for more complicated functions

146:10where the intent is harder to check.

146:12This goes into like NP completeness kind of things.

146:15Like I want to know that this code is correct

146:18and generates a giant thing

146:20that does some kind of calculation.

146:23It seems to be working.

146:25It's interesting to think like,

146:27should the system also try to generate checks

146:30for itself for correctness?

146:32Yeah, I don't know.

146:33And this is way beyond my experience.

146:35The thing that I think about is that

146:39there doesn't seem to be a lot of

146:41equational reasoning going on.

146:43There's a lot of pattern matching and filling in

146:45and kind of propagating patterns

146:47that have been seen before into the future

146:49and into the generator result.

146:50And so if you want to get correctness,

146:53you kind of need theorem proving kind of things

146:55and like higher level logic.

146:57And I don't know that...

146:58You could talk to Jan about that

147:00and see what the bright minds

147:03are thinking about right now,

147:04but I don't think the GPT is in that vein.

147:08It's still really cool.

147:09Yeah, and surprisingly, who knows,

147:11maybe reasoning is...

147:13Is overrated.

147:14Yeah, is overrated.

147:15Right, I mean, do we reason?

147:17Yeah.

147:18How do you tell, right?

147:18Are we just pattern matching based on what we have

147:20and then reverse justifying to ourselves?

147:22Exactly, the reverse.

147:24So like I think what the neural networks are missing

147:26and I think GPT4 might have

147:29is to be able to tell stories to itself about what it did.

147:33Well, that's what humans do, right?

147:34I mean, you talk about like network explainability, right?

147:38And we give, no, that's a hard time about this,

147:40but humans don't know why we make decisions.

147:42We have this thing called intuition

147:43and then we try to like say,

147:45this feels like the right thing, but why, right?

147:47And you wrestle with that

147:49when you're making hard decisions

147:50and is that science?

147:52Not really.

147:54Let me ask you about a few high level questions, I guess.

147:57Because you've done a million things in your life

148:02and been very successful.

148:04A bunch of young folks listen to this,

148:07ask for advice from successful people like you.

148:11If you were to give advice to somebody,

148:15you know, another graduate student

148:17or some high school student

148:19about pursuing a career in computing

148:23or just advice about life in general,

148:25is there some words of wisdom you can give them?

148:28So I think you come back to change

148:30and profound leaps happen

148:34because people are willing to believe

148:35that change is possible

148:36and that the world does change

148:39and are willing to do the hard thing

148:41that it takes to make change happen.

148:42And whether it be implementing a new programming language

148:45or employing a new system

148:47or employing a new research paper,

148:49designing a new thing,

148:50moving the world forward in science

148:51and philosophy, whatever,

148:53it really comes down to somebody

148:54who's willing to put in the work, right?

148:57And you have, the work is hard

149:00for a whole bunch of different reasons.

149:01One of which is, it's work, right?

149:06And so you have to have the space in your life

149:08in which you can do that work,

149:09which is why going to grad school

149:11can be a beautiful thing for certain people.

149:14But also there's a self doubt that happens.

149:16Like you're two years into a project,

149:18is it going anywhere, right?

149:20Well, what do you do?

149:21Do you just give up because it's hard?

149:23No, no, I mean, some people like suffering.

149:26And so you plow through it.

149:29The secret to me is that you have to love what you're doing

149:31and follow that passion

149:35because when you get to the hard times,

149:37that's when, if you love what you're doing,

149:40you're willing to kind of push through.

149:41And this is really hard

149:45because it's hard to know what you will love doing

149:48until you start doing a lot of things.

149:50And so that's why I think that,

149:51particularly early in your career,

149:53it's good to experiment.

149:54Do a little bit of everything.

149:55Go take the survey class on

149:59the first half of every class in your upper division lessons

150:03and just get exposure to things

150:05because certain things will resonate with you

150:07and you'll find out, wow, I'm really good at this.

150:08I'm really smart at this.

150:10Well, it's just because it works with the way your brain.

150:13And when something jumps out,

150:14I mean, that's one of the things

150:15that people often ask about is like,

150:19well, I think there's a bunch of cool stuff out there.

150:21Like how do I pick the thing?

150:23Like how do you hook, in your life,

150:27how did you just hook yourself in and stuck with it?

150:30Well, I got lucky, right?

150:31I mean, I think that many people forget

150:34that a huge amount of it or most of it is luck, right?

150:38So let's not forget that.

150:41So for me, I fell in love with computers early on

150:44because they spoke to me, I guess.

150:49What language did they speak?

150:50Basic.

150:51Basic, yeah.

150:53But then it was just kind of following

150:56a set of logical progressions,

150:58but also deciding that something that was hard

151:01was worth doing and a lot of fun, right?

151:04And so I think that that is also something

151:06that's true for many other domains,

151:08which is if you find something that you love doing

151:10that's also hard, if you invest yourself in it

151:13and add value to the world,

151:14then it will mean something generally, right?

151:17And again, that can be a research paper,

151:19that can be a software system,

151:20that can be a new robot,

151:22that can be, there's many things that that can be,

151:24but a lot of it is like real value

151:27comes from doing things that are hard.

151:29And that doesn't mean you have to suffer, but.

151:33It's hard.

151:34I mean, you don't often hear that message.

151:36We talked about it last time a little bit,

151:38but it's one of my, not enough people talk about this.

151:43It's beautiful to hear a successful person.

151:47Well, and self doubt and imposter syndrome,

151:49these are all things that successful people

151:52suffer with as well,

151:53particularly when they put themselves

151:55in a point of being uncomfortable,

151:56which I like to do now and then

151:59just because it puts you in learning mode.

152:02Like if you wanna grow as a person,

152:04put yourself in a room with a bunch of people

152:07that know way more about whatever you're talking about

152:09than you do and ask dumb questions.

152:11And guess what?

152:13Smart people love to teach often,

152:15not always, but often.

152:16And if you listen, if you're prepared to listen,

152:18if you're prepared to grow,

152:19if you're prepared to make connections,

152:20you can do some really interesting things.

152:22And I think a lot of progress is made by people

152:25who kind of hop between domains now and then,

152:28because they bring a perspective into a field

§20Transcript · 2:32:32–2:40:39

152:32that nobody else has,

152:34if people have only been working in that field themselves.

152:38We mentioned that the universe is kind of like a compiler.

152:43The entirety of it, the whole evolution

152:44is kind of a kind of compilation.

152:46Maybe us human beings are kind of compilers.

152:51Let me ask the old sort of question

152:53that I didn't ask you last time,

152:54which is what's the meaning of it all?

152:57Is there a meaning?

152:58Like if you asked a compiler why,

153:01what would a compiler say?

153:03What's the meaning of life?

153:04What's the meaning of life?

153:06I'm prepared for it not to mean anything.

153:09Here we are, all biological things programmed to survive

153:14and propagate our DNA.

153:19And maybe the universe is just a computer

153:21and you just go until entropy takes over the universe

153:25and then you're done.

153:27I don't think that's a very productive way

153:29to live your life, if so.

153:33And so I prefer to bias towards the other way,

153:34which is saying the universe has a lot of value.

153:37And I take happiness out of other people.

153:41And a lot of times part of that's having kids,

153:43but also the relationships you build with other people.

153:46And so the way I try to live my life is like,

153:49what can I do that has value?

153:51How can I move the world forward?

153:52How can I take what I'm good at

153:54and bring it into the world?

153:57And I'm one of these people that likes to work really hard

154:00and be very focused on the things that I do.

154:03And so if I'm gonna do that,

154:05how can it be in a domain that actually will matter?

154:08Because a lot of things that we do,

154:10we find ourselves in the cycle of like,

154:11okay, I'm doing a thing.

154:12I'm very familiar with it.

154:13I've done it for a long time.

154:15I've never done anything else,

154:16but I'm not really learning, right?

154:19I'm not really, I'm keeping things going,

154:21but there's a younger generation

154:23that can do the same thing,

154:24maybe even better than me, right?

154:26Maybe if I actually step out of this

154:28and jump into something I'm less comfortable with,

154:31it's scary.

154:32But on the other hand,

154:33it gives somebody else a new opportunity.

154:34It also then puts you back in learning mode,

154:37and that can be really interesting.

154:38And one of the things I've learned is that

154:41when you go through that,

154:42that first you're deep into imposter syndrome,

154:45but when you start working your way out,

154:46you start to realize,

154:47hey, well, there's actually a method to this.

154:49And now I'm able to add new things

154:53because I bring different perspective.

154:54And this is one of the good things

154:57about bringing different kinds of people together.

154:59Diversity of thought is really important.

155:01And if you can pull together people

155:04that are coming at things from different directions,

155:06you often get innovation.

155:07And I love to see that, that aha moment

155:10where you're like, oh, we've really cracked this.

155:12This is something nobody's ever done before.

155:15And then if you can do it in the context

155:16where it adds value, other people can build on it,

155:18it helps move the world,

155:20then that's what really excites me.

155:22So that kind of description

155:24of the magic of the human experience,

155:26do you think we'll ever create that in an AGI system?

155:29Do you think we'll be able to create,

155:34give AI systems a sense of meaning

155:38where they operate in this kind of world

155:39exactly in the way you've described,

155:41which is they interact with each other,

155:43they interact with us humans.

155:44Sure, sure.

155:45Well, so, I mean, why are you being so a speciest, right?

155:50All right, so AGI versus Bionets,

155:54or something like that versus biology, right?

155:57You know, what are we but machines, right?

156:00We're just programmed to run our,

156:02we have our objective function

156:03that we were optimized for, right?

156:06And so we're doing our thing,

156:07we think we have purpose, but do we really, right?

156:10I'm not prepared to say that those newfangled AGI's

156:13have no soul just because we don't understand them, right?

156:16And I think that would be, when they exist,

156:20that would be very premature to look at a new thing

156:24through your own lens without fully understanding it.

156:28You might be just saying that

156:29because AI systems in the future

156:31will be listening to this and then.

156:33Oh yeah, exactly.

156:34You don't wanna say anything.

156:34Please be nice to me, you know,

156:36when Skynet kills everybody, please spare me.

156:39So wise look ahead thinking.

156:42Yeah, but I mean, I think that people will spend

156:44a lot of time worrying about this kind of stuff,

156:46and I think that what we should be worrying about

156:48is how do we make the world better?

156:49And the thing that I'm most scared about with AGI's

156:52is not that necessarily the Skynet

156:57will start shooting everybody with lasers

156:58and stuff like that to use us for our calories.

157:03The thing that I'm worried about is that

157:05humanity, I think, needs a challenge.

157:08And if we get into a mode of not having a personal challenge,

157:11not having a personal contribution,

157:13whether that be like, you know, your kids

157:15and seeing what they grow into and helping guide them,

157:18whether it be your community that you're engaged in,

157:21you're driving forward, whether it be your work

157:23and the things that you're doing

157:25and the people you're working with

157:25and the products you're building and the contribution there,

157:28if people don't have a objective,

157:31I'm afraid what that means.

157:33And I think that this would lead to a rise

157:37of the worst part of people, right?

157:39Instead of people striving together

157:42and trying to make the world better,

157:45it could degrade into a very unpleasant world.

157:49But I don't know.

157:51I mean, we hopefully have a long ways to go

157:53before we discover that.

157:54And fortunately, we have pretty on the ground problems

157:57with the pandemic right now,

157:58and so I think we should be focused on that as well.

158:01Yeah, ultimately, just as you said, you're optimistic.

158:04I think it helps for us to be optimistic.

158:07So that's fake it until you make it.

158:10Yeah, well, and why not?

158:11What's the other side, right?

158:12So, I mean, I'm not personally a very religious person,

158:17but I've heard people say like,

158:19oh yeah, of course I believe in God.

158:20Of course I go to church, because if God's real,

158:23you know, I wanna be on the right side of that.

158:25If it's not real, it doesn't matter.

158:27Yeah, it doesn't matter.

158:27And so, you know, that's a fair way to do it.

158:32Yeah, I mean, the same thing with nuclear deterrence,

158:35all, you know, global warming, all these things,

158:38all these threats, natural engineer pandemics,

158:41all these threats we face.

158:42I think it's paralyzing to be terrified

158:49of all the possible ways we could destroy ourselves.

158:52I think it's much better or at least productive

158:56to be hopeful and to engineer defenses

158:59against these things, to engineer a future

159:03where like, you know, see like a positive future

159:06and engineer that future.

159:07Yeah, well, and I think that's another thing

159:10to think about as, you know, a human,

159:12particularly if you're young and trying to figure out

159:14what it is that you wanna be when you grow up, like I am.

159:18I'm always looking for that.

159:19The question then is, how do you wanna spend your time?

159:24And right now there seems to be a norm

159:26of being a consumption culture.

159:28Like I'm gonna watch the news and revel

159:31in how horrible everything is right now.

159:33I'm going to go find out about the latest atrocity

159:36and find out all the details of like the terrible thing

159:38that happened and be outraged by it.

159:41You can spend a lot of time watching TV

159:44and watching the news at home or whatever

159:46people watch these days, I don't know.

159:49But that's a lot of hours, right?

159:51And those are hours that if you're turned

159:53to being productive, learning, growing,

159:56experiencing, you know, when the pandemic's over,

159:59going exploring, right, it leads to more growth.

160:03And I think it leads to more optimism and happiness

160:06because you're building, right?

160:08You're building yourself, you're building your capabilities,

160:10you're building your viewpoints,

160:12you're building your perspective.

160:13And I think that a lot of the consuming

160:18of other people's messages leads

160:19to kind of a negative viewpoint,

160:21which you need to be aware of what's happening

160:24because that's also important,

160:25but there's a balance that I think focusing

160:28on creation is a very valuable thing to do.

160:32Yeah, so what you're saying is people should focus

160:33on working on the sexiest field of them all,

160:37which is compiler design.

160:38Exactly.

§21Transcript · 2:40:39–2:42:47

160:39Hey, you could go work on machine learning

160:41and be crowded out by the thousands of graduates

160:43popping out of school that all want to do the same thing,

160:45or you could work in the place that people overpay you

160:48because there's not enough smart people working in it.

160:51And here at the end of Moore's Law,

160:53according to some people,

160:55actually the software is the hard part too.

160:58I mean, optimization is truly, truly beautiful.

161:02And also on the YouTube side or education side,

161:07it'd be nice to have some material

161:09that shows the beauty of compilers.

161:12Yeah, yeah.

161:13That's something.

161:14So that's a call for people to create

161:17that kind of content as well.

161:18Chris, you're one of my favorite people to talk to.

161:22It's such a huge honor that you would waste your time

161:25talking to me.

161:26I've always appreciated it.

161:27Thank you so much for talking to me.

161:29The truth of it is you spent a lot of time talking to me

161:32just on walks and other things like that,

161:34so it's great to catch up with.

161:35Thanks, man.

161:37Thanks for listening to this conversation

161:39with Chris Latner, and thank you to our sponsors.

161:42Blinkist, an app that summarizes key ideas

161:45from thousands of books.

161:46Neuro, which is a maker of functional gum and mints

161:49that supercharge my mind.

161:51Masterclass, which are online courses from world experts.

161:55And finally, Cash App, which is an app

161:57for sending money to friends.

162:00Please check out these sponsors in the description

162:02to get a discount and to support this podcast.

162:06If you enjoy this thing, subscribe on YouTube,

162:08review it with five stars on Apple Podcast,

162:10follow on Spotify, support it on Patreon,

162:13connect with me on Twitter at Lex Friedman.

162:16And now, let me leave you with some words from Chris Latner.

162:19So much of language design is about tradeoffs,

162:21and you can't see those tradeoffs

162:23unless you have a community of people

162:25that really represent those different points.

162:28Thank you for listening, and hope to see you next time.

— A LITTLE MORE TO THINK ABOUT. —