Open kaushik143 opened 3 years ago
Optimizable means that the function can be optimized, but the compiler has not yet found it worthwhile to optimize the method. It is not a bottleneck. However, if you have megamorphic property access sites then you should look into if you can avoid mutating the properties of the input object. That property will be unnecessarily slow to access.
I am using deoptigate to find out bottlenecks for my node application and I see a lot of functions in an optimizable state but I don't understand if this is a bottleneck or not. Since I expect the function to be in an optimized state if it is not a bottleneck.
Attaching screenshot for optimizable state
Similarly, under inline-cache grouping, I see dynamic key access as megamorphism but that also I am not sure if it is bottleneck. Here is the definition of function
const getResponseHeaders = (▲response, key) => response[☎'_headers'][☎key];
It shows problem at '_headers' and 'key' and key here is string which get 2 different valuesPlease help me understand properly that How to use this in a better way. I read this blog multiple times and it is really helpful in the case of deoptimization but nothing is mention for these two 2 other grouping.