You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, just by brief looking at your code I noticed that you actually measure time with an instantiation of an object. That could possibly distort the results quite a bit since instantiation of an object is usually much more expensive then accessing method.
Meaning that if lets say creating new instance needs 100 units of time, getting property without magic method takes 1 and with magic method takes 10 your results will be 101 units without magic method and 110 with magic method.
This way it looks like it is only about 10% faster. But if you do it without the instantiation you will get 1 to 10 which is actually 10x faster, in percent its 1000%.
Because of that I would like to ask you to either remake your test and do it again.
The text was updated successfully, but these errors were encountered:
Hi, just by brief looking at your code I noticed that you actually measure time with an instantiation of an object. That could possibly distort the results quite a bit since instantiation of an object is usually much more expensive then accessing method.
Meaning that if lets say creating new instance needs 100 units of time, getting property without magic method takes 1 and with magic method takes 10 your results will be 101 units without magic method and 110 with magic method.
This way it looks like it is only about 10% faster. But if you do it without the instantiation you will get 1 to 10 which is actually 10x faster, in percent its 1000%.
Because of that I would like to ask you to either remake your test and do it again.
The text was updated successfully, but these errors were encountered: