Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(28)

Issue 872933002: Subzero: Second attempt at fixing MacOS 10.6 build. (Closed)

Created:
5 years, 11 months ago by Jim Stichnoth
Modified:
5 years, 10 months ago
CC:
native-client-reviews_googlegroups.com
Base URL:
https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Subzero: Second attempt at fixing MacOS 10.6 build. Manages thread_local pointer fields through a set of macros. If ICE_THREAD_LOCAL_HACK is defined, the thread_local definitions and accesses are defined in terms of pthread operations. This assumes that the underlying std::thread library is based on pthread. BUG= none R=jfb@chromium.org, jvoung@chromium.org Committed: https://gerrit.chromium.org/gerrit/gitweb?p=native_client/pnacl-subzero.git;a=commit;h=a5fe17a11eae0bbbbed481ea31806d45606198c9

Patch Set 1 #

Patch Set 2 : Reformat to 80-columns #

Total comments: 6

Patch Set 3 : Change macro argument order #

Total comments: 2

Patch Set 4 : Fix comment #

Total comments: 2

Patch Set 5 : Code review updates #

Total comments: 2

Patch Set 6 : Handle pthread_key_create() error return values #

Patch Set 7 : Change field name. Handle pthread_key_create() errors. #

Total comments: 2

Patch Set 8 : llvm_unreachable --> report_fatal_error #

Patch Set 9 : Add llvm:: prefix #

Unified diffs Side-by-side diffs Delta from patch set Stats (+130 lines, -24 lines) Patch
M src/IceCfg.h View 1 2 3 4 2 chunks +8 lines, -5 lines 0 comments Download
M src/IceCfg.cpp View 1 2 1 chunk +1 line, -1 line 0 comments Download
M src/IceDefs.h View 1 2 1 chunk +1 line, -8 lines 0 comments Download
M src/IceGlobalContext.h View 1 2 3 4 2 chunks +10 lines, -7 lines 0 comments Download
M src/IceGlobalContext.cpp View 1 2 3 4 3 chunks +10 lines, -3 lines 0 comments Download
A src/IceTLS.h View 1 2 3 4 5 6 7 8 1 chunk +100 lines, -0 lines 0 comments Download

Messages

Total messages: 20 (1 generated)
Jim Stichnoth
To complete this, I need to define ICE_THREAD_LOCAL_HACK if the MacOS 10.6 environment is detected. ...
5 years, 11 months ago (2015-01-24 03:42:53 UTC) #2
JF
On cmake you have CMAKE_SYSTEM_NAME and CMAKE_SYSTEM_VERSION, and then you can define something in the ...
5 years, 11 months ago (2015-01-24 05:42:47 UTC) #3
Jim Stichnoth
https://codereview.chromium.org/872933002/diff/20001/src/IceDefs.h File src/IceDefs.h (right): https://codereview.chromium.org/872933002/diff/20001/src/IceDefs.h#newcode48 src/IceDefs.h:48: #endif // !_MSC_VER On 2015/01/24 05:42:47, JF wrote: > ...
5 years, 11 months ago (2015-01-24 16:55:34 UTC) #4
jvoung (off chromium)
Small nit, but otherwise looks okay =( Is the difference libc++ on OSX vs an ...
5 years, 11 months ago (2015-01-24 18:47:40 UTC) #5
jvoung (off chromium)
On 2015/01/24 18:47:40, jvoung wrote: > Small nit, but otherwise looks okay =( > > ...
5 years, 11 months ago (2015-01-24 18:59:39 UTC) #6
Jim Stichnoth
So is it __APPLE__ that is defined for those builds? I would add that check ...
5 years, 11 months ago (2015-01-24 21:47:30 UTC) #7
JF
> I don't see how that could be a problem here, unless the C++ runtime ...
5 years, 11 months ago (2015-01-25 04:37:02 UTC) #8
Jim Stichnoth
On 2015/01/25 04:37:02, JF wrote: > > I don't see how that could be a ...
5 years, 11 months ago (2015-01-25 08:05:52 UTC) #9
Jim Stichnoth
On 2015/01/25 04:37:02, JF wrote: > > I don't see how that could be a ...
5 years, 11 months ago (2015-01-25 08:05:53 UTC) #10
JF
On 2015/01/25 08:05:53, stichnot wrote: > On 2015/01/25 04:37:02, JF wrote: > > > I ...
5 years, 11 months ago (2015-01-25 18:06:19 UTC) #11
jvoung (off chromium)
On 2015/01/25 04:37:02, JF wrote: > > I don't see how that could be a ...
5 years, 11 months ago (2015-01-25 18:43:00 UTC) #12
Jim Stichnoth
In the latest version, an initialization function must be explicitly called after main() starts. Also ...
5 years, 11 months ago (2015-01-25 18:58:40 UTC) #13
Jim Stichnoth
On 2015/01/25 18:06:19, JF wrote: > Here's another idea that may not be any better: ...
5 years, 11 months ago (2015-01-25 19:14:34 UTC) #14
JF
lgtm after one last comment on pthread_key_create. > Also in this version, I'm being bold ...
5 years, 11 months ago (2015-01-25 23:05:05 UTC) #15
Jim Stichnoth
https://codereview.chromium.org/872933002/diff/80001/src/IceTLS.h File src/IceTLS.h (right): https://codereview.chromium.org/872933002/diff/80001/src/IceTLS.h#newcode75 src/IceTLS.h:75: FieldName##__dummy = pthread_key_create(&FieldName##__key, nullptr) On 2015/01/25 23:05:05, JF wrote: ...
5 years, 11 months ago (2015-01-26 05:43:37 UTC) #16
jvoung (off chromium)
lgtm
5 years, 10 months ago (2015-01-26 18:35:23 UTC) #17
JF
https://codereview.chromium.org/872933002/diff/120001/src/IceTLS.h File src/IceTLS.h (right): https://codereview.chromium.org/872933002/diff/120001/src/IceTLS.h#newcode79 src/IceTLS.h:79: llvm_unreachable("Failed to create pthread key"); \ This should be ...
5 years, 10 months ago (2015-01-26 18:48:33 UTC) #18
Jim Stichnoth
https://codereview.chromium.org/872933002/diff/120001/src/IceTLS.h File src/IceTLS.h (right): https://codereview.chromium.org/872933002/diff/120001/src/IceTLS.h#newcode79 src/IceTLS.h:79: llvm_unreachable("Failed to create pthread key"); \ On 2015/01/26 18:48:33, ...
5 years, 10 months ago (2015-01-26 19:06:19 UTC) #19
Jim Stichnoth
5 years, 10 months ago (2015-01-26 19:10:07 UTC) #20
Message was sent while issue was closed.
Committed patchset #9 (id:160001) manually as
a5fe17a11eae0bbbbed481ea31806d45606198c9 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698