java - Does attaching a profiler cause some things to run slower then others? -
is possible attaching profiler jvm (let's visualvm) make methods run slower, while not effecting others , causing skew in results makes piece of code hotspot when in fact it's not. ask reflection calls example. i'm running code shows lot of time spent in spring aop calls (specifically invokejoinpointusingreflection) - author says runs fine in testing (using in code microbenchmark) when profiled showed method take longer other non-reflection methods. (sorry if that' little unclear) got wondering if profiler have effect , lead developer down false trail. feel free answer examples, reflection part example.
profilers regularly give mis-leading information, in right. tend skew result in simple methods might further optimised if profiling wasn't enabled.
if in doubt suggest use profiler, such yourkit (evalation version should fine) has more light weight recording, can have same issues.
Comments
Post a Comment