Closed
Bug 959484
Opened 10 years ago
Closed 10 years ago
de-THREADSAFE XPConnect
Categories
(Core :: XPConnect, defect)
Core
XPConnect
Tracking
()
RESOLVED
FIXED
mozilla29
People
(Reporter: mccr8, Assigned: mccr8)
References
Details
Attachments
(1 file)
20.04 KB,
patch
|
bholley
:
review+
|
Details | Diff | Splinter Review |
There are a number of vestigial THREADSAFE things in XPConnect that I think can be removed: - NS_DECL_THREADSAFE_ISUPPORTS (change to NS_DECL_ISUPPORTS) - NS_INTERFACE_MAP_END_THREADSAFE (change to NS_INTERFACE_MAP_END) - nsIClassInfo::THREADSAFE (change to nsIClassInfo::MAIN_THREAD_ONLY) With those converted, there's only one remaining instance of THREADSAFE in XPConnect: host-4-56:mc amccreight$ grep THREADSAFE js/xpconnect/*/*.cpp js/xpconnect/*/*.h js/xpconnect/src/XPCShellImpl.cpp:#ifdef JS_THREADSAFE It is at least stable enough to open the browser and load a few pages.
Assignee | ||
Comment 1•10 years ago
|
||
Bug 951948 is removing some or all of this already.
Depends on: 951948
Assignee | ||
Comment 2•10 years ago
|
||
https://tbpl.mozilla.org/?tree=Try&rev=5646ed8743fb
Assignee | ||
Comment 3•10 years ago
|
||
I discovered in some local testing that nsScriptError is actually used off the main thread. This object is just a glob of strings, so it seems benign enough to leave it as threadsafe. Thread 28 Crashed:: Compositor nsScriptError::Release() + 188 (nsScriptError.cpp:18) nsConsoleService::LogMessageWithMode(nsIConsoleMessage*, nsConsoleService::OutputMode) + 632 (nsConsoleService.cpp:236) nsConsoleService::LogStringMessage(char16_t const*) + 211 (nsConsoleService.cpp:157) mozilla::layers::CompositorOGL::Initialize() + 4829 (CompositorOGL.cpp:545) mozilla::layers::LayerManagerComposite::Initialize() + 17 (LayerManagerComposite.cpp:120) It looks like maybe the console service throws out a message, which is from the main thread, when something on the compositor thread pushes a new message on, or something like that.
Assignee | ||
Comment 4•10 years ago
|
||
I don't know what that flag thing is, but hopefully MAINTHREAD is okay...
Attachment #8360685 -
Flags: review?(bobbyholley+bmo)
Assignee | ||
Comment 5•10 years ago
|
||
This patch is a little silly, but I think it is nice to have the code give accurate information about what is actually used on multiple threads.
Comment 6•10 years ago
|
||
Comment on attachment 8360685 [details] [diff] [review] de-THREADSAFE XPConnect. Review of attachment 8360685 [details] [diff] [review]: ----------------------------------------------------------------- Yeehah! Once this lands, can we mark the dependent bug fixed?
Attachment #8360685 -
Flags: review?(bobbyholley+bmo) → review+
Assignee | ||
Comment 7•10 years ago
|
||
I think so. I can't think of anything else.
Assignee | ||
Comment 8•10 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/7ff8f88da96d
Comment 9•10 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/7ff8f88da96d
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla29
You need to log in
before you can comment on or make changes to this bug.
Description
•