summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2020-04-19 21:53:59 +1000
committerDamien George <damien.p.george@gmail.com>2020-04-22 14:03:26 +1000
commit17dc86369f018caaee0b81740619bb1ca5a5f891 (patch)
tree842a3218cc76539479982be2df9c9b5730f5a3f8
parent1cc24cd39a971a03fe397ce575e59aa7d9b48e3b (diff)
tools/metrics.py: Use OrderedDict when reading build log.
So that the output (eg of the diff command) always has the lines in the same order.
-rwxr-xr-xtools/metrics.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/metrics.py b/tools/metrics.py
index e603c43de..25acb30f5 100755
--- a/tools/metrics.py
+++ b/tools/metrics.py
@@ -43,7 +43,7 @@ Other commands:
"""
-import sys, re, subprocess
+import collections, sys, re, subprocess
MAKE_FLAGS = ["-j3", "CFLAGS_EXTRA=-DNDEBUG"]
@@ -98,7 +98,7 @@ def parse_port_list(args):
def read_build_log(filename):
- data = dict()
+ data = collections.OrderedDict()
lines = []
found_sizes = False
with open(filename) as f: