Unverified Commit 56cb07c2 authored by Alexandru Vasile's avatar Alexandru Vasile
Browse files

bench: Use KIB instead of `1 * KiB`



Signed-off-by: default avatarAlexandru Vasile <alexandru.vasile@parity.io>
parent db35a04d
Pipeline #202779 passed with stages
in 6 minutes and 48 seconds
......@@ -320,7 +320,7 @@ fn http_custom_headers_round_trip(
name: &str,
request: RequestType,
) {
for header_size in [1 * KIB, 2 * KIB, 8 * KIB] {
for header_size in [KIB, 2 * KIB, 8 * KIB] {
let mut headers = HeaderMap::new();
headers.insert("key", "A".repeat(header_size).parse().unwrap());
......@@ -334,7 +334,7 @@ fn http_custom_headers_round_trip(
/// Bench WS handshake with different header sizes.
fn ws_custom_headers_handshake(rt: &TokioRuntime, crit: &mut Criterion, url: &str, name: &str, request: RequestType) {
let mut group = crit.benchmark_group(request.group_name(name));
for header_size in [0, 1 * KIB, 2 * KIB, 4 * KIB] {
for header_size in [0, KIB, 2 * KIB, 4 * KIB] {
group.bench_function(format!("{}", header_size), |b| {
b.to_async(rt).iter(|| async move {
let mut headers = HeaderMap::new();
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment