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

Side by Side Diff: tools/external-reference-check.py

Issue 1812853002: Moved the ExternalReferenceTable class to src/external-reference-table.cc/.h (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebase. Created 4 years, 9 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 | « test/cctest/wasm/test-run-wasm-64.cc ('k') | tools/gyp/v8.gyp » ('j') | 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 2014 the V8 project authors. All rights reserved. 2 # Copyright 2014 the V8 project 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 import re 6 import re
7 import os 7 import os
8 import sys 8 import sys
9 9
10 DECLARE_FILE = "src/assembler.h" 10 DECLARE_FILE = "src/assembler.h"
11 REGISTER_FILE = "src/snapshot/serializer-common.cc" 11 REGISTER_FILE = "src/external-reference-table.cc"
12 DECLARE_RE = re.compile("\s*static ExternalReference ([^(]+)\(") 12 DECLARE_RE = re.compile("\s*static ExternalReference ([^(]+)\(")
13 REGISTER_RE = re.compile("\s*Add\(ExternalReference::([^(]+)\(") 13 REGISTER_RE = re.compile("\s*Add\(ExternalReference::([^(]+)\(")
14 14
15 WORKSPACE = os.path.abspath(os.path.join(os.path.dirname(sys.argv[0]), "..")) 15 WORKSPACE = os.path.abspath(os.path.join(os.path.dirname(sys.argv[0]), ".."))
16 16
17 # Ignore those. 17 # Ignore those.
18 BLACKLISTED = [ 18 BLACKLISTED = [
19 "fixed_typed_array_base_data_offset", 19 "fixed_typed_array_base_data_offset",
20 "page_flags", 20 "page_flags",
21 "math_exp_constants", 21 "math_exp_constants",
(...skipping 13 matching lines...) Expand all
35 def Main(): 35 def Main():
36 declarations = Find(DECLARE_FILE, DECLARE_RE) 36 declarations = Find(DECLARE_FILE, DECLARE_RE)
37 registrations = Find(REGISTER_FILE, REGISTER_RE) 37 registrations = Find(REGISTER_FILE, REGISTER_RE)
38 difference = list(set(declarations) - set(registrations) - set(BLACKLISTED)) 38 difference = list(set(declarations) - set(registrations) - set(BLACKLISTED))
39 for reference in difference: 39 for reference in difference:
40 print("Declared but not registered: ExternalReference::%s" % reference) 40 print("Declared but not registered: ExternalReference::%s" % reference)
41 return len(difference) > 0 41 return len(difference) > 0
42 42
43 if __name__ == "__main__": 43 if __name__ == "__main__":
44 sys.exit(Main()) 44 sys.exit(Main())
OLDNEW
« no previous file with comments | « test/cctest/wasm/test-run-wasm-64.cc ('k') | tools/gyp/v8.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698