File tree Expand file tree Collapse file tree 5 files changed +11
-20
lines changed Expand file tree Collapse file tree 5 files changed +11
-20
lines changed Original file line number Diff line number Diff line change 1
1
# Check that libFuzzer honors SIGUSR1/SIGUSR2
2
2
# Disabled on Windows which does not have SIGUSR1/SIGUSR2.
3
+ REQUIRES: shell
3
4
UNSUPPORTED: darwin, target={{.*windows.*}}, target=aarch64{{.*}}
4
5
RUN: rm -rf %t
5
6
RUN: mkdir -p %t
6
7
RUN: %cpp_compiler %S/SleepOneSecondTest.cpp -o %t/ForkSIGUSR
7
8
8
- # The line below needs the " | env" at the end, in order to make the
9
- # script continue executing, rather than waiting (forever) for the
10
- # 'nohup run...' command to finish.
11
- RUN: bash -c "nohup %run %t/ForkSIGUSR -fork=3 -ignore_crashes=1 2>%t/log & echo -n $! > %t2" | env
9
+ RUN: %run %t/ForkSIGUSR -fork=3 -ignore_crashes=1 2>%t/log & export PID=$!
12
10
RUN: sleep 3
13
- RUN: kill -SIGUSR2 %{readfile:%t2}
11
+ RUN: kill -SIGUSR2 $PID
14
12
RUN: sleep 6
15
13
RUN: cat %t/log | FileCheck %s --dump-input=fail
16
14
Original file line number Diff line number Diff line change 1
- REQUIRES: msan
1
+ REQUIRES: shell, msan
2
2
UNSUPPORTED: target=arm{{.*}}
3
3
4
4
# Check that libFuzzer exits gracefully under SIGINT with MSan.
5
5
RUN: rm -rf %t
6
6
RUN: mkdir -p %t
7
7
RUN: %msan_compiler %S/SleepOneSecondTest.cpp -o %t/LFSIGINT
8
8
9
- # The line below needs the " | env" at the end, in order to make the
10
- # script continue executing, rather than waiting (forever) for the
11
- # 'nohup run...' command to finish.
12
- RUN: bash -c "nohup %run %t/LFSIGINT 2> %t/log & echo -n $! > %t2" | env
9
+ RUN: %run %t/LFSIGINT 2> %t/log & export PID=$!
13
10
RUN: sleep 2
14
- RUN: kill -SIGINT %{readfile:%t2}
11
+ RUN: kill -SIGINT $PID
15
12
RUN: sleep 3
16
13
RUN: cat %t/log | FileCheck %s
17
14
Original file line number Diff line number Diff line change 1
1
# FIXME: Disabled on Windows for now because of reliance on posix only features
2
2
# (eg: export, "&", pkill).
3
+ REQUIRES: shell
3
4
UNSUPPORTED: darwin, target={{.*windows.*}}
4
5
# Check that libFuzzer honors SIGUSR1/SIGUSR2
5
6
RUN: rm -rf %t
6
7
RUN: mkdir -p %t
7
8
RUN: %cpp_compiler %S/SleepOneSecondTest.cpp -o %t/LFSIGUSR
8
9
9
- # The line below needs the " | env" at the end, in order to make the
10
- # script continue executing, rather than waiting (forever) for the
11
- # 'nohup run...' command to finish.
12
- RUN: bash -c "nohup %run %t/LFSIGUSR 2> %t/log & echo -n $! > %t2"| env
10
+ RUN: %run %t/LFSIGUSR 2> %t/log & export PID=$!
13
11
RUN: sleep 2
14
- RUN: kill -SIGUSR1 %{readfile:%t2}
12
+ RUN: kill -SIGUSR1 $PID
15
13
RUN: sleep 3
16
14
RUN: cat %t/log | FileCheck %s
17
15
Original file line number Diff line number Diff line change 3
3
// mapping the heap early, in __msan_init.
4
4
//
5
5
// RUN: %clangxx_msan -O0 %s -o %t_1
6
- // RUN: %run %t_1 > %t_3
7
- // RUN: %clangxx_msan -O0 -DHEAP_ADDRESS=%{readfile:%t_3} %s -o %t_2 && %run %t_2
6
+ // RUN: %clangxx_msan -O0 -DHEAP_ADDRESS=$(%run %t_1) %s -o %t_2 && %run %t_2
8
7
//
9
8
// This test only makes sense for the 64-bit allocator. The 32-bit allocator
10
9
// does not have a fixed mapping. Exclude platforms that use the 32-bit
Original file line number Diff line number Diff line change 2
2
// / Test that a module constructor can not map memory over the NSan heap
3
3
// / (without MAP_FIXED, of course).
4
4
// RUN: %clangxx_nsan -O0 %s -o %t_1
5
- // RUN: %run %t_1 > %t_3
6
- // RUN: %clangxx_nsan -O0 -DHEAP_ADDRESS=%{readfile:%t_3} %s -o %t_2 && %run %t_2
5
+ // RUN: %clangxx_nsan -O0 -DHEAP_ADDRESS=$(%run %t_1) %s -o %t_2 && %run %t_2
7
6
8
7
#include < assert.h>
9
8
#include < stdio.h>
You can’t perform that action at this time.
0 commit comments