Closed Bug 558773 Opened 13 years ago Closed 13 years ago
Reduce virtual calls during event dispatch
nsIEventListenerManager::HandleEvent can be moved to nsEventListenerManager, since the only one who should call it is nsEventDispatcher/nsEventTargetChainItem. And by inlining some of the HandleEvent we can speed up the code even more. The inlining part is basically saying: "we know we're not going to handle the event, return as early as possible" Code size shouldn't change much, because there is only one HandleEvent caller. I could try to inline the whole method, but atm that doesn't seem practical. In many cases this all seems to give 4% speed up in event *dispatching*, but in pathological cases, like http://mozilla.pettay.fi/moztests/events/event_speed_4.html , it is closer to 10%.
Attachment #438467 - Flags: review?(jst)
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.