I know I read a very specific blog post about when Google technnically considers the page to be "loaded" and what events can occur after that - but I've tried a good bit and I just can't find it now.
I'm pretty sure it's when the onload event fires - and that further JS methods that are fired BY the onload event are not counted. There are pages that wait as much as 30 seconds to pop up a poll or something like that, and I'm pretty sure those don't get counted as part of the rendering time.
However, most if not all adservers are called before the onload event, so those times definitely drag you down.
I'm going to keep looking for that official reference, however - it will mean a lot to have that on hand.