GNOME Bugzilla – Bug 367869
All operation class_init() routines are called once per node.
Last modified: 2006-11-01 23:16:02 UTC
While tracking down an issue in the svg-load operation I noticed that its class_init() routine was being called multiple times while processing XML files. This was seen while doing a make in the gallery even though the svg-load operation wasn't used in most of the XML files. The number of times the routine is being called while processing an XML file seems to relate to the number of nodes listed in the XML file.
g_type_from_op_class in gegl/gegl-node.c which probably should be renamed to have the proper prefix. Shoudl be changed to cache the first traversal of the type tree in a static GSlist, which is used for both the first and subsequent lookups, thus avoiding instantiating the class structure for every registered operation every time a type is set.
Using a GHashTable made more sense. Fixed in CVS.