Bug 1338210 - Set threshold for num_static_constructor alerts to 3 r?jmaher
MozReview-Commit-ID: 6publ0XDq3G
--- a/build/util/count_ctors.py
+++ b/build/util/count_ctors.py
@@ -1,11 +1,12 @@
#!/usr/bin/python
import json
+
import re
import subprocess
import sys
def count_ctors(filename):
proc = subprocess.Popen(
['readelf', '-W', '-S', filename], stdout=subprocess.PIPE)
@@ -51,14 +52,15 @@ if __name__ == '__main__':
for f in sys.argv[1:]:
perfherder_data = {
"framework": {"name": "build_metrics"},
"suites": [{
"name": "compiler_metrics",
"subtests": [{
"name": "num_static_constructors",
"value": count_ctors(f),
- "alertThreshold": 0.25
+ "alertChangeType": "absolute",
+ "alertThreshold": 3
}]}
]
}
print "PERFHERDER_DATA: %s" % json.dumps(perfherder_data)