summaryrefslogtreecommitdiff
path: root/util/stats/info.py
diff options
context:
space:
mode:
authorSteve Reinhardt <stever@eecs.umich.edu>2004-11-23 00:00:59 -0500
committerSteve Reinhardt <stever@eecs.umich.edu>2004-11-23 00:00:59 -0500
commita6696a4e7bbc3a1286e9fac8c8c3fab42e8e50de (patch)
tree04f418983a12f5a0e4f1abaab1ab46dd80dc969e /util/stats/info.py
parent45198407d11aecc856d0418466e46a94286425f9 (diff)
parent409f7812b25fe7be9beea066f21a929da2bc83c8 (diff)
downloadgem5-a6696a4e7bbc3a1286e9fac8c8c3fab42e8e50de.tar.xz
Merge zizzer.eecs.umich.edu:/z/m5/Bitkeeper/m5
into zizzer.eecs.umich.edu:/z/stever/bk/m5 --HG-- extra : convert_revision : 8c257ce0f25c1a9deab4cbad1c81ada006b10b8d
Diffstat (limited to 'util/stats/info.py')
-rw-r--r--util/stats/info.py44
1 files changed, 21 insertions, 23 deletions
diff --git a/util/stats/info.py b/util/stats/info.py
index 15a4a7d73..fa318a650 100644
--- a/util/stats/info.py
+++ b/util/stats/info.py
@@ -47,28 +47,21 @@ def wrapop(op, lv, rv):
return op(lv, rv)
-def same(lv, rv):
- for lrun,rrun in zip(lv.keys(),rv.keys()):
- if lrun != rrun:
- print 'lrun != rrun'
- print lrun, rrun
- print lv.keys()
- print rv.keys()
+def same(lrun, rrun):
+ for lx,rx in zip(lrun.keys(),rrun.keys()):
+ if lx != rx:
+ print 'lx != rx'
+ print lx, rx
+ print lrun.keys()
+ print rrun.keys()
return False
- for lx,rx in zip(lv[lrun].keys(),rv[rrun].keys()):
- if lx != rx:
- print 'lx != rx'
- print lx, rx
- print lv[lrun].keys()
- print rv[rrun].keys()
+ for ly,ry in zip(lrun[lx].keys(),rrun[rx].keys()):
+ if ly != ry:
+ print 'ly != ry'
+ print ly, ry
+ print lrun[lx].keys()
+ print rrun[rx].keys()
return False
- for ly,ry in zip(lv[lrun][lx].keys(),rv[rrun][rx].keys()):
- if ly != ry:
- print 'ly != ry'
- print ly, ry
- print lv[lrun][lx].keys()
- print rv[rrun][rx].keys()
- return False
return True
@@ -79,10 +72,15 @@ def binaryop(op, lf, rf):
lv = lf.value
rv = rf.value
- if not same(lv, rv):
- raise AttributeError, "run,x,y not identical"
+ theruns = []
+ for r in lv.keys():
+ if rv.has_key(r):
+ if same(lv[r], rv[r]):
+ theruns.append(r)
+ else:
+ raise AttributeError
- for run in lv.keys():
+ for run in theruns:
result[run] = {}
for x in lv[run].keys():
result[run][x] = {}