Changeset f4abc58 for doc/papers/general/evaluation/cpp-vbench.cpp
- Timestamp:
- Mar 7, 2018, 5:09:18 PM (6 years ago)
- 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:
- fb11446e
- Parents:
- b2e8841 (diff), 7b0dfa4 (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 edited
Legend:
- Unmodified
- Added
- Removed
-
doc/papers/general/evaluation/cpp-vbench.cpp
rb2e8841 rf4abc58 1 1 #include <algorithm> 2 #include <fstream>3 2 #include "bench.hpp" 4 3 #include "cpp-vstack.hpp" 5 #include "cpp-vprint.hpp"6 4 #include "object.hpp" 7 5 8 6 int main(int argc, char** argv) { 9 std::ofstream out{"/dev/null"};10 7 integer maxi{ 0 }, vali{ 42 }; 11 8 stack si, ti; … … 15 12 TIMED( "clear_int", si.clear(); ) 16 13 REPEAT_TIMED( "pop_int", N, maxi = std::max( maxi, ti.pop()->as<integer>() ); /***/ ) 17 REPEAT_TIMED( "print_int", N/2, print( out, vali, c_string{":"}, vali, c_string{"\n"} ); )18 14 19 15 ptr<pair> maxp = make<pair>( make<boolean>(false), make<character>('\0') ); … … 27 23 ptr<pair> xp = as_ptr<pair>( tp.pop() ); /***/ 28 24 if ( *xp > *maxp ) { maxp = std::move(xp); } ) 29 REPEAT_TIMED( "print_pair", N/2, print( out, valp, c_string{":"}, valp, c_string{"\n"} ); )30 25 }
Note: See TracChangeset
for help on using the changeset viewer.