Closed
Bug 1173923
Opened 9 years ago
Closed 9 years ago
Executing console.profile and console.profileEnd doesn't happen in order
Categories
(DevTools :: Performance Tools (Profiler/Timeline), defect, P2)
DevTools
Performance Tools (Profiler/Timeline)
Tracking
(Not tracked)
RESOLVED
DUPLICATE
of bug 1173588
People
(Reporter: epmatsw, Unassigned)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
(deleted),
application/x-javascript
|
Details |
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:40.0) Gecko/20100101 Firefox/40.0
Build ID: 20150610004004
Steps to reproduce:
I'm trying to profile a particular function. To do so, I've created a test harness that calls console.profile("<display text for function>"), followed by the function, followed by console.profileEnd("<display text for function>"). However, this doesn't behave as expected. Sometimes, no profiling occurs at all. More often, the profiling is started, but never stops. I've attached sample code that reproduces this issue.
Actual results:
Profiler does not start when told to, or if it does start, does not end when expected.
Expected results:
Profiler starts, profiles function, and ends.
Reporter | ||
Updated•9 years ago
|
OS: Unspecified → Mac OS X
Hardware: Unspecified → x86
Comment 1•9 years ago
|
||
This happens to me too.
On B2G, at startup, if I call console.profile("x"), then console.profileEnd("x"), nothing happens. It's like console.profile is never called. If I reload though, console.profile("x") works, but console.profileEnd("x") doesn't. I have to manually call profileEnd. Even adding profileEnd in a setTimeout doesn't appear to stop the profile.
Jordan, any idea what's going on?
Status: UNCONFIRMED → NEW
Component: Untriaged → Developer Tools: Performance Tools (Profiler/Timeline)
Ever confirmed: true
Flags: needinfo?(jsantell)
Comment 2•9 years ago
|
||
Sorry, adding console.profileEnd() in a timeout appears to work.
Comment 3•9 years ago
|
||
Guessing this is similar to bug 1173588 -- the recording starts asynchronously, so when having a chunk of code wrapped in a profile/profileEnd all in the same tick, it's unlikely to record
Flags: needinfo?(jsantell)
Updated•9 years ago
|
Updated•9 years ago
|
Blocks: perf-console
Comment 4•9 years ago
|
||
Triaging. Filter on ADRENOCORTICOTROPIC (yes).
OS: Mac OS X → Unspecified
Priority: -- → P2
Hardware: x86 → Unspecified
Version: 40 Branch → unspecified
Updated•9 years ago
|
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → DUPLICATE
Updated•6 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•