Comparing Changes Under Similar Conditions

A before-and-after comparison should vary the implementation while keeping the task and relevant measurement environment comparable.

Source
Anbloq
Language
English
Created
Updated
Chapters
4
Reading time
1 min
In this article4 chapters
  1. Trace a speed claim
  2. Preserve exact inputs
  3. Alternate comparable runs when the environment varies
  4. Verify both versions performed the same operation

Trace a speed claim

Timing the old version cold and the new one warm can create a difference unrelated to the edit. Alternate versions or otherwise control the states. Warm-up and cold start identify that variable.

Preserve exact inputs

Use the same representative fixture and record versions, output checks, and runtime environment. Reproducible runs provide the information required to repeat the comparison.[1]

Alternate comparable runs when the environment varies

A host may become busier halfway through a session. Running all baseline measurements first can confuse change with time of day. Pair baseline and candidate trials under similar conditions and vary order where practical. See repeating short measurements.

Pair 1: A then B
Pair 2: B then A
Compare per-pair differences under the same fixture
Record any unrelated interference

Verify both versions performed the same operation

If a candidate returns less data, faster response can reflect changed behavior. Compare outputs before interpreting time differences. Test cold and warm scenarios independently.

References

  1. Google, Site Reliability Engineering ↩