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

Issue 1825893002: PNaCl Dynamic Linking: Added portable dependencies to shared objects. (Closed)

Created:
4 years, 9 months ago by Sean Klein
Modified:
4 years, 8 months ago
Reviewers:
Mark Seaborn
CC:
native-client-reviews_googlegroups.com
Base URL:
https://chromium.googlesource.com/native_client/src/native_client.git@master
Target Ref:
refs/heads/master
Project:
nacl
Visibility:
Public.

Description

PNaCl Dynamic Linking: Added portable dependencies to shared objects. Interface: - This patch will pass the name of any shared libraries (passed to pnacl-clang or pnacl-ld) to the ConvertToPso pass, which can store them in a section similar to DT_NEEDED. - Eventually, we will have to determine a solution for translating / caching PLLs. In the meantime, any applications using a PLL named "libfoo.so" will expect a native shared library named "libfoo.so.translated" to exist at runtime. This is a temporary solution; ideally the application will translate "libfoo.so" itself. This patch: - Teaches drivers how to recognize and filter PLLs, passing them to opt instead of the native linker. - Forces the pll_loader to only load a single ELF file at a time, and determine dependencies by reading the PLLRoot of that file. Additionally, teaches the pll_loader how to recursively add dependencies. - Modifies the pll_hello_world test to depend on a pll_libc using this mechanism for "-l<name>" dependencies. - Adds "dependencies_test" which tests recursively loading multiple dependencies from a single PLL. Relies on https://codereview.chromium.org/1829793002/ TEST=pll_dependencies_test, pll_hello_world_test, run_pll_loader_test BUG=https://bugs.chromium.org/p/nativeclient/issues/detail?id=4351 Committed: https://chromium.googlesource.com/native_client/src/native_client/+/bdf73e78fc501ba9d914f23d2686e1add56566f9

Patch Set 1 : Added basic dependencies test. Need to modify nacl.scons more. #

Patch Set 2 : Merged with duplicate module detection. Updated scons file + documentation. #

Patch Set 3 : TESTING (do not submit -- view for Trybot results) #

Patch Set 4 : #

Total comments: 12

Patch Set 5 : Use file basename as dependency, not absolute / relative path. #

Total comments: 23

Patch Set 6 : Responded to code review #

Total comments: 15

Patch Set 7 : #

Patch Set 8 : Merging #

Patch Set 9 : Bumping Feature Version #

