From: Godmar Back (gback@cs.utah.edu)
Date: Fri Dec 04 1998 - 21:46:14 EST
>
> If you mean to do real performance checking, you may give the attached
> program a try.
>
Test NO check, quick CHECK slow CHECK
--------------------------------------------------------------------------
getTime: 2624.999510 2623.806348 2624.440289
emptyloop: 23.759843 17.515912 16.802838
monitorenter/exit: 1468.098265 1457.878904 1458.128382
invokestatic: 14.943306 17.559267 16.826722
invokespecial: 16.808857 13.524088 13.511190
invokevirtual: 807.934473 805.949898 835.151376
invokeinterface: 700.212376 790.542561 851.271848
getstatic: 20.843526 23.454546 23.452554
putstatic: 23.404077 23.490909 23.452555
getfield: 26.798050 20.527273 20.111295
putfield: 21.824601 21.735813 21.821157
arraylength: 26.791868 20.581818 20.127328
iaload: 36.853581 33.578761 33.490910
iastore: 32.727273 36.839119 36.849174
new/invokespecial: 10245.772179 9909.426034 10686.333533
newarray: 4938.190797 5085.461581 5336.369934
multianewarray: 17508.844478 17127.715718 20421.951463
println: 70995.777874 79507.162940 93135.850864
All times obtained by running performance four times, and then
averaging the last three runs and multiplying by 1e9 --- so the
times should be in nanoseconds. (This is on a PII/300)
NO check is the JIT as it currently is, without checking for
stack overflow. I'd expect this to be the fastest.
quick CHECK is with an inlined jthread_on_current_stack function
in checkStackOverflow, as shown below:
#if defined(CHECK_STACKOVERFLOW)
#include "systems/unix-jthreads/jthread.h"
static void
checkStackOverflow(void)
{
Hjava_lang_Throwable* overflow;
#if QUICK
/* that would be fast, but break current encapsulation */
if (jthread_on_current_stack((void*)&overflow - needOnStack))
return;
#endif
overflow = (*Kaffe_ThreadInterface.checkStack)(needOnStack);
if (overflow != 0) {
if (needOnStack == STACK_LOW) {
fprintf(stderr,
"Panic: unhandled StackOverflowError()\n");
ABORT();
}
needOnStack = STACK_LOW;
throwException(overflow);
}
}
#endif /* CHECK_STACKOVERFLOW */
slow CHECK uses the "checkStack" interface. I expected that to be the
slowest.
Alexandre, you wrote the tests, how would you interpret the results?
- Godmar
This archive was generated by hypermail 2b29 : Sat Sep 23 2000 - 19:57:06 EDT