Enable the CrossProcessMutex code on more Unices

RESOLVED FIXED in Firefox 47

Status

()

Core
IPC
RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: Jan Beich, Assigned: Jan Beich)

Tracking

Trunk
mozilla47
Unspecified
FreeBSD
Points:
---

Firefox Tracking Flags

(firefox47 fixed)

Details

(Whiteboard: [npotb] btpp-active)

Attachments

(1 attachment, 2 obsolete attachments)

(Assignee)

Description

2 years ago
+++ This bug was initially created as a clone of Bug #1072093 +++

The CrossProcessMutex is used in the APZ/tiling code for implementing progressive painting. On Desktop platforms layers.async-pan-zoom.enabled;true since bug 1178298 while layers.enable-tiles;true is limited to OS X. Let's prepare for layers.progressive-paint;true in advance by always building _posix.cpp where pthread_mutexattr_setpshared() is supported. If PTHREAD_PROCESS_SHARED doesn't work yet it'd only trade NS_RUNTIMEABORT() with MOZ_CRASH().

https://dxr.mozilla.org/mozilla-central/search?q=CrossProcessMutex
https://svnweb.freebsd.org/changeset/base/296162 DragonFly may want to adopt
bug 1072093 comment 16 (simple test program)
(Assignee)

Comment 1

2 years ago
Created attachment 8724975 [details] [diff] [review]
v1: Solaris, GNU/kFreeBSD, FreeBSD, DragonFly, etc

Partially backs out bug 1098607. According to ipc/chromium/chromium-config.mozbuild anything non-Windows is OS_POSIX, so it can be omitted thus avoiding ugliness in moz.build.

https://treeherder.mozilla.org/#/jobs?repo=try&revision=0715f6d11c4e
Attachment #8724975 - Flags: review?(mh+mozilla)
Attachment #8724975 - Flags: review?(bugmail.mozilla)
(Assignee)

Updated

2 years ago
Depends on: 1098607
(Assignee)

Comment 2

2 years ago
Created attachment 8724976 [details] [diff] [review]
v1: Solaris, GNU/kFreeBSD, FreeBSD, DragonFly, etc

Oops, forgot to sort OS_ARCH values in moz.build.
Attachment #8724975 - Attachment is obsolete: true
Attachment #8724975 - Flags: review?(mh+mozilla)
Attachment #8724975 - Flags: review?(bugmail.mozilla)
Attachment #8724976 - Flags: review?(mh+mozilla)
Attachment #8724976 - Flags: review?(bugmail.mozilla)
Comment on attachment 8724976 [details] [diff] [review]
v1: Solaris, GNU/kFreeBSD, FreeBSD, DragonFly, etc

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

I have no objections to this, but I'll defer to glandium.

::: ipc/glue/CrossProcessMutex.h
@@ +8,5 @@
>  
>  #include "base/process.h"
>  #include "mozilla/Mutex.h"
>  
> +#if (!defined(OS_NETBSD) && !defined(OS_OPENBSD))

This one needs a !defined(OS_WIN) as well since there's no #if branch for windows like in the other sites.
Attachment #8724976 - Flags: review?(bugmail.mozilla) → feedback+
(Assignee)

Comment 4

2 years ago
Created attachment 8724995 [details] [diff] [review]
v1.1: Solaris, GNU/kFreeBSD, FreeBSD, DragonFly, etc

Carrying over f=kats after adding missing !defined(OS_WIN) per comment 3. Also, dropped unnecessary parentheses when stacking negation:

  !defined(OS_WIN) && !defined(OS_NETBSD) && !defined(OS_OPENBSD) 

vs.

  defined(OS_POSIX) && (!defined(OS_NETBSD) && !defined(OS_OPENBSD))

https://treeherder.mozilla.org/#/jobs?repo=try&revision=de279a712c9d
Attachment #8724976 - Attachment is obsolete: true
Attachment #8724976 - Flags: review?(mh+mozilla)
Attachment #8724995 - Flags: review?(mh+mozilla)
Assignee: nobody → jbeich
Whiteboard: [npotb] → [npotb] btpp-active
Attachment #8724995 - Flags: review?(mh+mozilla) → review+
(Assignee)

Updated

2 years ago
Keywords: checkin-needed

Comment 6

2 years ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/ee9285c872a5
Status: NEW → RESOLVED
Last Resolved: 2 years ago
status-firefox47: affected → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla47
You need to log in before you can comment on or make changes to this bug.