Re: A tale of waiting



On Tue, 2009-06-23 at 22:16 +0200, Benjamin Otte wrote:
> I have been on a quest to improve performance of the file chooser
> lately. This post is about this process: what I measured, what I
> learned and what I patched.
<snip>
>  * Getting the mime type
> Getting the mime type for a file requires opening the file and
> checking the first bytes against the known patterns for files. Both
> operations take time. The mime type also is usually not required.

It will only open the file if the suffix of the file can't be used,
please read the shared-mime-info spec.
<snip>
>  * Fix the usage of a filter on the mime type. Currently we don't
> query the mime type (it requires file sniffing after all), so we never
> get matches.

As above.

In majority of cases it should be a string match.
<snip>
> And now the obvious question: Should I just merge it to master when
> I'm done with the regressions?

Personally, I'd rather see the changes merged incrementally, rather than
a wholesale rewrite going in. Makes it much easier to pinpoint what
broke the file chooser (as is likely to happen, it's not like software
is ever bug-free).

Cheers



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]