<?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/"
	>

<channel>
	<title>~robcee/ &#187; performance</title>
	<atom:link href="http://antennasoft.net/robcee/tag/performance/feed/" rel="self" type="application/rss+xml" />
	<link>http://antennasoft.net/robcee</link>
	<description>more than just sandwiches</description>
	<lastBuildDate>Mon, 19 Jul 2010 17:44:36 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Mac Optimized Builds of Firefox</title>
		<link>http://antennasoft.net/robcee/2010/02/01/mac-optimized-builds-of-firefox/</link>
		<comments>http://antennasoft.net/robcee/2010/02/01/mac-optimized-builds-of-firefox/#comments</comments>
		<pubDate>Mon, 01 Feb 2010 15:29:57 +0000</pubDate>
		<dc:creator>robcee</dc:creator>
				<category><![CDATA[Build]]></category>
		<category><![CDATA[Firefox]]></category>
		<category><![CDATA[Mozilla]]></category>
		<category><![CDATA[buld]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[osx]]></category>
		<category><![CDATA[performance]]></category>
		<category><![CDATA[pgo]]></category>

		<guid isPermaLink="false">http://antennasoft.net/robcee/?p=402</guid>
		<description><![CDATA[A couple of weeks ago I came across a reference to Mac Optimized Builds of Firefox. There&#8217;s a long tradition of community-based builds of Firefox for the Mac dating back to the PowerPC days.
A lot&#8217;s changed since those dark days, however. To say that we spend a lot of energy doing performance analysis is a [...]]]></description>
			<content:encoded><![CDATA[<p>A couple of weeks ago I came across a reference to <a href="http://www.latko.org/downloads/" target="_blank">Mac Optimized Builds</a> of Firefox. There&#8217;s a long tradition of community-based builds of Firefox for the Mac dating back to the PowerPC days.</p>
<p>A lot&#8217;s changed since those dark days, however. To say that we spend a lot of energy doing performance analysis is a bit of an understatement. We have entire teams dedicated to improving performance. Build options are analyzed and re-analyzed in an attempt to find cheap performance improvements. Specifying global code optimization settings can actually have an adverse effect on overall system performance because certain modules react better to, say, -O2 versus -O3, for example. All code that gets checked in has to make it through our <a href="http://graphs.mozilla.org/" target="_blank">performance tracking system</a> or it gets backed out.</p>
<p>In the interest of Science, I wanted to actually see if there were any differences, so I pulled a fresh copy of mozilla-central and applied the referenced .mozconfig.</p>
<p>The first thing I noticed, was that &#8211;enable-profile-guided-optimization didn&#8217;t seem to be doing what I thought it would. Namely, I expected to see a browser window popup and run through some automation before starting a second compilation phase. It didn&#8217;t. Even so, the resultant build did feel a little faster at opening windows and tabs<a href="#asterisk-perf">*</a>.</p>
<p>So, I applied the latest stand-alone <a href="https://wiki.mozilla.org/StandaloneTalos" target="_blank">version</a> of Talos to the build and executed the Ts (startup) and Twinopen (Window open) tests and compared this with the most-recent Mozilla <a href="http://nightly.mozilla.org" target="_blank">nightly</a> build of Minefield. Surprisingly, the windows didn&#8217;t appear to be opening much faster, but the startup time was on average 5% faster in the new &#8220;optimized&#8221; build vs. moz-central nightlies.</p>
<p>By this time, Ted had <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=542095#c9" target="_blank">commented</a> in the bug tracking all this and pointed me to the PGO <a href="https://developer.mozilla.org/En/Building_with_Profile-Guided_Optimization" target="_blank">page</a> on MDC. It turns out, PGO builds require a separate make target &#8220;profiledbuild&#8221; instead of &#8220;build&#8221;. I reran the build, saw the automation was working this time and then reran the Talos tests. No change. Best guess around these parts is that GCC just isn&#8217;t very good at doing PGO. The same option gives us an across-the-board 10% speedup to all our tests on Windows.</p>
<p>It turned out that the option that was giving us the 5% startup time (and likely a slight boost to tab performance) was the 10.6 SDK target. Each revision of OS X includes optimizations and Snow Leopard is no different. If you want your own optimized build, just put that target (&#8211;with-macos-sdk=/Developer/SDKs/MacOSX10.6.sdk) in there if you&#8217;re on Snow Leopard and you&#8217;ll get a little extra snappy.</p>
<p>I haven&#8217;t booted into the 64 bit kernel to see if there&#8217;s any difference there, or even if the build options produce a 64 bit build. I don&#8217;t believe they do and the version shipped on the above optimized builds page don&#8217;t have the tell-tale &#8220;Open in 32 bit mode&#8221; checkbox in the app&#8217;s &#8220;Get Info&#8221; dialog.</p>
<p><small><a name="asterisk-perf">*</a> A word about perceived performance differences: It&#8217;s very hard to tell  the difference between, say, 20ms and 30ms. That&#8217;s a 50% slow-down  compared to 20ms but the actual slices of time are so small that the  human brain has a hard time picking up on them. Nevertheless, people  used to dealing with high-velocity timings (musicians, gamers, fighter  pilots) can actually detect that kind of change. But there&#8217;s also a  &#8220;wishful thinking&#8221; factor. It&#8217;s very easy to be told you&#8217;re going to see a speedup, and when given an identical application, think you&#8217;re seeing something faster. &#8220;It just feels snappier&#8221; you might say when given  this placebo.</small></p>
]]></content:encoded>
			<wfw:commentRss>http://antennasoft.net/robcee/2010/02/01/mac-optimized-builds-of-firefox/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Firebug and the JIT</title>
		<link>http://antennasoft.net/robcee/2009/12/15/firebug-and-the-jit/</link>
		<comments>http://antennasoft.net/robcee/2009/12/15/firebug-and-the-jit/#comments</comments>
		<pubDate>Tue, 15 Dec 2009 20:19:29 +0000</pubDate>
		<dc:creator>robcee</dc:creator>
				<category><![CDATA[Firebug]]></category>
		<category><![CDATA[Mozilla]]></category>
		<category><![CDATA[Firefox]]></category>
		<category><![CDATA[jit]]></category>
		<category><![CDATA[performance]]></category>

		<guid isPermaLink="false">http://antennasoft.net/robcee/?p=377</guid>
		<description><![CDATA[One thing we hear a lot from Firebug users is that Firebug slows down Firefox. When Firebug is active, particularly when you&#8217;ve enabled the Console/Script panels, some pages perform much more slowly. Enabling these panels turns on all of our debugging hooks, so some slowdown isn&#8217;t surprising, but what may surprise you is that, in [...]]]></description>
			<content:encoded><![CDATA[<p>One thing we hear a lot from Firebug users is that Firebug slows down Firefox. When Firebug is active, particularly when you&#8217;ve enabled the Console/Script panels, some pages perform much more slowly. Enabling these panels turns on all of our debugging hooks, so some slowdown isn&#8217;t surprising, but what may surprise you is that, in order to get accurate debugging information, these hooks also turn off Firefox&#8217; high-performance Javascript JIT compiler, even when Firebug is inactive. And now we have a fix for that.</p>
<p>First, a little terminology. Feel free to skip this paragraph if you consider yourself a master of Javascript internals or compiler run-time optimization makes your skin crawl. <a target="_blank" href="https://developer.mozilla.org/en/spidermonkey/internals/tracing_jit">Tracing</a> is the mechanism Firefox&#8217; Javascript engine (aka, &#8220;SpiderMonkey&#8221;) uses to improve code execution performance. It provides a major speedup for code running in Firefox 3.5 and up, often an order of magnitude for certain types of operations. It is the basis of the JIT or <a target="_blank" href="http://en.wikipedia.org/wiki/Just-in-time_compilation">Just-in-Time compiler</a>. Without tracing, the JS engine can&#8217;t optimize code as well, leading to significantly slower execution.</p>
<p>I need to be clear here: <b>If you have Firebug installed you are  probably not getting fast Javascript.</b> Firebug doesn&#8217;t have to be  active on your current page. If you have the grey icon on your status  bar, you have probably disabled the JIT. This is true if you have ever  enabled the Console and consequently the Script panels and left them on. This is likely true for most recent versions of Firebug. The quick fix  is to disable the Script and Console panels via the mini menu on their  respective tabs.</p>
<div style="text-align: center;"><img style="max-width: 800px;" src="http://antennasoft.net/robcee/wp-content/uploads/2009/12/fb-disabled-script.png" /></div>
<p>Boris Zbarsky has been doing a lot of poking around in the belly of the JS debugger lately. Working in conjunction with John Barton, they have concocted fixes for the soon-to-be-released Firebug 1.5 and Firefox 3.6. We&#8217;re working to get testable versions out as quickly as possible, but I can say that I&#8217;ve tested development builds using the pages mentioned <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=534120#c33">in the bug</a> and can verify that these fix the problem. As a side-benefit, I got to watch Boris dissect the problem through gdb  in an Xterm (yes, an Xterm) and Emacs and it was pretty impressive and  fun, to boot.</p>
<p>When installing Firebug one of the first things most people do is enable the Console. It&#8217;s such a useful debugging tool. I myself have been using Firebug for over a year without JITted code. I probably never noticed the slowdown simply because I&#8217;m so used to running my browser this way and have pretty fast machines. After disabling the Console and Script panels there are a few pages that just load much much quicker. It&#8217;s kind of shocking.</p>
<p>Since the patch has landed on Firefox 3.6, I&#8217;m expecting either a beta or release candidate of that to come out shortly. I&#8217;m also hoping for another Firebug beta (or release candidate) later this week. In the meantime, if you&#8217;re not using them, I recommend disabling the Console and Script panels and find out what you&#8217;ve been missing and turn them on only as-needed. This will likely be the work-around for Firefox 3.5 users unless we decide to push this back to that branch but I have my doubts that this is something we would do.</p>
]]></content:encoded>
			<wfw:commentRss>http://antennasoft.net/robcee/2009/12/15/firebug-and-the-jit/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
		<item>
		<title>Velocity 09</title>
		<link>http://antennasoft.net/robcee/2009/06/29/velocity-09/</link>
		<comments>http://antennasoft.net/robcee/2009/06/29/velocity-09/#comments</comments>
		<pubDate>Mon, 29 Jun 2009 13:32:57 +0000</pubDate>
		<dc:creator>robcee</dc:creator>
				<category><![CDATA[Mozilla]]></category>
		<category><![CDATA[Web]]></category>
		<category><![CDATA[conference]]></category>
		<category><![CDATA[performance]]></category>
		<category><![CDATA[velocity]]></category>

		<guid isPermaLink="false">http://antennasoft.net/robcee/2009/06/29/velocity-09/</guid>
		<description><![CDATA[Last week Honza and I went to San Jose, CA for Velocity 09 to hang out and take in some of the excellent presentations taking place there.
I can say without hyperbole that this was the best conference I&#8217;ve attended. The presentations were from people doing real large-scale web development and included a fair amount of [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.flickr.com/photos/robceemoz/3655824014/" title="grainy steve by robceemoz, on Flickr"><img src="http://farm4.static.flickr.com/3417/3655824014_e29fcfb34c_m.jpg" alt="grainy steve" align="right" width="240" height="180" /></a>Last week <a target="_blank" href="http://www.softwareishard.com/blog/index.php">Honza</a> and I went to San Jose, CA for <a target="_blank" href="http://en.oreilly.com/velocity2009">Velocity 09</a> to hang out and take in some of the excellent presentations taking place there.</p>
<p>I can say without hyperbole that this was the best conference I&#8217;ve attended. The presentations were from people doing real large-scale web development and included a fair amount of real data and some of their solutions to hard problems.</p>
<p>One of the highlights was John Adams of Twitter talking about the engineering challenges they&#8217;ve encountered keeping your tweets flowing. They&#8217;ve rewritten intensive chunks of code in C. They&#8217;ve implemented their own queue system (called Kestrel which has an API very similar to memcached). They use Google Analytics to monitor the frequency of the Fail Whale. You can see the whole presentation <a target="_blank" href="http://en.oreilly.com/velocity2009/public/schedule/detail/7479">here</a>, on video.</p>
<p>Other speakers I enjoyed seeing included Marissa Mayer of Google, Nicholas Zakas of Yahoo on JavaScript performance tuning and the mighty Steve Souders (pictured above) talking about Even Faster Websites. I liked his presentation so much, I bought the book!</p>
<p>Some of the take-aways from the conference were: Instrument Everything. Analyze your performance constantly. Employ phased roll-outs and measure user reactions to changes.</p>
<p>I was surprised to learn that changes in website responsiveness sometimes as little as 50ms could incur changes to pageviews or searches, directly impacting revenue. Anyone whose ever played Rockband or, gosh, a real guitar or set of drums can tell you that 50ms is very noticeable and at the outer-limit of responsiveness (not to mention can make your music sound imprecise). Humans are capable of detecting latency well below that number, but the surprising thing is that we humans are now expecting this level of performance from our websites.</p>
<p>You can see a <a target="_blank" href="http://galbraiths.org/feedback.html">simple visual demonstration</a> of this with Ben Galbraiths&#8217; feedback demo, presented by Ben and Dion Almaer in their <a target="_blank" href="http://en.oreilly.com/velocity2009/public/schedule/detail/9430">On Responsiveness</a> session.</p>
<p>I don&#8217;t think it&#8217;s something we would consciously think about when using a site, though it would likely form some sort of nebulous impression upon us. Using a search engine that didn&#8217;t post any response for 50ms or worse would probably make us think, &#8220;this thing&#8217;s slow&#8221; or &#8220;I&#8217;m not getting any results&#8221;. Those delays add up over time. As users know there&#8217;s going to be a delay, they might start a search and flip to another application or browser tab. As soon as that happens, the user&#8217;s attention is lost and may not return.</p>
<p>What I find really interesting about this, is that people are now treating websites with the same levels of performance expectations that they have with video games and desktop applications. Website performance is more important than ever, so if you&#8217;re creating or maintaining a website, keep that in mind.</p>
<p>Too much content, not enough blog. I&#8217;ll try to talk about some of the other cool things I saw later this week.</p>
]]></content:encoded>
			<wfw:commentRss>http://antennasoft.net/robcee/2009/06/29/velocity-09/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Firebug Performance By The Numbers</title>
		<link>http://antennasoft.net/robcee/2008/09/19/firebug-performance-by-the-numbers/</link>
		<comments>http://antennasoft.net/robcee/2008/09/19/firebug-performance-by-the-numbers/#comments</comments>
		<pubDate>Fri, 19 Sep 2008 19:16:55 +0000</pubDate>
		<dc:creator>robcee</dc:creator>
				<category><![CDATA[Firebug]]></category>
		<category><![CDATA[Mozilla]]></category>
		<category><![CDATA[performance]]></category>
		<category><![CDATA[Testing]]></category>

		<guid isPermaLink="false">http://antennasoft.net/robcee/2008/09/19/firebug-performance-by-the-numbers/</guid>
		<description><![CDATA[One of the goals we had recently was to get some idea of the performance characteristics of Firebug in its various operating states within Firefox. I spent some time a couple of weeks ago running some performance tests in Dromaeo and Talos and came up with some interesting numbers and graphs. Rather than rehash the [...]]]></description>
			<content:encoded><![CDATA[<p>One of the goals we had recently was to get some idea of the performance characteristics of Firebug in its various operating states within Firefox. I spent some time a couple of weeks ago running some performance tests in <a target="_blank" href="http://dromaeo.com/">Dromaeo</a> and <a target="_blank" href="https://wiki.mozilla.org/StandaloneTalos">Talos</a> and came up with some interesting numbers and graphs. Rather than rehash the entire thing here, I&#8217;ll link to the relevant analysis docs here for perusal: Dromaeo <a target="_blank" href="https://wiki.mozilla.org/User:Rcampbell/Firebug_performance">results</a>, Talos <a target="_blank" href="https://wiki.mozilla.org/User:Rcampbell/Firebug_Talos">results</a>.</p>
<p>What became pretty clear was that there was only a very negligible performance hit for having Firebug installed. Better yet, it&#8217;s quite performant even with the Firebug console enabled, meaning you can keep Firebug on your default profile without worrying about impacting your regular browsing.</p>
<p><a href="http://www.flickr.com/photos/robceemoz/2871045156/" title="Firebug_1.2_Tp by robceemoz, on Flickr"><img src="http://farm4.static.flickr.com/3076/2871045156_5669d27014.jpg" alt="Firebug_1.2_Tp" height="373" width="500" /></a><br />
<br/><br />
Memory performance was similar and even with the script debugger enabled, memory usage peaked and levelled off indicating that there were no real leaks visible, even though pages took noticeably longer to load.</p>
<p><a href="http://www.flickr.com/photos/robceemoz/2871045218/" title="Firebug_1.2_Tp_RSS by robceemoz, on Flickr"><img src="http://farm4.static.flickr.com/3073/2871045218_26117b039c.jpg" alt="Firebug_1.2_Tp_RSS" height="375" width="500" /></a><br />
<br/></p>
<p>This isn&#8217;t to say that we&#8217;re sitting idly on our hands congratulating everyone on a job well-done. John Barton noticed a particular JavaScript test that was noticeably slower than it&#8217;s neighbors and it jogged his memory about some testing he&#8217;d done earlier in the 1.2 development cycle. This should translate into improved eval script performance in 1.3 and future versions of Firebug.</p>
<p>I&#8217;m looking forward to revisiting these benchmarks down the line to track our improvements.</p>
]]></content:encoded>
			<wfw:commentRss>http://antennasoft.net/robcee/2008/09/19/firebug-performance-by-the-numbers/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
