[ALL] Lobbying - Smalltalk KILLER APP!
Tim Olson
tim at jumpnet.com
Wed Jun 30 12:41:10 UTC 1999
>But I don't understand how an interpreted server can have processes
>as lightweight as compiled lightweight processes. Is this after some
>hypothetical compiler has sped up frequently used code paths or
>something? I think I understand parts of that direction, but it does
>not seem to get much discussion here.
An interesting point is that as the number of threads goes up and the
work done per thread between context switches goes down, at some point
interpretive code can actually outperform native code, especially if the
host machine has a lot of registers which must be saved and restored
during native context switches.
For example, a lightweight (user-mode) thread on a PowerPC processor
would take maybe 70-80 cycles (save and restore 32 general-purpose
registers and a few others). An interpreter, on the other hand, may only
have to save and restore a couple of registers (instruction pointer and
heap pointer).
-- tim
More information about the Squeak-dev
mailing list
|