You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The instruction pointer for the VM must be stored per coroutine. However, as D does not offer built-in thread-local storage, it is currently stored in a hashmap with the current Fiber being the key (Solution 1).
An alternative solution (Solution 2), if there were no coroutines in Lua, would be to store a single, global IP.
When comparing 7 runs of solutions 1 and 2, taking the best of 1 and the worst of 2 on the given benchmark.lua file, the times being 375.109 and 184.882 milliseconds respectively, solution 2 outperforms the current solution, being over 2.02 times faster.
More than half the runtime of a given program is spent accessing the instruction pointer. This is not good!
The text was updated successfully, but these errors were encountered:
The instruction pointer for the VM must be stored per coroutine. However, as D does not offer built-in thread-local storage, it is currently stored in a hashmap with the current Fiber being the key (Solution 1).
An alternative solution (Solution 2), if there were no coroutines in Lua, would be to store a single, global IP.
When comparing 7 runs of solutions 1 and 2, taking the best of 1 and the worst of 2 on the given
benchmark.lua
file, the times being 375.109 and 184.882 milliseconds respectively, solution 2 outperforms the current solution, being over 2.02 times faster.More than half the runtime of a given program is spent accessing the instruction pointer. This is not good!
The text was updated successfully, but these errors were encountered: