Skip to content

Commit edcf5c2

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 847fab7 commit edcf5c2

File tree

2 files changed

+7216
-4
lines changed

2 files changed

+7216
-4
lines changed

Diff for: .travis.yml

+14-4
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ jobs:
182182
- CCACHE_CPP2=yes
183183
script: echo "Not running any tests for a debug build."
184184

185-
# cmake build using g++-5
185+
# cmake build using g++-5 + memory regression test
186186
- stage: Test different OS/CXX/Flags
187187
os: linux
188188
compiler: gcc
@@ -195,14 +195,24 @@ jobs:
195195
- ubuntu-toolchain-r-test
196196
packages:
197197
- g++-5
198+
- valgrind
198199
before_install:
199200
- mkdir bin ; ln -s /usr/bin/gcc-5 bin/gcc
200201
install:
201202
- ccache -z
202-
- ccache --max-size=1G
203-
- cmake -H. -Bbuild '-DCMAKE_BUILD_TYPE=Release' '-DCMAKE_CXX_COMPILER=/usr/bin/g++-5'
203+
- ccache --max-size=2G
204+
- cmake -H. -Bbuild '-DCMAKE_BUILD_TYPE=RelWithDebInfo' '-DCMAKE_CXX_COMPILER=/usr/bin/g++-5'
204205
- cmake --build build -- -j4
205-
script: (cd build; ctest -V -L CORE -j2)
206+
env:
207+
- NAME="memory-regression"
208+
script:
209+
- cd build && ctest -V -L CORE -j2 || exit 1
210+
- valgrind --tool=massif --massif-out-file=massif.out --time-unit=B
211+
bin/cbmc ../regression/cbmc/address_space_size_limit1/test.c
212+
--no-simplify --unwind 300 --object-bits 8 || true
213+
- if ! ../scripts/memory-test/memory.py
214+
-r ../scripts/memory-test/massif.ref.x86-64 massif.out ; then
215+
echo "Dumping massif.out" ; cat massif.out ; exit 1 ; fi
206216

207217
- stage: Test different OS/CXX/Flags
208218
os: osx

0 commit comments

Comments
 (0)