![Page 2: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/2.jpg)
Ex-Hacker Tells All!• One-time scalac hacker
• Now full-time malcontent
• Voted Mr. Congeniality by scala community
• Zero years in a row (and counting)
![Page 3: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/3.jpg)
Jon Pretty admits it took him 10 years to amass 10 years scala experience.
The picture suggests he was enjoying the forty weeks vacation standard in Western Europe.
I dub thee Jon Pretty Slow.
![Page 4: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/4.jpg)
< 10 years
![Page 5: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/5.jpg)
Scientifically Determined Factsabout me, in the domain of interpersonal orientation
![Page 6: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/6.jpg)
How Software Is Made
![Page 7: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/7.jpg)
![Page 8: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/8.jpg)
Initiate build
sequence!
![Page 9: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/9.jpg)
TIME PASSES
You're older than you've ever been and now you're even older and now you're even older and now you're even older
!You're older than you've ever been
and now you're even older and now you're older still
!-- They Might Be Giants
![Page 10: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/10.jpg)
![Page 11: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/11.jpg)
Hmm, let's try it with that one brick three
millimeters to the left.
![Page 12: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/12.jpg)
![Page 13: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/13.jpg)
Wait a Minute• The titular "silent killer" is not the
time spent waiting
• It is the inhibition of flow state
• Outside of flow, you are but a shadow of your best self
![Page 14: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/14.jpg)
Mihaly Csikszentmihalyi (mee-hy cheek-sent-mə-hy-ee) identifies these preconditions for flow: !1) Goals are clear 2) Feedback is immediate 3) A balance between opportunity and capacity
![Page 15: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/15.jpg)
The Lag Analogy• Imagine editing system files on a faraway server
under a 6 second echo lag. No mistakes!
• Is the time to completion only 6 seconds greater?
• Is your error rate only "6 seconds" higher?
• Is the task only "6 seconds" less enjoyable?
![Page 16: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/16.jpg)
• How often do we tolerate a "6 second lag" when writing code?
• To a first approximation: always
• Optimistically: way too often
The Lag Analogy
![Page 17: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/17.jpg)
The Lag Analogy• "You should have been using screen/tmux!"
• Right: why tolerate such uncivilized conditions?
• A highly responsive layer coalesces inputs and batches them to the high-latency system
• It's madness to have to traverse every requirement to connect cause to effect
![Page 18: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/18.jpg)
What IS a compiler?• Responsiveness is a (or THE) key to a UX
• It is mandatory to achieve flow state
• We are unwise to turn this critical task over to a general purpose compiler
• More responsive does not mean faster: usually it means slower! (i.e. less throughput)
![Page 19: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/19.jpg)
repl startup• Initialize the compiler in a separate thread
• Print the prompt immediately
• Result: startup feels impossibly faster!
• Yet "minimum time to first result" is unchanged
• Responsiveness, where perception IS reality
![Page 20: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/20.jpg)
multitasking• scalac is so slow to build, I always had two work
trees going simultaneously
• Context switching in that codebase is not cheap for the wetware
• Incremental compilation is useless in scalac
![Page 21: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/21.jpg)
Interrupting Myself• Everyone seems to agree interruptions are costly
• I experience no interruptions - from humans
• Flow state is no less elusive for that
• "Flow interruptions" are everywhere
![Page 22: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/22.jpg)
"incremental comp..."• Incremental compilation recompiles less (at best)
• I say: recompile never! Recompiling is rebooting
• First requirement is a functional compiler
• And we derive the output from the delta
![Page 23: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/23.jpg)
A change to a base trait may incur the
recompilation of over one thousand files.
!The regeneration of 100
MB of class files. !
While the ΔOutput requires writing 4 bytes to
a single classfile.
![Page 24: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/24.jpg)
![Page 25: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/25.jpg)
Skeptical Hippo
![Page 26: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/26.jpg)
"that's impossib..."• Yes, very likely it's impossible for scala, and most
existing languages
• But a language can be engineered around it
• And a language SHOULD be engineered around it
![Page 27: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/27.jpg)
"who needs a comp..."• Bad news: most software cannot be reasoned about
• Try some pure reasoning against a few scalac bugs
• We can design better software, but that won't unwrite the rest of it
• And regardless, frobbing knobs and seeing what happens is how most of the humans learn
![Page 28: Keynote, LambdaConf 2014 - The Silent Productivity Killer](https://reader033.vdocuments.us/reader033/viewer/2022052821/5549c2a9b4c90564768b5600/html5/thumbnails/28.jpg)
"The next step is to transfer some psychic energy each day from tasks that we don’t like doing, or from passive leisure, into something we never did before, or something we enjoy doing but don’t do often enough because it seems too much trouble. !There are literally millions of potentially interesting things in the world to see, to do, to learn about. But they don’t become actually interesting until we devote attention to them."
Mihaly Csikszentmihalyi