Bug 1175857 - Build libraries composing dump_syms with optimization. r=glandium
authorChris Manchester <cmanchester@mozilla.com>
Mon, 19 Oct 2015 17:57:11 -0700
changeset 303610 35ceec16cee3195ba2c9c5545aeede8198a1d575
parent 303609 11908baa6ee8fe90daad19f5dedef8ca07ee358f
child 303611 ede755bf408567d1ff919e5e5c9fc20e7bff7a73
push id1001
push userraliiev@mozilla.com
push dateMon, 18 Jan 2016 19:06:03 +0000
treeherdermozilla-release@8b89261f3ac4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersglandium
bugs1175857
milestone44.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1175857 - Build libraries composing dump_syms with optimization. r=glandium A previous patch enabled optimizations when building the dump_syms executable. This patch enables optimizations when building dependent libraries, where much of the work is actually done, to achieve the expected speeedup.
toolkit/crashreporter/google-breakpad/src/common/dwarf/moz.build
toolkit/crashreporter/google-breakpad/src/common/linux/moz.build
toolkit/crashreporter/google-breakpad/src/common/mac/moz.build
toolkit/crashreporter/google-breakpad/src/common/moz.build
toolkit/crashreporter/google-breakpad/src/common/solaris/moz.build
--- a/toolkit/crashreporter/google-breakpad/src/common/dwarf/moz.build
+++ b/toolkit/crashreporter/google-breakpad/src/common/dwarf/moz.build
@@ -7,16 +7,20 @@
 if CONFIG['MOZ_CRASHREPORTER']:
     HostLibrary('host_breakpad_dwarf_s')
     HOST_SOURCES += [
         'bytereader.cc',
         'dwarf2diehandler.cc',
         'dwarf2reader.cc',
         'functioninfo.cc',
     ]
+    HOST_CXXFLAGS += [
+        '-O2',
+        '-g',
+    ]
     LOCAL_INCLUDES += [
         '../..',
     ]
 
 # need static lib
 FORCE_STATIC_LIB = True
 
 # This code is only compiled for build-time tools,
--- a/toolkit/crashreporter/google-breakpad/src/common/linux/moz.build
+++ b/toolkit/crashreporter/google-breakpad/src/common/linux/moz.build
@@ -28,16 +28,20 @@ if CONFIG['MOZ_CRASHREPORTER']:
         'dump_symbols.cc',
         'elf_symbols_to_module.cc',
         'elfutils.cc',
         'file_id.cc',
         'guid_creator.cc',
         'linux_libc_support.cc',
         'memory_mapped_file.cc',
     ]
+    HOST_CXXFLAGS += [
+        '-O2',
+        '-g',
+    ]
 
 Library('breakpad_linux_common_s')
 
 FINAL_LIBRARY = 'xul'
 
 if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk':
     DEFINES['ELFSIZE'] = 32
 
--- a/toolkit/crashreporter/google-breakpad/src/common/mac/moz.build
+++ b/toolkit/crashreporter/google-breakpad/src/common/mac/moz.build
@@ -21,16 +21,20 @@ if CONFIG['HOST_OS_ARCH'] != 'Darwin':
 # This is a little weird, but we're building a host and a target lib here.
 # The host lib is used for dump_syms, and the target lib for the
 # crash reporter client.  Therefore, we don't need all the srcs in both.
 if CONFIG['MOZ_CRASHREPORTER']:
     HOST_SOURCES += UNIFIED_SOURCES
     HOST_SOURCES += [
         'dump_syms.cc',
     ]
+    HOST_CXXFLAGS += [
+        '-O2',
+        '-g',
+    ]
     HostLibrary('host_breakpad_mac_common_s')
 
 SOURCES += [
     'bootstrap_compat.cc',
     'HTTPMultipartUpload.m',
     'MachIPC.mm',
     'string_utilities.cc',
 ]
--- a/toolkit/crashreporter/google-breakpad/src/common/moz.build
+++ b/toolkit/crashreporter/google-breakpad/src/common/moz.build
@@ -62,16 +62,20 @@ if CONFIG['OS_ARCH'] != 'WINNT' and CONF
         'md5.cc',
         'module.cc',
         'pathname_stripper.cc',
         'stabs_reader.cc',
         'stabs_to_module.cc',
         'string_conversion.cc',
         'unique_string.cc',
     ]
+    HOST_CXXFLAGS += [
+        '-O2',
+        '-g',
+    ]
     HostLibrary('host_breakpad_common_s')
 
 if CONFIG['OS_ARCH'] == 'Darwin':
     UNIFIED_SOURCES += [
         'mac/dump_syms.cc',
     ]
     HOST_DEFINES['HAVE_MACH_O_NLIST_H'] = True
     DEFINES['HAVE_MACH_O_NLIST_H'] = True
--- a/toolkit/crashreporter/google-breakpad/src/common/solaris/moz.build
+++ b/toolkit/crashreporter/google-breakpad/src/common/solaris/moz.build
@@ -16,15 +16,19 @@ Library('breakpad_solaris_common_s')
 
 # not compiling http_upload.cc currently
 # since it depends on libcurl
 HOST_SOURCES += [
     'dump_symbols.cc',
     'file_id.cc',
     'guid_creator.cc',
 ]
+HOST_CXXFLAGS += [
+    '-O2',
+    '-g',
+]
 
 FINAL_LIBRARY = 'xul'
 
 LOCAL_INCLUDES += [
     '../..',
 ]