[cairo] hash table issues

"Karl Tomlinson"cairo at karlt.net "Karl Tomlinson"cairo at karlt.net
Mon Oct 27 15:16:47 PDT 2008


I'm seeing too much time spent in
_cairo_hash_table_lookup_internal and *keys_equal functions.

The problem develops in tables that have close to constant size,
then the worst hit is on entry look-ups that are not found.  This
situation is produced with scaled glyph caches and is taking an
unnecessary 5% of time during Firefox web page loads on Linux.

A suggested fix for this is in

  "_cairo_hash_table_lookup_internal is O(n) slower than it should be"
  https://bugs.freedesktop.org/show_bug.cgi?id=17399

and either or both of the patches in the following bugs would also
provide an improvement in behavior.

  "don't fill hash tables with dead entries as fast as possible"
  https://bugs.freedesktop.org/show_bug.cgi?id=18166

  "_cairo_hash_table_insert can pass key_unique = TRUE to
   _cairo_hash_table_lookup_internal"
  https://bugs.freedesktop.org/show_bug.cgi?id=18165


More information about the cairo mailing list