From bb577748c0a1ad96b5861fa42636c2e63779830e Mon Sep 17 00:00:00 2001 From: Alexey Samsonov Date: Tue, 21 Jul 2015 22:51:49 +0000 Subject: [PATCH] [Fuzzer] Clearly separate regular and DFSan tests. NFC. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@242850 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Fuzzer/test/CMakeLists.txt | 6 +++--- lib/Fuzzer/test/{DFSanMemcmpTest.cpp => MemcmpTest.cpp} | 0 .../test/{DFSanSimpleCmpTest.cpp => SimpleCmpTest.cpp} | 0 lib/Fuzzer/test/fuzzer-dfsan.test | 6 ++++++ lib/Fuzzer/test/fuzzer.test | 5 +---- 5 files changed, 10 insertions(+), 7 deletions(-) rename lib/Fuzzer/test/{DFSanMemcmpTest.cpp => MemcmpTest.cpp} (100%) rename lib/Fuzzer/test/{DFSanSimpleCmpTest.cpp => SimpleCmpTest.cpp} (100%) create mode 100644 lib/Fuzzer/test/fuzzer-dfsan.test diff --git a/lib/Fuzzer/test/CMakeLists.txt b/lib/Fuzzer/test/CMakeLists.txt index a9acec15d4d..2769f6a114a 100644 --- a/lib/Fuzzer/test/CMakeLists.txt +++ b/lib/Fuzzer/test/CMakeLists.txt @@ -5,8 +5,8 @@ set(CMAKE_CXX_FLAGS_RELEASE "${LIBFUZZER_FLAGS_BASE} -O0 -fsanitize-coverage=edge,indirect-calls") set(DFSanTests - DFSanMemcmpTest - DFSanSimpleCmpTest + MemcmpTest + SimpleCmpTest ) set(Tests @@ -16,9 +16,9 @@ set(Tests FullCoverageSetTest InfiniteTest NullDerefTest + SimpleCmpTest SimpleTest TimeoutTest - ${DFSanTests} ) set(CustomMainTests diff --git a/lib/Fuzzer/test/DFSanMemcmpTest.cpp b/lib/Fuzzer/test/MemcmpTest.cpp similarity index 100% rename from lib/Fuzzer/test/DFSanMemcmpTest.cpp rename to lib/Fuzzer/test/MemcmpTest.cpp diff --git a/lib/Fuzzer/test/DFSanSimpleCmpTest.cpp b/lib/Fuzzer/test/SimpleCmpTest.cpp similarity index 100% rename from lib/Fuzzer/test/DFSanSimpleCmpTest.cpp rename to lib/Fuzzer/test/SimpleCmpTest.cpp diff --git a/lib/Fuzzer/test/fuzzer-dfsan.test b/lib/Fuzzer/test/fuzzer-dfsan.test new file mode 100644 index 00000000000..79fbcbb8c80 --- /dev/null +++ b/lib/Fuzzer/test/fuzzer-dfsan.test @@ -0,0 +1,6 @@ +CHECK: BINGO + +RUN: not ./LLVMFuzzer-SimpleCmpTest-DFSan -use_traces=1 -seed=1 -runs=1000000 -timeout=5 2>&1 | FileCheck %s + +RUN: not ./LLVMFuzzer-MemcmpTest-DFSan -use_traces=1 -seed=1 -runs=100 -timeout=5 2>&1 | FileCheck %s + diff --git a/lib/Fuzzer/test/fuzzer.test b/lib/Fuzzer/test/fuzzer.test index b8e672f0fec..ffd2f2034fc 100644 --- a/lib/Fuzzer/test/fuzzer.test +++ b/lib/Fuzzer/test/fuzzer.test @@ -19,10 +19,7 @@ RUN: not ./LLVMFuzzer-FourIndependentBranchesTest -timeout=15 -seed=1 -use_full_ RUN: not ./LLVMFuzzer-CounterTest -use_counters=1 -max_len=6 -seed=1 -timeout=15 2>&1 | FileCheck %s -RUN: not ./LLVMFuzzer-DFSanSimpleCmpTest-DFSan -use_traces=1 -seed=1 -runs=1000000 -timeout=5 2>&1 | FileCheck %s -RUN: not ./LLVMFuzzer-DFSanSimpleCmpTest -use_traces=1 -seed=1 -runs=1000000 -timeout=5 2>&1 | FileCheck %s - -RUN: not ./LLVMFuzzer-DFSanMemcmpTest-DFSan -use_traces=1 -seed=1 -runs=100 -timeout=5 2>&1 | FileCheck %s +RUN: not ./LLVMFuzzer-SimpleCmpTest -use_traces=1 -seed=1 -runs=1000000 -timeout=5 2>&1 | FileCheck %s RUN: not ./LLVMFuzzer-CxxTokensTest -seed=1 -timeout=15 -tokens=%S/../cxx_fuzzer_tokens.txt 2>&1 | FileCheck %s -- 2.34.1