Lags, Freezes, and RenderGeom

So for a long time I was having occasional whole-machine crashes in Second Life, where I’d get a Blue Screen of Death from Windows, blaming the video drivers for something, or the screen would go black and the machine unresponsive, or the machine would stop responding with the screen just frozen on whatever I was last seeing, or the machine would power down entirely.

Camming around too fast or too far from my AV seemed to increase the crashing, so I slowly got trained not to do that (although ordinarily camming all over the heck is one of my chief occupations).

There were a few days when the entire machine would lock up about half the time that I tried to start up the SL viewer, and the other half the time it would usually lock up or crash within an hour or so. That was horrible, and I was afraid I’d just have to give up SL entirely. Then it stopped doing that for no apparent reason, and as of 1.19 I’ve pretty much stopped having SL-related machine crashes entirely. The viewer itself crashes once in awhile, but not often, and it’s pretty quick to start up again.

Now I’m running 1.20, the former RC now actually Released, and things seem even better. FSP seems higher, and camming and zooming and so forth seem smoother. I’m back to camming all over the place, and I haven’t had any crashes at all yet on 1.20 (knock wood), although I expect that I will eventually. And I like some of the new 1.20 features (stretching images in the image previewer, clicking on names in chat and IM to bring up profiles, being able to be smug about how low my Avatar Rendering Cost is, etc, etc), and I haven’t found anything I really dislike. Yay!

There’s still one very annoying viewer behavior left, though. Sometimes at random (and I think more often when there are alot of AVs around, but I could be wrong about that) my fps (frames per second, the framerate) will drop from some normalish value to significantly less than one; that is, my view of SL will get updated less often than once per second! And it’s not only the view; because of the way the SL viewer is written, it means that it also won’t notice my keystrokes or mouse actions except every second or two (or three or…). Which makes it pretty much impossible to do anything, even chat!

If I turn off prim rendering (control shift alt 9, natch), things get fast again. On the other hand everyone is bald and all buildings and objects vanish. :) So I can chat again and stuff, but I can’t sit on things, and I tend to walk into walls.

My investigations so far reveal that pretty much invariably what’s happening is that the “RenderGeom” part of the viewer has gone insane, and started to eat up huge amounts of time. The figure there shows the timing graphs (control shift 2) during one of these “freezelag” times, both with and without prim rendering on. The top part of the graph is with prim rendering on and a horribly low FPS rate; note that almost the entirety of each horizontal bar is the grey color of RenderGeom. The bottom half is with prim rendering off and a high FPS; RenderGeom is still significant, but not like 95% of rendering time. The bottom part is also what the bars look like, roughly, when I have prim rendering on but I’m not freezelagging. (Note that the chart is in normalized mode, so each bar is the same size, even though the absolute scene rendering time is much much much higher in the top ones.)

Has anyone else experienced similar stuff? Have any clever suggestions? There’s a JIRA on the problem, and it has an internal Linden issue number, but it doesn’t seem to be getting alot of visible attention or work. If anyone has seen any other related JIRA (I did search for “RenderGeom”), a pointer to that would also be greatly appreciated.

Isn’t that all fascinating? :) In other news, I’ve been flying around and exploring and dancing and talking to people and writing scripts and stuff!