Google’s master plan: NaCl

featured

Judging by the title you may be wondering if Google’s big idea is to enter the pharmaceutical market or some other activity heavy on chemistry.  Sadly, as attractive as the idea of buying my amoxicillin  straight from Google is, NaCl actually stands for Native Client: Google’s effort to finally bring native-like performance to the web. Unlike Netrunner, or any other Linux distribution or relevant operating system, Chrome doesn’t support running native apps (Chrome itself aside), this severely limits how much can be done in the platform, developers could potentially be trapped between Javascript and Flash as their only choices to develop.

A bit of background

While is true that web technologies have come a long way and that more and more people are using web solutions to get their work done, the undeniable fact is that if your workflow includes any sort of power intensive activity the web isn’t gonna cut it. Some may be thinking these tasks are not common, after all I’ve argued in the past that Linux failure to achieve a higher market share is not technological but that it rather lacks a go-to-market strategy (i.e. lack of Photoshop is not the issue),  so regular users could be more than served.

The problem with this line of thinking is that it severely underestimates how much of what people do is processor intensive. If the statistics that come out from the mobile space are worth something then the most common kind of third party application are games and games require power. True: for a brief time in history flash games were enough, but now people is used to play games with complex geometries and physics in their pockets for something between free and 10 dollars.

Google needs a way to give its Chrome OS the ability to compete with Microsoft Windows and Mac OS X in functionality, including games and applications like Photoshop, Excel and Final Cut Pro.

Meet Google’s solution

A reasonable person may conclude the solution is trivial: Just allow native application to run in your platform, use something great like Qt and called it a day (note: this doesn’t mean you can’t use Qt with NaCl). But no, not Google. Instead they built an open source solution to run native code (x86 or ARM) inside the browser with many security measures, most notably, all applications are sandboxed.

Moreover, NaCl is portable and part of Google Chrome, and it works on all important platforms: Linux, Windows and Mac OS X. NaCl has not been out there much, and it has been mostly used to port games to Chrome.

Games like Bastion are clearly superior to your usual browser games: Graphics and audio are much better than your typical browser game:

Not to mention games support fullscreen and capturing the mouse:

But while games are indeed important, I suspect they’re not as important on the desktop as they’re on mobile platforms, while the ability to do basic tasks such as editing word documents is necessary. Until not long ago games were the only examples of NaCl apps but Google bought QuickOffice a few months ago and announced during the Chromebook Pixel launch its plans to port it to NaCl. This is big news for the platform because currently editing support is limited to Drive files, and support to convert Office files into Drive files and back is rather limited.

Yesterday Google released Chrome Office Viewer an NaCl application that does exactly what the name suggests, while editing is not yet supported the sole addition of being able to view Office files offline is important to Chrome OS, it’s has been confirmed that it contains pieces of QuickOffice.

Just like it happens with Google Drive the output is still not nearly as good as I would like it to be. If you’re using a full Linux distribution this new application is only useful as far as it means not having to open LibreOffice when you want a fast preview of a file you’ve just downloaded, if the document is a bit complex you may want to click that save icon and open it using LibreOffice. But the future is brighter than it seems: Eventually QuickOffice will be fully ported to NaCl bringing Office editing capabilities to Chrome OS.

What does it mean to us?

Remember: At the end of the day Chrome OS is just basically Linux + Chrome. Meaning any step forward in the Chrome OS ecosystem also helps us. It’s true that any new application developed on NaCl also works on Windows and Mac OS X, however if Google manages to make people switch from their regular desktop apps to NaCl apps a big barrier would be lifted: The problem users face when they need to relearn how to do things after switching operating systems.

Netrunner, for example, already includes a few web apps out of the box: A couple of games, the suite of Google Apps, Dropbox and Runners-ID. We could benefit greatly from web applications with higher performance. There’s two minor caveats though.

First caveat: Attracting developers

While I’m sure Google can by itself bring office support to LibreOffice-like levels with QuickOffice, the issue of whether this will be enough to attract developers remains an open question. Ecosystems attract and solidify your user base, and at the same time it attracts developers, it’s the opposite experience of a vicious circle. Sadly, attracting developers remains a complicated issue: without a user base is hard to bring them on board, and without them on board is hard to attract users, i.e. is a vicious circle. Google needs developers to create apps that can extend the feature set of their platform, it can’t do it all by itself.

Second caveat: Open Source Politics

Google Chrome is the most popular browser in the world and is based on the open source project Chromium (which obviously supports NaCl) which uses Blink as its engine (which itself is based on Webkit), which is also open source. Firefox is Chrome’s most important competitor is also open source (Internet Explorer doesn’t compete with these two, it’s only a matter if the user is versed enough to switch…).

As I mentioned at the very beginning NaCl is also open source and it could be implemented on others browser (for instance, given the fact that future versions of Opera will be based on Chromium, it is safe to assume Opera will support NaCl), however Mozilla has decided not to. The reason stated? They want to use HTML5 and Javascript exclusively as they believe they can match Google’s NaCl performance, I don’t want to bash Mozilla too much, but that’s plainly delusional or a straight up lie. Technical reasons regarding instruction sets are also baseless (as both  LLVM and PNaCl exist).

Mozilla’s stubbornness to adopt NaCl also hurts the future of the web, their decision basically helps the status quo by promoting the perpetual advantage of native applications over web applications.

Why is Mozilla doing this? I don’t want to sound like a conspiracy theorist, but there may be a slight conflict of interests between Mozilla’s own Brendan Eich and the right choice for the web. Let just say Mozilla’s Chief Technology Officer is the creator of Javascript and leave it there.

Another rather striking thing is that despite Chromium’s overwhelming popularity and open source nature it is not the usual default browser on Linux distributions. Firefox has improved in the last few releases, but a few months ago there was no doubt that Chrome was superior, the gap has shrunk, but I would still argue that Chrome is a better browser than Firefox. But besides each browser’s merits Chrome offers functionality Firefox can’t: Offline access to Google Drive, Offline Editing, Offline Calendar, Offline GMail, among many others, also worth mentioning is that while Firefox offers a sync feature it is not as good as Chrome’s nor is tight to an account and service people actually use.

Can Google push NaCl?

I like to think it can. After all, Chrome is the most popular browser in the planet. If Google manages to do it many of the advantages Microsoft built with years of anti-competitive practices hard work will vanish. I also suspect will be hearing news regarding Android and NaCl soon, maybe not in the next I/O but soon. Open Source technologies, including Linux, have taken over a lot of what people do over the last few years, but walled gardens such as Apple’s ecosystem threaten the future of freedom to develop whatever you want: not only in the sense that is a threat to open source software, is a threat to the freedom of being able to develop and distribute any application, closed or open, without a big corporation giving you a green light. NaCl could makes those fears vanish and ensure an open environment for developers.

Mathematics and Philosophy student at the National Autonomous University of Mexico. Website

  • Andrew Clunn

    I support Mozilla in this. There’s one point you’re missing, cross platform development. I don’t mean in terms of OSes, I mean in terms of architecture. As machines get more powerful, getting rid of abstraction layers to do things in a down and dirty processor specific manner is the wrong direction.

  • Whiley W. Riwte

    All Commercial Operating Systems are failing because they are bloated. I do not want more bloat and more portable code, I want speed, performance, increased effeciency of resource use and User Interface. I don’t want my computer to a search engine for stuff that I already know where it is on my computer. Give me a break!