←back to thread

122 points phsilva | 1 comments | | HN request time: 0.221s | source
Show context
riffraff ◴[] No.43111815[source]
How does this differ from direct threading interpreters?

It seems like it solves the same problem (saving the function call overhead) and has the same downsides (requires non-standard compiler extensions)

EDIT: it seems the answer is that compilers do not play well with direct-threaded interpreters and they are able to perform more/better optimizations when looking at normal-sized functions rather than massive blocks

http://lua-users.org/lists/lua-l/2011-02/msg00742.html

replies(3): >>43112497 #>>43112649 #>>43116851 #
1. coldtea ◴[] No.43112649[source]
>and has the same downsides (requires non-standard compiler extensions)

It's not a downside if:

(a) you have those non-standard compiler extensions in the platforms you target

(c) for the rest, you can ifdef an alternative that doesn't require them