Performance Properties
Learn about different aspects of performance to speed up the execution time.
We'll cover the following...
Aspects of performance
Before we start measuring, we must know which performance properties are important for the application we are writing. In this section, we will know some frequently used terms when measuring performance. Depending on the application we are writing, some properties are more relevant than others. For example, throughput might be a more important property than latency if we are writing an online image converter service, whereas latency is key when writing interactive applications with real-time requirements. Below are some valuable terms and concepts that are worth becoming familiar with during performance measurement:
Latency/response time: Depending on the domain, latency and response time might have very precise and different meanings. However, in this course, we mean the time between the request and the response of an operation—for example, the time it takes for an image conversion service to process one image.
Throughput: This refers to the number of transactions (operations, requests, and so on) processed per time unit—for example, the number of images that an image conversion service can process per second.
I/O bound or CPU bound: A task usually spends the majority of its time computing things on the CPU or waiting for I/O (hard drives, networks, and so on). A task is said to be CPU bound if it would run faster if the CPU were faster. It's said to be I/O bound if it would run faster by making the I/O faster. Sometimes you hear about memory-bound tasks too, which means that the amount or speed of the main memory is the current bottleneck.
Power consumption: This is a very important consideration for code that executes on mobile devices ...