Closed
Bug 595071
Opened 14 years ago
Closed 6 years ago
Optimize TimeDataOffset insertion when building buffered ranges for WebM
Categories
(Core :: Audio/Video: Playback, defect)
Tracking
()
RESOLVED
INACTIVE
People
(Reporter: kinetik, Unassigned)
References
Details
Attachments
(1 file)
10.43 KB,
patch
|
Details | Diff | Splinter Review |
Bug 570904 implements buffered ranges for WebM. With large files in cases where the file is buffering in slightly unusual ways, insertion of the TimeDataOffset entries becomes quite expensive due to array shuffling (see bug 570904 comment 12). This can be fixed by switching mTimeMapping over to an ordered tree. std::map would be perfect, if it's possible to use that.
Reporter | ||
Comment 1•14 years ago
|
||
This works, but I don't know if using std::map in Gecko is acceptable.
Repeating the test in bug 570904 comment 12 with this patch, no NotifyDataAvailable call took longer than 0.5ms except two, which took 1.5ms and 5ms. CalculateBufferedForRange is a bit slower (often taking 0.5 - 1ms per call), but I suspect most that time would disappear in an optimized build.
Reporter | ||
Comment 2•14 years ago
|
||
Also worth pointing out that the per-entry overhead using std::map is something like 44-64 bytes vs 16 bytes for the nsTArray approach. It's possible to reduce the number of entries per file by only storing entries for a single active track rather than for any track data we parse--it's common for there to be ~8 audio entries per video entry for files that aren't using laced blocks.
Reporter | ||
Updated•11 years ago
|
Assignee: kinetik → nobody
Updated•9 years ago
|
Component: Audio/Video → Audio/Video: Playback
Comment 3•6 years ago
|
||
Mass closing do to inactivity.
Feel free to re-open if still needed.
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → INACTIVE
You need to log in
before you can comment on or make changes to this bug.
Description
•