Test Build: Asynchronous location bar
58 posts
• Page 1 of 4 • 1, 2, 3, 4
Hey all,
A few months ago I decided to try to use the asynchronous storage API that was added in Firefox 3.1 to help reduce the pain of disk IO on the main thread. Sadly, it became quite apparent that this was going to be too big of a change and need to much work to make it into 3.1, so I put off doing any more work on it. However, this week I started working on the patch again, updating it to work with the changes to the location bar and the storage back-end. Today I finally got it passing all of our existing tests (although, I know of at least one condition where it fails and is untested). Now that it's passing all tests, I feel comfortable posting a test build for folks to try and see if it helps or not. I should note that the current implementation is pretty dumb and doesn't take many opportunities speed up results. Additionally, there are some other performance wins that are on my mind that become a lot easier to do with this newer implementation. Admittedly, I haven't benchmarked this yet, so I don't know how it compares to the existing code. During causal use, however, it feels no slower than the existing implementation, but I don't usually have issues with it. The goal here is to help out those who do have performance issues with the location bar. In fact, that's exactly the feedback I'm looking to get. So, if you are feeling ambitious and willing to live on the wild side for a bit, I'd like you try this test build. After a little bit of use, let me know if you think the results are faster, slower, or about the same. Note: this is build off of mozilla-central, so it's like a 3.2a1pre build. Your feedback is greatly appreciated! Last edited by sdwilsh on February 21st, 2009, 11:04 pm, edited 3 times in total.
Problem Solver
Thanks for the test build, using it now. I never had a performance problem with locationbar* but all speed improvements are good.
Can you point us to the bug# which this fixes? Also, can you say what kind of storage operations are now moved off the main thread - populating the awesomebar, updating history after visiting a site, both, something else? * hard limit history of 15 days does wonders for speed; imho bug 425219 should be just fixed - firefox is sacrificing a lot of speed for a fuzzy idea of "randomly retaining stuff even when not needed or expected, under a condition that retained stuff can be deleted at random" and it should just stop doing that (imho of course).
I think expiration simplification is one of the targets for 3.2, still we need a finalized plan for that. That said, i don't think hard limiting history will be a perf win as we expect it to be, our queries are not so slow, often the code the manages results can be slower than the query itself. We have people running with 999 days of history with very limited perf problems, that we are trying to solve, so hard limiting to a small value (15 days for example) will bring no real benefit, but cause loss of functionality. If people increases the history expiration limits is because they need more data, not less. Personally i use a lot the awesomebar with bugzilla entries, and i can find bugs losing the minor time possible, and that's because i've visited those bugs, many many days ago. Btw, notice we don't retain random stuff, nor delete it randomly ![]() Hey sdwilsh I just had a deadlock.
I was browsing a random page and clicked on a link while a page was still loading, and browser froze. CPU usage was zero. I tried activating a debugger and all threads were idling in ntdll.dll. Of course I have no way of knowing if your patch is responsible, I didn't even have symbols (are there symbols for tryserver builds?) but I haven't seen such freeze since forever.
Oh I don't advocate limiting the history below its current 90 days. It's fine. I do, however, advocate not keeping it *above* 90 days, particularly without user's knowledge and control. Notice that current situation is a useless-UI problem: the history setting available under options is a "what is guaranteed" setting only (not "what browser does" setting), and for vast majority of users (who don't hit the 40k limit) changing it is a no-op. Particularly lowering it.
Sure, more data is more work in general. Size of the places.sqlite file mostly has effect on roaming (networked) profiles. Still, you can't make database contain twice as many items (180 days actual expiration vs 90 days as per user setting) and expect it to have no effect ![]()
Well, very few things in computing world is random ![]() ![]() With the tryserver build and my 50MB places.sqlite file with 1yr of history I can't say I noticed a difference in speed one way or the other on my ancient AthlonXP2400.
bug 455555 I'll probably blog about all the changes we've done with places on threading for 3.1, but I'll keep it out of here for now to try and keep this thread on topic. This particular change doesn't introduce a whole lot of threading (this is partly why it's a dumb implementation). It only reads data from the disk asynchronously, but the filtering is still done on the main thread. The next step is to evaluate different ways of filtering off of the main thread and see how that impacts performance. Problem Solver
Deadlock and not a crash, right? Sadly, try server builds do not have symbols, so can't really figured it out. I've had at least two reports of a crash though, but those look like they are the result of the image cache, and shouldn't have anything to do with my changes. Problem Solver
With this initial implementation, that's exactly what I am looking for. This is just the first step to make the code easier to modify. Problem Solver
New build can be found here (updated first post as well):
https://build.mozilla.org/tryserver-bui ... 328a1c0aa/ Problem Solver
For those who want to compare speeds between trunk and these async builds, copy/paste the following code into Error Console. It'll open a new page that looks like the chunk of text after the code block..
It shows the minimum, average, maximum of 5 times to get the first result and the finish time for a given query. The numbers aren't useful by themselves, but if you pair them with the numbers you get for Firefox 3, Firefox 3.1, trunk, async builds, that'll be interesting data. Like the above data is trunk vs the following is Firefox 3
(The async builds don't work for me...) I should note that I'm getting reports that the async builds don't work for some people. I'm not sure what's up with that, but I hope to look into it next week.
Problem Solver
New build out here:
https://build.mozilla.org/tryserver-bui ... 58fef1cb9/ This runs for me (I hadn't tried try-server builds in the past but my local build worked). Hopefully this works out better for folks who were having issues. Minor fixes to the algorithm for correctness. Problem Solver
Hi, for me this build doesn't show any urlbar autocomplete popup at all. Also in safe mode. No errors in error console. I'll try a windows build at the office on Monday. Sadly, I can't debug this from home right now.
Problem Solver
58 posts
Page 1 of 4 • 1, 2, 3, 4
Who is onlineUsers browsing this forum: No registered users and 1 guest |
![]() |