Skip to content

Commit 21841a7

Browse files
committed
Integrate hwloc with valgrind
Hwloc requires dumping CPUID before running under valgrind.
1 parent cba18d1 commit 21841a7

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

.github/workflows/nightly.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
- name: Install apt packages
2323
run: |
2424
sudo apt-get update
25-
sudo apt-get install -y cmake libhwloc-dev libjemalloc-dev libnuma-dev libtbb-dev valgrind
25+
sudo apt-get install -y cmake hwloc libhwloc-dev libjemalloc-dev libnuma-dev libtbb-dev valgrind
2626
2727
- name: Configure CMake
2828
run: >

test/test_valgrind.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,13 +49,18 @@ esac
4949

5050
FAIL=0
5151

52+
mkdir -p cpuid
53+
54+
echo "Gathering data for hwloc so it can be run under valgrind:"
55+
hwloc-gather-cpuid ./cpuid
56+
5257
echo "Running: \"valgrind $OPTION\" for the following tests:"
5358

5459
for tf in $(ls -1 ./test/umf_test-*); do
5560
[ ! -x $tf ] && continue
5661
echo -n "$tf "
5762
LOG=${tf}.log
58-
valgrind $OPTION $tf >$LOG 2>&1 || echo -n "(valgrind failed) "
63+
HWLOC_CPUID_PATH=./cpuid valgrind $OPTION $tf >$LOG 2>&1 || echo -n "(valgrind failed) "
5964
if grep -q -e "ERROR SUMMARY: 0 errors from 0 contexts" $LOG; then
6065
echo "- OK"
6166
rm $LOG

0 commit comments

Comments
 (0)