[CLJS-443] protocol dispatch performance enhancement & extend-type to nil Created: 17/Dec/12 Updated: 19/Nov/13 Resolved: 19/Nov/13
Currently we extend to nil to a bunch of protocols, while this was convenient for the initial implementation this has many unfortunate performance consequences. We should probably not extend nil to anything and deal with the nil value directly as is done in Clojure on the JVM. In addition we can add a special ^not-native type-hint. In critical paths this would allow us to inline calls directly to protocol implementations.
Perhaps this could also allow us to hint with ^native to inline calls to the native tables.
|Comment by David Nolen [ 20/Feb/13 8:40 AM ]|
^not-native support is already in master and does deliver performance benefits in the cases where native types need not be considered.
|Comment by David Nolen [ 19/Nov/13 9:33 PM ]|
There are other tickets now that represent a comprehensive path towards optimizing away protocol overheads.