Changeset dbb1073
- Timestamp:
- Nov 3, 2020, 1:42:53 PM (4 years ago)
- Branches:
- ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
- Children:
- daefe93
- Parents:
- 2c7eee0
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
benchmark/rmit.py
r2c7eee0 rdbb1073 10 10 11 11 import argparse 12 import datetime 12 13 import itertools 13 14 import os … … 101 102 return nopts 102 103 104 def actions_eta(actions): 105 time = 0 106 for a in actions: 107 i = 0 108 while i < len(a): 109 if a[i] == '-d': 110 i += 1 111 if i != len(a): 112 time += int(a[i]) 113 i += 1 114 return time 115 103 116 if __name__ == "__main__": 104 117 # ================================================================================ … … 160 173 # ================================================================================ 161 174 # Prepare to run 175 print(actions) 176 177 # find expected time 178 time = actions_eta(actions) 179 print("Running {} trials{}".format(len(actions), "" if time == 0 else " (expecting to take {}".format(str(datetime.timedelta(seconds=int(time)))) )) 180 162 181 random.shuffle(actions) 163 164 print("Running {} trials".format(len(actions)))165 182 result = [] 166 183
Note: See TracChangeset
for help on using the changeset viewer.