News for hackers. Stuff that matters.
Re:Squeezing a Little More Performance Out of Bytecode Inter... by kaba0 on Monday June 19, 2023 @12:48AM (#36387412)
I wrote that interpreter roughly a year ago — my computer is definitely not the most up-to-date (the CPU is an intel i5-4690), but I would be surprised if the difference would have disappeared.

Also, I don’t think that it could even in principle be efficiently branch predicted — you are basically doing a memory read, jump conditionally based on that, jump back, do another memory read vs memory read, jump there, memory read, jump there. There is one less jump involved here, so any form of improved branch prediction would also enhance this second form as well.

I found this, you might be able to benchmark it yourself if you have better hardware: https://github.com/vshymanskyy/interp

There are no comments on this comment yet.