diff options
Diffstat (limited to 'emcc')
-rwxr-xr-x | emcc | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -565,9 +565,10 @@ try: shared.Building.llvm_opt(in_temp(target_basename + '.bc'), LLVM_OPT_LEVEL[opt_level]) if DEBUG: save_intermediate('opt', 'bc') # Do LTO in a separate pass to work around LLVM bug XXX (see failure e.g. in cubescript) - if DEBUG: print >> sys.stderr, 'emcc: LLVM LTO' - shared.Building.llvm_opt(in_temp(target_basename + '.bc'), ['-disable-inlining', '-std-link-opts']) - if DEBUG: save_intermediate('lto', 'bc') + if not shared.Settings.BUILD_AS_SHARED_LIB and not shared.Settings.LINKABLE: + if DEBUG: print >> sys.stderr, 'emcc: LLVM LTO' + shared.Building.llvm_opt(in_temp(target_basename + '.bc'), ['-disable-inlining', '-std-link-opts']) + if DEBUG: save_intermediate('lto', 'bc') else: # If possible, remove dead functions etc., this potentially saves a lot in the size of the generated code (and the time to compile it) if not LEAVE_INPUTS_RAW and not shared.Settings.BUILD_AS_SHARED_LIB and not shared.Settings.LINKABLE: |