Functions created with eval or new Function will get optimized (after a
while, just like other functions -- nothing is optimized on first use).

That said, modifying prototypes after the fact tends to have a performance
impact, because V8 makes optimizations (all over the place) based on the
assumption that prototypes don't change much. When they do, optimized code
built on such assumptions must be discarded. That may or may not be an
issue for your use case, the only way to find out is to try.



On Fri, Mar 2, 2018 at 7:47 AM Koray <burakko...@gmail.com> wrote:

> Forwarding here from Node.js group as this one is more appropriate.
>
> Hello,
>
> I have a real time application which will require constant updates /
> bug fixes. So I will be constantly defining new functions on
> prototypes or constructors.
>
> My question is, will there be a difference between functions which
> were hard coded and functions defined using eval or Function
> constructor? If so, will require() be possibly able to get around
> this?
>
> Note: Functions will be used multiple times throughout the lifetime of
> the application. Giving this information just in case if they are
> being optimized after the first usage.
> Thank you
>
> --
> --
> v8-users mailing list
> v8-users@googlegroups.com
> http://groups.google.com/group/v8-users
> ---
> You received this message because you are subscribed to the Google Groups
> "v8-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to v8-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to