Neal Norwitz wrote: > On Wed, Feb 26, 2003 at 04:48:37AM +0100, Christian Tismer wrote: > >>Maybe it also makes sense to use indexing into a static >>array, instead of the case construct. Note that there >>can be one single such table for all opcodes and all cases, >>since opcodes are still disjoint. It depends where this >>table is stored and if this can get in the cache. >> >>While I don't know if this really makes the interpreter >>more efficient, at least it makes it shorter to read >>and maybe easier to maintain. > > Been there, done that: http://python.org/sf/693638 > > I already rejected the patch. :-) Making my own jump table, rather > than using a switch was about 15% slower. Oh, that was not what I meant. I also did this two years ago and tossed it. Function calls are too expensive. What I mean was to fold opcodes by common patterns. Unfortunately this is slower, too. Anyway, I didn't want to get too deep into this. Stopping wasting time now :-) cheers - chris -- Christian Tismer :^) <mailto:tismer@tismer.com> Mission Impossible 5oftware : Have a break! Take a ride on Python's Johannes-Niemeyer-Weg 9a : *Starship* http://starship.python.net/ 14109 Berlin : PGP key -> http://wwwkeys.pgp.net/ work +49 30 89 09 53 34 home +49 30 802 86 56 pager +49 173 24 18 776 PGP 0x57F3BF04 9064 F4E1 D754 C2FF 1619 305B C09C 5A3B 57F3 BF04 whom do you want to sponsor today? http://www.stackless.com/
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4