Closed Bug 1324894 Opened 3 years ago Closed 3 years ago
remove the PR
_Interrupt call in Background Hang Monitor
This call makes BackgroundHangMonitor depend on internal implementation details of PRThread and NSPR's synchronization code in ways that I'd really rather not. Having this call makes it difficult to get rid of using NSPR's synchronization primitives. How strongly do you feel about a lock being taken here? http://dxr.mozilla.org/mozilla-central/source/xpcom/threads/BackgroundHangMonitor.cpp#100
We already take mLock when Wakeup() is called, so this could be as simple as changing PR_Interrupt to lock.Notify(), and shouldn't make that big of a difference.
(In reply to Jim Chen [:jchen] [:darchons] from comment #1) > We already take mLock when Wakeup() is called, so this could be as simple as > changing PR_Interrupt to lock.Notify(), and shouldn't make that big of a > difference. Oh my, we do, don't we? Sheesh. Well, forget that, we'll just use the ordinary mechanism here.
Assignee: nobody → nfroyd
Priority: -- → P3
Using PR_Interrupt here makes life difficult for other things, such as moving away from NSPR synchronization primitives.
Attachment #8825084 - Flags: review?(nchen)
Attachment #8825084 - Flags: review?(nchen) → review+
Pushed by firstname.lastname@example.org: https://hg.mozilla.org/integration/mozilla-inbound/rev/5f42a80cee03 use standard Monitor APIs rather than PR_Interrupt in BackgroundHangMonitor; r=darchons
You need to log in before you can comment on or make changes to this bug.