- Mastering High Performance with Kotlin
- Igor Kucherenko
- 140字
- 2021-06-25 20:55:24
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.
推薦閱讀
- 程序員面試白皮書
- GeoServer Cookbook
- Docker技術入門與實戰(第3版)
- Manga Studio Ex 5 Cookbook
- Mastering Python Scripting for System Administrators
- R語言編程指南
- Python應用輕松入門
- Learning Neo4j 3.x(Second Edition)
- Learning Unity 2D Game Development by Example
- 好好學Java:從零基礎到項目實戰
- Python Data Science Cookbook
- 時空數據建模及其應用
- 細說Python編程:從入門到科學計算
- Python Machine Learning Blueprints:Intuitive data projects you can relate to
- App Inventor少兒趣味編程動手做