<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Andreas Gal</title>
	<atom:link href="http://andreasgal.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://andreasgal.com</link>
	<description>Engineering the Open Web Platform.</description>
	<lastBuildDate>Tue, 22 Jan 2013 23:46:31 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='andreasgal.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Andreas Gal</title>
		<link>http://andreasgal.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://andreasgal.com/osd.xml" title="Andreas Gal" />
	<atom:link rel='hub' href='http://andreasgal.com/?pushpress=hub'/>
		<item>
		<title>Open Engineering</title>
		<link>http://andreasgal.com/2013/01/22/open-engineering/</link>
		<comments>http://andreasgal.com/2013/01/22/open-engineering/#comments</comments>
		<pubDate>Tue, 22 Jan 2013 23:46:28 +0000</pubDate>
		<dc:creator>Andreas</dc:creator>
				<category><![CDATA[Mozilla]]></category>

		<guid isPermaLink="false">http://andreasgal.com/?p=274</guid>
		<description><![CDATA[Mozilla builds software very differently than any other company, because, well, we are not a company. Mozilla is an open-source project backed by a not-for-profit foundation for the public benefit. For us open-source doesn&#8217;t just mean the source is out &#8230; <a href="http://andreasgal.com/2013/01/22/open-engineering/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=274&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>Mozilla builds software very differently than any other company, because, well, we are not a company. Mozilla is an open-source project backed by a not-for-profit foundation for the public benefit. For us open-source doesn&#8217;t just mean the source is out there. We actually care about <strong>Open Engineering</strong>.</p>
<h2>Open from the start</h2>
<p>The Boot 2 Gecko project, which is today known as Firefox OS, started on July 25, 2011 with an email to Mozilla&#8217;s dev-platform mailing list by Chris Jones, Brendan Eich, Mike Shaver and myself. In that email we expressed our opinion that as an open-source Mozilla community we should build a web-based smartphone. As a rallying cry and gathering point, we created an empty github repository and Chris and I started filing the first <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=715782">bugzilla bugs</a> for Firefox OS, and started <a href="https://github.com/andreasgal/B2G">hacking</a> on the first lines of code for Firefox OS.</p>
<p>Firefox OS was completely open from day 1, including the design process as well as the implementation. As we are building Firefox OS today, you can follow along live <em>and jump in and help</em>. You can see the same source live as our device and carrier partners. You don&#8217;t have to work for Mozilla (many Firefox OS contributors do not) and you don&#8217;t have to ask for permission to help. Just join our IRC channels and mailing lists, and get involved in the design or the code.</p>
<h2>Community</h2>
<p>Mozilla&#8217;s large and diverse base of contributors always included organizations and not just individual contributors. With Firefox OS, the direct engagement of large organizations in the design and implementation of our products has increased tremendously. Qualcomm, Telefonica, Deutsche Telekom, and many others have large product and engineering teams committed to the project, building Firefox OS alongside with us. They are able to do so because of the openness of our processes, and they are motivated to do so, because Firefox OS is the only truly open smartphone platform where everyone who is willing to help can have an equal stake in. Mozilla doesn&#8217;t own Firefox OS. We merely care for it.</p>
<p>Last week we wrapped up a major Firefox OS engineering milestone. Leading up to that milestone, Deutsche Telekom Innovation Labs hosted a work week for the project. More than 140 engineers from Mozilla and our key partners attended. We use these work weeks to get engineers into one room who are usually distributed all over the world. Mozilla has offices on every continent, and so do most of our partners.</p>
<p>Below you can see a picture of the team. In the background is our milestone dashboard, showing the total number of bugs remaining, as well as the number of bugs between the frontend team (Gaia, 26) and platform team (Gecko, 50). The frontend and platform teams raced each other for the whole week. On Friday the Gecko team was almost able to catch up, with only 8 bugs remaining by the time the Gaia team hit 0 bugs. Those 8 remaining bugs landed over the weekend after the work week in Berlin.</p>
<p><a href="http://andreasgal.files.wordpress.com/2013/01/8369589247_d18da48aa1_b.jpg"><img class="alignnone size-full wp-image-275" alt="8369589247_d18da48aa1_b" src="http://andreasgal.files.wordpress.com/2013/01/8369589247_d18da48aa1_b.jpg?w=640&#038;h=430" width="640" height="430" /></a></p>
<br />Filed under: <a href='http://andreasgal.com/category/mozilla/'>Mozilla</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/andreasgal.wordpress.com/274/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/andreasgal.wordpress.com/274/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/andreasgal.wordpress.com/274/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/andreasgal.wordpress.com/274/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/andreasgal.wordpress.com/274/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/andreasgal.wordpress.com/274/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/andreasgal.wordpress.com/274/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/andreasgal.wordpress.com/274/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/andreasgal.wordpress.com/274/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/andreasgal.wordpress.com/274/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/andreasgal.wordpress.com/274/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/andreasgal.wordpress.com/274/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/andreasgal.wordpress.com/274/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/andreasgal.wordpress.com/274/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=274&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://andreasgal.com/2013/01/22/open-engineering/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/dc614466f1a6d8f9c0e7a868bda77196?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96" medium="image">
			<media:title type="html">andreasgal</media:title>
		</media:content>

		<media:content url="http://andreasgal.files.wordpress.com/2013/01/8369589247_d18da48aa1_b.jpg" medium="image">
			<media:title type="html">8369589247_d18da48aa1_b</media:title>
		</media:content>
	</item>
		<item>
		<title>Why the Web is going to win Mobile</title>
		<link>http://andreasgal.com/2013/01/08/why-the-web-is-going-to-win-mobile/</link>
		<comments>http://andreasgal.com/2013/01/08/why-the-web-is-going-to-win-mobile/#comments</comments>
		<pubDate>Wed, 09 Jan 2013 01:09:04 +0000</pubDate>
		<dc:creator>Andreas</dc:creator>
				<category><![CDATA[Mozilla]]></category>

		<guid isPermaLink="false">http://andreasgal.com/?p=246</guid>
		<description><![CDATA[On July 25, 2011 Chris Jones and I, with help from Mike Shaver and Brendan Eich, for the first time publicly talked about our vision to build a smartphone based on the Web. The announcement didn&#8217;t come out of nowhere, &#8230; <a href="http://andreasgal.com/2013/01/08/why-the-web-is-going-to-win-mobile/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=246&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p><a href="http://andreasgal.com/2013/01/08/why-the-web-is-going-to-win-mobile/firefox-phone/" rel="attachment wp-att-253"><img class=" wp-image-253 alignright" alt="firefox-phone" src="http://andreasgal.files.wordpress.com/2012/12/firefox-phone.png?w=300&#038;h=243" width="300" height="243" /></a>On July 25, 2011 Chris Jones and I, with help from Mike Shaver and Brendan Eich, for the first time <a href="https://groups.google.com/forum/?fromgroups#!topic/mozilla.dev.platform/dmip1GpD5II">publicly talked</a> about our vision to build a smartphone based on the Web. The announcement didn&#8217;t come out of nowhere, and didn&#8217;t happen in isolation. Chris and I had been working together for Mozilla for a few years, but we didn&#8217;t get to spend a lot of time talking to each other since Chris doesn&#8217;t work in the same office. On a trip to Asia as part of the Firefox 4 launch campaign, we finally had the opportunity to catch up and we ended up talking a lot about what later became the guiding question and principle for Mozilla&#8217;s research group:</p>
<p><em>What can the Web <strong>NOT</strong> do? And if so, <strong>WHY NOT?</strong> </em></p>
<p>We identified a couple of use cases where the Web is intentionally not used today. We are both platform engineers at heart. We wrestle with bits and bytes and CPU and GPU cycles for a living and we understand the Web platform and the implementation thereof (in Mozilla&#8217;s case: Gecko) pretty well. For the life of us, we couldn&#8217;t figure out why in a few key areas the Web hasn&#8217;t progressed as much as elsewhere. Two particular areas we homed in on were plugins and mobile.</p>
<p><strong>Plugins</strong></p>
<p>If you ever had to work on a rendering engine, you probably hate plugins just as much as we do. Plugins are like a thorn in the Web&#8217;s side. They are difficult to render efficiently, binary compatibility requirements make the browser-side support code super ugly and hard to maintain, plugins leak memory, plugins can cause all sorts of security issues, and they generally hold back the development of the Web&#8217;s native capabilities. A good example of this is Flash: because the Web relied for over a decade on Flash to play back video, the VIDEO element didn&#8217;t really take off until pretty recently and some essential capabilities such as adaptive streaming are still missing from the Web stack. Chris and I both worked on the plugin support code in the Firefox, and we agreed that for the better of the Web, we really would like to <strong>DELETE</strong> that code. There is a large number of plugins out there, but realistically, only a handful matter, including Flash, Acrobat Reader (PDF), and maybe Silverlight (we included Silverlight back then, but by now Microsoft has totally given up on it, so I guess we can as well drop Silverlight from the list). We wondered why Flash and Acrobat Reader are implemented as native code plugins, instead of building the same functionality with HTML5/CSS and JavaScript, and since we didn&#8217;t have an answer for that question, we decided we should just build it and see what happens. We started with PDF first, because it seemed like less code to write until we can see whether performance and quality are comparable. A year later, Firefox is about to <a href="http://blog.mozilla.org/futurereleases/category/firefox-beta/">ship</a> with the JavaScript-based PDF reader we started, so I think it&#8217;s safe to say that we found the answer to the question: the Web is ready to render PDF. We didn&#8217;t forget about Flash either. A few month later we started the <a href="https://blog.mozilla.org/research/2012/11/12/introducing-the-shumway-open-swf-runtime-project/">Shumway</a> project, which is still evolving, but might at least partially replace the role of Adobe&#8217;s native Flash player in Firefox eventually.</p>
<p><strong>On Canvas and Dashed Lines</strong></p>
<p>A lesser known part of the PDF.js project&#8217;s history is that <em>the Web was actually <strong>NOT</strong> ready</em> to render PDF when we started. We are using the CANVAS element to render PDF documents. We ran across a few loose ends and missing features. Infamously, we pretty quickly discovered that the CANVAS element couldn&#8217;t render dashed lines. It seems the spec authors just forgot to include this feature. We ran into this problem 4 days into implementing PDF.js because the first document we chose to render had some dashed lines in it. As it happens, Chris and I are both committers to the Mozilla code base, so Chris whipped up a prototype implementation in Firefox and we posted a proposed spec to the W3C mailing list. Two weeks later Firefox trunk (Nightly) could display dashed lines in the CANVAS element, and pretty soon thereafter a bug was filed for WebKit to add support as well (WebKit is used by Safari and Chrome, amongst others). This approach is the third part of the research group&#8217;s mission: <em>Find out what the web can&#8217;t do, figure out why not, and <strong> FIX IT</strong>.</em></p>
<p><strong>Standards vs Prototypes</strong></p>
<p>The Web is so powerful because it&#8217;s not governed by committees and standards bodies. Instead, standards bodies like W3C merely help the Web avoid fragmentation by giving browser vendors a forum to coordinate and collaborate on jointly developed technology. To add dashed lines support, we didn&#8217;t have to convince a standards body. Instead, we added a prefixed prototype implementation to Firefox, and within a few months hundreds of millions of Firefox users could start using this feature. This was also the reason WebKit quickly decided to implement dashed lines support: competitive pressure. Firefox could do something WebKit-based browsers couldn&#8217;t. This is how the Web evolves. Someone finds a missing feature and implements a prototype for it, and if it&#8217;s a good feature, the rest of the browser vendors have little choice than to add support as well. The W3C&#8217;s role is to help browser vendors implement the feature in a compatible fashion across the different browser engines. The result is a pace of innovation that is unparalleled in technology history. Hundreds of millions of users had access to a feature after a few months of two engineers realizing that it was missing, and the rest of the Web adopted the same feature another few months later. Compare this to traditional governance by committee approaches such as the <a href="http://www.jcp.org/en/home/index">Java Community Process</a> and the <a href="http://www.open-std.org/jtc1/sc22/wg21/">C++ standards committee</a> where the pace of progress is measured in decades.</p>
<p><strong>Beyond the Desktop</strong></p>
<p>The second area we were interested in was Mobile. How come the Web is so ubiquitous on the desktop, but Mobile content (Apps) is implemented with proprietary native technology such as Java/Dalvik (Android) and ObjectiveC/Cocoa (iOS)? As with plugins, we didn&#8217;t have a technical explanation, and as with plugins, we did the same thing to find an answer: build it.</p>
<p>At the time of our first post about Boot 2 Gecko, which later became Firefox OS, Mozilla already had a Mobile product: Firefox for Android. It wasn&#8217;t particularly popular because it was pretty slow and memory hungry. We proposed a couple architectural changes to Firefox for Android, in particular abandoning our established XUL frontend toolkit in favor of a native Android UI. Mozilla&#8217;s mobile team did a heroic effort to turn the prototype we created into a full product within 6 months. Today, Firefox for Android is one of the most popular third party browsers for Android, and is faster and uses less memory than the native browser on most devices. In contrast to the often crappy browsing experience with the built-in browser, Firefox for Android is actually a pretty decent way to surf the Web on mobile. Yet most people still spend most of their time in native Apps. Why?</p>
<p><strong>Mobile, the neglected red-headed stepchild</strong></p>
<p>If you want to understand why the Web isn&#8217;t as popular on Mobile as on Desktop, just surf the Web on a phone: <strong>The Web totally blows on Mobile! </strong>Almost none of the device capabilities of a modern smartphone were available to the Web around the time we started talking about Boot 2 Gecko: making a phone call, SMS, bluetooth, NFC, proximity sensors, streaming camera access, etc. Name a device capability, and the Web didn&#8217;t support it back then. Browser vendors neglected to evolve the Web on Mobile with the same vigor as we did on the Desktop. No wonder content authors choose powerful native APIs instead of writing applications in HTML5!</p>
<p>The solution is pretty trivial and obvious: fix it. Mozilla started the <strong>WebAPI</strong> campaign as one of the first steps of the Boot 2 Gecko project. We have added dozens of new APIs to HTML5 to support mobile device capabilities, and many of these APIs have already been proposed as new W3C standards in various stages of progress, ranging from prototype specs all the way to final specs implemented across multiple browsers.</p>
<p><strong>Why Mozilla matters</strong></p>
<p>Our existing user-base of hundreds of millions of users gives Mozilla a tremendous amount of influence over Web technology, and this user-base is what enables us to push out new APIs and technologies. Any new device capability we add, we tend to add across all implementations of our browsers, ranging from Firefox OS devices (which are not in market yet), to Firefox Android (which has a ton of users) and Firefox Desktop (which a third of Internet-connected humans use). This gives us a loud voice in standards bodies, and we use that voice to aggressively push the boundaries of what can be done with the Web. Today, HTML5 is as powerful as native APIs, and within a year we have essentially closed the gap between the Web and native APIs when it comes to device capabilities.</p>
<p>Mozilla&#8217;s role in helping the Web succeed on Mobile is so critical, because we are driven by very different motives as the other three large browser vendors: Google, Apple and Microsoft. Mozilla is a public benefit non-profit foundation. Our goal is to promote innovation and choice on the Internet. We have no profit motive, and no services or products to sell. We want users to use our products, because they are better than the competition&#8217;s. And we want this choice to drive other vendors to advance their products to compete with us. This keeps us honest, and constantly pushes the envelope on Web technology.</p>
<p><strong>Why the Web is going to win Mobile</strong></p>
<p>Today, Firefox on Android is a powerful Web Browser and<strong> Web Runtime</strong> for Mobile applications. The Firefox Marketplace on Android offers a way for content authors to package HTML5 applications in an easily accessible marketplace that users can download applications from.</p>
<p>In 2013, jointly with our partners we will bring the first Firefox OS devices to market. These devices are completely built with the Web, and as Chris and I suspected a year and a half ago: there is really no technical reason why native technology should prevail on Mobile. In fact, Firefox OS and HTML5 apps are actually often much more CPU and memory efficient than proprietary alternatives such as Android and iOS. We are capitalizing on this fact and we are targeting in particular emerging markets such as Brazil with the first set of Firefox OS devices. The Web will bring smartphones to parts of the world where people can&#8217;t afford the expensive high-end smartphones Google, Apple and Microsoft like to compete over.</p>
<p>Only one question remains at this point: <em>Is the Web really going to take off on Mobile?</em> I think the best way to answer this is as follows: picture yourself being an executive at a company such as Facebook and someone pitches a new product to you: Facebook for Windows&#8211;a product designed for users to access Facebook from Windows desktops. In all likelihood, you would laugh that person out of the room. Obviously the Web is the way users access content such as Facebook on Desktop. Just the thought of using a native application for this purpose seems surreal and nonsensical. Now replace the word &#8220;Windows&#8221; with &#8220;iOS&#8221;, and suddenly everything is different. Obviously there is native Facebook for iOS.</p>
<p>In reality, in a world where the Mobile Web is as powerful as the Desktop Web, Facebook for iOS is just as surreal and nonsensical as Facebook for Windows is for the Desktop. Mozilla has been working tirelessly to create that world, and I think we are getting pretty close. Once we are there, native Mobile apps will be all but forgotten, just as Win32 applications are headed for extinction today.</p>
<br />Filed under: <a href='http://andreasgal.com/category/mozilla/'>Mozilla</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/andreasgal.wordpress.com/246/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/andreasgal.wordpress.com/246/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/andreasgal.wordpress.com/246/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/andreasgal.wordpress.com/246/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/andreasgal.wordpress.com/246/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/andreasgal.wordpress.com/246/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/andreasgal.wordpress.com/246/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/andreasgal.wordpress.com/246/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/andreasgal.wordpress.com/246/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/andreasgal.wordpress.com/246/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/andreasgal.wordpress.com/246/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/andreasgal.wordpress.com/246/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/andreasgal.wordpress.com/246/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/andreasgal.wordpress.com/246/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=246&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://andreasgal.com/2013/01/08/why-the-web-is-going-to-win-mobile/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/dc614466f1a6d8f9c0e7a868bda77196?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96" medium="image">
			<media:title type="html">andreasgal</media:title>
		</media:content>

		<media:content url="http://andreasgal.files.wordpress.com/2012/12/firefox-phone.png?w=300" medium="image">
			<media:title type="html">firefox-phone</media:title>
		</media:content>
	</item>
		<item>
		<title>Boot 2 Gecko @ JSConf US 2012</title>
		<link>http://andreasgal.com/2012/04/01/boot-2-gecko-jsconf-us-2012/</link>
		<comments>http://andreasgal.com/2012/04/01/boot-2-gecko-jsconf-us-2012/#comments</comments>
		<pubDate>Sun, 01 Apr 2012 10:35:46 +0000</pubDate>
		<dc:creator>Andreas</dc:creator>
				<category><![CDATA[Mozilla]]></category>

		<guid isPermaLink="false">http://andreasgal.com/?p=238</guid>
		<description><![CDATA[The Boot 2 Gecko team is attending JSConf US 2012, including B2G&#8217;s tech lead Chris Jones and the Gaia (Phone UX) lead Vivien Nicolas. We have a bunch of devices with us, so flag us down if you have any &#8230; <a href="http://andreasgal.com/2012/04/01/boot-2-gecko-jsconf-us-2012/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=238&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>The <a href="https://wiki.mozilla.org/B2G" target="_blank">Boot 2 Gecko</a> team is attending <a href="http://2012.jsconf.us/" target="_blank">JSConf US 2012</a>, including B2G&#8217;s tech lead <a href="http://blog.mozilla.com/cjones/" target="_blank">Chris Jones</a> and the Gaia (Phone UX) lead <a href="http://www.flickr.com/photos/paulrouget/3677602237/" target="_blank">Vivien Nicolas</a>. We have a bunch of devices with us, so flag us down if you have any questions or would like to play with a B2G phone.</p>
<br />Filed under: <a href='http://andreasgal.com/category/mozilla/'>Mozilla</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/andreasgal.wordpress.com/238/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/andreasgal.wordpress.com/238/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/andreasgal.wordpress.com/238/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/andreasgal.wordpress.com/238/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/andreasgal.wordpress.com/238/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/andreasgal.wordpress.com/238/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/andreasgal.wordpress.com/238/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/andreasgal.wordpress.com/238/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/andreasgal.wordpress.com/238/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/andreasgal.wordpress.com/238/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/andreasgal.wordpress.com/238/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/andreasgal.wordpress.com/238/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/andreasgal.wordpress.com/238/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/andreasgal.wordpress.com/238/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=238&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://andreasgal.com/2012/04/01/boot-2-gecko-jsconf-us-2012/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/dc614466f1a6d8f9c0e7a868bda77196?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96" medium="image">
			<media:title type="html">andreasgal</media:title>
		</media:content>
	</item>
		<item>
		<title>Mozilla Project vs Mozilla Corporation</title>
		<link>http://andreasgal.com/2012/03/12/mozilla-project-vs-mozilla-corporation/</link>
		<comments>http://andreasgal.com/2012/03/12/mozilla-project-vs-mozilla-corporation/#comments</comments>
		<pubDate>Tue, 13 Mar 2012 05:38:27 +0000</pubDate>
		<dc:creator>Andreas</dc:creator>
				<category><![CDATA[Mozilla]]></category>

		<guid isPermaLink="false">http://andreasgal.com/?p=234</guid>
		<description><![CDATA[We went through a lengthy thread on hardware-decoding and H.264 on dev-platform today. It was heated but mostly civil. We are all pretty passionate about open standards, so an intense debate was to be expected. One issue I keep running &#8230; <a href="http://andreasgal.com/2012/03/12/mozilla-project-vs-mozilla-corporation/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=234&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>We went through a lengthy thread on hardware-decoding and H.264 on dev-platform today. It was heated but mostly civil. We are all pretty passionate about open standards, so an intense debate was to be expected. One issue I keep running into whenever I take some idea to a public forum like dev-platform is my standing with the Mozilla Project and the Mozilla Corporation. I am the Director of Research for the Mozilla Corporation. I can speak with some authority about research stuff. I am also a contributor to the Mozilla Project. I own a couple modules, and I am a peer to another few. When I posted to dev-platform today about codecs, I was wearing my Mozilla Project contributor hat. Me being a director at the Mozilla Corporation buys me exactly zero standing and authority with the Mozilla Project. The Mozilla Project has a governance structure. Peers and module owners make decisions. Since we are talking about codecs here, and I am neither a peer nor a module owner, I have as much authority as any random contributor on whether we take the course I plotted in my email or not. I am absolutely convinced I am right, but I still don&#8217;t get to make the call. The decision is with the module owners. So next time you read something I write, keep in mind: I am allowed to have a lot of opinions, but I have actually very little authority over the Mozilla Project. The authority rests with a large experienced group of module owners, not any one individual, even less so someone hired for a job (like a director). Instead, module ownership is based on merit and contribution to the project. And that&#8217;s why Mozilla rocks.</p>
<br />Filed under: <a href='http://andreasgal.com/category/mozilla/'>Mozilla</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/andreasgal.wordpress.com/234/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/andreasgal.wordpress.com/234/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/andreasgal.wordpress.com/234/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/andreasgal.wordpress.com/234/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/andreasgal.wordpress.com/234/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/andreasgal.wordpress.com/234/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/andreasgal.wordpress.com/234/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/andreasgal.wordpress.com/234/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/andreasgal.wordpress.com/234/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/andreasgal.wordpress.com/234/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/andreasgal.wordpress.com/234/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/andreasgal.wordpress.com/234/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/andreasgal.wordpress.com/234/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/andreasgal.wordpress.com/234/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=234&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://andreasgal.com/2012/03/12/mozilla-project-vs-mozilla-corporation/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/dc614466f1a6d8f9c0e7a868bda77196?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96" medium="image">
			<media:title type="html">andreasgal</media:title>
		</media:content>
	</item>
		<item>
		<title>Boot 2 Gecko at Mobile World Congress 2012</title>
		<link>http://andreasgal.com/2012/02/21/boot-2-gecko-at-mobile-world-congress-2012/</link>
		<comments>http://andreasgal.com/2012/02/21/boot-2-gecko-at-mobile-world-congress-2012/#comments</comments>
		<pubDate>Wed, 22 Feb 2012 07:39:44 +0000</pubDate>
		<dc:creator>Andreas</dc:creator>
				<category><![CDATA[Mozilla]]></category>

		<guid isPermaLink="false">http://andreasgal.com/?p=222</guid>
		<description><![CDATA[Mozilla and the Boot 2 Gecko team are attending Mobile World Congress 2012. Visit us at our booth (7B96) in Hall 7. Filed under: Mozilla<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=222&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>Mozilla and the Boot 2 Gecko team are attending Mobile World Congress 2012. Visit us at our booth (7B96) in Hall 7.</p>
<br />Filed under: <a href='http://andreasgal.com/category/mozilla/'>Mozilla</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/andreasgal.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/andreasgal.wordpress.com/222/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/andreasgal.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/andreasgal.wordpress.com/222/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/andreasgal.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/andreasgal.wordpress.com/222/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/andreasgal.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/andreasgal.wordpress.com/222/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/andreasgal.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/andreasgal.wordpress.com/222/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/andreasgal.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/andreasgal.wordpress.com/222/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/andreasgal.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/andreasgal.wordpress.com/222/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=222&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://andreasgal.com/2012/02/21/boot-2-gecko-at-mobile-world-congress-2012/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/dc614466f1a6d8f9c0e7a868bda77196?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96" medium="image">
			<media:title type="html">andreasgal</media:title>
		</media:content>
	</item>
		<item>
		<title>pdf.js: Rendering PDF with HTML5 and JavaScript</title>
		<link>http://andreasgal.com/2011/06/15/pdf-js/</link>
		<comments>http://andreasgal.com/2011/06/15/pdf-js/#comments</comments>
		<pubDate>Thu, 16 Jun 2011 02:21:22 +0000</pubDate>
		<dc:creator>Andreas</dc:creator>
				<category><![CDATA[Mozilla]]></category>

		<guid isPermaLink="false">http://andreasgal.com/?p=206</guid>
		<description><![CDATA[Update: I updated the links again. pdf.js has moved to a new location on github. Why? While traveling to the Firefox 4 launch parties in Seoul and Taipei all the way from California, we killed a lot of time by &#8230; <a href="http://andreasgal.com/2011/06/15/pdf-js/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=206&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p><strong>Update:</strong> I updated the links again. pdf.js has moved to a new location on github.</p>
<h2>Why?</h2>
<p>While traveling to the Firefox 4 launch parties in Seoul and Taipei all the way from California, we killed a lot of time by brainstorming cool things to do with the web platform. Like many before us, we were wondering why nobody had implemented a PDF reader in HTML5/JavaScript. The kinds of operations a PDF reader needs to be fast at &#8211;render text, draw lines, blit images&#8211; need to be fast in browsers too, so browsers are already highly optimized for them.</p>
<p>Building an HTML5-based PDF renderer would also answer the question of whether the web platform and in particular canvas and SVG APIs are complete enough to efficiently and faithfully render PDFs.</p>
<p>Displaying PDFs directly in the browser would definitely improve the user&#8217;s experience. There are literally millions (billions?) of PDFs floating around the web, and on many devices loading PDFs switches to a different application (e.g. Preview on OS X and PDF View on Android). Also, external PDF readers and many plugins don&#8217;t support important PDF features well, including content links and fetch-as-you-go (HTTP range requests).</p>
<p>External readers and plugins are also forced to reinvent their own user interaction paradigms, meaning for example that users might scroll HTML pages in one way with one set of heuristics in the browser, but a totally different way in an external PDF reader.</p>
<p>It&#8217;s important to note that we&#8217;re not trying to promote PDF to a first-class web citizen like HTML5 is. Instead we hope that a browser-<a href="http://arewenativeyet.com/">native</a> PDF renderer written on the web platform allows web technologies to subsume PDF.</p>
<h2>Benefits</h2>
<p>The traditional approach to rendering PDFs in a browser is to use a native-code plugin, either Adobe&#8217;s own PDF Reader or other commercial renderers, or some open source alternative (e.g. poppler). From a security perspective, this enlarges the trusted code base, and because of that Google&#8217;s Chrome browser goes through quite some pain to sandbox the PDF renderer to avoid code injection attacks. An HTML5-based implementation is completely immune to this class of problems.</p>
<h2>Project Status</h2>
<p>We have been developing pdf.js in the open (on <a href="http://github.com/">github.com</a>), albeit quietly, for about a month now. We were waiting on the completion of some major features (Type1 fonts, gradients, etc.) before communicating <a href="https://github.com/mozilla/pdf.js">pdf.js</a> more broadly. We&#8217;ve been taken by surprise by the early and intense interest in our work, so we decided to blog and talk about our project earlier than we initially planned.</p>
<p>As part of our project plan, we are initially focused on achieveing pixel-perfect rendering of a single PDF paper, a <a href="http://people.mozilla.org/~gal/compressed.tracemonkey-pldi-09.pdf">2009 paper on Trace Compilation we submitted to the ACM SIGPLAN PLDI conference</a>. As the Tracemonkey work described in the paper led the way for JavaScript JITs, so we hope pdf.js opens the door to implementing legacy formats on top of the web platform.</p>
<p>If you want to see a demo of <a href="https://github.com/mozilla/pdf.js">pdf.js</a>, click on this <a href="http://mozilla.github.com/pdf.js/web/viewer.html">link</a>. There are still glitches and rendering artifacts, but you will get the picture. We are still missing Type1 PostScript fonts, which Vivien Nicolas is working on.</p>
<p>Along the way, we had to add some new interfaces to the HTML5 canvas element, and figure out how to implement some difficult features of the PDF spec in JavaScript. See Chris&#8217;s <a href="http://blog.mozilla.com/cjones/2011/06/15/overview-of-pdf-js-guts/">post</a> for a general technological overview, and Shaon&#8217;s <a href="https://sbarman.wordpress.com/">post</a> for details on rendering &#8220;shading patterns&#8221;.</p>
<h2>Whats next?</h2>
<p>We intend to use <a href="https://github.com/mozilla/pdf.js">pdf.js</a> to render PDFs &#8220;natively&#8221;, within Firefox itself. Our most immediate goal is to implement the most commonly used PDF features so we can render a large majority of the PDFs found on the web. We believe we can reach that point in less than 3 months (the entire code so far is less than one month old, and it already renders a large set of PDF features).</p>
<p>Initially we will make a Firefox extension available to interested users that enables inline PDF rendering using <a href="https://github.com/mozilla/pdf.js">pdf.js</a>, but our ultimate goal is of course shipping <a href="https://github.com/mozilla/pdf.js">pdf.js</a> with Firefox. This will result in a substantial usability but also security improvement for our users. <a href="https://github.com/mozilla/pdf.js">pdf.js</a> uses only safe web languages and doesn&#8217;t contain any native code pieces attackers could exploit.</p>
<h2>Open Source</h2>
<p>We want <a href="https://github.com/mozilla/pdf.js">pdf.js</a> to be a community driven and governed open-source project. We&#8217;ll use it for Firefox, but we think there are many cool applications for it. We would love to see it embedded in other browsers or web applications; because it&#8217;s written only in standards-compliant web technologies, the code will run in any compliant browser. We are licensing pdf.js under a very liberal 3-clause BSD license and we welcome external contributors. We are looking forward to your ideas or code to make pdf.js better! Take a look at our <a href="https://github.com/mozilla/pdf.js">github</a> and <a href="https://wiki.mozilla.org/PDF.js">our wiki</a>, or talk to us on IRC in <a href="irc://irc.mozilla.org/pdfjs">#pdfjs</a>.</p>
<p>Chris Jones and Andreas Gal (and the pdf.js team)</p>
<br />Filed under: <a href='http://andreasgal.com/category/mozilla/'>Mozilla</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/andreasgal.wordpress.com/206/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/andreasgal.wordpress.com/206/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/andreasgal.wordpress.com/206/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/andreasgal.wordpress.com/206/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/andreasgal.wordpress.com/206/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/andreasgal.wordpress.com/206/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/andreasgal.wordpress.com/206/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/andreasgal.wordpress.com/206/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/andreasgal.wordpress.com/206/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/andreasgal.wordpress.com/206/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/andreasgal.wordpress.com/206/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/andreasgal.wordpress.com/206/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/andreasgal.wordpress.com/206/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/andreasgal.wordpress.com/206/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=206&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://andreasgal.com/2011/06/15/pdf-js/feed/</wfw:commentRss>
		<slash:comments>199</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/dc614466f1a6d8f9c0e7a868bda77196?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96" medium="image">
			<media:title type="html">andreasgal</media:title>
		</media:content>
	</item>
		<item>
		<title>User data in the cloud: Lessons from the Sony debacle</title>
		<link>http://andreasgal.com/2011/05/02/user-data/</link>
		<comments>http://andreasgal.com/2011/05/02/user-data/#comments</comments>
		<pubDate>Mon, 02 May 2011 07:07:53 +0000</pubDate>
		<dc:creator>Andreas</dc:creator>
				<category><![CDATA[Mozilla]]></category>
		<category><![CDATA[Research]]></category>

		<guid isPermaLink="false">http://andreasgal.wordpress.com/?p=169</guid>
		<description><![CDATA[Two weeks ago our friends at Sony managed to get personal information of 70 million users stolen from them. I got one of the notification emails a couple days ago myself (I must have signed up for the Playstation Network &#8230; <a href="http://andreasgal.com/2011/05/02/user-data/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=169&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p><a href="http://andreasgal.files.wordpress.com/2011/04/safety.jpg"><img class="size-full wp-image-170 alignright" title="Don't try to lift more than you are able" src="http://andreasgal.files.wordpress.com/2011/04/safety.jpg?w=640" alt=""   /></a>Two weeks ago our friends at Sony managed to get personal information of 70 million users <a title="Sony Playstation network breach" href="http://www.unwiredview.com/2011/05/02/sony-execs-hang-heads-in-shame-over-playstation-network-breach/">stolen from them</a>. I got one of the notification emails a couple days ago myself (I must have signed up for the Playstation Network when I installed the PS3 we bought to do our Cell VM work back at UCI.) In this instance, Sony is a shining example of how <em><strong>NOT</strong></em> to handle user data.</p>
<h2>Whats user data?</h2>
<p>User data is any piece of identifiable data about a user. It can be all sorts of obvious stuff like your name, address, birth date, passwords (all of these Sony managed to lose), but also less obvious data such as usage history, communications, and what not. Whether Sony lost the latter is not clear. Some of the information Sony lost clearly should never have been stored in the first place. I understand why Sony asked me for my birth date when I signed up for PSN. Some jurisdictions want you to be a certain age before you can engage in virtual mayhem and violence that is modern video gaming. But why the hell did Sony store this information in a database? Why not just flag my account as &#8220;remembers the first techno song being played on the radio, definitely old enough&#8221;?</p>
<h2>Risks</h2>
<p>Storing data is always risky. If you store any data in the cloud, eventually someone will break into it. Investing a lot of money (expensive equipment, expensive practices, expensive staff) helps delaying that day of reconning, but only within limits. There are a lot of financial incentives to steal this kinda of data. Personal information of 70 million people is a fantastic starting point for all sorts of phishing attacks. And even if only one out of 10,000 people getting that Nigerian email falls for it, that&#8217;s still plenty of people to take advantage of. Sony took a risk storing user data. Unfortunately, it was not a well calculated risk. They could have easily reduces the fallout from a breach by storing less information, i.e. by not storing the birth date, or maybe even not storing personal information at all! Shocking proposition, I know.</p>
<h2>Not knowing is bliss</h2>
<p>Why does Sony need the names of its PSN subscribers in the PSN user database to begin with? Let people choose a handle and a password. If you want to personal the experience, let users <em>chose</em> their name. Dear PSN, you may call me Tracemonkey now. You really don&#8217;t need to know my real name and address. As for payment information, I think its ok if PSN asks me once a year to re-enter my credit card info, which is then briefly processed but never stored. Had they followed this simple principle of touching (and storing) as little user data as possible, they would have saved themselves a lot of legal trouble and liability.</p>
<h2>Browsers</h2>
<p>I am not ranting about this topic out of thin air. Web browsers handle a lot of personal information, and its tempting for browser vendors to get in on the whole social networks online transactions online identity game. A number of people at Mozilla don&#8217;t seem too comfortable with hosting on our infrastructure any user data ever. Its really scary and risky after all (just ask Sony). I think that&#8217;s wrong. We absolutely should get into the key areas of social and identity. Why? Because the state of the art is crappy, and we can do better.</p>
<h2>Microsoft Passport anyone?</h2>
<p>Web identity is a total mess. I have at least 30 accounts in various places with different account names and passwords (well at least I try). Various organizations and services have tried to established a single login. Microsoft Passport was one of the earlier ones. I am really glad that didn&#8217;t work out. Can you imagine the evil empire owning all your personal data and online identity? Microsoft has a lot of incentives to use and abuse such a powerful position, and it certainly does. I still get emails from Microsoft about my Passport account on a regular basis, almost a decade later. Its usually an invitation to try this new Microsoft feature Y or maybe try chatting with my passport account or &#8230; well whatever. Microsoft sits on a lot of data, and its tempting to monetize it. And of course its not just them. Everyone else is just as bad. Ever noticed how Google and Facebook customize ads for you based on the data they have about you? Creepy. This is why I think Mozilla can do a lot better. We don&#8217;t have any hidden agenda. We don&#8217;t have any extra services we want to sell you. We don&#8217;t have to monetize data we store to turn a profit and make shareholders happy. We simply don&#8217;t have any shareholders. We are a company owned by a non-profit foundation that wants to make the web a better place. This puts us in a much better position to do whats best for our users, instead of whats best for our quarterly statement (we don&#8217;t publish any of those in case you didn&#8217;t notice.)</p>
<h2>Playing it safe</h2>
<p>We are currently in the process of figuring out how exactly Mozilla should handle user data. I have exactly zero authority when it comes to these kind of decisions, but Mozilla is a pretty open and democratic place and we tend to discuss this stuff pretty openly, giving anyone a voice who wants to speak up. I think its imperative that we follow a couple guiding principles as we explore ways to better serve our users using services such as identity or social:</p>
<ol>
<li><strong>Always keep the users&#8217; best interest in mind (and only the users&#8217; best interests).</strong> I don&#8217;t care if we can ship a feature faster or cheaper if we store more user data (or maybe store it not encrypted instead of encrypted). Our new Sync service is a great example for this. Its a total pain in the butt to encrypt the browser history on the client before it is uploaded to our services, but its the right thing to do. It means that in case of Sync we can never see any of your browser history, even if we tried, and your data is safe by default.</li>
<li><strong>Always store as little data as possible in the cloud.</strong> If there is a way to implement a feature completely in the client without us ever having to see user data, that&#8217;s always the right approach, even if its harder. This is exactly the issue we are facing with our new F1 social browsing feature. It allows you to share websites on Facebook/Twitter/etc as you visit them. Its a really cool feature&#8211;I use it all the time. Unfortunately, the protocol Facebook/Twitter/etc offer to authenticate and access their APIs (<em>oauth</em>) is totally broken, and conceptually doesn&#8217;t really work for client applications. oauth requires the client (Firefox/F1) and Facebook/Twitter/etc to negotiate a shared secret (called the consumer key). With a pure client solution this secret can never be kept (someone could peek into Firefox/F1 and extract the key). It seems Facebook has blacklisted consumer keys before because people checked them into open-source repositories. The only alternative to this is to put the key behind a service Mozilla runs and then let Firefox/F1 post via that service, but that means we would be able to see (in theory, not intentionally of course) all the Facebook/Twitter/etc status updates of millions of people every day. That&#8217;s wrong. As tempting and quick as it would be to setup a Mozilla service that keeps the key hidden and posts for users, we should never put ourselves in a position where we handle user data without an overwhelming need for it. In this particular instance we should simply negotiate with Facebook/Twitter/etc to not enforce the shared secret rule (Twitter already doesn&#8217;t it seems, since there are so many Twitter client apps out there), and maybe in parallel we should work on better protocols than <em>oauth</em>.</li>
</ol>
<h2>Going fast</h2>
<p>As we were discussing these various architectural aspects of how to handle user data (or how not to handle it) the last few weeks, some people were tempted to go the easy route and store a lot more user data (in particular in the clear) than necessary because it might get us to market faster. I think this is wrong for the above two principles, but its also wrong because it will <em><strong>NOT</strong></em> get us to market faster. Dealing with user data from an infrastructure perspective is a total pain. To handle or even store things like Facebook/Twitter/etc account authentication tokens or user contacts, we have to build out a serious security infrastructure. We need to hire expensive, highly trained personnel and we have to seriously tighten our security practices. That doesn&#8217;t mean we are unsafe right now. It just means our current practices match our current threat scenarios. For example we have external IT administrators who don&#8217;t even work for Mozilla administering our source code repository access controls. They are simply Mozilla project volunteers. Considering the limited risks, this is acceptable. When it comes to storing user data, entirely different standards will be needed. And getting all that sorted out and implemented will require a lot of audits, careful planning &#8230; and a lot of time. So if you want to go fast, go zero user data. Or encrypt the user data on the client so all we get to see are blobs of meaningless zeros and ones. That&#8217;s how Sync works, and we got it up and running within a couple months. That&#8217;s how you go fast.</p>
<h2>What&#8217;s next?</h2>
<p>We are currently discussing what our process will be to store user data. Expect people with actual authority to make decisions (and to talk about them) to start talking about this publicly in a few weeks. I already know that the result of our internal deliberations will be a policy that will focus on what&#8217;s best for our users, and that will minimize risks for them (and in the end, for us). And expect a safe and secure implementation of F1 to show up in your browser really soon. You can already <a title="F1 sharing" href="http://f1.mozillamessaging.com/">try out the prototype now</a>. It really rocks.</p>
<p><strong>This blog post represents my personal opinion, not the official position of Mozilla.</strong></p>
<br />Filed under: <a href='http://andreasgal.com/category/mozilla/'>Mozilla</a>, <a href='http://andreasgal.com/category/research/'>Research</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/andreasgal.wordpress.com/169/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/andreasgal.wordpress.com/169/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/andreasgal.wordpress.com/169/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/andreasgal.wordpress.com/169/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/andreasgal.wordpress.com/169/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/andreasgal.wordpress.com/169/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/andreasgal.wordpress.com/169/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/andreasgal.wordpress.com/169/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/andreasgal.wordpress.com/169/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/andreasgal.wordpress.com/169/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/andreasgal.wordpress.com/169/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/andreasgal.wordpress.com/169/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/andreasgal.wordpress.com/169/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/andreasgal.wordpress.com/169/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=169&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://andreasgal.com/2011/05/02/user-data/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/dc614466f1a6d8f9c0e7a868bda77196?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96" medium="image">
			<media:title type="html">andreasgal</media:title>
		</media:content>

		<media:content url="http://andreasgal.files.wordpress.com/2011/04/safety.jpg" medium="image">
			<media:title type="html">Don&#039;t try to lift more than you are able</media:title>
		</media:content>
	</item>
		<item>
		<title>Compartments</title>
		<link>http://andreasgal.com/2010/10/13/compartments/</link>
		<comments>http://andreasgal.com/2010/10/13/compartments/#comments</comments>
		<pubDate>Thu, 14 Oct 2010 00:26:40 +0000</pubDate>
		<dc:creator>Andreas</dc:creator>
				<category><![CDATA[Research]]></category>

		<guid isPermaLink="false">http://andreasgal.wordpress.com/?p=130</guid>
		<description><![CDATA[Heap We have implemented a major change to the way Firefox manages JavaScript objects. JavaScript objects include script-instantiated objects such as Arrays or Date objects, but also include JavaScript representations of Document Object Model (DOM) elements, such as input fields &#8230; <a href="http://andreasgal.com/2010/10/13/compartments/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=130&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<h1>Heap</h1>
<p>We have implemented a major change to the way Firefox manages JavaScript objects. JavaScript objects include script-instantiated objects such as Arrays or Date objects, but also include JavaScript representations of Document Object Model (<strong>DOM</strong>) elements, such as input fields or <em>DIV</em> elements. In the past, Firefox held all JavaScript objects in a single JavaScript heap. This heap is occasionally garbage collected, which means the browser walks the entire object graph in the heap and determines which objects are still reachable and which are not. Unreachable objects are de-allocated and space is reclaimed.</p>
<p><a href="http://andreasgal.files.wordpress.com/2010/10/figure1.png"><img class="alignnone size-full wp-image-132" title="Firefox 3.6 single heap model." src="http://andreasgal.files.wordpress.com/2010/10/mochup1.png?w=640" alt="Firefox 3.6 single heap model."   /></a></p>
<p>Having all JavaScript objects in the browser congregate in a single heap is suboptimal for a number of reasons. If a user has multiple windows (or tabs) open, and one of these windows (or tabs) created a lot of objects, it is likely that many of these objects are no longer reachable (<em>garbage</em>). When the browser detects such a state, it will initiate a garbage collection. Unfortunately though, since objects from different windows (or tabs) are intermixed in the heap, the browser has to walk the <strong>entire</strong> heap. If a number of idle windows are open, this can be quite wasteful, since those windows haven&#8217;t really created any garbage, so whenever a window with heavy activity triggers a garbage collection, much of the garbage collection time is spent walking unrelated parts of the global object graph.</p>
<p>In Firefox this problem is even more pronounced than in other browsers, because our UI code (also called <strong>chrome</strong> code, not to be confused with Google Chrome) is implemented in JavaScript, and there are a lot of chrome (UI) objects alive at any given moment. These UI objects tend to stick around and every time a web content window causes a garbage collection, Firefox spends a lot of time figuring out whether chrome objects are still alive instead of being able to focus on the active web content window.</p>
<p><a href="http://andreasgal.files.wordpress.com/2010/10/figure2.png"><img class="alignnone size-full wp-image-133" title="FIrefox 4 Compartmentalized JavaScript Heaps" src="http://andreasgal.files.wordpress.com/2010/10/mockup2.png?w=640" alt="FIrefox 4 Compartmentalized JavaScript Heaps"   /></a></p>
<h2>Compartments</h2>
<p>For Firefox 4 we changed the way JavaScript objects are managed. Our JavaScript engine SpiderMonkey (sometimes also called TraceMonkey and JägerMonkey, which are SpiderMonkey&#8217;s trace-compilation and baseline Just-in-Time compilers) now supports multiple JavaScript heaps, which we also call <strong>compartments</strong>. All objects that belong to a certain <strong>origin</strong> (such as &#8220;<a href="http://mail.google.com/&#038;#8221" rel="nofollow">http://mail.google.com/&#038;#8221</a>; or &#8220;<a href="http://www.bank.com/&#038;#8221" rel="nofollow">http://www.bank.com/&#038;#8221</a>;) are placed into a separate compartment. This has a couple very important implications.</p>
<ul>
<li><em>All objects created by a website reside within the same compartment and hence are located in the same memory region.</em> This improves <strong>cache utilization</strong> by reducing false sharing of cache lines. False sharing occurs when we are trying to operate on an object and we have to read an entire cache line of data into the CPU cache. In the old model JavaScript objects could be co-located with arbitrary other JavaScript objects from other origins. Such cross origin objects are used together very infrequently, which reduces the number of cache hits we get. In the new model most objects touched by a website are tightly packed next to each other in memory, with no cross origin objects in between.</li>
<li><em>JavaScript objects (including JavaScript functions, which are objects as well) are only allowed to touch objects in the same compartment.</em> This invariant is very useful for security purposes. The JavaScript engine enforces this requirement at a very low level. It means that a &#8220;google.com&#8221; object can never accidentally leak into an untrusted website such as &#8220;evil.com&#8221;. Only a special object type can cross compartment boundaries. We call these objects <strong>cross compartment wrappers</strong>. We track the creation of these cross compartment wrappers, and thus the JavaScript engine knows at all times what objects from a compartment are kept alive by outside references (through cross compartment wrappers). This allows us to garbage collect individual compartments, in addition to a global collection. We simply assume all objects referenced from outside the compartment to be live, and then walk the object graph inside the compartment. Objects that are found to be disconnected from the graph are discarded. With this new <strong>per-compartment garbage collection</strong> we shortcut having to walk unrelated heap areas of a window (or tab) that triggered a garbage collection.</li>
</ul>
<h1>Wrappers</h1>
<p>Wrappers are not a new concept in Firefox, or browsers in general. In the past we have already used them to regulate how windows (or tabs) pass objects to each other. In the past, when another window (or tab or iframe) tried to touch an object that belongs to a different window, we handed it a wrapper object instead. That wrapper object dynamically checks at access time whether the accessor window (also called the <strong>subject</strong>) is permitted to access the target object. If one Google Mail window is trying to access another Google Mail window, the access is permitted, because these two windows (or tabs or iframes) are <strong>same origin</strong> and hence its safe to permit this access. If an untrusted website obtains a reference to a Google Mail DOM element, we hand it the same wrapper, and if it ever tries to access the Google Mail DOM Element the wrapper will at access time deny the property access because the untrusted website &#8220;evil.com&#8221; is cross origin with &#8220;google.com&#8221;.</p>
<p><a href="http://andreasgal.files.wordpress.com/2010/10/figure3.png"><img class="alignnone size-full wp-image-134" title="Firefox 3.6 Shared Wrappers" src="http://andreasgal.files.wordpress.com/2010/10/mockup3.png?w=640" alt="Firefox 3.6 Shared Wrappers"   /></a></p>
<p>A disadvantage of the Firefox 3.6 wrapper approach (which is similar to the way other browsers utilize wrappers) was the fact that these wrappers had to be injected manually at the right places in the C++ browser implementation, and each wrapper had to do a dynamic security check at access time. With compartments we can do a lot better:</p>
<ul>
<li>Since all objects belonging to the same origin are within the same compartment, <strong>and</strong> no object from a different origin is in that compartment, we can let all objects within a compartment touch other objects in the same compartment without a wrapper in between. Keep in mind that this doesn&#8217;t just apply to windows but also to iframes. A single Google Mail session often uses dozens of iframes that all heavily exchange objects with each other. In the past we had to inject wrappers in between that kept performing dynamic security checks. This is no longer necessary, and there is an observable speedup when using iframe heavy web applications such as Google Mail.</li>
<li>Since all cross origin objects are in a different compartment, any cross origin access that needs to perform a security check can only happen through a cross compartment wrapper. Such a cross compartment wrapper always lives in a source compartment, and accesses a single destination object. When we create a cross compartment wrapper, we consult with the <strong>wrapper factory </strong>to see what kind of security policy should be applied. When &#8220;evil.com&#8221; obtains a reference to a &#8220;google.com&#8221; object, for example, we have to create a wrapper to that object in the &#8220;evil.com&#8221; compartment. When that wrapper is created the wrapper factory will tell us to apply a stringent cross origin security policy, which makes it impossible for &#8220;evil.com&#8221; to glean information from the &#8220;google.com&#8221; window. In contrast to our old wrappers, this security policy is <strong>static</strong>. Since only &#8220;evil.com&#8221; objects ever see this wrapper, and it only points to one single DOM element in the destination compartment, the policy doesn&#8217;t have to be re-checked at access time. Instead, every time &#8220;evil.com&#8221; attempts to read information from the DOM element, the access is denied without even comparing the two origins.</li>
</ul>
<p><a href="http://andreasgal.files.wordpress.com/2010/10/figure4.png"><img class="alignnone size-full wp-image-135" title="Firefox 4 Cross Compartment Wrapper" src="http://andreasgal.files.wordpress.com/2010/10/mockup4.png?w=640" alt="Firefox 4 Cross Compartment Wrapper"   /></a></p>
<h1>Brain Transplants</h1>
<p>A particularly interesting oddity of the JavaScript DOM representation is the existence of two objects for each DOM window (or tab or iframe), the <strong>inner</strong> window and the <strong>outer</strong> window. This split was implemented by web browsers a few years ago to securely deal with windows being navigated to a new URL. When such a navigation occurs, the inner window object inside the outer window is replaced with a new object, whereas the actual reference to <em>window</em> (which is the outer window) remains unchanged. If such a navigation takes the window to a new origin, we allocate the inner window in the appropriate new compartment. This of course creates now the problem that the outer window can possibly no longer directly point to the new inner window, because it is in a different compartment.</p>
<p>We solve this problem through brain transplants. Whenever an outer window navigates, we copy it into the new destination compartment. The object in the old compartment is transformed into a cross compartment wrapper that points to the newly created object in the destination compartment. So the term brain transplants is very appropriate here. We are essentially transplanting the guts of the outer window object into a new object hull in the same compartment we allocated the inner object in.</p>
<h1>Processes</h1>
<p>Some readers might wonder how compartments compare to per-tab processes as they are used by Google Chrome and Internet Explorer. Compartments are similar in many ways, but also very different. Both processes and compartments shield JavaScript objects against each other. The most important distinction is that processes offer a stronger separation enforced by the processor hardware, while compartments offer a pure software guarantee. However, on the upside compartments allow much more efficient cross compartment communication that processes code. With compartments cross origin websites can still communicate with each other with a small overhead (governed by certain cross origin access policy), while with processes cross-process JavaScript object access is either impossible or extremely expensive. In a modern browser you will likely see both forms of separation being applied. Two web sites that never have to talk to each other can live in separate processes, while cross origin websites that do want to communicate can use compartments to enhance security and performance.</p>
<h1>Future</h1>
<p>We have landed the main compartments patch and current nightly builds (and Beta 7) are running with per-origin compartment JavaScript heaps. Some of the functionality described above will not ship until Beta 8, most importantly per-compartment garbage collections. Those currently still happen for all compartments at once. The foundation we laid with the compartments work will also enable a number of future extensions. Since we now cleanly separate objects belonging to different tabs, future changes to our JavaScript engine will permit us to not only perform JavaScript garbage collection for individual compartments, but we will also be able to do so in the background on a different thread for tabs with inactive content (i.e. no event handler is firing at the moment).</p>
<br />Filed under: <a href='http://andreasgal.com/category/research/'>Research</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/andreasgal.wordpress.com/130/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/andreasgal.wordpress.com/130/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/andreasgal.wordpress.com/130/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/andreasgal.wordpress.com/130/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/andreasgal.wordpress.com/130/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/andreasgal.wordpress.com/130/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/andreasgal.wordpress.com/130/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/andreasgal.wordpress.com/130/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/andreasgal.wordpress.com/130/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/andreasgal.wordpress.com/130/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/andreasgal.wordpress.com/130/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/andreasgal.wordpress.com/130/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/andreasgal.wordpress.com/130/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/andreasgal.wordpress.com/130/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=130&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://andreasgal.com/2010/10/13/compartments/feed/</wfw:commentRss>
		<slash:comments>129</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/dc614466f1a6d8f9c0e7a868bda77196?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96" medium="image">
			<media:title type="html">andreasgal</media:title>
		</media:content>

		<media:content url="http://andreasgal.files.wordpress.com/2010/10/mochup1.png" medium="image">
			<media:title type="html">Firefox 3.6 single heap model.</media:title>
		</media:content>

		<media:content url="http://andreasgal.files.wordpress.com/2010/10/mockup2.png" medium="image">
			<media:title type="html">FIrefox 4 Compartmentalized JavaScript Heaps</media:title>
		</media:content>

		<media:content url="http://andreasgal.files.wordpress.com/2010/10/mockup3.png" medium="image">
			<media:title type="html">Firefox 3.6 Shared Wrappers</media:title>
		</media:content>

		<media:content url="http://andreasgal.files.wordpress.com/2010/10/mockup4.png" medium="image">
			<media:title type="html">Firefox 4 Cross Compartment Wrapper</media:title>
		</media:content>
	</item>
		<item>
		<title>Narcissus/Zaphod JavaScript Research VM for Firefox 4</title>
		<link>http://andreasgal.com/2010/09/17/narcissuszaphod-javascript-vm-for-firefox-4/</link>
		<comments>http://andreasgal.com/2010/09/17/narcissuszaphod-javascript-vm-for-firefox-4/#comments</comments>
		<pubDate>Fri, 17 Sep 2010 18:58:23 +0000</pubDate>
		<dc:creator>Andreas</dc:creator>
				<category><![CDATA[Research]]></category>

		<guid isPermaLink="false">http://andreasgal.wordpress.com/?p=120</guid>
		<description><![CDATA[Our research intern Tom Austin released the first version of the Narcissus JavaScript Virtual Machine for Firefox 4. Narcissus is a JavaScript virtual machine written in JavaScript. Tom&#8217;s Firefox extension Zaphod allows using Narcissus as the default JavaScript engine in &#8230; <a href="http://andreasgal.com/2010/09/17/narcissuszaphod-javascript-vm-for-firefox-4/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=120&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<div id="attachment_121" class="wp-caption alignleft" style="width: 310px"><a href="http://andreasgal.files.wordpress.com/2010/09/zaphod-beeblebrox-001.jpg"><img class="size-medium wp-image-121 " title="Zaphod-Beeblebrox-001" src="http://andreasgal.files.wordpress.com/2010/09/zaphod-beeblebrox-001.jpg?w=300&#038;h=180" alt="Zaphod Beeblebrox" width="300" height="180" /></a><p class="wp-caption-text">Zaphod</p></div>
<div>
<p>Our research intern Tom Austin released the first version of the Narcissus JavaScript Virtual Machine for Firefox 4. Narcissus is a JavaScript virtual machine written in <strong>JavaScript</strong>. Tom&#8217;s Firefox extension <a href="https://mozillalabs.com/zaphod/" target="_self">Zaphod</a> allows using Narcissus as the default JavaScript engine in Firefox 4. This opens up the world of JavaScript language and virtual machine research to JavaScript programmers. It is no longer necessary to modify complex C++ code to implement new prototype language features for JavaScript (i.e. modules, type annotations, etc.). Similarly, Narcissus/Zaphod can also be used to try out new JavaScript optimizations and static analysis. Since Zaphod runs directly in Firefox, such experiments are no longer limited to simple command line JavaScript shell test cases. Zaphod can run complex websites and all the JS code on them.</p>
<p>Stay tuned for future updates to Zaphod and Narcissus. We have bold plans for both. Our <a href="http://doctorjs.org/" target="_self">static analysis</a> pass for Narcissus will soon be integrated with Zaphod, as well as our new Static Single Assignment-form Narcissus AST/intermediate representation.</p>
<p><em>Want to work on cool research projects in the JavaScript/Web space? Join Mozilla Research as research intern. We are looking for highly talented PhD students for Winter 2010/2011 and Summer 2011. Contact me at <strong>gal@mozilla.com</strong>.<br />
</em></p>
</div>
<br />Filed under: <a href='http://andreasgal.com/category/research/'>Research</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/andreasgal.wordpress.com/120/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/andreasgal.wordpress.com/120/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/andreasgal.wordpress.com/120/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/andreasgal.wordpress.com/120/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/andreasgal.wordpress.com/120/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/andreasgal.wordpress.com/120/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/andreasgal.wordpress.com/120/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/andreasgal.wordpress.com/120/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/andreasgal.wordpress.com/120/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/andreasgal.wordpress.com/120/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/andreasgal.wordpress.com/120/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/andreasgal.wordpress.com/120/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/andreasgal.wordpress.com/120/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/andreasgal.wordpress.com/120/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=120&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://andreasgal.com/2010/09/17/narcissuszaphod-javascript-vm-for-firefox-4/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/dc614466f1a6d8f9c0e7a868bda77196?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96" medium="image">
			<media:title type="html">andreasgal</media:title>
		</media:content>

		<media:content url="http://andreasgal.files.wordpress.com/2010/09/zaphod-beeblebrox-001.jpg?w=300" medium="image">
			<media:title type="html">Zaphod-Beeblebrox-001</media:title>
		</media:content>
	</item>
		<item>
		<title>TraceMonkey vs V8</title>
		<link>http://andreasgal.com/2008/09/03/tracemonkey-vs-v8/</link>
		<comments>http://andreasgal.com/2008/09/03/tracemonkey-vs-v8/#comments</comments>
		<pubDate>Wed, 03 Sep 2008 09:09:00 +0000</pubDate>
		<dc:creator>Andreas</dc:creator>
				<category><![CDATA[Trace Compilation]]></category>

		<guid isPermaLink="false">http://andreasgal.wordpress.com/?p=109</guid>
		<description><![CDATA[Update: I got a lot of comments on my post. I am trying to answer them as they come in, so check back after you leave a comment. Brendan Eich and Mike Shaver have posted an update on our progress &#8230; <a href="http://andreasgal.com/2008/09/03/tracemonkey-vs-v8/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=109&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>Update: <em>I got a lot of comments on my post. I am trying to answer them as they come in, so check back after you leave a comment.</em></p>
<p><a href="http://weblogs.mozillazine.org/roadmap/" target="_self">Brendan Eich</a> and <a href="http://shaver.off.net/diary/" target="_self">Mike Shaver</a> have posted an update on our progress on TraceMonkey. There has been a lot of buzz around Google&#8217;s new Chrome browsers and its V8 JavaScript VM. Some voices have claimed that V8 is several times faster than TraceMonkey. We did some head to head comparisons and these claims don&#8217;t match our observations.</p>
<p><img class="aligncenter" src="http://weblogs.mozillazine.org/roadmap/tm-v8-sunspider-totals.png" alt="" width="624" height="530" /></p>
<p>We used Apple&#8217;s SunSpider benchmarks for our tests. Depending on the OS and machine configuration we are 1.18x to 1.28x faster than V8. Since V8 is only available for Windows, we didn&#8217;t perform any tests on MacOSX and Linux, both of which we support already. Our latest builds also work on ARM, by the way.</p>
<p>I am sure you can derive different results by tweaking the benchmarks or designing entirely new custom benchmarks alltogether, but since SunSpider has been used fairly intensively in the past two years to measure the evolution of JavaScript performance in Safari, Firefox, Opera, and IE, I think SunSpider is probably the most reliable cross-platform benchmarking tool at this point (which doesn&#8217;t say that its a particularly good one, its just the best we have right now.)</p>
<p>Talking about IE, our tests also indicate that we are about 15 times faster than IE 7, and about 5 times faster than IE 8 beta on the SunSpider aggregate scores.</p>
<p>If you want to give TraceMonkey a try, take a look at our <a href="http://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/latest-trunk/" target="_self">nightly builds</a>. You can enable the JIT in the about:config <a href="http://ejohn.org/blog/tracemonkey/" target="_self">settings</a>. The nightly builds are certainly not ready yet for wide-spread use, but we have improved stability significantly since our initial preview release. Firefox with TraceMonkey enabled is now my default browser, and I am writing this post with it.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/andreasgal.wordpress.com/109/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/andreasgal.wordpress.com/109/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/andreasgal.wordpress.com/109/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/andreasgal.wordpress.com/109/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/andreasgal.wordpress.com/109/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/andreasgal.wordpress.com/109/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/andreasgal.wordpress.com/109/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/andreasgal.wordpress.com/109/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/andreasgal.wordpress.com/109/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/andreasgal.wordpress.com/109/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/andreasgal.wordpress.com/109/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/andreasgal.wordpress.com/109/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/andreasgal.wordpress.com/109/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/andreasgal.wordpress.com/109/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/andreasgal.wordpress.com/109/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/andreasgal.wordpress.com/109/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=andreasgal.com&#038;blog=891661&#038;post=109&#038;subd=andreasgal&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://andreasgal.com/2008/09/03/tracemonkey-vs-v8/feed/</wfw:commentRss>
		<slash:comments>40</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/dc614466f1a6d8f9c0e7a868bda77196?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96" medium="image">
			<media:title type="html">andreasgal</media:title>
		</media:content>

		<media:content url="http://weblogs.mozillazine.org/roadmap/tm-v8-sunspider-totals.png" medium="image" />
	</item>
	</channel>
</rss>
