capnproto/node-capnp

Performance

heri16 opened this issue · 1 comments

It's an addon, but the v8 -> C++ calling mechanism is not the main problem here. The problem is that once we get to C++ we're calling the Cap'n Proto dynamic API, which is based on lookup tables and such and is therefore quite a bit slower than accessing a native Javascript object would be. Regular C++ code using Cap'n Proto relies on generated code for performance, but we can't generate and compile new C++ code whenever Javascript tries to import a schema.