Home | History | Annotate | Download | only in CodeGenCXX
      1 // Test without the flag -fsanitize-memory-use-after-dtor, to ensure that
      2 // instrumentation is not erroneously inserted
      3 // RUN: %clang_cc1 -fsanitize=memory -triple=x86_64-pc-linux -emit-llvm -o - %s | FileCheck %s
      4 
      5 struct Simple {
      6   ~Simple() {}
      7 };
      8 Simple s;
      9 // CHECK-LABEL: define {{.*}}SimpleD1Ev
     10 // CHECK-NOT: call void @__sanitizer_dtor_callback
     11 
     12 struct Inlined {
     13   inline ~Inlined() {}
     14 };
     15 Inlined i;
     16 // CHECK-LABEL: define {{.*}}InlinedD1Ev
     17 // CHECK-NOT: call void @__sanitizer_dtor_callback
     18 
     19 // CHECK-LABEL: define {{.*}}SimpleD2Ev
     20 // CHECK-NOT: call void @__sanitizer_dtor_callback
     21 
     22 // CHECK-LABEL: define {{.*}}InlinedD2Ev
     23 // CHECK-NOT: call void @__sanitizer_dtor_callback
     24