Ignore:
Timestamp:
Apr 14, 2017, 4:51:13 PM (7 years ago)
Author:
Aaron Moss <a3moss@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
Children:
1504536, e3de500
Parents:
3895b8b5
Message:

Update benchmarks, cleanup edits to the evaluation section

File:
1 edited

Legend:

Unmodified
Added
Removed
  • doc/generic_types/evaluation/cpp-bench.cpp

    r3895b8b5 r3fb7f5e  
    88
    99int main(int argc, char** argv) {
     10        std::ofstream out{"cpp-out.txt"};
    1011        srand(20171025);
    1112
     
    2829                max = std::max( max, t.pop() );
    2930        )
     31        print( out, max, "\n" );
     32
     33        REPEAT_N_TIMED( "print_int", N/2,
     34                print( out, rand(), ":", rand(), "\n" );
     35        )
    3036
    3137        stack<std::pair<bool, char>> s2;
     
    4753                max2 = std::max( max2, t2.pop() );
    4854        )
     55        print( out, max2, "\n" );
    4956
    50         std::ofstream out{"cpp-out.txt"};
    51         REPEAT_TIMED( "print_int",
    52                 print( out, rand(), ":", rand(), "\n" );
    53         )
    54 
    55         REPEAT_TIMED( "print_pair",
     57        REPEAT_N_TIMED( "print_pair", N/2,
    5658                print( out, std::pair<bool, char>{ rand() & 0x1, rand() & 0x7F }, ":",
    5759                                std::pair<bool, char>{ rand() & 0x1, rand() & 0x7F }, "\n" );
Note: See TracChangeset for help on using the changeset viewer.