Ignore:
Timestamp:
Apr 10, 2017, 3:17:29 PM (7 years ago)
Author:
Thierry Delisle <tdelisle@…>
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:
b715c9a
Parents:
b0fedd4 (diff), b276be5 (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.
Message:

Merge branch 'master' of plg.uwaterloo.ca:software/cfa/cfa-cc

File:
1 edited

Legend:

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

    rb0fedd4 r7a054e82  
    11#include <stdlib.h>
    2 #include "bench.h"
    3 #include "cpp-stack.h"
     2#include "bench.hpp"
     3#include "cpp-stack.hpp"
    44
    55int main(int argc, char** argv) {
     
    77
    88        stack<int> s;
    9 
    109        REPEAT_TIMED( "push_int",
    1110                s.push( rand() );
    1211        )
     12
     13        stack<int> t;
     14        TIMED( "copy_int",
     15                t = s;
     16        )
     17
     18        TIMED( "clear_int",
     19                s.clear();
     20        )
     21
     22        int sum;
     23        REPEAT_TIMED( "pop_int",
     24                sum += t.pop();
     25        )
    1326}
Note: See TracChangeset for help on using the changeset viewer.