Skip to content

Commit

Permalink
Add amd64-debian-12-asan-ubsan
Browse files Browse the repository at this point in the history
  • Loading branch information
vladbogo committed Sep 29, 2023
1 parent 3205f0d commit 3d30176
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 0 deletions.
1 change: 1 addition & 0 deletions constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@
'amd64-centos-stream9',
'amd64-debian-11',
'amd64-debian-11-msan',
'amd64-debian-12-asan-ubsan',
'amd64-fedora-37',
'amd64-fedora-38',
'amd64-rhel-9',
Expand Down
40 changes: 40 additions & 0 deletions master-docker-nonstandard/master.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,9 @@ addWorker('hz-bbw', 1, '-msan-clang-debian-11', "quay.io/mariadb-foundation/bb-w
addWorker('hz-bbw', 4, '-msan-clang-debian-11', "quay.io/mariadb-foundation/bb-worker:debian11-msan", jobs=20, save_packages=False)
addWorker('hz-bbw', 5, '-msan-clang-debian-11', "quay.io/mariadb-foundation/bb-worker:debian11-msan", jobs=30, save_packages=False)

addWorker('hz-bbw', 2, '-debian-12', "quay.io/mariadb-foundation/bb-worker:debian12", jobs=20, save_packages=False)
addWorker('hz-bbw', 5, '-debian-12', "quay.io/mariadb-foundation/bb-worker:debian12", jobs=20, save_packages=False)

addWorker('aarch64-bbw', 6, '-ubuntu-2004-debug', "quay.io/mariadb-foundation/bb-worker:ubuntu20.04", jobs=10, save_packages=True)
addWorker('aarch64-bbw', 6, '-debian-10-bintar', "quay.io/mariadb-foundation/bb-worker:debian10-bintar", jobs=10, save_packages=True)

Expand All @@ -232,6 +235,33 @@ addWorker('hz-bbw', 5, '-centos-7-bintar', "quay.io/mariadb-foundation/bb-worker
f_quick_build = getQuickBuildFactory(mtrDbPool)
f_rpm_autobake = getRpmAutobakeFactory(mtrDbPool)

## f_asan_ubsan_build
f_asan_ubsan_build = util.BuildFactory()
f_asan_ubsan_build.addStep(steps.ShellCommand(name="Environment details", command=['bash', '-c', 'date -u && uname -a && ulimit -a']))
f_asan_ubsan_build.addStep(steps.SetProperty(property="dockerfile", value=util.Interpolate("%(kw:url)s", url=dockerfile), description="dockerfile"))
f_asan_ubsan_build.addStep(downloadSourceTarball())
f_asan_ubsan_build.addStep(steps.ShellCommand(command=util.Interpolate("tar -xvzf /mnt/packages/%(prop:tarbuildnum)s_%(prop:mariadb_version)s.tar.gz --strip-components=1")))
f_asan_ubsan_build.addStep(steps.ShellCommand(name="create html log file", command=['bash', '-c', util.Interpolate(getHTMLLogString(), jobs=util.Property('jobs', default='$(getconf _NPROCESSORS_ONLN)'))]))
# build steps
f_asan_ubsan_build.addStep(steps.ShellCommand(command='echo "leak:libtasn1\nleak:libgnutls\nleak:libgmp" > mysql-test/lsan.supp', doStepIf=filterBranch))
f_asan_ubsan_build.addStep(steps.ShellCommand(command='cat mysql-test/lsan.supp', doStepIf=filterBranch))
f_asan_ubsan_build.addStep(steps.Compile(command=
["sh", "-c", util.Interpolate('cmake . -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DCMAKE_BUILD_TYPE=Debug -DWITH_ASAN=YES -DWITH_UBSAN=YES -DPLUGIN_TOKUDB=NO -DPLUGIN_MROONGA=NO -DPLUGIN_OQGRAPH=NO -DPLUGIN_ROCKSDB=NO -DPLUGIN_CONNECT=NO -DWITH_SAFEMALLOC=OFF -DWITH_ZLIB=bundled -DWITH_SSL=bundled -DWITH_PCRE=system -DWITH_DBUG_TRACE=OFF -DWITH_SAFEMALLOC=OFF && make VERBOSE=1 -j%(kw:jobs)s package', jobs=util.Property('jobs', default='$(getconf _NPROCESSORS_ONLN)'))], haltOnFailure="true"))
f_asan_ubsan_build.addStep(steps.MTR(
logfiles={"mysqld*": "/buildbot/mysql_logs.html", "syslog": "/var/log/syslog"},
command=["sh", "-c", util.Interpolate('cd mysql-test && MTR_FEEDBACK_PLUGIN=1 ASAN_OPTIONS="abort_on_error=1" LSAN_OPTIONS="print_suppressions=0,suppressions=`pwd`/lsan.supp" perl mysql-test-run.pl --verbose-restart --force --retry=3 --max-save-core=1 --max-save-datadir=10 --max-test-fail=20 --mem --parallel=$(expr %(kw:jobs)s \* 2)', jobs=util.Property('jobs', default='$(getconf _NPROCESSORS_ONLN)'))],
timeout=950,
haltOnFailure="true",
parallel=mtrJobsMultiplier,
dbpool=mtrDbPool,
autoCreateTables=True,
env=MTR_ENV,
))
f_asan_ubsan_build.addStep(steps.ShellCommand(name="move mysqld log files", alwaysRun=True, command=['bash', '-c', util.Interpolate(moveMTRLogs(), jobs=util.Property('jobs', default='$(getconf _NPROCESSORS_ONLN)'))]))
f_asan_ubsan_build.addStep(steps.ShellCommand(name="create var archive", alwaysRun=True, command=['bash', '-c', util.Interpolate(createVar())], doStepIf=hasFailed))
f_asan_ubsan_build.addStep(steps.DirectoryUpload(name="save mysqld log files", compress="bz2", alwaysRun=True, workersrc='/buildbot/logs/', masterdest=util.Interpolate('/srv/buildbot/packages/' + '%(prop:tarbuildnum)s' + '/logs/' + '%(prop:buildername)s' )))
f_asan_ubsan_build.addStep(steps.ShellCommand(name="cleanup", command="rm -r * .* 2> /dev/null || true", alwaysRun=True))

## f_asan_build
f_asan_build = util.BuildFactory()
f_asan_build.addStep(steps.ShellCommand(name="Environment details", command=['bash', '-c', 'date -u && uname -a && ulimit -a']))
Expand Down Expand Up @@ -682,6 +712,16 @@ c['builders'].append(
locks=getLocks,
factory=f_asan_build))

c['builders'].append(
util.BuilderConfig(name="amd64-debian-12-asan-ubsan",
workernames=workers["x64-bbw-docker-debian-12"],
tags=["Ubuntu", "quick", "gcc", "asan", "ubsan"],
collapseRequests=True,
nextBuild=nextBuild,
canStartBuild=canStartBuild,
locks=getLocks,
factory=f_asan_ubsan_build))

c['builders'].append(
util.BuilderConfig(name="amd64-debian-11-msan",
workernames=workers["x64-bbw-docker-msan-clang-debian-11"],
Expand Down

0 comments on commit 3d30176

Please sign in to comment.