Home | History | Annotate | Download | only in Linux
      1 // Test that no data is collected without a runtime flag.
      2 //
      3 // RUN: %clangxx_asan -mllvm -asan-coverage=1 %s -o %t
      4 //
      5 // RUN: rm -rf %T/coverage-disabled
      6 //
      7 // RUN: mkdir -p %T/coverage-disabled/normal
      8 // RUN: ASAN_OPTIONS=coverage_direct=0:coverage_dir=%T/coverage-disabled/normal:verbosity=1 %run %t
      9 // RUN: not %sancov print %T/coverage-disabled/normal/*.sancov 2>&1
     10 //
     11 // RUN: mkdir -p %T/coverage-disabled/direct
     12 // RUN: ASAN_OPTIONS=coverage_direct=1:coverage_dir=%T/coverage-disabled/direct:verbosity=1 %run %t
     13 // RUN: cd %T/coverage-disabled/direct
     14 // RUN: not %sancov rawunpack *.sancov
     15 
     16 int main(int argc, char **argv) {
     17   return 0;
     18 }
     19