Closed Bug 1526716 Opened 5 years ago Closed 5 years ago

Fast path the adding nicks to the participants list when switching the selected conversation

Categories

(Thunderbird :: Instant Messaging, enhancement)

enhancement
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Thunderbird 67.0

People

(Reporter: florian, Assigned: florian)

References

Details

Attachments

(1 file)

On #developers (moznet) that has ~500 participants, it takes about 500ms to select the conversation and display the list of participants on my fast machine.

On #ubuntu (freenode) it takes more than 4s to display the ~1500 participants.

I explained in bug 1526285 why it takes so long. We should fix it in general, but for the specific case where we switch the selected conversation, we have the whole list of participants at once so we can add a fast path for this case to sort the participants before attempting to add anything in the DOM.

Profile before: https://perfht.ml/2SDXpiz

Profile after: https://perfht.ml/2SD73Ca

Both profiles are of the same operation: both #test and #ubuntu are already joined on freenode, #test was currently selected. I started the profiler, then selected #ubuntu, then back to #test and then #ubuntu again, and captured the profile.
In the "before" profile, it takes 4.1-4.4s to handle the "select" event when selecting the #ubuntu conversation. On the "after" profile, it takes 440-480ms instead.

Pushed by fqueze@mozilla.com:
https://hg.mozilla.org/comm-central/rev/852ae2446bee
Fast path the adding nicks to the participants list when switching the selected conversation, r=clokep.

Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 67.0
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: