官术网_书友最值得收藏!

Benchmarking

It's difficult to compare the performance of algorithms simply by looking at their descriptions or pseudocode. It's better to run actual implementations on a real system. This method of measurement is called benchmarking. There are three categories of benchmark:

  • Microbenchmarks: These are metrics showing the performance of certain functions. They assume that a small piece of business logic is contained in a single function, and we simply measure how fast this function runs.
  • Macrobenchmarks: These are the opposite of microbenchmarks; they test the entire application.
  • Mesobenchmarks: These are something in-between, measuring features or workflows.

Large applications more or less contain certain critical pieces of code. The JVM is an adaptive virtual machine, meaning it optimizes running code in many ways. Obtaining metrics that are meaningful is actually difficult, which is why microbenchmarks are the most interesting for developers.

主站蜘蛛池模板: 小金县| 汽车| 大厂| 孟津县| 平泉县| 綦江县| 泰兴市| 道真| 渭源县| 广宗县| 麻栗坡县| 潍坊市| 哈尔滨市| 手机| 武冈市| 原平市| 禄劝| 双鸭山市| 广安市| 广宗县| 东台市| 米脂县| 高邑县| 平定县| 徐水县| 铜山县| 鹤岗市| 彭阳县| 彭阳县| 南投市| 乐亭县| 娄烦县| 阿荣旗| 灵石县| 阿勒泰市| 河西区| 蓝田县| 铜梁县| 柘城县| 赤峰市| 曲水县|