Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Golang Concurrency
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Alex Wheeler
November 16, 2017
0
90
Golang Concurrency
Alex Wheeler
November 16, 2017
Tweet
Share
More Decks by Alex Wheeler
See All by Alex Wheeler
Running Rings Around Rack
alexwheeler
0
86
Rewriting Rack: A Functional Approach
alexwheeler
2
160
Man Computer Symbiosis
alexwheeler
0
130
Flipper
alexwheeler
0
140
Transducers
alexwheeler
0
70
Character Encodings
alexwheeler
0
120
Featured
See All Featured
How to Build an AI Search Optimization Roadmap - Criteria and Steps to Take #SEOIRL
aleyda
1
2k
Navigating the moral maze — ethical principles for Al-driven product design
skipperchong
2
280
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
162
16k
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
340
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
47
8k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
12
1.5k
How to make the Groovebox
asonas
2
2k
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
170
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
49
9.9k
Stop Working from a Prison Cell
hatefulcrawdad
274
21k
The SEO identity crisis: Don't let AI make you average
varn
0
410
KATA
mclloyd
PRO
35
15k
Transcript
Golang The Future of VTS
• Yes, there will be Vim.
Background • Developed at Google • Born out of frustration
• 1. efficient compilation • 2. efficient execution • 3. ease of programming
Background • make programming fun again • feel of dynamic
language with type safety • run-time that supports GC, concurrency • lightweight flexible type system
Hello, World
Syntax
implicit typing
Concurrency
BUT FIRST… • Concurrency != Parallelism • Concurrency is about
dealing with lots of things at once. • Parallelism is about doing lots of things at once
goroutine • lightweight thread managed by the go runtime •
little memory (~2kb stack space), can spawn millions if you want • go f() starts function f in a new groutine
None
• “Don't communicate by sharing memory; share memory by communicating.”
- Golang • Communicating Sequential Processes - Tony Hoare
<- channels <- • typed structure through which you can
send/receive values using the channel operator • first class values • block by default
sending to channel
receiving from channel
Time for some code
None
None
Vim Support • https://github.com/fatih/vim-go
Further Learning • https://tour.golang.org • brew install go -- cross-compile-common
• #go-nuts on freenode • @askwheeler