Closed
Bug 1410023
Opened 7 years ago
Closed 7 years ago
Non-unified xpcom/threads build is failing
Categories
(Core :: XPCOM, defect)
Core
XPCOM
Tracking
()
RESOLVED
FIXED
mozilla58
Tracking | Status | |
---|---|---|
firefox58 | --- | fixed |
People
(Reporter: philn, Assigned: philn)
References
Details
Attachments
(1 file, 3 obsolete files)
1.12 KB,
patch
|
froydnj
:
review+
|
Details | Diff | Splinter Review |
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13) AppleWebKit/604.1.38 (KHTML, like Gecko) Version/11.0 Safari/604.1.38 Actual results: After the patches from bug 1404198 landed the non-unified build fails again in xpcom/threads.
Assignee | ||
Updated•7 years ago
|
Blocks: servo-media
Updated•7 years ago
|
Attachment #8920075 -
Attachment is patch: true
Attachment #8920075 -
Attachment mime type: text/x-patch → text/plain
Assignee | ||
Comment 1•7 years ago
|
||
Attachment #8920075 -
Attachment is obsolete: true
Attachment #8920082 -
Flags: review?(nfroyd)
Updated•7 years ago
|
Component: Untriaged → XPCOM
Product: Firefox → Core
Comment 2•7 years ago
|
||
Comment on attachment 8920082 [details] [diff] [review] 2-Bug_1410023___Non_unified_build_fixes_for_xpcom_threads_.patch Review of attachment 8920082 [details] [diff] [review]: ----------------------------------------------------------------- Thanks, but I have some questions about the nature of these fixes. ::: xpcom/threads/ThreadEventTarget.cpp @@ +23,5 @@ > > using namespace mozilla; > > +nsresult > +NS_NewTimerWithCallback(nsITimer** aTimer, Why are we not simply including nsITimer.h for this declaration? ::: xpcom/threads/nsThreadUtils.cpp @@ +81,5 @@ > NS_IMPL_ISUPPORTS_INHERITED(IdleRunnable, CancelableRunnable, > nsIIdleRunnable) > > +nsresult > +NS_NewTimerWithFuncCallback(nsITimer** aTimer, Same question here. ::: xpcom/threads/nsThreadUtils.h @@ +640,4 @@ > namespace mozilla { > namespace detail { > > +already_AddRefed<nsITimer> NS_NewTimer(); Same question here. ::: xpcom/threads/nsTimerImpl.cpp @@ -74,5 @@ > return timer.forget(); > } > > -mozilla::Result<nsCOMPtr<nsITimer>, nsresult> > -NS_NewTimerWithObserver(nsIObserver* aObserver, The diff here is very peculiar and I am unable to figure out what the intent of these changes was. Can you shed some light on this, please?
Attachment #8920082 -
Flags: review?(nfroyd)
Assignee | ||
Comment 3•7 years ago
|
||
Comment on attachment 8920082 [details] [diff] [review] 2-Bug_1410023___Non_unified_build_fixes_for_xpcom_threads_.patch Review of attachment 8920082 [details] [diff] [review]: ----------------------------------------------------------------- Thanks for the review! Answers in-line. ::: xpcom/threads/ThreadEventTarget.cpp @@ +23,5 @@ > > using namespace mozilla; > > +nsresult > +NS_NewTimerWithCallback(nsITimer** aTimer, Because nsITimer.h seems to be generated during the build and doesn't include this declaration. ::: xpcom/threads/nsThreadUtils.cpp @@ +81,5 @@ > NS_IMPL_ISUPPORTS_INHERITED(IdleRunnable, CancelableRunnable, > nsIIdleRunnable) > > +nsresult > +NS_NewTimerWithFuncCallback(nsITimer** aTimer, Same answer :) ::: xpcom/threads/nsThreadUtils.h @@ +640,4 @@ > namespace mozilla { > namespace detail { > > +already_AddRefed<nsITimer> NS_NewTimer(); Same answer :) ::: xpcom/threads/nsTimerImpl.cpp @@ -74,5 @@ > return timer.forget(); > } > > -mozilla::Result<nsCOMPtr<nsITimer>, nsresult> > -NS_NewTimerWithObserver(nsIObserver* aObserver, Yes, I'm sorry about this. The diff is indeed confusing. The reason for these changes is that the function taking an nsIObserver as first argument call the variant of the same function but with a timer as first argument. But the latter isn't declared yet at that point. So I swapped the declaration order of each NS_NewTimer...() function to avoid this issue. I had this specific issue on High Sierra with the XCode 9 toolchain.
Assignee | ||
Comment 4•7 years ago
|
||
Oh I'm sorry, I didn't carefully check your comments about nsITimer.h. I'll try to update the patch!
Assignee | ||
Comment 5•7 years ago
|
||
Attachment #8920082 -
Attachment is obsolete: true
Assignee | ||
Updated•7 years ago
|
Attachment #8920616 -
Flags: review?(nfroyd)
Comment 6•7 years ago
|
||
Comment on attachment 8920616 [details] [diff] [review] 1-Bug_1410023___Non_unified_build_fixes_for_xpcom_threads_.patch Review of attachment 8920616 [details] [diff] [review]: ----------------------------------------------------------------- Thanks, this patch looks better! Just canceling the review to address the issue below. ::: xpcom/threads/nsTimerImpl.cpp @@ -80,5 @@ > - uint32_t aType, > - nsIEventTarget* aTarget) > -{ > - nsCOMPtr<nsITimer> timer; > - MOZ_TRY(NS_NewTimerWithObserver(getter_AddRefs(timer), Thanks for the explanation of what the changes to this file were supposed to be doing. But I am confused why this function wouldn't be declared...it's declared in nsITimer.h, which is included by nsTimerImpl.h, which is included by this file. So we shouldn't have any issues with the ordering here?
Attachment #8920616 -
Flags: review?(nfroyd)
Assignee | ||
Comment 7•7 years ago
|
||
Actually after checking the changes in this file again it turns out they're indeed un-necessary :) When I came up with this patch I was unknowingly relying on a old nsITimer.h header from gecko-media, that tricked me to this change! Thanks for the thorough review, Nathan.
Attachment #8920616 -
Attachment is obsolete: true
Attachment #8920630 -
Flags: review?(nfroyd)
Comment 8•7 years ago
|
||
Comment on attachment 8920630 [details] [diff] [review] 2-Bug_1410023___Non_unified_build_fixes_for_xpcom_threads_.patch Review of attachment 8920630 [details] [diff] [review]: ----------------------------------------------------------------- Excellent. Thank you for your patience!
Attachment #8920630 -
Flags: review?(nfroyd) → review+
Assignee | ||
Updated•7 years ago
|
Keywords: checkin-needed
Updated•7 years ago
|
Assignee: nobody → philn
Pushed by ryanvm@gmail.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/facc1bc84098 Non-unified build fixes for xpcom/threads. r=froydnj
Keywords: checkin-needed
Comment 10•7 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/facc1bc84098
Status: UNCONFIRMED → RESOLVED
Closed: 7 years ago
status-firefox58:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla58
You need to log in
before you can comment on or make changes to this bug.
Description
•