|
|
Created:
4 years ago by lawrencewu Modified:
4 years ago CC:
chromium-reviews, asvitkine+watch_chromium.org, vmpstr+watch_chromium.org Target Ref:
refs/pending/heads/master Project:
chromium Visibility:
Public. |
DescriptionShare field trial allocator on Mac
This CL shares the field trial allocator on MacOS. It depends on Mac having
POSIX shared memory support, but other than that it is basically the same mechanism as that in the Linux CL: https://codereview.chromium.org/2530573002/. We basically just need to edit some ifdefs.
NOTE: turning on NOPRESUBMIT because the dependent CL re-adds some banned calls to AllowIO.
BUG=663912
NOPRESUBMIT=true
Committed: https://crrev.com/d17b445e932a10c875cea034b037b19d30e47a8c
Cr-Commit-Position: refs/heads/master@{#438265}
Patch Set 1 #Patch Set 2 : Fix ios compile issue #Patch Set 3 : Add POSIX implementation of Duplicate() #Patch Set 4 : Fix comment in header file #Patch Set 5 : Fix breaking browsertests. #Patch Set 6 : readd getting the fds #Patch Set 7 : totally reset content_main_runner.cc #Patch Set 8 : Add some comments. #
Total comments: 2
Patch Set 9 : Use intentionally dummy value and fix comment #
Depends on Patchset: Messages
Total messages: 73 (61 generated)
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Description was changed from ========== Share field trial allocator on Mac BUG=663912 ========== to ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same as the Linux CL: https://codereview.chromium.org/2530573002/. We just need to edit some ifdefs. BUG=663912 ==========
lawrencewu@chromium.org changed reviewers: + asvitkine@chromium.org
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
lgtm woot!
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by lawrencewu@chromium.org
Description was changed from ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same as the Linux CL: https://codereview.chromium.org/2530573002/. We just need to edit some ifdefs. BUG=663912 ========== to ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same as the Linux CL: https://codereview.chromium.org/2530573002/. We just need to edit some ifdefs. NOTE: turning on NOPRESUBMIT because this re-adds some banned calls to AllowIO. BUG=663912 NOPRESUBMIT=true ==========
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: mac_chromium_rel_ng on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_...)
Description was changed from ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same as the Linux CL: https://codereview.chromium.org/2530573002/. We just need to edit some ifdefs. NOTE: turning on NOPRESUBMIT because this re-adds some banned calls to AllowIO. BUG=663912 NOPRESUBMIT=true ========== to ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same mechanism as that in the Linux CL: https://codereview.chromium.org/2530573002/. We just need to edit some ifdefs. NOTE: turning on NOPRESUBMIT because this re-adds some banned calls to AllowIO. BUG=663912 NOPRESUBMIT=true ==========
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
lawrencewu@chromium.org changed reviewers: + mark@chromium.org
mark@: I had to readd the POSIX implementation for Duplicate(). I thought I didn't need it for my project, but I forgot the unit tests still use it (e.g. https://cs.chromium.org/chromium/src/base/metrics/field_trial_unittest.cc?q=f...). Please take a look, thanks.
Description was changed from ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same mechanism as that in the Linux CL: https://codereview.chromium.org/2530573002/. We just need to edit some ifdefs. NOTE: turning on NOPRESUBMIT because this re-adds some banned calls to AllowIO. BUG=663912 NOPRESUBMIT=true ========== to ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same mechanism as that in the Linux CL: https://codereview.chromium.org/2530573002/. We just need to edit some ifdefs. NOTE: turning on NOPRESUBMIT because the dependent CL re-adds some banned calls to AllowIO. BUG=663912 NOPRESUBMIT=true ==========
Description was changed from ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same mechanism as that in the Linux CL: https://codereview.chromium.org/2530573002/. We just need to edit some ifdefs. NOTE: turning on NOPRESUBMIT because the dependent CL re-adds some banned calls to AllowIO. BUG=663912 NOPRESUBMIT=true ========== to ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same mechanism as that in the Linux CL: https://codereview.chromium.org/2530573002/. We basically just need to edit some ifdefs. NOTE: turning on NOPRESUBMIT because the dependent CL re-adds some banned calls to AllowIO. BUG=663912 NOPRESUBMIT=true ==========
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_chromium_chromeos_ozone_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...) linux_chromium_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...)
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: ios-simulator on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios-simulator/bui...)
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_android_rel_ng on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/linux_androi...)
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_android_rel_ng on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/linux_androi...)
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
On 2016/12/10 02:05:02, lawrencewu wrote: > mark@: I had to readd the POSIX implementation for Duplicate(). > > I thought I didn't need it for my project, but I forgot the unit tests still use > it (e.g. > https://cs.chromium.org/chromium/src/base/metrics/field_trial_unittest.cc?q=f...). > Please take a look, thanks. asvitkine@: I had to change the method of field trial handle passing on POSIX. The problem with the current method is some browser tests don't initialize the allocator, but the child process still tries to open the fd. Since it can't distinguish anymore whether or not the fd is valid (because it's a constant), the map will fail. I solved this by passing the --field-trial-handle flag and making the child check for the presence of the flag (the value is invalid but it doesn't matter). Let me know if this is acceptable and I'll update the comments and docs to reflect this.
That seems fine to me as long as we clearly document it. However, I'm curious why we don't see the same problem with the Linux implementation. Do we simply not run those tests on Linux? On Dec 10, 2016 6:35 PM, <lawrencewu@chromium.org> wrote: > On 2016/12/10 02:05:02, lawrencewu wrote: > > mark@: I had to readd the POSIX implementation for Duplicate(). > > > > I thought I didn't need it for my project, but I forgot the unit tests > still > use > > it (e.g. > > > https://cs.chromium.org/chromium/src/base/metrics/ > field_trial_unittest.cc?q=field_trial_unittest&sq= > package:chromium&dr&l=1193). > > Please take a look, thanks. > > asvitkine@: I had to change the method of field trial handle passing on > POSIX. > > The problem with the current method is some browser tests don't initialize > the > allocator, but the child process still tries to open the fd. > Since it can't distinguish anymore whether or not the fd is valid (because > it's > a constant), the map will fail. I solved this by passing the > --field-trial-handle flag and making the child check for the presence of > the > flag (the value is invalid but it doesn't matter). Let me know > if this is acceptable and I'll update the comments and docs to reflect > this. > > https://codereview.chromium.org/2565683003/ > -- You received this message because you are subscribed to the Google Groups "Chromium-reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to chromium-reviews+unsubscribe@chromium.org.
On 2016/12/11 14:10:01, Alexei Svitkine (slow) wrote: > That seems fine to me as long as we clearly document it. > > However, I'm curious why we don't see the same problem with the Linux > implementation. Do we simply not run those tests on Linux? OK, I added comments and will update the design doc. As for why the failures are Mac-only: all the tests log some error in vt_video_encode_accelerator_mac.cc, so I suspect some interaction between shm in the field trial segment and this is causing these crashes. This might also be related to crbug.com/672889.
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_android_rel_ng on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/linux_androi...)
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_android_rel_ng on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/linux_androi...)
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
lgtm https://codereview.chromium.org/2565683003/diff/140001/base/metrics/field_tri... File base/metrics/field_trial.cc (right): https://codereview.chromium.org/2565683003/diff/140001/base/metrics/field_tri... base/metrics/field_trial.cc:947: cmd_line->AppendSwitchASCII(field_trial_handle_switch, field_trial_handle); If in this case you're using the param with an intentionally dummy value, just pass a clear dummy value here - e.g. a hardcoded string "1" or whatever.
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_chromium_chromeos_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...)
The CQ bit was checked by lawrencewu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Address comments. mark@: PTAL, thanks. https://codereview.chromium.org/2565683003/diff/140001/base/metrics/field_tri... File base/metrics/field_trial.cc (right): https://codereview.chromium.org/2565683003/diff/140001/base/metrics/field_tri... base/metrics/field_trial.cc:947: cmd_line->AppendSwitchASCII(field_trial_handle_switch, field_trial_handle); On 2016/12/12 16:02:39, Alexei Svitkine (OO from 15th) wrote: > If in this case you're using the param with an intentionally dummy value, just > pass a clear dummy value here - e.g. a hardcoded string "1" or whatever. Done.
LGTM
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
The CQ bit was checked by asvitkine@chromium.org
The patchset sent to the CQ was uploaded after l-g-t-m from asvitkine@chromium.org Link to the patchset: https://codereview.chromium.org/2565683003/#ps160001 (title: "Use intentionally dummy value and fix comment")
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
CQ is committing da patch. Bot data: {"patchset_id": 160001, "attempt_start_ts": 1481658614612260, "parent_rev": "eb4733f0c5ab9e192ff5d16726f1199d0ec6f34b", "commit_rev": "e2275a42ccb549ee7a87efffb32d4ff2b361cdc4"}
Message was sent while issue was closed.
Description was changed from ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same mechanism as that in the Linux CL: https://codereview.chromium.org/2530573002/. We basically just need to edit some ifdefs. NOTE: turning on NOPRESUBMIT because the dependent CL re-adds some banned calls to AllowIO. BUG=663912 NOPRESUBMIT=true ========== to ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same mechanism as that in the Linux CL: https://codereview.chromium.org/2530573002/. We basically just need to edit some ifdefs. NOTE: turning on NOPRESUBMIT because the dependent CL re-adds some banned calls to AllowIO. BUG=663912 NOPRESUBMIT=true Review-Url: https://codereview.chromium.org/2565683003 ==========
Message was sent while issue was closed.
Committed patchset #9 (id:160001)
Message was sent while issue was closed.
Description was changed from ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same mechanism as that in the Linux CL: https://codereview.chromium.org/2530573002/. We basically just need to edit some ifdefs. NOTE: turning on NOPRESUBMIT because the dependent CL re-adds some banned calls to AllowIO. BUG=663912 NOPRESUBMIT=true Review-Url: https://codereview.chromium.org/2565683003 ========== to ========== Share field trial allocator on Mac This CL shares the field trial allocator on MacOS. It depends on Mac having POSIX shared memory support, but other than that it is basically the same mechanism as that in the Linux CL: https://codereview.chromium.org/2530573002/. We basically just need to edit some ifdefs. NOTE: turning on NOPRESUBMIT because the dependent CL re-adds some banned calls to AllowIO. BUG=663912 NOPRESUBMIT=true Committed: https://crrev.com/d17b445e932a10c875cea034b037b19d30e47a8c Cr-Commit-Position: refs/heads/master@{#438265} ==========
Message was sent while issue was closed.
Patchset 9 (id:??) landed as https://crrev.com/d17b445e932a10c875cea034b037b19d30e47a8c Cr-Commit-Position: refs/heads/master@{#438265} |