From: MikkelFJ Date: 2002-10-17T07:45:03+09:00 Subject: Re: Psyco "Dave Thomas" wrote in message news:m2vg42i7a9.fsf@zip.local.thomases.com... > "MikkelFJ" writes: > You > might have to keep the old bytecodes lying around, and reactivate them > if you ever determine any operators such as '+' had been changed. True. I actually believe this is the key to highperformance Ruby. There are many ways you can optimize ruby. Most or all of these optimizations may become invalidated, but rarely do. The solution is to always have a backup plan but use the optimized version whereever possible. For example a guarded compiled codesection that first tests for versioning or involved classes. Or code compiled for special argument types like C++ template specialization. Less aggressive is using dispatch tables that can be updated, but such that bytecode - or assembler calls into the dispatch without hash lookups. Calling methods not accounted for in the dispatch table goes via the ordinary hash lookup. Mikkel