- 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.
推薦閱讀
- Advanced Splunk
- Vue.js設(shè)計(jì)與實(shí)現(xiàn)
- WildFly:New Features
- Progressive Web Apps with React
- Magento 2 Theme Design(Second Edition)
- C語言程序設(shè)計(jì)基礎(chǔ)與實(shí)驗(yàn)指導(dǎo)
- Architecting the Industrial Internet
- Android程序設(shè)計(jì)基礎(chǔ)
- 好好學(xué)Java:從零基礎(chǔ)到項(xiàng)目實(shí)戰(zhàn)
- Learning jQuery(Fourth Edition)
- Advanced Express Web Application Development
- 自學(xué)Python:編程基礎(chǔ)、科學(xué)計(jì)算及數(shù)據(jù)分析(第2版)
- PrimeFaces Blueprints
- Continuous Delivery and DevOps:A Quickstart Guide Second Edition
- PHP 7 Programming Blueprints