Open BorysTheDev opened 2 hours ago
Two questions!
Why would we care about the performance of CommandRegistry? Have we ever noticed/seen that command lookup in the registry is a considerable bottleneck ? My two cents is that it is not. I see way more low hanging fruits that come from the design. For example proactor dispatch and multi hop operations, replying on single key commands on the dispatched proactor instead of doing the "hop" etc and I would expect that that there are more interesting optimizations there than the commend registry.
What do you mean by:
if-else construction for predefined strings can be easily transformed by a compiler into a hash table by string size and make comparisons as integers
Commands are executed at runtime, so the compiler knows nothing about transforming that string into an integer? Can you plz elaborate?
motivation:
The way for improvement:
@romange I've read about this approach some time ago and unfortunately haven't found that article now