aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2021-08-04Merge branch 'upstream-v1.5.5' of ↵androidx-work-releaseandroidx-window-releaseandroidx-window-extensions-releaseandroidx-window-extensions-core-releaseandroidx-webkit-releaseandroidx-wear-wear-tooling-preview-releaseandroidx-wear-wear-remote-interactions-releaseandroidx-wear-wear-phone-interactions-releaseandroidx-wear-watchface-releaseandroidx-wear-tiles-releaseandroidx-wear-releaseandroidx-wear-platform-releaseandroidx-wear-compose-releaseandroidx-versionedparcelable-releaseandroidx-vectordrawable-releaseandroidx-tracing-releaseandroidx-startup-releaseandroidx-sqlite-releaseandroidx-slidingpanelayout-releaseandroidx-sharetarget-releaseandroidx-savedstate-releaseandroidx-room-releaseandroidx-resourceinspection-releaseandroidx-recyclerview-releaseandroidx-profileinstaller-releaseandroidx-privacysandbox-ads-releaseandroidx-preference-releaseandroidx-platform-releaseandroidx-paging-releaseandroidx-navigation-releaseandroidx-metrics-releaseandroidx-mediarouter-releaseandroidx-media2-releaseandroidx-media-releaseandroidx-main-releaseandroidx-mainandroidx-localbroadcastmanager-releaseandroidx-lifecycle-releaseandroidx-hilt-releaseandroidx-health-releaseandroidx-glance-releaseandroidx-g3-releaseandroidx-fragment-releaseandroidx-emoji2-releaseandroidx-drawerlayout-releaseandroidx-draganddrop-releaseandroidx-customview-customview-poolingcontainer-releaseandroidx-credential-releaseandroidx-core-remoteviews-releaseandroidx-core-releaseandroidx-core-performance-releaseandroidx-core-core-splashscreen-releaseandroidx-core-core-role-releaseandroidx-core-core-google-shortcuts-releaseandroidx-core-animation-releaseandroidx-coordinatorlayout-releaseandroidx-compose-releaseandroidx-compose-material3-releaseandroidx-compose-integration-releaseandroidx-compose-g3-releaseandroidx-compose-compiler-releaseandroidx-compose-beta-releaseandroidx-collection-releaseandroidx-car-app-releaseandroidx-camera-releaseandroidx-browser-releaseandroidx-benchmark-releaseandroidx-arch-core-releaseandroidx-appcompat-releaseandroidx-annotation-releaseandroidx-annotation-annotation-experimental-releaseandroidx-activity-releaseDustin Lam
https://android.googlesource.com/platform/external/google-benchmark into androidx-main Change-Id: I952241ca6bd512eedb106f2966aa29249b559e63
2021-08-04Empty commitInna Palant
2021-06-09[NFCI] Drop warning to satisfy clang's -Wunused-but-set-variable diag (#1174)upstream-v1.5.5upstream-masterRoman Lebedev
Fixes https://github.com/google/benchmark/issues/1172
2021-06-08Add support for new architecture loongarch (#1173)huajingyun
2021-06-04Use modern clang/libc++ for sanitizers (#1171)Dominic Hamon
* Use modern clang/libc++ for sanitizers * update ubuntu * new llvm builds differently * clang, not clang-3.8 * just build what we need
2021-06-03Enable various sanitizer builds in github actions (#1167)Dominic Hamon
* Enable various sanitizer builds in github actions * try with off the shelf versions * nope * specific version? * rats * oops * remove msan for now * reorder so env is set before building libc++
2021-06-03Random interleaving of benchmark repetitions - the sequel (fixes #1051) (#1163)Roman Lebedev
Inspired by the original implementation by Hai Huang @haih-g from https://github.com/google/benchmark/pull/1105. The original implementation had design deficiencies that weren't really addressable without redesign, so it was reverted. In essence, the original implementation consisted of two separateable parts: * reducing the amount time each repetition is run for, and symmetrically increasing repetition count * running the repetitions in random order While it worked fine for the usual case, it broke down when user would specify repetitions (it would completely ignore that request), or specified per-repetition min time (while it would still adjust the repetition count, it would not adjust the per-repetition time, leading to much greater run times) Here, like i was originally suggesting in the original review, i'm separating the features, and only dealing with a single one - running repetitions in random order. Now that the runs/repetitions are no longer in-order, the tooling may wish to sort the output, and indeed `compare.py` has been updated to do that: #1168.
2021-06-03Fix leak in test, and provide path to remove leak from library (#1169)Dominic Hamon
* Fix leak in test, and provide path to remove leak from library * make doc change
2021-06-03[NFCI] Make BenchmarkRunner non-internal to it's .cpp fileRoman Lebedev
Currently the lifetime of a single BenchmarkRunner is constrained to a RunBenchmark(), but that will have to change for interleaved benchmark execution, because we'll need to keep it around to not forget how much repetitions of an instance we've done.
2021-06-03[NFCI] RunBenchmarks(): extract FlushStreams()/Report() functionsRoman Lebedev
Based on original implementation by Hai Huang @haih-g in https://github.com/google/benchmark/pull/1105
2021-06-03compare.py: sort the results (#1168)Roman Lebedev
Currently, the tooling just keeps the whatever benchmark order that was present, and this is fine nowadays, but once the benchmarks will be optionally run interleaved, that will be rather suboptimal. So, now that i have introduced family index and per-family instance index, we can define an order for the benchmarks, and sort them accordingly. There is a caveat with aggregates, we assume that they are in-order, and hopefully we won't mess that order up..
2021-06-03Make 'complexity reports' cache per-family, not global (#1166)Roman Lebedev
While the current variant works, it assumes that all the instances of a single family will be run together, with nothing inbetween them. Naturally, that won't work once the runs may be interleaved.
2021-06-02Introduce per-family instance index (#1165)Roman Lebedev
Much like it makes sense to enumerate all the families, it makes sense to enumerate stuff within families. Alternatively, we could have a global instance index, but i'm not sure why that would be better. This will be useful when the benchmarks are run not in order, for the tools to sort the results properly.
2021-06-02Introduce "family index" field into JSON output (#1164)Roman Lebedev
It may be useful for those wishing to further post-process JSON results, but it is mainly geared towards better support for run interleaving, where results from the same family may not be close-by in the JSON. While we won't be able to do much about that for outputs, the tools can and perhaps should reorder the results to that at least in their output they are in proper order, not run order. Note that this only counts the families that were filtered-in, so if e.g. there were three families, and we filtered-out the second one, the two families (which were first and third) will have family indexes 0 and 1.
2021-06-02BenchmarkFamilies::FindBenchmarks(): correctly use std::vector<>::reserve()Roman Lebedev
It takes the whole total new capacity, not the increase.
2021-06-02Ensure that we print repetition count even when it was specified via flag ↵Roman Lebedev
`--benchmark_repetitions=`
2021-06-01Revert "Implementation of random interleaving. (#1105)" (#1161)Dominic Hamon
This reverts commit a6a738c1cc3b754f1bccc0cefc3aeb551c341f88.
2021-06-01Fix perf counter argument parsing (#1160)Norman Heino
* Fix argument order in StrSplit * Update AUTHORS, CONTRIBUTORS
2021-06-01Run build-and-test on all branchesDominic Hamon
2021-06-01Un-disable github actions :]Roman Lebedev
2021-06-01Run build-and-test on all branchesDominic Hamon
2021-05-30Set theme jekyll-theme-hackerDominic Hamon
2021-05-30bump version to v1.5.4Dominic Hamon
2021-05-28Removing freenode from READMEDominic Hamon
It seems that by setting the /topic in freenode #googlebenchmark to point to libera I have angered the powers that be and we've been locked out of the channel. Libera it is then.
2021-05-21Fix pedantic compilation flag violation (#1156)Mariusz Wachowicz
';' after method definition was removed. Also, pedantic flag is now uncommented in CMakeList.txt.
2021-05-20fix version recorded in releases (#1047)Kai Germaschewski
* cmake: fix handling the case where `git describe` fails * cmake: fix version recorded in releases If downloaded as a tarball release, there will be no info from git to determine the release, so it ends up v0.0.0. If that's the case, we'll now use the release specified in the project() command, which needs to be updated for each new release. * cmake: add `--tags` to `git describe` That way, lightweight tags will also be taken into account, which should never hurt, but it'll help in cases where, for some mysterious reason or other, annotated tags don't make it into a clone. * update releasing.md
2021-05-20Implementation of random interleaving. (#1105)haih-g
* Implementation of random interleaving. See http://github.com/google/benchmark/issues/1051 for the feature requests. Committer: Hai Huang (http://github.com/haih-g) On branch fr-1051 Changes to be committed: modified: include/benchmark/benchmark.h modified: src/benchmark.cc new file: src/benchmark_adjust_repetitions.cc new file: src/benchmark_adjust_repetitions.h modified: src/benchmark_api_internal.cc modified: src/benchmark_api_internal.h modified: src/benchmark_register.cc modified: src/benchmark_runner.cc modified: src/benchmark_runner.h modified: test/CMakeLists.txt new file: test/benchmark_random_interleaving_gtest.cc * Fix benchmark_random_interleaving_gtest.cc for fr-1051 Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark.cc modified: src/benchmark_runner.cc modified: test/benchmark_random_interleaving_gtest.cc * Fix macos build for fr-1051 Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark_api_internal.cc modified: src/benchmark_api_internal.h modified: src/benchmark_runner.cc * Fix macos and windows build for fr-1051. Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark_runner.cc * Fix benchmark_random_interleaving_test.cc for macos and windows in fr-1051 Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: test/benchmark_random_interleaving_gtest.cc * Fix int type benchmark_random_interleaving_gtest for macos in fr-1051 Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: test/benchmark_random_interleaving_gtest.cc * Address dominichamon's comments 03/29 for fr-1051 Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark.cc modified: src/benchmark_api_internal.cc modified: src/benchmark_api_internal.h modified: test/benchmark_random_interleaving_gtest.cc * Address dominichamon's comment on default min_time / repetitions for fr-1051. Also change sentinel of random_interleaving_repetitions to -1. Hopefully it fixes the failures on Windows. Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark.cc modified: src/benchmark_api_internal.cc modified: src/benchmark_api_internal.h * Fix windows test failures for fr-1051 Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark_api_internal.cc modified: src/benchmark_runner.cc * Add license blurb for fr-1051. Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark_adjust_repetitions.cc modified: src/benchmark_adjust_repetitions.h * Switch to std::shuffle() for fr-1105. Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark.cc * Change to 1e-9 in fr-1105 Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark_adjust_repetitions.cc * Fix broken build caused by bad merge for fr-1105. Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark_api_internal.cc modified: src/benchmark_runner.cc * Fix build breakage for fr-1051. Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark.cc modified: src/benchmark_api_internal.cc modified: src/benchmark_api_internal.h modified: src/benchmark_register.cc modified: src/benchmark_runner.cc * Print out reports as they come in if random interleaving is disabled (fr-1051) Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark.cc * size_t, int64_t --> int in benchmark_runner for fr-1051. Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark_runner.cc modified: src/benchmark_runner.h * Address comments from dominichamon for fr-1051 Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark.cc modified: src/benchmark_adjust_repetitions.cc modified: src/benchmark_adjust_repetitions.h modified: src/benchmark_api_internal.cc modified: src/benchmark_api_internal.h modified: test/benchmark_random_interleaving_gtest.cc * benchmar_indices --> size_t to make CI pass: fr-1051 Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark.cc * Fix min_time not initialized issue for fr-1051. Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark_api_internal.cc modified: src/benchmark_api_internal.h * min_time --> MinTime in fr-1051. Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: src/benchmark_api_internal.cc modified: src/benchmark_api_internal.h modified: src/benchmark_runner.cc * Add doc for random interleaving for fr-1051 Committer: Hai Huang <haih@google.com> On branch fr-1051 Your branch is up to date with 'origin/fr-1051'. Changes to be committed: modified: README.md new file: docs/random_interleaving.md Co-authored-by: Dominic Hamon <dominichamon@users.noreply.github.com>
2021-05-20remove appveyor and add libera.chat as IRC resourceDominic Hamon
2021-05-19[PFM] Extend perf counter support to multi-threaded cases. (#1153)Mircea Trofin
* Extend perf counter support to multi-threaded cases. * Docs update * const-ed Snapshot
2021-05-11Support -Wsuggest-override (#1059)Guillaume Chatelet
* Support -Wsuggest-override google/benchmark is C++11 compatible but doesn't use the `override` keyword. Projects using google/benchmark with enabled `-Wsuggest-override` and `-Werror` will fail to compile. * Add -Wsuggest-override cxx flag * Revert unrelated formatting * Revert unrelated formatting, take 2 * Revert unrelated formatting, take 3 * Disable -Wsuggest-override when compiling tests, gtest does not handle it yet Co-authored-by: Dominic Hamon <dominichamon@users.noreply.github.com>
2021-05-10Refactor `BenchmarkInstance` (#1148)Dominic Hamon
* Refactor BenchmarkInstance (precursor to #1105) * fix bazel (debug) build * clang-format on header * fix build error on g++-4.8
2021-05-10Remove travis configs that are covered by actions (#1145)Dominic Hamon
2021-05-07remove done TODOsDominic Hamon
2021-05-07add g++-6 to ubuntu-14.04 (#1144)Dominic Hamon
* add g++-6 to ubuntu-14.04 * fix syntax * fix yamllint errors for build-and-test * fix 'add-apt-repository' command not found * make 'run tests' explicit * enable testing and run both release and debug * oops
2021-05-07Add MSVC ARM64 support to cmake (#1090)Michał Janiszewski
2021-05-07Add ubuntu-14.04 build and test workflow (#1131)Dominic Hamon
* Add ubuntu-14.04 build and test workflow * avoid '.' in job name * no need for fail fast * fix workflow syntax * install some stuff * better compiler installations * update before install * just say yes * trying to match up some paths * Difference between runner and github context in container? * Try some judicious logging * cmake 3.5+ required * specific compiler versions * need git for googletest * Disable testing on old compilers * disable testing properly
2021-05-06Clean -Wreserved-identifier instances (#1143)Roman Lebedev
2021-05-06Fix StrSplit empty string case (#1142)Mircea Trofin
This also fixes #1135. Because StrSplit was returning a vector with an empty string, it was treated by PerfCounters::Create as a legitimate ask for setting up a counter with that name. The empty vector is understood by PerfCounters as "just return NoCounters()".
2021-05-06cmake: Add explicit BENCHMARK_ENABLE_LIBPFM option (#1141)Paweł Bylica
2021-05-05Add API to benchmark allowing for custom context to be added (#1137)Dominic Hamon
* Add API to benchmark allowing for custom context to be added Fixes #525 * add docs * Add context flag output to JSON reporter * Plumb everything into the global context. * Add googletests for custom context * update docs with duplicate key behaviour
2021-05-04Add `benchmark_context` flag that allows per-run custom context. (#1127)Dominic Hamon
* Add `benchmark_context` flag that allows per-run custom context. Add support for key-value flags in general. Added test for key-value flags. Added `benchmark_context` flag. Output content of `benchmark_context` to base reporter. Solves the first part of #525. * Docs and better help
2021-04-30Add multiple compiler support to build-and-test workflow (#1128)Dominic Hamon
* Add 32-bit build support to build-and-test * attempt different yaml multiline string format * syntax fixes to yaml * switch to getting alternative compilers working * remove done TODO * trying to separate out windows * oops, typo. * add TODOs for missing builds wrt travis
2021-04-28enable markdown rendering on github pagesDominic Hamon
2021-04-28Support optional, user-directed collection of performance counters (#1114)Mircea Trofin
* Support optional, user-directed collection of performance counters The patch allows an engineer wishing to drill into the root causes of a regression, for example. Currently, only single threaded runs are supported. The feature is a build-time opt in, and then a runtime opt in. The engineer may run the benchmark executable, passing a list of performance counter names (using libpfm's naming scheme) at the command line. The counter values will then be collected and reported back as UserCounters. This is different from #240 in that it is a benchmark user opt-in, and the counter collection is transparent to the benchmark. Currently, this is only supported on platforms where libpfm is supported. libpfm: http://perfmon2.sourceforge.net/ * 'Use' values param in Snapshot when BENCHMARK_OS_WINDOWS This is to avoid unused parameter warning-as-error * Added missing include for <vector> in perf_counters.cc * Moved doc to docs * Added license blurbs
2021-04-27Be compliant and return 0 from main.Dominic Hamon
Fixes #713
2021-04-27Fix windows warning on type conversion (#1121)Dominic Hamon
2021-04-26Add verbosity to CI logs (#1122)Dominic Hamon
2021-04-26fix cmake issue with referencing a non-existing function argument (#1118)Kai Germaschewski
according to https://cmake.org/cmake/help/latest/command/function.html, "Referencing to ARGV# arguments beyond ARGC have undefined behavior.", which I hit with cmake 3.19.7. This uses ARGC to check whether ARGV1 has been passed before referencing it.
2021-04-24[tools] Fix dumb mistake in previous commit - print aggregates only means ↵Roman Lebedev
aggregates, not non-aggregates
2021-04-24[tools] Don't forget to print UTest when printing aggregates onlyRoman Lebedev
This probably regressed in #1042.