summaryrefslogtreecommitdiff
path: root/python/m5/convert.py
diff options
context:
space:
mode:
authorNathan Binkert <binkertn@umich.edu>2005-04-06 17:59:31 -0400
committerNathan Binkert <binkertn@umich.edu>2005-04-06 17:59:31 -0400
commitf3544a13f3559e1e51b1f039e6613d5c47e41fa8 (patch)
tree3e5e584dcad898295ea50e518f1a3b333f19e3c5 /python/m5/convert.py
parent1ee77fb23e12e6d75b4bc7395a244e9f19c7d0db (diff)
downloadgem5-f3544a13f3559e1e51b1f039e6613d5c47e41fa8.tar.xz
Fix the python NetworkBandwidth conversion function
python/m5/convert.py: Fix the NetworkBandwidth conversion function --HG-- extra : convert_revision : 93d9856fe6b59827c116e15835d2ef51292bd6c4
Diffstat (limited to 'python/m5/convert.py')
-rw-r--r--python/m5/convert.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/python/m5/convert.py b/python/m5/convert.py
index 6ccefd2fc..a89303687 100644
--- a/python/m5/convert.py
+++ b/python/m5/convert.py
@@ -153,15 +153,15 @@ def toNetworkBandwidth(value):
raise TypeError, "wrong type '%s' should be str" % type(value)
if value.endswith('Tbps'):
- return float(value[:-3]) * tera
+ return float(value[:-4]) * tera
elif value.endswith('Gbps'):
- return float(value[:-3]) * giga
+ return float(value[:-4]) * giga
elif value.endswith('Mbps'):
- return float(value[:-3]) * mega
+ return float(value[:-4]) * mega
elif value.endswith('kbps'):
- return float(value[:-3]) * kilo
+ return float(value[:-4]) * kilo
elif value.endswith('bps'):
- return float(value[:-2])
+ return float(value[:-3])
else:
return float(value)