Math
A napkin-math scratchpad: compose a request from live operations, and see what it adds up to in time and in dollars.
Your scratchpad, not a published figure. Every operation's P50, P99, rate and unit cost below is a live LedgerMath figure, as its Method derived it. Every total is your arithmetic on them, under the assumptions listed at the end: it is not a Derivation of any LedgerMath Method.
Presets
Workload
Each row is one step of a request; steps run one after another, and their percentiles are added, a rough heuristic rather than a bound.
- P50
- ≥ 22.9 ms
- P99
- ≥ 33.4 ms
- Per request
- $0.0000064
slowest of 16: at least one op's P50 and P99; 1 − 0.99^16 = 14.9% of requests wait past one op's P99 (independence assumed)
16 × $0.4 / 10⁶ requests
- P50
- 58.4 ms
- P99
- 58.4 ms
- Per request
- $0.0000111
64 MiB ÷ 1.15 GB/s
0.0671 GB × $0.5968 per GB/s·h / 3,600 s
- P50
- 408 µs
- P99
- 569 µs
- Per request
- —
P50 2 × 204 µs · P99 2 × 285 µs
priced per GB moved, and a round trip's bytes are not measured: use a data volume row of Cross-AZ transfer
Traffic
Per request, and per month
- Sum of P50s
- ≥ 81.8 ms
- Sum of P99s
- ≥ 92.4 ms
- Cost per request
- $0.0000175
- Requests per month
- 262,800,000
- Monthly AWS cost
- $4,606
2 of 3 rows priced
- S3 Standard GET 4 KiB$1,682
- NVMe sequential read$2,924
- Cross-AZ RTT—
What the totals assume
- Operations are independent: one's time says nothing of another's.
- Serial times add: N in a row, and the rows of a request, are summed as N × P50 and N × P99. Adding the percentiles of independent operations is a rough heuristic, not a mathematical bound: the sum of P50s is not the median of the sum, nor a floor under it, and the sum of P99s is not an upper bound (two independent operations can together take more than 2 × P99 more than 1% of the time).
- A parallel fan-out waits for the slowest of k: its CDF is F(t)^k, read from the operation's pooled histogram once the page has it, a quantile interpolated linearly in rank between the times of its bins. Where the pooled sample is too small to say the fan-out's P99, the tail is a lower bound: the larger of one operation's P99 and the fan-out's P50.
- A data volume moves at the operation's median rate, from start to end.
- Costs are the operations' economics v1 figures times your counts: request prices as AWS lists them, box time at the measured speed as if the box did nothing else.
What they leave out
- Storage at rest (S3 GB-months, EBS volumes you keep), NAT gateways, load balancers, internet egress and support plans.
- S3 Express One Zone's per-GB data retrieval and upload fees: its rows are priced by their request fees ($/1M req) alone.
- Your application's own time: parsing, queues, retries, cold starts, connection setup beyond what each benchmark measured.
- Contention: the figures are of one box doing one thing; a shared box, a hot key or a throttled bucket is slower.
Operations
Each is one row of the home timetable, on the machine its Reference stack names: the figures are the Series', as the Methods derived them.
CPU & memory
| Operation | Machine | P50 | P99 | Rate | Unit cost |
|---|---|---|---|---|---|
| Memory read, sequential, one thread per 1 GiB pass | c8i.2xlarge | 53.89 ms | — | 19.93 GB/s | $0.0186 /GB/s·h |
| Decode bit-packed integers per 256 B block | c8i.2xlarge | 24.30 ns | — | 42.13 GB/s | $0.00904 /GB/s·h |
| SHA-256 of 64 B per hash | c8i.2xlarge | 76.69 ns | — | 834.5 MB/s | $0.00000798 /1M ops |
| Sort 1 MiB per 1 MiB sort | c8i.2xlarge | 1.680 ms | — | 624.0 MB/s | $0.175 /1M ops |
Storage
| Operation | Machine | P50 | P99 | Rate | Unit cost |
|---|---|---|---|---|---|
| NVMe random read | i4i.2xlarge | 119.3 µs | 142.3 µs | — | $0.839 /10k IOPS·h |
| NVMe sequential read per 8 KiB pread | i4i.2xlarge | 7.134 µs | — | 1.148 GB/s | $0.597 /GB/s·h |
| EBS gp3 random read | c8i.2xlarge | 342.0 µs | 733.3 µs | — | $1.25 /10k IOPS·h |
Network
| Operation | Machine | P50 | P99 | Rate | Unit cost |
|---|---|---|---|---|---|
| Same-AZ RTT | c8g.2xlarge | 78.46 µs | 116.2 µs | — | $0 /GB moved |
| Cross-AZ RTT | c8g.2xlarge | 203.8 µs | 284.7 µs | — | $0.02 /GB moved |
| Cross-AZ transfer per 128 MiB sample | c8g.2xlarge | 83.59 ms | — | 1.607 GB/s | $0.02 /GB moved |
| Cross-Region RTT, to eu-west-1 | c8i.2xlarge | 78.12 ms | 91.75 ms | — | — |
Object storage (S3)
| Operation | Machine | P50 | P99 | Rate | Unit cost |
|---|---|---|---|---|---|
| S3 Standard GET 4 KiB | c8i.2xlarge | 22.94 ms | 33.42 ms | — | $0.4 /1M req |
| S3 Express GET 4 KiB | c8i.2xlarge | 4.489 ms | 5.538 ms | — | $0.03 /1M req |
| S3 Standard PUT 4 KiB | c8i.2xlarge | 24.51 ms | 31.33 ms | — | $5 /1M req |
| S3 Standard GET throughput | c8i.2xlarge | 509.6 ms | 2.188 s | 1.829 GB/s | $0.205 /GB/s·h |
| S3 Standard HEAD | c8i.2xlarge | 9.896 ms | 32.13 ms | — | $0.4 /1M req |