The odd thing is that it seems to take more time in the IRC bot, a dynamic library seems slower than the compiled interpreter. It's 16 seconds for the console application versus roughly a minute in the bot.
I am two or three orders off. That roughly corresponds to 2^8 to 2^10, so there are in the neighborhood of at least eight reasons why Egel is slower.
- The Egel interpreter is a vannila term rewriter.
- The interpreter doesn't optimize.
- The language is untyped.
- The interpreter uses idiomatic C++ and classes from the standard library.
- Thread safe reference counting.
- No standard arithmetic primitives.
- The bytecode generated is dumb.
- The overhead of exceptions.
But not bad for a simplistic robust interpreter. Not bad at all.
I love back-of-an-envelope reasoning.
I love back-of-an-envelope reasoning.
No comments:
Post a Comment