chromium/net/spdy/spdy_http_utils_perftest.cc

// Copyright 2023 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "net/spdy/spdy_http_utils.h"

#include "base/memory/ref_counted.h"
#include "net/http/http_request_headers.h"
#include "net/http/http_request_info.h"
#include "net/http/http_response_headers.h"
#include "net/third_party/quiche/src/quiche/common/http/http_header_block.h"
#include "third_party/google_benchmark/src/include/benchmark/benchmark.h"
#include "url/gurl.h"

namespace net {

namespace {

quiche::HttpHeaderBlock MakeHeaderBlock() {}

SpdyHeadersToHttpResponseHeadersFunctionPtrType;

// The benchmark code is templated on the function to force it to be specialized
// at compile time so there is no indirection via a function pointer at runtime
// sllowing it down.
template <SpdyHeadersToHttpResponseHeadersFunctionPtrType convert>
void Benchmark(::benchmark::State& state) {}

BENCHMARK();
BENCHMARK();

void BM_CreateSpdyHeadersFromHttpRequest(::benchmark::State& state) {}

BENCHMARK();

}  // namespace

}  // namespace net