Closed Bug 834928 Opened 11 years ago Closed 11 years ago

videocontrols.xml is parsed and executed twice when starting the camera app

Categories

(Firefox OS Graveyard :: Gaia::Camera, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 821695

People

(Reporter: gsvelto, Assigned: daleharvey)

References

Details

(Whiteboard: [FFOS_perf])

While starting up the videocontrols.xml file is evaluated twice and it's .init() method is also called twice as seen in this profile (only the parts relevant to videocontrols.xml are visible, remove the filtering to see the full profile):

http://people.mozilla.com/~bgirard/cleopatra/#report=40d5408a8d23b67bb82148ed4178742b34b00dcf&search=videocontrols.xml

This results in a delay of 180ms which is the time required to parse & run videocontrols.xml.

I am categorizing this as Gaia::Camera but since videocontrols.xml is a Gecko widget this might be actually a Gecko bug.
blocking-b2g: --- → tef?
Whiteboard: [FFOS_perf]
Assignee: nobody → dale
Is this also related on bug 821695 ?
(In reply to Fabrice Desré [:fabrice] from comment #1)
> Is this also related on bug 821695 ?

Possibly, I'll try profiling with the provided patch applied and see if both loads/executions disappear. If they do and the patch can be landed, this in conjunction with the patch in bug 819000 should allow us to meet the startup requirements that certain of our partners have requested.
blocking-b2g: tef? → tef+
This is a profile with the patch from bug 821695 applied:

http://people.mozilla.com/~bgirard/cleopatra/#report=a7344ff105ac092282d7a10ebdf20b0b8cad89f3

The initial load time for videocontrols.xml is gone entirely, saving us up to ~500ms. Additionally the time we spent in the JS code in videocontrols.xml which was executed for every frame is also gone which is a nice added bonus. Fabrice, if you're OK with this I'll close this as a duplicate of bug 821965.
blocking-b2g: tef+ → tef?
Gabriele, did you mean to renom? If this is resolved as a dup, please nom bug 821965.
(In reply to Lawrence Mandel [:lmandel] from comment #4)
> Gabriele, did you mean to renom? If this is resolved as a dup, please nom
> bug 821965.

You mean adding the blocking-b2g:tef? flag to bug 821965? I'll do that, I hadn't noticed it didn't have it yet. Bear with me if I don't handle the flags properly but I haven't figured all of them out yet.
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → DUPLICATE
blocking-b2g: tef? → ---
You need to log in before you can comment on or make changes to this bug.