aboutsummaryrefslogtreecommitdiff
path: root/v_windows/v/cmd/tools/fuzz/fuzz.sh
blob: cbba7d722f2f32f1178e405469c7bbd6d4d1aab1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh

cores=$(nproc --all)

echo Number of cores: $cores
echo Compiling...
./v -cc clang -o cmd/tools/fuzz/map_fuzz cmd/tools/fuzz/map_fuzz.v -prod -cflags "-fsanitize=memory"

echo Fuzzing:
while true
do
  for ((i=1;i<=cores;++i))
  do
    sleep 0.001
    ./cmd/tools/fuzz/map_fuzz &
  done
  wait
done