by dabernathy89 · 12y ago · 0 comments
> native functions often have to cover complicated edge cases from the ECMAScript specification, which put them at a performance disadvantage.
Aren't these opposing statements?
function add (a, b) {
return a + b;
}
and this in C: int add(int a,int b)
{
return a + b;
}
you're going to get essentially the same performance.The latter sentence you quoted refers to the specific builtin functions that fast.js re-implements. So we first get close to native performance in JS, then we beat the builtin functions by doing less work overall.