qxo edited a comment on issue #3068: improve ContextManager.stopSpan performance: call ThreadLocal only once URL: https://github.com/apache/skywalking/pull/3068#issuecomment-511168201 ``` # JMH version: 1.21 # VM version: JDK 11.0.3, Java HotSpot(TM) 64-Bit Server VM, 11.0.3+12-LTS # VM invoker: D:\JDK\jdk-11.x\bin\java.exe # VM options: -Dclassworlds.conf=D:\maven\maven\bin\..\bin\m2.conf -Dmaven.home=D:\maven\maven\bin\.. -Dlibrary.jansi.path=D:\maven\maven\bin\..\lib\jansi-native -Dmaven.multiModuleProjectDirectory=E:\GitHub\dev4skywalking1 -Djava.library.path=D:/java/nativelib # Warmup: 5 iterations, 1 s each # Measurement: 10 iterations, 1 s each # Timeout: 10 min per iteration # Threads: 1 thread, will synchronize iterations # Benchmark mode: Throughput, ops/time # Benchmark: org.apache.skywalking.apm.agent.core.context.ThreadLocalGetXTimeBenchmark.getThreadLocalFourTime T480 ComputerInfo [ CPU=8 cpu OS=Windows 8.1 amd64 6.3 ] Benchmark Mode Cnt Score Error Units Score/min ThreadLocalGetXTimeBenchmark.getThreadLocalFourTime thrpt 10 62499.613 ± 394.732 ops/ms 1.000 ThreadLocalGetXTimeBenchmark.getThreadLocalOnce1 thrpt 10 261239.953 ± 1319.958 ops/ms 4.180 ThreadLocalGetXTimeBenchmark.getThreadLocalTwice thrpt 10 160433.026 ± 17864.714 ops/ms 2.567 ```
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
