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

Side by Side Diff: pnacl/driver/pnacl-ld.py

Issue 14358048: Update pnacl/DEPS to bring in stricter ABI checks for metadata (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client
Patch Set: update deps too Created 7 years, 8 months 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
« pnacl/DEPS ('K') | « pnacl/DEPS ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/python 1 #!/usr/bin/python
2 # Copyright (c) 2012 The Native Client Authors. All rights reserved. 2 # Copyright (c) 2012 The Native Client Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 # 5 #
6 # IMPORTANT NOTE: If you make local mods to this file, you must run: 6 # IMPORTANT NOTE: If you make local mods to this file, you must run:
7 # % pnacl/build.sh driver 7 # % pnacl/build.sh driver
8 # in order for them to take effect in the scons build. This command 8 # in order for them to take effect in the scons build. This command
9 # updates the copy in the toolchain/ tree. 9 # updates the copy in the toolchain/ tree.
10 # 10 #
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 chain.add(DoLTO, 'opt.' + bitcode_type) 371 chain.add(DoLTO, 'opt.' + bitcode_type)
372 elif env.getone('STRIP_MODE') != 'none': 372 elif env.getone('STRIP_MODE') != 'none':
373 chain.add(DoStrip, 'stripped.' + bitcode_type) 373 chain.add(DoStrip, 'stripped.' + bitcode_type)
374 374
375 if env.getbool('STATIC'): 375 if env.getbool('STATIC'):
376 # ABI simplification passes. We should not place arbitrary 376 # ABI simplification passes. We should not place arbitrary
377 # passes after '-expand-constant-expr' because they might 377 # passes after '-expand-constant-expr' because they might
378 # reintroduce ConstantExprs. However, '-expand-getelementptr' 378 # reintroduce ConstantExprs. However, '-expand-getelementptr'
379 # must follow '-expand-constant-expr' to expand the 379 # must follow '-expand-constant-expr' to expand the
380 # getelementptr instructions it creates. 380 # getelementptr instructions it creates.
381 passes = ['-expand-constant-expr', 381 # We place '-strip-metadata' after optimization passes are run
Mark Seaborn 2013/04/26 21:36:45 It would be clearer to omit "are run"
jvoung (off chromium) 2013/04/26 22:54:51 Done.
382 # since optimizations depend on the metadata.
383 passes = ['-strip-metadata',
384 '-expand-constant-expr',
382 '-expand-getelementptr'] 385 '-expand-getelementptr']
383 if (not env.getbool('DISABLE_ABI_CHECK') and 386 if (not env.getbool('DISABLE_ABI_CHECK') and
384 not env.getbool('ALLOW_CXX_EXCEPTIONS') and 387 not env.getbool('ALLOW_CXX_EXCEPTIONS') and
385 len(native_objects) == 0): 388 len(native_objects) == 0):
386 passes += ['-verify-pnaclabi-module', 389 passes += ['-verify-pnaclabi-module',
387 '-verify-pnaclabi-functions'] 390 '-verify-pnaclabi-functions',
391 '-pnaclabi-allow-debug-metadata']
Mark Seaborn 2013/04/26 21:36:45 Maybe comment "This option modifies the behaviour
jvoung (off chromium) 2013/04/26 22:54:51 Done.
388 chain.add(DoLLVMPasses(passes), 392 chain.add(DoLLVMPasses(passes),
389 'expand_features_after_opt.' + bitcode_type) 393 'expand_features_after_opt.' + bitcode_type)
390 else: 394 else:
391 chain = DriverChain('', output, tng) 395 chain = DriverChain('', output, tng)
392 396
393 # If -arch is also specified, invoke pnacl-translate afterwards. 397 # If -arch is also specified, invoke pnacl-translate afterwards.
394 if arch_flag_given: 398 if arch_flag_given:
395 env.set('NATIVE_OBJECTS', *native_objects) 399 env.set('NATIVE_OBJECTS', *native_objects)
396 chain.add(DoTranslate, native_type) 400 chain.add(DoTranslate, native_type)
397 401
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
534 -O<opt-level> Optimize output file 538 -O<opt-level> Optimize output file
535 -M, --print-map Print map file on standard output 539 -M, --print-map Print map file on standard output
536 --whole-archive Include all objects from following archives 540 --whole-archive Include all objects from following archives
537 --no-whole-archive Turn off --whole-archive 541 --no-whole-archive Turn off --whole-archive
538 -s, --strip-all Strip all symbols 542 -s, --strip-all Strip all symbols
539 -S, --strip-debug Strip debugging symbols 543 -S, --strip-debug Strip debugging symbols
540 --undefined SYMBOL Start with undefined reference to SYMBOL 544 --undefined SYMBOL Start with undefined reference to SYMBOL
541 545
542 -help | -h Output this help. 546 -help | -h Output this help.
543 """ 547 """
OLDNEW
« pnacl/DEPS ('K') | « pnacl/DEPS ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698