pike.git / lib / modules / Tools.pmod / Standalone.pmod / benchmark.pike

version» Context lines:

pike.git/lib/modules/Tools.pmod/Standalone.pmod/benchmark.pike:1: - // $Id: benchmark.pike,v 1.7 2004/07/08 15:36:42 grubba Exp $ + // $Id: benchmark.pike,v 1.8 2004/07/15 08:55:10 grubba Exp $      #pike __REAL_VERSION__      constant description = "Runs some built in Pike benchmarks.";   constant help = #"   Benchmarks Pike with %d built in benchmark tests.   Arguments:      -h, --help    Shows this help text.
pike.git/lib/modules/Tools.pmod/Standalone.pmod/benchmark.pike:65:    ->run(0,1,1); // fill caches       write("test total user mem (runs)\n");       /* Run overhead check first by default. */    array(string) to_run = ({"Overhead"}) + (sort (indices (tests)) - ({"Overhead"}));    array(string) to_run_names = rows (tests, to_run)->name;       foreach (test_globs, string test_glob)    foreach (to_run; int idx; string id) -  if (id && glob (test_glob, to_run_names[idx])) { +  if (id) { +  if (!to_run_names[idx]) { +  write("No name on test %O!\n", id); +  ecode++; +  // Don't report the error multiple times. +  to_run[idx] = 0; +  } else if (glob (test_glob, to_run_names[idx])) {    ecode += Tools.Shoot.ExecTest(id,tests[id])    ->run(seconds_per_test,maximum_runs);    // Don't run test more than once if it matches several globs.    to_run[idx] = 0;    } -  +  }    return ecode;   }