SvgItem: hold one texture for one picture, like FrameSvgItem does
SvgItem uploaded its own texture straight from the window, so every item drawing the same element at the same size uploaded the same picture again and took an atlas entry of its own. Counted with texture accounting over one plasmashell session, widgets/arrows down-arrow was uploaded 69 times for 4 distinct sizes, 60 of them the very same 25x25, and not one was served from a cache. A FrameSvgItem in the same session was served 88 of 90 requests.
FrameSvgItem has gone through ImageTexturesCache since it was written, which keys on the image and the window. KSvg hands back the same image for the same request, so the same key comes out and one texture serves every item drawing that picture.
The cache is now shared between the two rather than living in framesvgitem.cpp, and it takes a lock: an item asks from the render thread of its own window, and a window has its own, so with a second caller the hash is reached from several threads at once.