diff options
author | tbreisacher@chromium.org <tbreisacher@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-02-07 05:59:26 +0000 |
---|---|---|
committer | tbreisacher@chromium.org <tbreisacher@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-02-07 05:59:26 +0000 |
commit | 1acc0bb23795010c761bab0f396a31543e7f0121 (patch) | |
tree | 1cbdf65b05facc02dc7eb5a435f36fdc543e0e7d /tools/linux | |
parent | 04651e90f90d737ad38a1fd6d974774a8892d69d (diff) | |
download | chromium_src-1acc0bb23795010c761bab0f396a31543e7f0121.zip chromium_src-1acc0bb23795010c761bab0f396a31543e7f0121.tar.gz chromium_src-1acc0bb23795010c761bab0f396a31543e7f0121.tar.bz2 |
Adds '#'s to the beginning of each output line when running with -d
This way, if the output format changes in a way that confuses the bot running sizes.py, we can tell the bot to just ignore lines that start with '#'. See http://codereview.chromium.org/9323047/#msg11
BUG=102013
TEST=none
Review URL: https://chromiumcodereview.appspot.com/9347013
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@120726 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'tools/linux')
-rwxr-xr-x | tools/linux/dump-static-initializers.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/linux/dump-static-initializers.py b/tools/linux/dump-static-initializers.py index 61261cb8..584e222 100755 --- a/tools/linux/dump-static-initializers.py +++ b/tools/linux/dump-static-initializers.py @@ -147,7 +147,7 @@ def main(): parser.add_option('-d', '--diffable', dest='diffable', action='store_true', default=False, help='Prints the filename on each line, for more easily ' - 'diff-able output.') + 'diff-able output. (Used by sizes.py)') opts, args = parser.parse_args() if len(args) != 1: parser.error('missing filename argument') @@ -183,12 +183,14 @@ def main(): ref_output.append(' ' + ref) if opts.diffable: - print '\n'.join(qualified_filename + r for r in ref_output) + print '\n'.join('# ' + qualified_filename + r for r in ref_output) else: print '%s (initializer offset 0x%x size 0x%x)' % (qualified_filename, addr, size) print '\n'.join(ref_output) + '\n' + if opts.diffable: + print '#', print 'Found %d static initializers in %d files.' % (initializer_count, file_count) |