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

Issue 381883002: Non-SFI NaCl: Fix browser_tests based on libc_free.c (Closed)

Created:
6 years, 5 months ago by hamaji
Modified:
6 years, 5 months ago
Reviewers:
Mark Seaborn
CC:
chromium-reviews, native-client-reviews_googlegroups.com, hidehiko, Yuta Kitamura, Nico
Project:
chromium
Visibility:
Public.

Description

Non-SFI NaCl: Fix browser_tests based on libc_free.c There were two issues with clang: - Clang emits .data.rel.ro.local for local struct values with an initializer, which lets the linker to emit a few relocation info. - In debug build, clang uses memcpy to copy a structure with five members. Neither -fno-builtin nor -ffreestanding did not prevent this issue. - In release build, clang translates for-loop based zero copy to memset. This patch initializes all structures without initializers or copy. This patch works with GYP_DEFINES=clang=0. To make sure we will not add memcpy or something in future, we will build libc_free.nexe with -Wl,--no-undefined. This also reverts https://codereview.chromium.org/386543002 to enable the disabled tests. BUG=392768 TEST=./out/Debug/browser_tests --gtest_filter='*NonSfi*Messaging*' Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=282697

Patch Set 1 #

Patch Set 2 : stop using GNU_RELRO #

Total comments: 5

Patch Set 3 : remove -z norelro #

Patch Set 4 : drop -O2 #

Total comments: 3

Patch Set 5 : comment update #

Unified diffs Side-by-side diffs Delta from patch set Stats (+22 lines, -29 lines) Patch
M chrome/test/data/nacl/nacl_test_data.gyp View 1 2 3 4 2 chunks +9 lines, -0 lines 0 comments Download
M chrome/test/data/nacl/nonsfi/libc_free.c View 1 chunk +11 lines, -18 lines 0 comments Download
M chrome/test/nacl/nacl_browsertest.cc View 1 2 1 chunk +2 lines, -11 lines 0 comments Download

Messages

Total messages: 15 (0 generated)
hamaji
https://codereview.chromium.org/381883002/diff/20001/chrome/test/data/nacl/nonsfi/libc_free.c File chrome/test/data/nacl/nonsfi/libc_free.c (right): https://codereview.chromium.org/381883002/diff/20001/chrome/test/data/nacl/nonsfi/libc_free.c#newcode224 chrome/test/data/nacl/nonsfi/libc_free.c:224: struct PP_StartFunctions start_funcs; The initialization of this structure is ...
6 years, 5 months ago (2014-07-10 11:32:24 UTC) #1
Mark Seaborn
LGTM, but I think you should remove the "norelro" bit (and update the commit message), ...
6 years, 5 months ago (2014-07-10 17:17:45 UTC) #2
Nico
(You will also want to revert https://codereview.chromium.org/382013002/ when you land this)
6 years, 5 months ago (2014-07-10 22:15:47 UTC) #3
hamaji
thakis: IrtManifest seems to have a different issue. In short, I think the test code ...
6 years, 5 months ago (2014-07-11 05:16:48 UTC) #4
hamaji
The CQ bit was checked by hamaji@chromium.org
6 years, 5 months ago (2014-07-11 05:16:56 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/hamaji@chromium.org/381883002/40001
6 years, 5 months ago (2014-07-11 05:18:21 UTC) #6
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: linux_chromium_chromeos_rel on tryserver.chromium ...
6 years, 5 months ago (2014-07-11 07:14:18 UTC) #7
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 5 months ago (2014-07-11 07:23:56 UTC) #8
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_chromeos_rel on tryserver.chromium (http://build.chromium.org/p/tryserver.chromium/builders/linux_chromium_chromeos_rel/builds/46661) linux_chromium_rel on tryserver.chromium (http://build.chromium.org/p/tryserver.chromium/builders/linux_chromium_rel/builds/50602) linux_gpu ...
6 years, 5 months ago (2014-07-11 07:23:57 UTC) #9
hamaji
LLVM optimizer is too smart. I guess it would be OK to land this without ...
6 years, 5 months ago (2014-07-11 07:46:16 UTC) #10
Mark Seaborn
LGTM https://codereview.chromium.org/381883002/diff/60001/chrome/test/data/nacl/nacl_test_data.gyp File chrome/test/data/nacl/nacl_test_data.gyp (right): https://codereview.chromium.org/381883002/diff/60001/chrome/test/data/nacl/nacl_test_data.gyp#newcode1143 chrome/test/data/nacl/nacl_test_data.gyp:1143: # requires builtin functions and/or relocations. Actually, Nit: ...
6 years, 5 months ago (2014-07-11 16:27:24 UTC) #11
hamaji
https://codereview.chromium.org/381883002/diff/60001/chrome/test/data/nacl/nacl_test_data.gyp File chrome/test/data/nacl/nacl_test_data.gyp (right): https://codereview.chromium.org/381883002/diff/60001/chrome/test/data/nacl/nacl_test_data.gyp#newcode1143 chrome/test/data/nacl/nacl_test_data.gyp:1143: # requires builtin functions and/or relocations. Actually, On 2014/07/11 ...
6 years, 5 months ago (2014-07-11 18:34:36 UTC) #12
hamaji
The CQ bit was checked by hamaji@chromium.org
6 years, 5 months ago (2014-07-11 18:34:49 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/hamaji@chromium.org/381883002/80001
6 years, 5 months ago (2014-07-11 18:36:18 UTC) #14
commit-bot: I haz the power
6 years, 5 months ago (2014-07-11 21:06:20 UTC) #15
Message was sent while issue was closed.
Change committed as 282697

Powered by Google App Engine
This is Rietveld 408576698