mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-03-05 14:06:27 -05:00
Merge bitcoin/bitcoin#22923: test: Switch multiprocess to clang i686 build
fa309ee61c
bench: Fix 32-bit compilation failure in addrman bench (MarcoFalke)fae0295a79
ci: Switch multiprocess to i686 build (MarcoFalke) Pull request description: Building for i686 with clang helps to catch bugs early for: * The OSS-Fuzz i686 clang libFuzzer build * The arm 32-bit native clang build Fixes #22889 ACKs for top commit: hebasto: ACKfa309ee61c
Tree-SHA512: 581820d319aae2fcd4dd44979ee3d4164a575f0438476890aa2a7447f1392a5da26766cd6ab954530499b54f66eec2417bdeefdd7efb19bc27dd679cd2b9d0ce
This commit is contained in:
commit
020c2b7609
3 changed files with 9 additions and 6 deletions
|
@ -233,7 +233,7 @@ task:
|
||||||
FILE_ENV: "./ci/test/00_setup_env_native_fuzz.sh"
|
FILE_ENV: "./ci/test/00_setup_env_native_fuzz.sh"
|
||||||
|
|
||||||
task:
|
task:
|
||||||
name: '[multiprocess, DEBUG] [focal]'
|
name: '[multiprocess, i686, DEBUG] [focal]'
|
||||||
<< : *GLOBAL_TASK_TEMPLATE
|
<< : *GLOBAL_TASK_TEMPLATE
|
||||||
container:
|
container:
|
||||||
image: ubuntu:focal
|
image: ubuntu:focal
|
||||||
|
@ -242,7 +242,7 @@ task:
|
||||||
env:
|
env:
|
||||||
<< : *CIRRUS_EPHEMERAL_WORKER_TEMPLATE_ENV
|
<< : *CIRRUS_EPHEMERAL_WORKER_TEMPLATE_ENV
|
||||||
MAKEJOBS: "-j8"
|
MAKEJOBS: "-j8"
|
||||||
FILE_ENV: "./ci/test/00_setup_env_native_multiprocess.sh"
|
FILE_ENV: "./ci/test/00_setup_env_i686_multiprocess.sh"
|
||||||
|
|
||||||
task:
|
task:
|
||||||
name: '[no wallet] [bionic]'
|
name: '[no wallet] [bionic]'
|
||||||
|
|
|
@ -6,11 +6,12 @@
|
||||||
|
|
||||||
export LC_ALL=C.UTF-8
|
export LC_ALL=C.UTF-8
|
||||||
|
|
||||||
export CONTAINER_NAME=ci_native_multiprocess
|
export HOST=i686-pc-linux-gnu
|
||||||
|
export CONTAINER_NAME=ci_i686_multiprocess
|
||||||
export DOCKER_NAME_TAG=ubuntu:20.04
|
export DOCKER_NAME_TAG=ubuntu:20.04
|
||||||
export PACKAGES="cmake python3 python3-pip llvm clang"
|
export PACKAGES="cmake python3 python3-pip llvm clang g++-multilib"
|
||||||
export DEP_OPTS="DEBUG=1 MULTIPROCESS=1"
|
export DEP_OPTS="DEBUG=1 MULTIPROCESS=1"
|
||||||
export GOAL="install"
|
export GOAL="install"
|
||||||
export BITCOIN_CONFIG="--enable-debug CC=clang CXX=clang++" # Use clang to avoid OOM
|
export BITCOIN_CONFIG="--enable-debug CC='clang -m32' CXX='clang++ -m32' LDFLAGS='--rtlib=compiler-rt -lgcc_s'"
|
||||||
export TEST_RUNNER_ENV="BITCOIND=bitcoin-node"
|
export TEST_RUNNER_ENV="BITCOIND=bitcoin-node"
|
||||||
export PIP_PACKAGES="lief"
|
export PIP_PACKAGES="lief"
|
|
@ -5,6 +5,7 @@
|
||||||
#include <addrman.h>
|
#include <addrman.h>
|
||||||
#include <bench/bench.h>
|
#include <bench/bench.h>
|
||||||
#include <random.h>
|
#include <random.h>
|
||||||
|
#include <util/check.h>
|
||||||
#include <util/time.h>
|
#include <util/time.h>
|
||||||
|
|
||||||
#include <optional>
|
#include <optional>
|
||||||
|
@ -110,7 +111,8 @@ static void AddrManGood(benchmark::Bench& bench)
|
||||||
* we want to do the same amount of work in every loop iteration. */
|
* we want to do the same amount of work in every loop iteration. */
|
||||||
|
|
||||||
bench.epochs(5).epochIterations(1);
|
bench.epochs(5).epochIterations(1);
|
||||||
const size_t addrman_count{bench.epochs() * bench.epochIterations()};
|
const uint64_t addrman_count{bench.epochs() * bench.epochIterations()};
|
||||||
|
Assert(addrman_count == 5U);
|
||||||
|
|
||||||
std::vector<std::unique_ptr<CAddrMan>> addrmans(addrman_count);
|
std::vector<std::unique_ptr<CAddrMan>> addrmans(addrman_count);
|
||||||
for (size_t i{0}; i < addrman_count; ++i) {
|
for (size_t i{0}; i < addrman_count; ++i) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue