Closed Bug 1034138 Opened 6 years ago Closed 5 years ago

Get the native stack during a permanent thread hang

Categories

(Toolkit :: Telemetry, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla34

People

(Reporter: jchen, Assigned: jchen)

References

Details

Attachments

(5 files, 1 obsolete file)

No description provided.
nativeStack is set, in addition to stack, if we have a native stack for a particular hang.
Attachment #8453975 - Flags: review?(vdjeric)
Display native stack instead of pseudostack if available.
Attachment #8453976 - Flags: review?(vdjeric)
Add simple test for permahang / native stack code, by causing a 10 second hang (which is treated as a permahang), and making sure we do have a native stack from the permahang.
Attachment #8453978 - Flags: review?(vdjeric)
Attachment #8453973 - Flags: review?(snorp) → review+
Attachment #8453976 - Flags: review?(vdjeric) → review+
Attachment #8453978 - Flags: review?(vdjeric) → review+
Comment on attachment 8453975 [details] [diff] [review]
b. Add thread hang native stack output to nsITelemetry;

Review of attachment 8453975 [details] [diff] [review]:
-----------------------------------------------------------------

::: toolkit/components/telemetry/Telemetry.cpp
@@ +2057,5 @@
>    return ret;
>  }
>  
>  static JSObject*
> +CreateJSHangStack(JSContext* cx, const Telemetry::HangStack& stack)

Let's rename this function since it will return both native & JS stacks
Attachment #8453975 - Flags: review?(vdjeric) → review+
sorry had to back this changes in https://tbpl.mozilla.org/?tree=Mozilla-Inbound&rev=6ffcd2030ed8 since one of this changesets caused a nearly permanent error like https://tbpl.mozilla.org/php/getParsedLog.php?id=44598113&tree=Mozilla-Inbound
test_dbgsocket.js is prone to timing out because we log all the "really long" data that we send, which apparently really stresses the test harness. This patch disables logging and hugely improves the test's performance.
Attachment #8463488 - Flags: review?(jryans)
Comment on attachment 8463488 [details] [diff] [review]
e. Don't log large amounts of data when running test_dbgsocket.js (v1)

Review of attachment 8463488 [details] [diff] [review]:
-----------------------------------------------------------------

There are other tests in the same directory that will probably have similar issues.

Let's instead comment out the prefs that cause this (which is done[1] in various other DevTools directories), so that it's easy to enable in local debugging.

In this case, you'd comment out the two prefs here[2], and update / remove the comment above them.

[1]: http://hg.mozilla.org/mozilla-central/annotate/a4dcfbebcb58/browser/devtools/inspector/test/head.js#l11
[2]: http://hg.mozilla.org/mozilla-central/file/d77f6a96ff96/toolkit/devtools/transport/tests/unit/head_dbg.js#l21
Attachment #8463488 - Flags: review?(jryans)
Thanks for the pointer!
Attachment #8463488 - Attachment is obsolete: true
Attachment #8463546 - Flags: review?(jryans)
You need to log in before you can comment on or make changes to this bug.