Changeset c86ee4c for doc/theses/andrew_beach_MMath/code/cond-fixup.cfa
- Timestamp:
- Jul 7, 2021, 6:24:42 PM (5 years ago)
- Branches:
- ADT, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum, stuck-waitfor-destruct
- Children:
- d83b266
- Parents:
- 1f45c7d (diff), b1a2c4a (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - File:
-
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
doc/theses/andrew_beach_MMath/code/cond-fixup.cfa
r1f45c7d rc86ee4c 1 1 // Conditional Match (or Re-Raise) 2 #include <clock.hfa> 2 3 #include <exception.hfa> 4 #include <fstream.hfa> 3 5 #include <stdlib.hfa> 4 6 … … 23 25 int main(int argc, char * argv[]) { 24 26 unsigned int times = 1; 25 unsigned int total_frames = 1; 26 if (2 < argc) { 27 if (1 < argc) { 27 28 times = strtol(argv[1], 0p, 10); 28 29 } 29 if ( 3< argc) {30 total_frames= strtol(argv[2], 0p, 10);30 if (2 < argc) { 31 should_catch = strtol(argv[2], 0p, 10); 31 32 } 32 33 34 Time start_time = timeHiRes(); 33 35 for (unsigned int count = 0 ; count < times ; ++count) { 34 36 try { … … 38 40 } 39 41 } 42 Time end_time = timeHiRes(); 43 sout | "Run-Time (ns): " | (end_time - start_time)`ns; 40 44 }
Note:
See TracChangeset
for help on using the changeset viewer.