Clang Project

clang_source_code/test/CodeGenCXX/cfi-ms-rtti.cpp
1// RUN: %clang_cc1 -flto -flto-unit -emit-llvm -o - -triple=x86_64-pc-win32 %s -fsanitize=cfi-vcall | FileCheck --check-prefix=RTTI %s
2// RUN: %clang_cc1 -flto -flto-unit -emit-llvm -o - -triple=x86_64-pc-win32 %s -fsanitize=cfi-vcall -fno-rtti-data | FileCheck --check-prefix=NO-RTTI %s
3
4struct A {
5  A();
6  virtual void f() {}
7};
8
9A::A() {}
10
11// RTTI: !{i64 8, !"?AUA@@"}
12// NO-RTTI: !{i64 0, !"?AUA@@"}
13