1 #!/usr/bin/env python 2 # Copyright 2017 the V8 project 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 Fake results processor for testing that just sums some things up. 8 """ 9 10 import fileinput 11 import re 12 13 richards = 0.0 14 deltablue = 0.0 15 16 for line in fileinput.input(): 17 match = re.match(r'^Richards\d: (.*)$', line) 18 if match: 19 richards += float(match.group(1)) 20 match = re.match(r'^DeltaBlue\d: (.*)$', line) 21 if match: 22 deltablue += float(match.group(1)) 23 24 print 'Richards: %f' % richards 25 print 'DeltaBlue: %f' % deltablue 26