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

Side by Side Diff: components/cronet/tools/check_no_neon.py

Issue 2060333002: [Cronet] Enforce ARMv7 Cronet doesn't inadvertently use ARM Neon instructions (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: get working Created 4 years, 4 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
OLDNEW
(Empty)
1 #!/usr/bin/python
2 # Copyright 2016 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file.
5
6 """
7 check_no_neon.py - Check modules do not contain ARM Neon instructions.
8 """
Dirk Pranke 2016/08/18 17:10:38 nit: this can probably be a single line.
pauljensen 2016/08/19 11:52:05 Done.
9
10 import argparse
11 import os
12 import sys
13
14 def main(args):
Dirk Pranke 2016/08/18 17:10:38 nit: two blank lines.
pauljensen 2016/08/19 11:52:05 Done.
15 parser = argparse.ArgumentParser(
16 description='Check modules do not contain ARM Neon instructions.')
17 parser.add_argument('objdump', metavar='path/to/ARM/objdump')
18 parser.add_argument('objects', metavar='files/to/check/*.o')
19 opts = parser.parse_args(args)
20 return os.system(opts.objdump + ' -d --no-show-raw-insn ' +
21 opts.objects + ' | grep -q "vld[1-9]\\|vst[1-9]"')
22
23 if __name__ == '__main__':
Dirk Pranke 2016/08/18 17:10:38 two blank lines.
pauljensen 2016/08/19 11:52:05 Done.
24 sys.exit(0 if main(sys.argv[1:]) != 0 else -1)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698