LAURENCE MORONEY: Welcome to the Googleplex.
This is an incredible place with lots of great stuff being
worked on every single day.
Before I worked here, I always wondered
what it be like to come to the Googleplex,
meet up with a Googler, and have coffee with them,
and just chat about what they do, how they do it,
and why they do it.
And today we're going to do exactly that.
So welcome to this episode of "Coffee with a Googler."
And one of the things that we've been doing since we started
the show is we've been asking about which
Googlers you'd like to speak with,
which Googlers you'd like me to have a conversation with,
and what kind of topics we could talk about.
And the first name that came up was Colt McAnlis.
He's also the name that came up the most often.
So Colt, you're finally with us.
Thank you.
Congratulations.
COLT MCANLIS: Thank you.
So I just want to make sure that this is clear.
I want to make sure I understand this.
I outranked Larry Page to be here.
LAURENCE MORONEY: Your page rank is
higher than Larry Page's rank.
COLT MCANLIS: Thank you, community, for voting me here.
I mean, what does Larry have to talk about?
LAURENCE MORONEY: I don't know.
I will talk about it with him someday,
and we'll see what he has to say.
And I'd love to hear what he has to say about you.
COLT MCANLIS: You shouldn't probably ask him about me.
LAURENCE MORONEY: I'll give it a try and we'll see.
COLT MCANLIS: OK.
LAURENCE MORONEY: So Colt, you're
a developer advocate here at Google.
And tell us, what is a developer advocate and what do they do?
COLT MCANLIS: Well, it's this really weird hybrid role,
right?
I mean, we're all very technically inclined people
who know very technical stuff.
But in reality, we've got to spit out content.
We're kind of like talking sock puppets.
LAURENCE MORONEY: Indeed.
COLT MCANLIS: Yes.
LAURENCE MORONEY: To be sure, to be sure.
COLT MCANLIS: I feel for Kermit the Frog.
LAURENCE MORONEY: Yes, me too.
I think he's angry because he's got your hand up his butt.
COLT MCANLIS: Well, tell me, Laurence.
What do you think about the developer advocacy role
and how you approach it's craft?
LAURENCE MORONEY: You know, one of the ways
that I like to approach it is really enriching people
through video.
I have this show where I'm a host,
and I call it "Coffee with a Googler."
Wait, what?
So Colt is a developer advocate here at Google.
And there's lots of ways that one can
be an advocate for developers.
And Colt, you've got some pretty unique stuff
that you've been working on.
Can you tell us about it?
COLT MCANLIS: You know, I really try
to find the stuff that helps developers that's
not part of our normal rigor.
So we talk about APIs a lot.
We talk about the platform a lot.
We talk about how the new stuff is coming out.
But there's a lot of things that are just
core and fundamental to making and building great applications
that kind of fall through the cracks, that no one else
is really covering.
And to be honest, I really like to focus a lot of my advocacy
in those rare areas.
LAURENCE MORONEY: Like I know some examples.
You've been working on the "Compressor Head" and "Android
Performance Patterns."
Tell us about "Compressor Head."
I mean, I keep hearing there's this TV show out there.
And did you get the idea from them,
or did they get the idea from you,
those folks in Silicon Valley?
COLT MCANLIS: Yeah, so "Compressor Head," for those
who may not have seen it, is a show about compression
that we do on the Google Developers channel.
And effectively, it's me trying to distill these really crazy
complex algorithms that drive everything we
do in computers now-- like every bit you see on a mobile device
has been compressed at this point--
and distill the algorithms down.
Because for some reason, the art and science of compression
really has fallen away from the education that we've done.
LAURENCE MORONEY: Now, some people might say that
with bandwidth getting increasingly cheaper
and storage getting increasingly cheaper, compression
isn't really that important.
What would you think about that?
COLT MCANLIS: I wholeheartedly challenge that.
You have to remember that software and data is a gas,
right?
It will grow to fill whatever container we put it in.
And we're going through this great industrial boom
right now where hardware costs are coming down.
But that is not something that's going to continue indefinitely.
If you watch the way that computing
has worked over the past 50 years,
you end up with these booms and busts.
You get a huge jump in processing power.
And then that will level off for a while
until a new technology comes around
and you get a huge one again.
And we're seeing that with data right now.
And you also have to remember that while our data centers are
getting larger and where we host our content gets larger,
the medium between the cell tower and your phone
is not growing at that same rate.
I mean, you have to remember that almost half of America
is still on a 2G network.
Worldwide, 2G is like the king's knees.
That's the best they can get, especially
for the next 5 billion humans that are coming online.
They're not going to be on 4G LTE networks.
LAURENCE MORONEY: Absolutely.
COLT MCANLIS: If you're someone that's
trying to create a strategy around getting the most
users to your content, trying to build an ecosystem that's
data driven in their social networks
for these next 5 billion users, you
can't rely on data centers and all these other hardware.
You have to compress your data.
We talk a little bit about this in the show.
There's a couple different spots where
we talk about these things.
In fact, I think we have the clip of it.
LAURENCE MORONEY: We have a clip, yeah.
Jimmy, can you run the clip?
COLT MCANLIS: The move-to-front algorithm is pretty simple.
For each symbol we read, we write its output buffer
position, and then move it to the front of our buffer.
Now, for example, if we input the letter N,
that sits at position 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12,
13, 14.
So we write that to our output stream.
LAURENCE MORONEY: So it's a pretty complex subject,
and you're teaching it quite simply.
Is that the theme of the show?
Is that how you do it?
COLT MCANLIS: That's exactly what it was.
I mean, we're using Lego blocks in there.
The whole concept came from, how do we
take this really complex idea and break it down
to be able to teach it with sticky notes and Play-Doh
and Lego blocks?
Because we've got kids, and we're constantly
teaching things to kids.
And so I figured if this method works on three-year-olds,
obviously it'll work on programmers-- no offense.
So yeah, that's the whole gimmick.
That's the whole point of the show.
How complex can we get from an algorithm
and how can we teach it with Play-Doh and sticky notes?
LAURENCE MORONEY: So now as well as "Compressor Head,"
you talk a lot about performance.
And you have your perfmatters hashtag
and your "Android Performance Patterns" show.
And I think you've just finished up another season of that.
Tell us about it.
COLT MCANLIS: So "Android Performance Patterns"
is, again, one of those gap filling initiatives.
Everyone has to care about performance.
If you're shipping an application,
users leave feedback about bad performing applications
in a negative manner three times more than anything else
in your app, more than if they don't like your social media
is laid out, or they don't like how long it
takes to download something, or just your UI is bad.
That's like crickets.
However, if you're slow, or if it feels laggy,
man, people just hate it.
It's just the truth of the industry.
LAURENCE MORONEY: And negative reviews, I mean,
everybody wants to avoid that.
COLT MCANLIS: Exactly.
And you can't fix that with chiming back with people.
You just have to fundamentally fix that at your level.
And "Android Performance Patterns"
is built around that gap.
Because you've got the documentation,
which tells you how to use the API and what it does.
But then you really don't have anything past
that to tell you the right way to use it for your performance
cases across all the devices in our ecosystem.
LAURENCE MORONEY: Cool.
COLT MCANLIS: Because what works on a high end
Android device may not work on a low end one
or on a different device type or form factor or something.
LAURENCE MORONEY: So what are the typical performance gotchas
that people have that you might help them avoid with the show?
COLT MCANLIS: So there's three big pillars of performance
that we like to talk about.
So you can either have rendering problems-- so for example,
overdrawing too many pixels on the screen at one time.
So this means you're going to be wasting GPU and CPU cycle time.
We've also got memory problems.
So this is the quintessential programmer issue--
using too many memories, kicking off garbage collection events.
In fact, I think we actually have a clip of that.
We have a clip of that.
LAURENCE MORONEY: OK, can we run the clip please, Jimmy?
COLT MCANLIS: Even though you're in a managed memory
environment, improperly using memory
can still kick off a load of performance problems.
And allocating too many objects in a short time frame
is a clear problem that you should be aware of.
You have to remember that the memory heap in Android
is segmented up into separate spaces
based upon what type of allocation is occurring.
LAURENCE MORONEY: OK, so in that scene, we saw memory.
And earlier, we were talking about graphics.
And the third one-- is it battery?
COLT MCANLIS: Battery, that's right.
I gotta tell you, one of the things
that we all hate with our mobile devices right now is
you can't get through a day without needing to recharge.
I mean, you're doing cool stuff, and you need to get it done.
But the fact is that most developers
aren't thinking enough about how to optimize their battery
performance.
And we talk a great deal about the things
that developers need to do to keep users'
batteries lasting longer.
And I think we all benefit from that.
LAURENCE MORONEY: Absolutely.
That's more than just negative reviews and avoiding them.
That's actually making someone's life a little better.
COLT MCANLIS: It's a little karma, really.
I mean, as a developer, you want to get that good karma.
It's doing the right thing.
LAURENCE MORONEY: Speaking of karma,
I keep hearing about this Perf Like a Pirate.
I mean, there's good pirates, and there's bad pirates.
And this seems to be one of the good pirates.
COLT MCANLIS: Yeah.
LAURENCE MORONEY: So what's this whole Perf Like a Pirate thing?
I've always wanted to go, arr.
So now I get to.
COLT MCANLIS: (PIRATE VOICE) Yar, matey.
You've got to do it in the right voice.
It's a little between Irish leprechaun and British weirdo.
I don't know.
LAURENCE MORONEY: That sounds a lot like me.
COLT MCANLIS: Comment in the section.
So Perf Like a Pirate was an event
that we started a year before last.
We ended up wanting to do this event on performance
for HTML5 Users Group in San Francisco, SFHTML5.
And just weird dice roll that the event actually happened
on Talk Like a Pirate Day.
LAURENCE MORONEY: Yar, I see.
COLT MCANLIS: And no one really thought about it.
It was kind of in the back of everyone's mind.
And I was like, you know what?
We've got to do something with this.
And so I gave my entire talk in pirate.
LAURENCE MORONEY: Cool.
COLT MCANLIS: And so for like the next six to eight months,
every time I would go to a conference or something,
someone would walk by me and be like, yar matey, do we
be talking about performance, which was fantastic,
because I'm like, we've got to do this again.
So we did it again last year.
I got a huge turnout, another great set of people.
And so it's just kind of really cool
to take this really mundane topic like performance
that makes everyone's eyes roll back in their head
and have fun with it.
And really more, it's like to me,
that's the essence of what we do as developer advocates is
take these really crazy, insane things and make them
fun to learn about and fun to bring together and change
the way we do our development.
LAURENCE MORONEY: Well, it certainly
has been fun having you here today, Colt.
Thank you so much for coming.
And thanks everybody for watching this far.
As always, we're on the Google Developers channel.
I'm Laurence Moroney.
You can see my link underneath.
And Colt McAnlis, you can see his link there too.
So please subscribe to the Google Developers
channel for more shows, including "Compressor Head"
and including Perf Like a Pirate-- well,
not Perf Like a Pirate, Perfmatters,
and "Android Performance Patterns."
And if you've any other questions for Colt or for me
or any other Googlers that you'd like to chat with, maybe even
Larry Page himself, please put it in the comments below.
Thanks, everybody.
[MUSIC PLAYING]