PredictableLoading

From Gnash Project Wiki

Jump to: navigation, search

Time-related issues would be fixed by implementing predictable loading or by fixing one by one making them not time-related.

Time-related failed tests

Bug #41253

 --=[ testsuite/misc-ming.all/loading ]=-- 
FAIL: loadMovieTestRunner: coverart->get_root()->url() == 'file:///bb/build/rawhide-linux-i386/build/testsuite/media/blue.swf'
(expected: file:///bb/build/rawhide-linux-i386/build/testsuite/media/red.swf) [loadMovieTestRunner.cpp:113]
FAIL: loadMovieTestRunner: expected: red.swf , obtained: blue.swf (loadMovieTest.c:202)

Bug #41254

 --=[ testsuite/misc-mtasc.all ]=-- 
FAIL: sanetests-runner: expected: "1" , obtained: ""  [level87.as:72]

Bug #41255

 --=[ testsuite/swfdec ]=-- 
FAIL: run_swfdec_testsuite_g: gotolabel-multiple.swf:9b7e815d0ec8b35cae93165ad9a54fcd (traces in gotolabel-multiple.swf.trace-gnash,
log in gotolabel-multiple.swf.log)
FAIL: run_swfdec_testsuite_m: movieclip-lockroot-loadmovie-6.swf:679b3cea0d9643744aa29c88ae9908e1 (traces in
movieclip-lockroot-loadmovie-6.swf.trace-gnash, log in movieclip-lockroot-loadmovie-6.swf.log)
FAIL: run_swfdec_testsuite_m: movieclip-lockroot-loadmovie-7.swf:84ad9218797251db3ee79f9241f27b67 (traces in
movieclip-lockroot-loadmovie-7.swf.trace-gnash, log in movieclip-lockroot-loadmovie-7.swf.log)
FAIL: run_swfdec_testsuite_m: movieclip-lockroot-loadmovie-8.swf:3ac7430bf84185e34aee32b2d2394600 (traces in
movieclip-lockroot-loadmovie-8.swf.trace-gnash, log in movieclip-lockroot-loadmovie-8.swf.log)

Implementation

< bwy> We'll have to implement predictable loading to fix those properly.
< bwy> I have an idea how to do it fairly easily, but no time.
< gg0> well share the idea, maybe bjacques or strk have that time 
< bwy> The only thing that's easier about it is that much of it could be done using sed.
< bwy> You would convert the parsing code to a push parser first, which would involve changing the SWFStream& argument to an
iterator_range and using free functions to read from it.
< bjacques> what to do about ensureBytes?
< bwy> That wouldn't be a problem with a push parser, because you'd make sure the whole tag was available before parsing it.
< bwy> There are still the problems of bit reading and image data parsing though.
< bjacques> sounds good
< bjacques> how so?
< bwy> The former would require some kind of extra class to keep track of the bits read (like libbase/BitsReader)
< bwy> It's not hard, but also not easy using find and replace.
< bwy> The latter needs a rewrite of much of the image reading code, which would improve it but needs time.
< bjacques> I think the push parsing model is necessary anyway for the plugin migration
< bjacques> it is theoretically possible to avoid it but it would be a big mess