-
-
Notifications
You must be signed in to change notification settings - Fork 191
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
upgrading to google benchmark v1.5.1; adding google benchmark
- Loading branch information
Showing
139 changed files
with
18,947 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
Language: Cpp | ||
BasedOnStyle: Google | ||
PointerAlignment: Left | ||
... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
--- | ||
name: Bug report | ||
about: Create a report to help us improve | ||
title: "[BUG]" | ||
labels: '' | ||
assignees: '' | ||
|
||
--- | ||
|
||
**Describe the bug** | ||
A clear and concise description of what the bug is. | ||
|
||
**System** | ||
Which OS, compiler, and compiler version are you using: | ||
- OS: | ||
- Compiler and version: | ||
|
||
**To reproduce** | ||
Steps to reproduce the behavior: | ||
1. sync to commit ... | ||
2. cmake/bazel... | ||
3. make ... | ||
4. See error | ||
|
||
**Expected behavior** | ||
A clear and concise description of what you expected to happen. | ||
|
||
**Screenshots** | ||
If applicable, add screenshots to help explain your problem. | ||
|
||
**Additional context** | ||
Add any other context about the problem here. |
20 changes: 20 additions & 0 deletions
20
lib/benchmark_1.5.1/.github/ISSUE_TEMPLATE/feature_request.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
name: Feature request | ||
about: Suggest an idea for this project | ||
title: "[FR]" | ||
labels: '' | ||
assignees: '' | ||
|
||
--- | ||
|
||
**Is your feature request related to a problem? Please describe.** | ||
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] | ||
|
||
**Describe the solution you'd like** | ||
A clear and concise description of what you want to happen. | ||
|
||
**Describe alternatives you've considered** | ||
A clear and concise description of any alternative solutions or features you've considered. | ||
|
||
**Additional context** | ||
Add any other context or screenshots about the feature request here. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
*.a | ||
*.so | ||
*.so.?* | ||
*.dll | ||
*.exe | ||
*.dylib | ||
*.cmake | ||
!/cmake/*.cmake | ||
!/test/AssemblyTests.cmake | ||
*~ | ||
*.swp | ||
*.pyc | ||
__pycache__ | ||
|
||
# lcov | ||
*.lcov | ||
/lcov | ||
|
||
# cmake files. | ||
/Testing | ||
CMakeCache.txt | ||
CMakeFiles/ | ||
cmake_install.cmake | ||
|
||
# makefiles. | ||
Makefile | ||
|
||
# in-source build. | ||
bin/ | ||
lib/ | ||
/test/*_test | ||
|
||
# exuberant ctags. | ||
tags | ||
|
||
# YouCompleteMe configuration. | ||
.ycm_extra_conf.pyc | ||
|
||
# ninja generated files. | ||
.ninja_deps | ||
.ninja_log | ||
build.ninja | ||
install_manifest.txt | ||
rules.ninja | ||
|
||
# bazel output symlinks. | ||
bazel-* | ||
|
||
# out-of-source build top-level folders. | ||
build/ | ||
_build/ | ||
build*/ | ||
|
||
# in-source dependencies | ||
/googletest/ | ||
|
||
# Visual Studio 2015/2017 cache/options directory | ||
.vs/ | ||
CMakeSettings.json | ||
|
||
# Visual Studio Code cache/options directory | ||
.vscode/ | ||
|
||
# Python build stuff | ||
dist/ | ||
*.egg-info* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
#!/usr/bin/env bash | ||
|
||
# Install a newer CMake version | ||
curl -sSL https://cmake.org/files/v3.6/cmake-3.6.1-Linux-x86_64.sh -o install-cmake.sh | ||
chmod +x install-cmake.sh | ||
sudo ./install-cmake.sh --prefix=/usr/local --skip-license | ||
|
||
# Checkout LLVM sources | ||
git clone --depth=1 https://github.com/llvm-mirror/llvm.git llvm-source | ||
git clone --depth=1 https://github.com/llvm-mirror/libcxx.git llvm-source/projects/libcxx | ||
git clone --depth=1 https://github.com/llvm-mirror/libcxxabi.git llvm-source/projects/libcxxabi | ||
|
||
# Setup libc++ options | ||
if [ -z "$BUILD_32_BITS" ]; then | ||
export BUILD_32_BITS=OFF && echo disabling 32 bit build | ||
fi | ||
|
||
# Build and install libc++ (Use unstable ABI for better sanitizer coverage) | ||
mkdir llvm-build && cd llvm-build | ||
cmake -DCMAKE_C_COMPILER=${C_COMPILER} -DCMAKE_CXX_COMPILER=${COMPILER} \ | ||
-DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=/usr \ | ||
-DLIBCXX_ABI_UNSTABLE=ON \ | ||
-DLLVM_USE_SANITIZER=${LIBCXX_SANITIZER} \ | ||
-DLLVM_BUILD_32_BITS=${BUILD_32_BITS} \ | ||
../llvm-source | ||
make cxx -j2 | ||
sudo make install-cxxabi install-cxx | ||
cd ../ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,231 @@ | ||
sudo: required | ||
dist: trusty | ||
language: cpp | ||
|
||
matrix: | ||
include: | ||
- compiler: gcc | ||
addons: | ||
apt: | ||
packages: | ||
- lcov | ||
env: COMPILER=g++ C_COMPILER=gcc BUILD_TYPE=Coverage | ||
- compiler: gcc | ||
env: COMPILER=g++ C_COMPILER=gcc BUILD_TYPE=Debug | ||
- compiler: gcc | ||
env: COMPILER=g++ C_COMPILER=gcc BUILD_TYPE=Release | ||
- compiler: gcc | ||
addons: | ||
apt: | ||
packages: | ||
- g++-multilib | ||
- libc6:i386 | ||
env: | ||
- COMPILER=g++ | ||
- C_COMPILER=gcc | ||
- BUILD_TYPE=Debug | ||
- BUILD_32_BITS=ON | ||
- EXTRA_FLAGS="-m32" | ||
- compiler: gcc | ||
addons: | ||
apt: | ||
packages: | ||
- g++-multilib | ||
- libc6:i386 | ||
env: | ||
- COMPILER=g++ | ||
- C_COMPILER=gcc | ||
- BUILD_TYPE=Release | ||
- BUILD_32_BITS=ON | ||
- EXTRA_FLAGS="-m32" | ||
- compiler: gcc | ||
env: | ||
- INSTALL_GCC6_FROM_PPA=1 | ||
- COMPILER=g++-6 C_COMPILER=gcc-6 BUILD_TYPE=Debug | ||
- ENABLE_SANITIZER=1 | ||
- EXTRA_FLAGS="-fno-omit-frame-pointer -g -O2 -fsanitize=undefined,address -fuse-ld=gold" | ||
- compiler: clang | ||
env: COMPILER=clang++ C_COMPILER=clang BUILD_TYPE=Debug | ||
- compiler: clang | ||
env: COMPILER=clang++ C_COMPILER=clang BUILD_TYPE=Release | ||
# Clang w/ libc++ | ||
- compiler: clang | ||
dist: xenial | ||
addons: | ||
apt: | ||
packages: | ||
clang-3.8 | ||
env: | ||
- INSTALL_GCC6_FROM_PPA=1 | ||
- COMPILER=clang++-3.8 C_COMPILER=clang-3.8 BUILD_TYPE=Debug | ||
- LIBCXX_BUILD=1 | ||
- EXTRA_CXX_FLAGS="-stdlib=libc++" | ||
- compiler: clang | ||
dist: xenial | ||
addons: | ||
apt: | ||
packages: | ||
clang-3.8 | ||
env: | ||
- INSTALL_GCC6_FROM_PPA=1 | ||
- COMPILER=clang++-3.8 C_COMPILER=clang-3.8 BUILD_TYPE=Release | ||
- LIBCXX_BUILD=1 | ||
- EXTRA_CXX_FLAGS="-stdlib=libc++" | ||
# Clang w/ 32bit libc++ | ||
- compiler: clang | ||
dist: xenial | ||
addons: | ||
apt: | ||
packages: | ||
- clang-3.8 | ||
- g++-multilib | ||
- libc6:i386 | ||
env: | ||
- INSTALL_GCC6_FROM_PPA=1 | ||
- COMPILER=clang++-3.8 C_COMPILER=clang-3.8 BUILD_TYPE=Debug | ||
- LIBCXX_BUILD=1 | ||
- BUILD_32_BITS=ON | ||
- EXTRA_FLAGS="-m32" | ||
- EXTRA_CXX_FLAGS="-stdlib=libc++" | ||
# Clang w/ 32bit libc++ | ||
- compiler: clang | ||
dist: xenial | ||
addons: | ||
apt: | ||
packages: | ||
- clang-3.8 | ||
- g++-multilib | ||
- libc6:i386 | ||
env: | ||
- INSTALL_GCC6_FROM_PPA=1 | ||
- COMPILER=clang++-3.8 C_COMPILER=clang-3.8 BUILD_TYPE=Release | ||
- LIBCXX_BUILD=1 | ||
- BUILD_32_BITS=ON | ||
- EXTRA_FLAGS="-m32" | ||
- EXTRA_CXX_FLAGS="-stdlib=libc++" | ||
# Clang w/ libc++, ASAN, UBSAN | ||
- compiler: clang | ||
dist: xenial | ||
addons: | ||
apt: | ||
packages: | ||
clang-3.8 | ||
env: | ||
- INSTALL_GCC6_FROM_PPA=1 | ||
- COMPILER=clang++-3.8 C_COMPILER=clang-3.8 BUILD_TYPE=Debug | ||
- LIBCXX_BUILD=1 LIBCXX_SANITIZER="Undefined;Address" | ||
- ENABLE_SANITIZER=1 | ||
- EXTRA_FLAGS="-g -O2 -fno-omit-frame-pointer -fsanitize=undefined,address -fno-sanitize-recover=all" | ||
- EXTRA_CXX_FLAGS="-stdlib=libc++" | ||
- UBSAN_OPTIONS=print_stacktrace=1 | ||
# Clang w/ libc++ and MSAN | ||
- compiler: clang | ||
dist: xenial | ||
addons: | ||
apt: | ||
packages: | ||
clang-3.8 | ||
env: | ||
- INSTALL_GCC6_FROM_PPA=1 | ||
- COMPILER=clang++-3.8 C_COMPILER=clang-3.8 BUILD_TYPE=Debug | ||
- LIBCXX_BUILD=1 LIBCXX_SANITIZER=MemoryWithOrigins | ||
- ENABLE_SANITIZER=1 | ||
- EXTRA_FLAGS="-g -O2 -fno-omit-frame-pointer -fsanitize=memory -fsanitize-memory-track-origins" | ||
- EXTRA_CXX_FLAGS="-stdlib=libc++" | ||
# Clang w/ libc++ and MSAN | ||
- compiler: clang | ||
dist: xenial | ||
addons: | ||
apt: | ||
packages: | ||
clang-3.8 | ||
env: | ||
- INSTALL_GCC6_FROM_PPA=1 | ||
- COMPILER=clang++-3.8 C_COMPILER=clang-3.8 BUILD_TYPE=RelWithDebInfo | ||
- LIBCXX_BUILD=1 LIBCXX_SANITIZER=Thread | ||
- ENABLE_SANITIZER=1 | ||
- EXTRA_FLAGS="-g -O2 -fno-omit-frame-pointer -fsanitize=thread -fno-sanitize-recover=all" | ||
- EXTRA_CXX_FLAGS="-stdlib=libc++" | ||
- os: osx | ||
osx_image: xcode8.3 | ||
compiler: clang | ||
env: | ||
- COMPILER=clang++ BUILD_TYPE=Debug | ||
- os: osx | ||
osx_image: xcode8.3 | ||
compiler: clang | ||
env: | ||
- COMPILER=clang++ BUILD_TYPE=Release | ||
- os: osx | ||
osx_image: xcode8.3 | ||
compiler: clang | ||
env: | ||
- COMPILER=clang++ | ||
- BUILD_TYPE=Release | ||
- BUILD_32_BITS=ON | ||
- EXTRA_FLAGS="-m32" | ||
- os: osx | ||
osx_image: xcode9.4 | ||
compiler: gcc | ||
env: | ||
- COMPILER=g++-7 C_COMPILER=gcc-7 BUILD_TYPE=Debug | ||
|
||
before_script: | ||
- if [ -n "${LIBCXX_BUILD}" ]; then | ||
source .travis-libcxx-setup.sh; | ||
fi | ||
- if [ -n "${ENABLE_SANITIZER}" ]; then | ||
export EXTRA_OPTIONS="-DBENCHMARK_ENABLE_ASSEMBLY_TESTS=OFF"; | ||
else | ||
export EXTRA_OPTIONS=""; | ||
fi | ||
- mkdir -p build && cd build | ||
|
||
before_install: | ||
- if [ -z "$BUILD_32_BITS" ]; then | ||
export BUILD_32_BITS=OFF && echo disabling 32 bit build; | ||
fi | ||
- if [ -n "${INSTALL_GCC6_FROM_PPA}" ]; then | ||
sudo add-apt-repository -y "ppa:ubuntu-toolchain-r/test"; | ||
sudo apt-get update --option Acquire::Retries=100 --option Acquire::http::Timeout="60"; | ||
fi | ||
|
||
install: | ||
- if [ -n "${INSTALL_GCC6_FROM_PPA}" ]; then | ||
travis_wait sudo -E apt-get -yq --no-install-suggests --no-install-recommends install g++-6; | ||
fi | ||
- if [ "${TRAVIS_OS_NAME}" == "linux" -a "${BUILD_32_BITS}" == "OFF" ]; then | ||
travis_wait sudo -E apt-get -y --no-install-suggests --no-install-recommends install llvm-3.9-tools; | ||
sudo cp /usr/lib/llvm-3.9/bin/FileCheck /usr/local/bin/; | ||
fi | ||
- if [ "${BUILD_TYPE}" == "Coverage" -a "${TRAVIS_OS_NAME}" == "linux" ]; then | ||
PATH=~/.local/bin:${PATH}; | ||
pip install --user --upgrade pip; | ||
travis_wait pip install --user cpp-coveralls; | ||
fi | ||
- if [ "${C_COMPILER}" == "gcc-7" -a "${TRAVIS_OS_NAME}" == "osx" ]; then | ||
rm -f /usr/local/include/c++; | ||
brew update; | ||
travis_wait brew install gcc@7; | ||
fi | ||
- if [ "${TRAVIS_OS_NAME}" == "linux" ]; then | ||
sudo apt-get update -qq; | ||
sudo apt-get install -qq unzip cmake3; | ||
wget https://github.com/bazelbuild/bazel/releases/download/3.2.0/bazel-3.2.0-installer-linux-x86_64.sh --output-document bazel-installer.sh; | ||
travis_wait sudo bash bazel-installer.sh; | ||
fi | ||
- if [ "${TRAVIS_OS_NAME}" == "osx" ]; then | ||
curl -L -o bazel-installer.sh https://github.com/bazelbuild/bazel/releases/download/3.2.0/bazel-3.2.0-installer-darwin-x86_64.sh; | ||
travis_wait sudo bash bazel-installer.sh; | ||
fi | ||
|
||
script: | ||
- cmake -DCMAKE_C_COMPILER=${C_COMPILER} -DCMAKE_CXX_COMPILER=${COMPILER} -DCMAKE_BUILD_TYPE=${BUILD_TYPE} -DCMAKE_C_FLAGS="${EXTRA_FLAGS}" -DCMAKE_CXX_FLAGS="${EXTRA_FLAGS} ${EXTRA_CXX_FLAGS}" -DBENCHMARK_DOWNLOAD_DEPENDENCIES=ON -DBENCHMARK_BUILD_32_BITS=${BUILD_32_BITS} ${EXTRA_OPTIONS} .. | ||
- make | ||
- ctest -C ${BUILD_TYPE} --output-on-failure | ||
- bazel test -c dbg --define google_benchmark.have_regex=posix --announce_rc --verbose_failures --test_output=errors --keep_going //test/... | ||
|
||
after_success: | ||
- if [ "${BUILD_TYPE}" == "Coverage" -a "${TRAVIS_OS_NAME}" == "linux" ]; then | ||
coveralls --include src --include include --gcov-options '\-lp' --root .. --build-root .; | ||
fi |
Oops, something went wrong.