Lines Matching defs:loops

57 **             - l <num> to control the number of loops
105 PRInt32 loops;
114 PRInt32 loops;
122 static PRIntervalTime Sleeper(PRUint32 loops)
125 while (loops-- > 0)
136 static PRIntervalTime MakeLock(PRUint32 loops)
139 while (loops-- > 0)
148 static PRIntervalTime NonContentiousLock(PRUint32 loops)
152 while (loops-- > 0)
164 while (contention->loops-- > 0)
174 static PRIntervalTime ContentiousLock(PRUint32 loops)
182 contention->loops = loops;
193 while (contention->loops-- > 0)
218 static PRIntervalTime MakeMonitor(PRUint32 loops)
221 while (loops-- > 0)
230 static PRIntervalTime NonContentiousMonitor(PRUint32 loops)
234 while (loops-- > 0)
253 static PRIntervalTime ReentrantMonitor(PRUint32 loops)
288 while (contention->loops-- > 0)
298 static PRUint32 ContentiousMonitor(PRUint32 loops)
306 contention->loops = loops;
317 while (contention->loops-- > 0)
342 static PRIntervalTime NonContentiousCMonitor(PRUint32 loops)
345 while (loops-- > 0)
356 while (contention->loops-- > 0)
366 static PRIntervalTime ContentiousCMonitor(PRUint32 loops)
375 contention->loops = loops;
384 while (contention->loops-- > 0)
406 const char* msg, PRUint32 (*test)(PRUint32 loops),
407 PRUint32 loops, PRIntervalTime overhead)
421 PRIntervalTime predicted = test(loops);
435 PR_fprintf(PR_STDOUT, "%8.2f usecs/iteration\n", elapsed/loops);
444 PRUint32 cpu, cpus = 2, loops = 100;
454 Command line argument -l <num> sets the number of loops.
471 case 'l': /* number of loops */
472 loops = atoi(opt->value);
492 if (loops == 0) loops = 100;
496 PR_fprintf(std_err, "Lock: Using %d loops\n", loops);
509 duration = Test("Overhead of PR_Sleep", Sleeper, loops, 0);
512 (void)Test("Lock creation/deletion", MakeLock, loops, 0);
513 (void)Test("Lock non-contentious locking/unlocking", NonContentiousLock, loops, 0);
514 (void)Test("Lock contentious locking/unlocking", ContentiousLock, loops, duration);
515 (void)Test("Monitor creation/deletion", MakeMonitor, loops, 0);
516 (void)Test("Monitor non-contentious locking/unlocking", NonContentiousMonitor, loops, 0);
517 (void)Test("Monitor contentious locking/unlocking", ContentiousMonitor, loops, duration);
519 (void)Test("Cached monitor non-contentious locking/unlocking", NonContentiousCMonitor, loops, 0);
520 (void)Test("Cached monitor contentious locking/unlocking", ContentiousCMonitor, loops, duration);
522 (void)ReentrantMonitor(loops);