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

Side by Side Diff: chrome/nacl.gypi

Issue 8588046: nacl_helper_bootstrap: Reserve correct address space size for ARM, none for x86-64 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/nacl/nacl_helper_bootstrap_linux.x » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 { 5 {
6 'include': [ 6 'include': [
7 '../native_client/build/untrusted.gypi', 7 '../native_client/build/untrusted.gypi',
8 ], 8 ],
9 'target_defaults': { 9 'target_defaults': {
10 'variables': { 10 'variables': {
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 'defines': [ 120 'defines': [
121 'NACL_BLOCK_SHIFT=5', 121 'NACL_BLOCK_SHIFT=5',
122 'NACL_BLOCK_SIZE=32', 122 'NACL_BLOCK_SIZE=32',
123 '<@(nacl_defines)', 123 '<@(nacl_defines)',
124 ], 124 ],
125 }, 125 },
126 }, 126 },
127 ], 127 ],
128 }], 128 }],
129 ['OS=="linux" and coverage==0', { 129 ['OS=="linux" and coverage==0', {
130 'conditions': [
131 ['target_arch=="x64"', {
132 'variables': {
133 # No extra reservation.
134 'nacl_reserve_top': [],
135 }
136 }],
137 ['target_arch=="ia32"', {
138 'variables': {
139 # 1G address space.
140 'nacl_reserve_top': ['--defsym', 'RESERVE_TOP=0x40000000'],
141 }
142 }],
143 ['target_arch=="arm"', {
144 'variables': {
145 # 1G address space, plus 4K guard area above because
146 # immediate offsets are 12 bits.
147 'nacl_reserve_top': ['--defsym', 'RESERVE_TOP=0x40001000'],
Mark Seaborn 2011/11/18 00:31:03 As an aside, do we cross-check this? If I lower e
148 }
149 }],
150 ],
130 'targets': [ 151 'targets': [
131 { 152 {
132 'target_name': 'nacl_helper', 153 'target_name': 'nacl_helper',
133 'type': 'executable', 154 'type': 'executable',
134 'include_dirs': [ 155 'include_dirs': [
135 '..', 156 '..',
136 ], 157 ],
137 'dependencies': [ 158 'dependencies': [
138 'nacl', 159 'nacl',
139 ], 160 ],
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
267 }], 288 }],
268 ['target_arch=="ia32"', { 289 ['target_arch=="ia32"', {
269 'variables': { 290 'variables': {
270 'linker_emulation': 'elf_i386', 291 'linker_emulation': 'elf_i386',
271 'bootstrap_extra_lib': '', 292 'bootstrap_extra_lib': '',
272 } 293 }
273 }], 294 }],
274 ['target_arch=="arm"', { 295 ['target_arch=="arm"', {
275 'variables': { 296 'variables': {
276 'linker_emulation': 'armelf_linux_eabi', 297 'linker_emulation': 'armelf_linux_eabi',
277 # ARM requires linking against libc due to ABI dependenc ies on 298 # ARM requires linking against libc due to ABI
278 # memset 299 # dependencies on memset.
279 'bootstrap_extra_lib' : "${SYSROOT}/usr/lib/libc.a", 300 'bootstrap_extra_lib' : "${SYSROOT}/usr/lib/libc.a",
280 } 301 }
281 }], 302 }],
282 ], 303 ],
283 'action': ['../tools/ld_bfd/ld', 304 'action': ['../tools/ld_bfd/ld',
284 '-m', '<(linker_emulation)', 305 '-m', '<(linker_emulation)',
285 '--build-id', 306 '--build-id',
286 # This program is (almost) entirely standalone. It 307 # This program is (almost) entirely
287 # has its own startup code, so no crt1.o for it. I t is 308 # standalone. It has its own startup code, so
288 # statically linked, and on x86 it does not use 309 # no crt1.o for it. It is statically linked,
289 # libc at all. However, on ARM it needs a few (saf e) 310 # and on x86 it does not use libc at all.
290 # things from libc. 311 # However, on ARM it needs a few (safe) things
312 # from libc.
291 '-static', 313 '-static',
292 # Link with custom linker script for special layout . 314 # Link with custom linker script for special
315 # layout. The script uses the symbol RESERVE_TOP.
316 '<@(nacl_reserve_top)',
293 '--script=<(linker_script)', 317 '--script=<(linker_script)',
294 '-o', '<@(_outputs)', 318 '-o', '<@(_outputs)',
295 # On x86-64, the default page size with some 319 # On x86-64, the default page size with some
296 # linkers is 2M rather than the real Linux page 320 # linkers is 2M rather than the real Linux page
297 # size of 4K. A larger page size is incompatible 321 # size of 4K. A larger page size is incompatible
298 # with our custom linker script's special layout. 322 # with our custom linker script's special layout.
299 '-z', 'max-page-size=0x1000', 323 '-z', 'max-page-size=0x1000',
300 '--whole-archive', '<(bootstrap_lib)', 324 '--whole-archive', '<(bootstrap_lib)',
301 '--no-whole-archive', 325 '--no-whole-archive',
302 '<@(bootstrap_extra_lib)', 326 '<@(bootstrap_extra_lib)',
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
339 'target_name': 'nacl_win64', 363 'target_name': 'nacl_win64',
340 'type': 'none', 364 'type': 'none',
341 'sources': [], 365 'sources': [],
342 }, 366 },
343 ], 367 ],
344 }], 368 }],
345 ], 369 ],
346 }], 370 }],
347 ], 371 ],
348 } 372 }
OLDNEW
« no previous file with comments | « no previous file | chrome/nacl/nacl_helper_bootstrap_linux.x » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698