Performance Flashcards
What are several attributes of performance?
Speed
Throughput
Responsiveness
Memory Consumption
To measure performance, we need to design ______ specifically targeting performance objectives
tests
When measuring performance, it really comes down to _______
benchmarking
What are microbenchmarks?
Focusing on small things, like the cost of an operation in isolation. It can help identify core performance details and explain causes
What are macrobenchmarks?
Real world system performance
What are some possible issues in the below code? startTime = getCurrentTimeInSeconds(); doWorkloadOfInterest(); endTime = getCurrentTimeInSeconds(); reportResult(endTime – startTime);
Measurement granularity Warm up effects Nondeterminism Size of workload System interference Background programs?
When bench marking, why do workloads need to be chosen carefully?
Workloads need to be representative. Some inputs can be pathological to stress test.
Measuring something ____ means nothing
once
Using ______ instead of time can be better to predict performance on different machines
cycles
Why is warm up time necessary?
Code might not be compiled until it’s executed frequently (JIT for Java)
Need to make sure code is paged in`
How can we alleviate warm up time issues in tests?
Run the workload many times before benchmarking it (Bad strategy for JVMs)
When benchmarking, you should benchmark many times and average the times to combat ______________ behavior. However, this might throw info away and we might want to know each value
Nondeterministic
How do we interpret/report a benchmark?
Compare that benchmark with your expectation, different solutions, or the performance over time
What is a benchmark suite?
A dataset with multiple benchmarks
What are two methods we can use to consider interpreting a benchmark suite?
Hypothesis testing (ANOVA) Summary statistic (condensing a suite to a single number)