gnash-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnash-commit] gnash ChangeLog server/as_value.cpp server/fill...


From: zou lunkai
Subject: Re: [Gnash-commit] gnash ChangeLog server/as_value.cpp server/fill...
Date: Tue, 20 May 2008 20:54:57 +0800

>                * server/as_value.cpp: use std::fmod, drop using namespace 
> std;,
>                  drop c_str() for logging, replace snprintf with boost::format
>                  (will be slightly slower for those cases), drop snprintf 
> ifdef.
>                  A slightly faster alternative to boost::format that also 
> avoids
>                  using non-standard functions would be stringstreams, but it 
> is
>                  not as clear.

Question: boost::format  is not dependent on any external binary
library, right?

boost::format was mainly used for logging and debugging, that's fine
to me, as the speed there is not very important.  But I also heard
boost::format is about 10 ~20 times slower than sprintf(not tested).
If it is true, then we may want to keep some 'snprintf' related
functions in our AS interpreter.

I profiled Gnash with an small swf which targets at 100fps and
contains 100 empty static sprites on a slow CPU. The target FPS was
not reached, but the profiling result showed that there's no one(low
level)function cost more than 10%  CPU. That means, when Gnash is
slow, we cann't just assum the renderer or the AS interpreter is too
slow. There's also many other details need to be cared/improved.

Not against this patch, just a general discussion.

--zou




reply via email to

[Prev in Thread] Current Thread [Next in Thread]