Revert "[llvm] Improve llvm.objectsize computation by computing GEP, alloca and mallo...
[llvm-project.git] / clang / test / CodeGen / coverage-target-attr.c
blobd46299f5bee223dc02aef285ef23c327101e3dd7
1 // RUN: %clang_cc1 -emit-llvm -coverage-notes-file=/dev/null -coverage-data-file=/dev/null -triple aarch64-linux-android30 -target-cpu generic -target-feature +tagged-globals -fsanitize=hwaddress %s -o %t
2 // RUN: FileCheck %s < %t
4 // CHECK: define internal void @__llvm_gcov_writeout() unnamed_addr [[ATTR:#[0-9]+]]
5 // CHECK: define internal void @__llvm_gcov_reset() unnamed_addr [[ATTR]]
6 // CHECK: define internal void @__llvm_gcov_init() unnamed_addr [[ATTR]]
7 // CHECK: define internal void @hwasan.module_ctor() [[ATTR2:#[0-9]+]]
8 // CHECK: attributes [[ATTR]] = {{.*}} "target-cpu"="generic" "target-features"="+tagged-globals"
9 // CHECK: attributes [[ATTR2]] = {{.*}} "target-cpu"="generic" "target-features"="+tagged-globals"
11 __attribute__((weak)) int foo = 0;
13 __attribute__((weak)) void bar() {}
15 int main() {
16 if (foo) bar();