Skip to content

Commit 1d90a73

Browse files
committed
Perform memory regression test in Travis/Ubuntu/cmake/g++ build
The CMake build configuration is now set to RelWithDebInfo to obtain usable function call names in the heap trace. As this yields different and larger binaries, ccache's cache size is increased to 2G for this stage.
1 parent a02caa4 commit 1d90a73

File tree

2 files changed

+7238
-2
lines changed

2 files changed

+7238
-2
lines changed

Diff for: .travis.yml

+36-2
Original file line numberDiff line numberDiff line change
@@ -199,11 +199,44 @@ jobs:
199199
- mkdir bin ; ln -s /usr/bin/gcc-5 bin/gcc
200200
install:
201201
- ccache -z
202-
- ccache --max-size=1G
203-
- cmake -H. -Bbuild '-DCMAKE_BUILD_TYPE=Release' '-DCMAKE_CXX_COMPILER=/usr/bin/g++-5'
202+
- ccache --max-size=2G
203+
- cmake -H. -Bbuild '-DCMAKE_BUILD_TYPE=RelWithDebInfo' '-DCMAKE_CXX_COMPILER=/usr/bin/g++-5'
204204
- cmake --build build -- -j4
205205
script: (cd build; ctest -V -L CORE -j2)
206206

207+
# cmake build using g++-5 + memory regression test
208+
- &memory-regression-test
209+
stage: Test different OS/CXX/Flags
210+
os: linux
211+
compiler: gcc
212+
cache: ccache
213+
env:
214+
- BUILD_SYSTEM=cmake
215+
addons:
216+
apt:
217+
sources:
218+
- ubuntu-toolchain-r-test
219+
packages:
220+
- g++-5
221+
- valgrind
222+
before_install:
223+
- mkdir bin ; ln -s /usr/bin/gcc-5 bin/gcc
224+
install:
225+
- ccache -z
226+
- ccache --max-size=2G
227+
- cmake -H. -Bbuild '-DCMAKE_BUILD_TYPE=RelWithDebInfo' '-DCMAKE_CXX_COMPILER=/usr/bin/g++-5'
228+
- cmake --build build -- -j4
229+
env:
230+
- NAME="memory-regression"
231+
script:
232+
- cd build
233+
- valgrind --tool=massif --massif-out-file=massif.out --time-unit=B
234+
bin/cbmc ../regression/cbmc/address_space_size_limit1/test.c
235+
--no-simplify --unwind 300 --object-bits 8 || true
236+
- if ! ../scripts/memory-test/memory.py --fuzzy --peak-only
237+
-r ../scripts/memory-test/massif.ref.x86-64 massif.out ; then
238+
echo "Dumping massif.out" ; cat massif.out ; exit 1 ; fi
239+
207240
- stage: Test different OS/CXX/Flags
208241
os: osx
209242
compiler: clang
@@ -262,6 +295,7 @@ jobs:
262295
allow_failures:
263296
- <<: *formatting-stage
264297
- <<: *linter-stage
298+
- <<: *memory-regression-test
265299

266300
install:
267301
- ccache -z

0 commit comments

Comments
 (0)