Unified diffs Side-by-side diffs Delta from patch set Stats (+193 lines, -59 lines) Patch
M pnacl/build.sh View 1 2 3 4 5 6 7 8 1 chunk +1 line, -1 line 0 comments Download
M pnacl/driver/filetype.py View 1 2 3 4 5 2 chunks +8 lines, -0 lines 0 comments Download
M pnacl/driver/pnacl-ld.py View 1 2 3 4 5 6 4 chunks +23 lines, -0 lines 0 comments Download
M src/untrusted/pll_loader/pll_loader.h View 1 2 3 4 5 6 7 1 chunk +4 lines, -2 lines 0 comments Download
M src/untrusted/pll_loader/pll_loader.cc View 1 2 3 4 5 6 7 3 chunks +22 lines, -9 lines 0 comments Download
M src/untrusted/pll_loader/pll_loader_main.cc View 1 2 3 4 5 1 chunk +7 lines, -7 lines 0 comments Download
A tests/pnacl_dynamic_loading/dependencies_test.c View 1 2 3 4 5 1 chunk +37 lines, -0 lines 0 comments Download
A tests/pnacl_dynamic_loading/dependencies_test.stdout View 1 chunk +3 lines, -0 lines 0 comments Download
M tests/pnacl_dynamic_loading/nacl.scons View 1 2 3 4 5 6 7 8 8 chunks +67 lines, -31 lines 0 comments Download
M tests/pnacl_dynamic_loading/pll_loader_test.cc View 1 2 3 4 5 6 7 1 chunk +6 lines, -3 lines 0 comments Download
M tests/pnacl_dynamic_loading/pll_symbols_test.cc View 1 2 3 4 5 1 chunk +3 lines, -3 lines 0 comments Download
A + tests/pnacl_dynamic_loading/test_pll_c.c View 1 1 chunk +11 lines, -2 lines 0 comments Download
M toolchain_build/toolchain_build_pnacl.py View 1 2 3 4 5 6 7 8 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 36 (23 generated)
Sean Klein
4 years, 8 months ago (2016-03-28 21:09:29 UTC) #15
Sean Klein
This latest patch has merged in the changes from: https://codereview.chromium.org/1841113002/ and also updated the format ...
4 years, 8 months ago (2016-03-30 01:35:37 UTC) #17
Mark Seaborn
I think this bit in the commit message needs updating: "This section does not yet ...
4 years, 8 months ago (2016-03-30 23:24:58 UTC) #18
Mark Seaborn
https://codereview.chromium.org/1825893002/diff/180001/tests/pnacl_dynamic_loading/dependencies_test.c File tests/pnacl_dynamic_loading/dependencies_test.c (right): https://codereview.chromium.org/1825893002/diff/180001/tests/pnacl_dynamic_loading/dependencies_test.c#newcode33 tests/pnacl_dynamic_loading/dependencies_test.c:33: printf("%d\n", get_module_a_var()); On 2016/03/30 23:24:57, Mark Seaborn wrote: > ...
4 years, 8 months ago (2016-04-01 19:10:42 UTC) #20
Sean Klein
https://codereview.chromium.org/1825893002/diff/160001/pnacl/driver/filetype.py File pnacl/driver/filetype.py (right): https://codereview.chromium.org/1825893002/diff/160001/pnacl/driver/filetype.py#newcode356 pnacl/driver/filetype.py:356: # Although this file looks like a native ".so", ...
4 years, 8 months ago (2016-04-01 23:12:25 UTC) #22
Mark Seaborn
LGTM https://codereview.chromium.org/1825893002/diff/220001/pnacl/driver/pnacl-ld.py File pnacl/driver/pnacl-ld.py (right): https://codereview.chromium.org/1825893002/diff/220001/pnacl/driver/pnacl-ld.py#newcode353 pnacl/driver/pnacl-ld.py:353: assert(plls == []) Style nit: don't need ()s ...
4 years, 8 months ago (2016-04-01 23:42:20 UTC) #23
Sean Klein
https://codereview.chromium.org/1825893002/diff/220001/pnacl/driver/pnacl-ld.py File pnacl/driver/pnacl-ld.py (right): https://codereview.chromium.org/1825893002/diff/220001/pnacl/driver/pnacl-ld.py#newcode353 pnacl/driver/pnacl-ld.py:353: assert(plls == []) On 2016/04/01 23:42:19, Mark Seaborn wrote: ...
4 years, 8 months ago (2016-04-02 00:50:33 UTC) #24
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1825893002/260001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1825893002/260001
4 years, 8 months ago (2016-04-04 18:06:59 UTC) #27
commit-bot: I haz the power
Try jobs failed on following builders: nacl-precise_64-newlib-arm_qemu-pnacl on tryserver.nacl (JOB_FAILED, http://build.chromium.org/p/tryserver.nacl/builders/nacl-precise_64-newlib-arm_qemu-pnacl/builds/5475)
4 years, 8 months ago (2016-04-04 18:17:29 UTC) #29
Mark Seaborn
On 2016/04/04 18:17:29, commit-bot: I haz the power wrote: > Try jobs failed on following ...
4 years, 8 months ago (2016-04-04 18:19:07 UTC) #30
Sean Klein
On 2016/04/04 18:19:07, Mark Seaborn wrote: > On 2016/04/04 18:17:29, commit-bot: I haz the power ...
4 years, 8 months ago (2016-04-04 18:22:43 UTC) #31
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1825893002/280001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1825893002/280001
4 years, 8 months ago (2016-04-04 18:26:19 UTC) #34
commit-bot: I haz the power
4 years, 8 months ago (2016-04-04 19:25:30 UTC) #36
Message was sent while issue was closed.
Committed patchset #9 (id:280001) as
https://chromium.googlesource.com/native_client/src/native_client/+/bdf73e78f...

Powered by Google App Engine
This is Rietveld 408576698