29
Aug 12

DXR now does live regexp search, thanks Google Code

Google code was once the best code-search tool in the business. Then it got shut down, except for a few special instances like chromium.

Our intern, Jonas Finnemann Jensen, took the re2 code that used to power google code search and integrated it into DXR (among other cleanups). See his blog post for more details.

Regexps combined with the new instant search feature changed how I search Mozilla code. Instant search means that I’m constantly refining my search terms to narrow down my results to a minimum before I leave the search page. Digging through Mozilla code is pretty fun now. I believe our development instance* of DXR is the most pleasant./efficient (even if a bit rough) code indexing solution atm. I no longer miss google code for searching Mozilla.

Now that Mozilla can be searched in a pleasant way, something needs to fill the searching of masses of open source code usecase. Perhaps github could plug the “google code”-sized gap in developer hearts?

 

* we also need to stabilize the development version and move it to dxr.mozilla.org.


23
Aug 12

Snappy #37

Highlights from meeting notes for today:

  • Tim Taubert worked on Firefox UI speedups
  • Lots of improvements to the profiler from Benoit Girard
  • More incremental GC work from Jon Coppeard
  • Vladan Djeric got all of the security reviews and should be able to land Nicholas Chaim’s fix for networked certificate validation: bug 726125

We spent most of the meeting discussing bug bug 784512. According several data sources Firefox 15 Beta loads pages slower than 14. Occasionally problems squeeze past our performance testing + telemetry infrastructure, this looks like one of these times. Unfortunately, it’s quite hard to reduce a few noisy signals to a concrete performance problem. If you can reproduce a performance regression to do with loading webpages/games/etc in FF15 vs FF14, please leave a comment.

Thanks!

Thanks for the great comments on my previous snappy updates. Bug 783755 should take care of the new cache size pref not sticking. Bug 718910 on hiding Cache directory from Spotlight is making progress too.

Commenter, kumalos, reported a tab switching regression and posted a profile recorded with our profiler as evidence. This proved to be an example of bug 783748, and lead us to identify a previously unknown issue in bug 784756. Constructive feedback like this is one of the main reasons I blog.

I highly encourage users interested in improving Firefox performance to use Nightly builds and report bugs with profiler traces attached.

Shutdown Times

I’ll end with our latest Telemetry data point. This one took a while to get right, but we finally track our shutdown speed.


16
Aug 12

TriLite, Fast String Matching in Sqlite

One of the limitations of the SQLite FTS is that it can’t do regular expression or substring searches. Jonas is addressing this with TriLite. Be sure to subscribe to Jonas’ blog for exciting DXR developments coming up within the final two weeks of his internship.

 

Coming to our test DXR instance soon…


16
Aug 12

Snappy #36

Misc

I have been using dates to mark passage of time in the Snappy project. I think I’ll switch to a simple counter instead. We are ~36 updates into this project.

Blogging

Ludovic Hirlimann blogged about how spotlight spends a lot of time indexing the Firefox network ‘Cache’ directory (known problem, bug 718910). If you experience this problem and would like to see it fixed, please comment in the bug if the suggested remedy helps.

Tim Taubert wrote about reducing new-tab jank. I mention Tim a lot in these updates. He takes on a lot of interesting bugs in Firefox frontend. Hopefully he’ll make a habit out of blogging about his work.

Networking

Nick Hurley landed a change to reduce our maximum cache size to 350 megabytes. In order to avoid excessive disk IO traffic old cache size of 1 gigabyte remains in effect until the cache is reset. See bug 709297 and Nick’s blog post for more details. Progress is also being made on bug 777328 so we can move towards not blowing away our cache 10-20% of the time.

Michal Novotny is proceeding with incrementally reducing cache-caused jank that’s due to holding a lock on the main thread while doing IO on a background thread. He also removing a multitude of synchronous necko APIs, see bug 695399.

Patrick McManus is removing synchronous proxy-related code, see bug 766973 for the DNS-related bit. Turns out our proxy code also does all kinds of synchronous operations when detecting proxy configuration, etc. This is being worked on, but hasn’t been filed yet.

I usually try to highlight work that has already landed, but in this case it is important to point out that the Necko team is working hard on addressing significant problems in the networking code. These problems are tricky and will take a while to fix. The team is relatively new and is still discovering hidden surprises in their codebase.

Profiler

Benoit Girard posted a preview of view-source in the profiler. This will be handy for figuring out where performance problems lay, especially in JS files that have been preprocessed (our JS preprocessor does not try to keep the line numbers sane).


15
Aug 12

DXR is back at dxr.mozilla.org

For a while DXR lived on a lanedo.com server. Lanedo folks are now done with DXR development. DXR is once again deployed at dxr.mozilla.org. Our Perf intern, Jonas, is driving DXR development this summer. See his progress report. Be sure to subscribe to his blog. He may change how you use DXR as a result of his current work.

PS. Mozilla interns rule


14
Aug 12

Snappy for Aug 9

Lawrence took excellent Snappy meeting notes last week.

 


06
Aug 12

Snappy, Aug 2

Landed This Week

Neil Deakin joined the Snappy effort. He is working on eliminating pointless reflows in the tab strip. His fix for bug 752486 landed, 752376, 752496 are next.

Brian Bondy landed removal of our prefetch-nuking code in bug 770911. xul.dll preload is now always on based on our telemetry startup study in bug 765850.

Bill McCloskey landed the following improvements to reduce garbage collection pauses:

  • bug 777919 - Free LifoAlloc chunks on background thread, instead of as part of the final IGC slice. This isn’t a problem for most people, but for some people on OSX it can take anywhere from 50ms to 250ms or more.
  • bug 778993 - Separate runtime’s gcMallocBytes from compartment’s gcMallocBytes, so we trigger less non-incremental GCs with many tabs open
  • bug 767209 - Make GC slices longer when not painting to avoid non-incremental GCs.

See Bill’s comments in bug 767209 for some insight into the complex heuristics that go into minimizing GC interruptions: comment 1, comment 2.

Coming Soon

In the coming week I expect to see some good optimizations land for page rendering, tab-switching behavior, more robust cache, etc.

Some Snappy people will be attending MozCamp.eu 2012 in Warsaw, Poland on September 8, 9. Expect to see lots of talk on profiling and other performance tools.

I hope to have above 15-20 Performance/Snappy people in Warsaw for the following week. This is not yet finalized. At the moment we are looking to see if there is a coworking space or a company in Warsaw who could host us.