mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-05-13 17:37:00 +00:00

Don't fetch BFI if the function has no entry count. Peculiarly, the implementation was already doing this for the (no longer existing) legacy PM implementation, but the same principle applies to the new pass manager. The only reason why the new PM doesn't have LazyBFI is that with the new pass manager all passes are lazy. This improves compile-time for non-PGO builds.
22 lines
737 B
C
22 lines
737 B
C
// RUN: %clang_cc1 -triple x86_64-linux-gnu -fsanitize=address -O3 -emit-llvm -fdebug-pass-manager -o - %s 2>&1 | FileCheck %s
|
|
// RUN: %clang_cc1 -triple x86_64-linux-gnu -fsanitize=thread -O3 -emit-llvm -fdebug-pass-manager -o - %s 2>&1 | FileCheck %s
|
|
// RUN: %clang_cc1 -triple x86_64-linux-gnu -fsanitize=memory -O3 -emit-llvm -fdebug-pass-manager -o - %s 2>&1 | FileCheck %s
|
|
|
|
// This is regression test for PR42877
|
|
|
|
typedef struct a *b;
|
|
struct a {
|
|
int c;
|
|
};
|
|
int d;
|
|
b e;
|
|
static void f(b g) {
|
|
for (d = g->c;;)
|
|
;
|
|
}
|
|
void h(void) { f(e); }
|
|
|
|
// CHECK: Running pass: {{.*}}SanitizerPass
|
|
// CHECK-NOT: Running pass: LoopSimplifyPass on {{.*}}san.module_ctor
|
|
// CHECK: Running analysis: TargetLibraryAnalysis on {{.*}}san.module_ctor
|