On Thu, 2006-05-11 at 23:27 +0200, Bas Wijnen wrote: > Yes, these things can be enforced with a virtual machine. But I don't > actually see why a virtual machine would be better than a real machine, > considering the performance penalty a virtual machine gives. I have no > numbers, but I don't think it's comparable to the performance you lose because > you can't share more flexible than per page.
There are two separate things here, and it is good not to confuse them. The cost of a safe programming language, compiled in the traditional way, is between 5% and 10%. The cost of a language virtual machine **for long-running programs** is about 100% (i.e. 2x). The cost of a language virtual machine for short-running programs is nearly infinite. One factoid from my IBM days: There was a time when the idea of running java inside a database system seemed attractive. Then they ran some numbers. A typical transaction requires 150,000 instructions for the database server to perform. A typical Java startup requires 1,500,000 bytecodes (about 10 instructions each, so 15,000,000 instructions) **before the first bytecode of the main procedure is executed**. Conclusion: adding server-side java to databases is a great way to convince people that they need faster hardware! shap _______________________________________________ L4-hurd mailing list [email protected] http://lists.gnu.org/mailman/listinfo/l4-hurd
