Skip to content

Commit

Permalink
Google Benchmark
Browse files Browse the repository at this point in the history
  • Loading branch information
dahlstrom-g committed May 9, 2024
1 parent 2df15ff commit 765abfc
Show file tree
Hide file tree
Showing 136 changed files with 487 additions and 408 deletions.
116 changes: 75 additions & 41 deletions third_party/google_benchmark/BUILD.gn
Original file line number Diff line number Diff line change
@@ -1,42 +1,76 @@
# Copyright 2021 The Cobalt Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

static_library("google_benchmark") {
testonly = true

sources = [
"src/benchmark.cc",
"src/benchmark_api_internal.cc",
"src/benchmark_name.cc",
"src/benchmark_register.cc",
"src/benchmark_runner.cc",
"src/colorprint_starboard.cc",
"src/commandlineflags.cc",
"src/complexity.cc",
"src/console_reporter.cc",
"src/counter.cc",
"src/csv_reporter.cc",
"src/json_reporter.cc",
"src/reporter.cc",
"src/sleep.cc",
"src/statistics.cc",
"src/string_util.cc",
"src/sysinfo.cc",
"src/timers.cc",
]

include_dirs = [ "include" ]

public_deps = [ "//starboard/common" ]
# Copyright 2019 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

import("buildconfig.gni")

if (enable_google_benchmarks) {
config("benchmark_config") {
include_dirs = [ "src/include" ]
}

source_set("google_benchmark") {
testonly = true

public = [ "src/include/benchmark/benchmark.h" ]

sources = [
"src/src/arraysize.h",
"src/src/benchmark.cc",
"src/src/benchmark_api_internal.cc",
"src/src/benchmark_api_internal.h",
"src/src/benchmark_name.cc",
"src/src/benchmark_register.cc",
"src/src/benchmark_register.h",
"src/src/benchmark_runner.cc",
"src/src/benchmark_runner.h",
"src/src/check.h",
"src/src/colorprint.cc",
"src/src/colorprint.h",
"src/src/commandlineflags.cc",
"src/src/commandlineflags.h",
"src/src/complexity.cc",
"src/src/complexity.h",
"src/src/console_reporter.cc",
"src/src/counter.cc",
"src/src/counter.h",
"src/src/csv_reporter.cc",
"src/src/cycle_clock.h",
"src/src/internal_macros.h",
"src/src/json_reporter.cc",
"src/src/log.h",
"src/src/mutex.h",
"src/src/re.h",
"src/src/reporter.cc",
"src/src/sleep.cc",
"src/src/sleep.h",
"src/src/statistics.cc",
"src/src/statistics.h",
"src/src/string_util.cc",
"src/src/string_util.h",
"src/src/sysinfo.cc",
"src/src/thread_manager.h",
"src/src/thread_timer.h",
"src/src/timers.cc",
"src/src/timers.h",
]

all_dependent_configs = [ ":benchmark_config" ]

configs -= [ "//build/config/compiler:chromium_code" ]
configs += [ "//build/config/compiler:no_chromium_code" ]

defines = [
# Tell gtest to always use standard regular expressions.
"HAVE_GNU_POSIX_REGEX=0",
"HAVE_POSIX_REGEX=0",
"HAVE_STD_REGEX=1",
]
}

source_set("benchmark_main") {
testonly = true
sources = [ "src/src/benchmark_main.cc" ]
deps = [ ":google_benchmark" ]
}
}
277 changes: 0 additions & 277 deletions third_party/google_benchmark/CMakeLists.txt

This file was deleted.

Loading

0 comments on commit 765abfc

Please sign in to comment.