diff options
| author | Petr Hosek <phosek@chromium.org> | 2019-09-10 06:25:13 +0000 |
|---|---|---|
| committer | Petr Hosek <phosek@chromium.org> | 2019-09-10 06:25:13 +0000 |
| commit | 7d1757aba808db3d42362176862fe4e60bf3840d (patch) | |
| tree | 3f807fbdabbcb05e68bff2e2f65acb9651543c4d /clang/test/Profile/misexpect-branch-cold.c | |
| parent | 0e533ca4bb82fee0b1c25853129a2f5f80dbf97b (diff) | |
| download | bcm5719-llvm-7d1757aba808db3d42362176862fe4e60bf3840d.tar.gz bcm5719-llvm-7d1757aba808db3d42362176862fe4e60bf3840d.zip | |
Revert "clang-misexpect: Profile Guided Validation of Performance Annotations in LLVM"
This reverts commit r371484: this broke sanitizer-x86_64-linux-fast bot.
llvm-svn: 371488
Diffstat (limited to 'clang/test/Profile/misexpect-branch-cold.c')
| -rw-r--r-- | clang/test/Profile/misexpect-branch-cold.c | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/clang/test/Profile/misexpect-branch-cold.c b/clang/test/Profile/misexpect-branch-cold.c deleted file mode 100644 index 6d34f92a254..00000000000 --- a/clang/test/Profile/misexpect-branch-cold.c +++ /dev/null @@ -1,26 +0,0 @@ -// Test that misexpect emits no warning when prediction is correct - -// RUN: llvm-profdata merge %S/Inputs/misexpect-branch.proftext -o %t.profdata -// RUN: %clang_cc1 %s -O2 -o - -disable-llvm-passes -emit-llvm -fprofile-instrument-use-path=%t.profdata -verify -Wmisexpect - -// expected-no-diagnostics -#define likely(x) __builtin_expect(!!(x), 1) -#define unlikely(x) __builtin_expect(!!(x), 0) - -int foo(int); -int baz(int); -int buzz(); - -const int inner_loop = 100; -const int outer_loop = 2000; - -int bar() { - int rando = buzz(); - int x = 0; - if (unlikely(rando % (outer_loop * inner_loop) == 0)) { - x = baz(rando); - } else { - x = foo(50); - } - return x; -} |

