The new "num" property lets identical blocks be aggregated in the output. This
patch only uses the "num" property for dead blocks, because that's where the
greatest potential benefit lies, but it could be used for live blocks as well.
On one test case (a complex PDF file) running with --mode=cumulative
--sample-below=1 this patch had the following effects.
- Change in running speed was negligible.
- Compressed output file size dropped from 8.8 to 5.0 MB.
- Compressed output file size dropped from 297 to 50 MB.
- dmd.py runtime (without stack fixing) dropped from 30 to 8 seconds.
--HG--
extra : rebase_source : 46a32058cd5c31cd823fe3f1accb5e68bcd320f3
The DEFINES and XPCOM_API changes are needed to get rid of "inconsistent dll
linkage" warnings on Windows builds.
--HG--
extra : rebase_source : 00756f51ebee85c70f65d51dbac17b4835262697
Fixes a bug in the SourceBufferResource eviction code where it was
using the mOffset of the resource as the min bound for what to evict.
This offset is almost always zero though due to ReadFromCache being
used which never updates the offset. This prevented eviction from
happening in most cases.
Moves the code to remove old decoders so that it does this during
the same loop as that which remove data from existing decoders.
This more aggressively prunes old decoders and is more likely to
keep data in the current playing decoder around for seeking, etc.
Prevent removing any decoder that the MediaSourceReader is
currently using for playback to prevent RemoveDecoder crashes.
Add a threshold to subtract from the current time when working out
the time bound to evict before to make it less likely to evict
current data that is needed for current playback.
Remove all data from evicted decoders in the initial iteration then
iterate after to remove empty decoders to put the RemoveDecoder
logic in one place.
Iterate decoders in order that they were added rather than sorted
by time so the logic that removes entire decoders can do it only
to those old decoders that existed before the existing one was
created.
Keeps track of the time that was evicted from the current decoder
and uses that as the time to EvictBefore for all decoders in the
track buffer when doing MediaSource::NotifyEvict.
--HG--
extra : rebase_source : f7b4fe263a8041b3882585caea389742b2a1a9b3
I noticed the GetRootPresContext call being expensive in a profile that
involved painting in a (non-e10s) window with around 400-500 tabs.
Moving the mIsActive test (most likely to be false) first should fix
that.
This adjusts existing reftest annotations for tests that fail on 10.8
that are showing up as failing on 10.10 as well to be marked using >=
version tests rather than == version tests.
This fails without the patch; I'm hoping it will be fixed by the
combination of patch 1 in this bug and bug 1055667 patch 5.
(Interestingly, it fails both due to mispositioning as expected, and
also due to bad overflow area computation causing failure to paint the
ruby text.)