LWN.net Logo

Firefox OS on the ZTE Open

Firefox OS on the ZTE Open

Posted Sep 5, 2013 21:15 UTC (Thu) by roc (subscriber, #30627)
In reply to: Firefox OS on the ZTE Open by khim
Parent article: Firefox OS on the ZTE Open

As someone who has done a lot of work on performance issues in FirefoxOS, and someone dogfooding FirefoxOS on the lowest-end hardware, I don't agree. I don't know exactly what issues Corbet is complaining about, but most of the slowness/lag issues I see are not GC related.

One big issue is app startup time. This is related to Web platform issues --- it's hard to precompile a Web app --- but not GC.

Another big issue is smoothness of CSS animations and transitions. These are managed by C++ code and GC is not involved.

Another big issue is smoothness of panning with touch gestures. Again these are managed by C++ code that isn't impacted by GC.

(Our JS GC has gotten a lot better since the version of Gecko that's present in these 1.0 devices. We have greatly reduced pause times since then. I don't think that will make much difference to FirefoxOS users though.)


(Log in to post comments)

Firefox OS on the ZTE Open

Posted Sep 6, 2013 11:29 UTC (Fri) by khim (subscriber, #9252) [Link]

This is related to Web platform issues --- it's hard to precompile a Web app --- but not GC.

I've said "interpreted language plus garbage collection", not just GC. If you say that first part is more problematic then second one then you probably are right. Both are pretty awful but their combination is especially bad.

Another big issue is smoothness of panning with touch gestures. Again these are managed by C++ code that isn't impacted by GC.

I'm not all that sure. I've never worked with FirefoxOS but I've played with Android. Once when we've tried to see why panning does not work smoothly after small change we've found that one, single Java-based printf in the frame-generated procedure generated over 200 temporary objects and created lags. We've replaced Java printf with C++ code and problem went away. Granted it was an old version of Android and the old hardware (original Android device: HTC Dream), and I hope there are nothing so bad in FirefoxOS but I would not dismiss the possibility entirely: even if 99% of work is done in C++ you still can not be sure GC will not hurt you. Note that while said HTC Dream is considered fatally underpowered by modern Android standards it's not all that worse then ZTE Open from purely hardware standpoint.

Our JS GC has gotten a lot better since the version of Gecko that's present in these 1.0 devices. We have greatly reduced pause times since then.

Bwahaha. I first heard this excuse over twenty years ago when I was still in middle school and asked why some "uberpowerfull" text editor (don't remember the name, but I know it was not Emacs) periodically stops responding and displays "GC in progress, please wait" message. Few years later I've tried to use Whitewater Resource Toolkit in Borland C++ 3.0, met the same problem and heard the same excuse. I've heard it bazillion times since then and this is why I don't believe in GC.

P.S. Note that I could be wrong. I was similarly sceptical about C++ decision to create the standard library with huge amount of garbage which is supposed to be optimized away by optimizing compiler — yet C++ guys have provent me wrong since today compilers indeed know how to optimize all that mess and the result is often faster then nice and clean C code. I will be ready to admit that GC is no longer a problem when I'll see UI with GC and no lag — but not before. Actually I have seen such UI. In Emacs. But if please recall that Emacs means "Eight Megabytes And Constantly Swapping" and notice that today even mobile phones have hundred times more then that… it's not very convincing.

Firefox OS on the ZTE Open

Posted Sep 6, 2013 12:48 UTC (Fri) by danieldk (subscriber, #27876) [Link]

> (Our JS GC has gotten a lot better since the version of Gecko that's present in these 1.0 devices. We have greatly reduced pause times since then. I don't think that will make much difference to FirefoxOS users though.)

Will these devices get such updates? How long will a phone such as the ZTE Open get Firefox OS updates?

BTW. It's great to see more competition!

Firefox OS on the ZTE Open

Posted Sep 6, 2013 18:08 UTC (Fri) by Lennie (subscriber, #49641) [Link]

I've read somewhere that Mozilla's play is to have regular updates like Firefox and Chrome on the desktop for the top part of FirefoxOS (so not the kernel and daemons).

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds