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

Side by Side Diff: chrome/tools/build/win/syzygy_instrument.py

Issue 14189005: Make Syzygy instrumentation use --debug-friendly switch. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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
« no previous file with comments | « no previous file | 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/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2012 The Chromium 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 """A utility script to help building Syzygy-instrumented Chrome binaries.""" 6 """A utility script to help building Syzygy-instrumented Chrome binaries."""
7 7
8 import glob 8 import glob
9 import logging 9 import logging
10 import optparse 10 import optparse
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 63
64 64
65 def _InstrumentBinary(syzygy_dir, mode, executable, symbol, dst_dir, 65 def _InstrumentBinary(syzygy_dir, mode, executable, symbol, dst_dir,
66 filter_file): 66 filter_file):
67 """Instruments the executable found in input_dir, and writes the resultant 67 """Instruments the executable found in input_dir, and writes the resultant
68 instrumented executable and symbol files to dst_dir. 68 instrumented executable and symbol files to dst_dir.
69 """ 69 """
70 cmd = [os.path.abspath(os.path.join(syzygy_dir, _INSTRUMENT_EXE)), 70 cmd = [os.path.abspath(os.path.join(syzygy_dir, _INSTRUMENT_EXE)),
71 '--overwrite', 71 '--overwrite',
72 '--mode=%s' % mode, 72 '--mode=%s' % mode,
73 '--debug-friendly',
73 '--input-image=%s' % executable, 74 '--input-image=%s' % executable,
74 '--input-pdb=%s' % symbol, 75 '--input-pdb=%s' % symbol,
75 '--output-image=%s' % os.path.abspath( 76 '--output-image=%s' % os.path.abspath(
76 os.path.join(dst_dir, os.path.basename(executable))), 77 os.path.join(dst_dir, os.path.basename(executable))),
77 '--output-pdb=%s' % os.path.abspath( 78 '--output-pdb=%s' % os.path.abspath(
78 os.path.join(dst_dir, os.path.basename(symbol)))] 79 os.path.join(dst_dir, os.path.basename(symbol)))]
79 80
80 # If a filter was specified then pass it on to the instrumenter. 81 # If a filter was specified then pass it on to the instrumenter.
81 if filter_file: 82 if filter_file:
82 cmd.append('--filter=%s' % os.path.abspath(filter_file)) 83 cmd.append('--filter=%s' % os.path.abspath(filter_file))
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 options.agent_dll = os.path.abspath(os.path.join(options.syzygy_dir, 167 options.agent_dll = os.path.abspath(os.path.join(options.syzygy_dir,
167 _DEFAULT_AGENT_DLLS[options.mode])) 168 _DEFAULT_AGENT_DLLS[options.mode]))
168 _LOGGER.info('Using default agent DLL: %s' % options.agent_dll) 169 _LOGGER.info('Using default agent DLL: %s' % options.agent_dll)
169 170
170 return options 171 return options
171 172
172 173
173 if '__main__' == __name__: 174 if '__main__' == __name__:
174 logging.basicConfig(level=logging.INFO) 175 logging.basicConfig(level=logging.INFO)
175 sys.exit(main(_ParseOptions())) 176 sys.exit(main(_ParseOptions()))
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698