Rework RTCDTMFSender-ontonechange tests to use cumulative time when checking whether tonechange events are happening too early
Categories
(Core :: WebRTC: Signaling, enhancement, P2)
Tracking
()
Tracking | Status | |
---|---|---|
firefox67 | --- | fixed |
People
(Reporter: bwc, Assigned: bwc)
Details
Attachments
(1 file)
The reason why these tests are flaky right now seems to be because when there is a delay between setting the timer for the next tone, and calling the tonechange event handler, the next time the tonechange handler is called will appear to happen too soon. An example:
0ms: Schedule next tone to fire in 170ms.
... some processing delay
2ms: tonechange handler called, remembers time, expects next call in 170ms, at t=172ms
170ms: Next tone fires, right on time
170ms: tonechange handler called, and test is sad
Assignee | ||
Comment 1•5 years ago
|
||
This is a bit of a mess. The way this test is written, all of the test-cases run simultaneously, because waiting for tone events to fire is kinda time-consuming. Unfortunately, that means that we're creating a bunch of PCs (which involves quite a bit of time) which significantly delays the first tonechange callbacks (by about 200ms). This padding is more than enough to hide errors in test-cases that do fire events way too early.
Assignee | ||
Comment 2•5 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=865755cd8d0c0795f51a6d8c43dcf38a9f9b3b9b
Assignee | ||
Comment 3•5 years ago
|
||
Assignee | ||
Comment 4•5 years ago
|
||
Almost works. Seeing intermittent nullptr crashes on linux32 debug only. Looking into it.
Assignee | ||
Comment 5•5 years ago
|
||
Ok... seeing a nullptr crash entirely in binding code. |mImpl| is null here:
void
RTCRtpTransceiver::SetStopped(ErrorResult& aRv, JS::Realm* aRealm)
{
return mImpl->SetStopped(aRv, aRealm);
}
The binding code never nulls out |mImpl| (except in d'tor code maybe), but the cycle collector might. This is very weird.
Assignee | ||
Comment 6•5 years ago
|
||
I should point out that this happens only on the non-e10s tests; this seems to be why it happens only on linux32 debug. It would be nice if there were some way to coerce try into running some non-e10s tests on ASAN...
Assignee | ||
Comment 7•5 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=219e3231774fd142ec1f2b87c101957b9aa4245c
Assignee | ||
Comment 8•5 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=cb45fec70aa493d1b7f9ffaedd32e09437b8cf9f
Assignee | ||
Comment 9•5 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=7193ecbdecc7f1aa085b46b66228d0cd595112c9
Assignee | ||
Comment 10•5 years ago
|
||
FWIW, I cannot reproduce this (on non-e10s) on linux ASAN locally.
Assignee | ||
Comment 11•5 years ago
|
||
Ok, bug 1531448 is definitely the culprit here. I wonder why it is not safe to call that code in close()?
Assignee | ||
Comment 12•5 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=6c480fba54dc48dc4927d3b5a587e69a1797afcf
Assignee | ||
Comment 13•5 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=2945f0ba2ec8fbd7d415f7cef8cea6d8247f2a1b
Assignee | ||
Comment 14•5 years ago
|
||
Dunno why mach try is putting links in here that don't work, here is one that does.
https://treeherder.mozilla.org/#/jobs?repo=try&revision=f57adc1a45ec
Assignee | ||
Comment 15•5 years ago
|
||
Ok, so the crash in comment 5 is happening when we close the pc due to the window going away. Evidently, we're in the middle of a cycle collection, and some of the stuff in the cycle has already been cleaned up. This particular problem is easy enough to work around (see patches in comment 14), but I'm left with a nagging feeling that this sort of bug is liable to happen again.
Assignee | ||
Comment 16•5 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=c49cb91bfeb4f3877bc138a47f14ee1517c052c1
Assignee | ||
Comment 17•5 years ago
|
||
Comment 18•5 years ago
|
||
Pushed by bcampen@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/d57f48d6e42b Re-enable and de-flake the RTCDTMFSender-ontonechange tests. r=jib
Comment 19•5 years ago
|
||
bugherder |
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/16005 for changes under testing/web-platform/tests
Upstream PR was closed without merging
Description
•