-
Notifications
You must be signed in to change notification settings - Fork 13.5k
[NFC][asan] Try to deflake asan_lsan_deadlock test #137718
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[NFC][asan] Try to deflake asan_lsan_deadlock test #137718
Conversation
Created using spr 1.3.4
@llvm/pr-subscribers-compiler-rt-sanitizer Author: Vitaly Buka (vitalybuka) Changes10s looks not enough. With highly parallel test I can reproduce locally 1s is not always enough, Additionally, don't use puts/CHECK to validate Full diff: https://github.com/llvm/llvm-project/pull/137718.diff 1 Files Affected:
diff --git a/compiler-rt/test/asan/TestCases/asan_lsan_deadlock.cpp b/compiler-rt/test/asan/TestCases/asan_lsan_deadlock.cpp
index 7ca07edbaf18c..7c2dbf27da3d4 100644
--- a/compiler-rt/test/asan/TestCases/asan_lsan_deadlock.cpp
+++ b/compiler-rt/test/asan/TestCases/asan_lsan_deadlock.cpp
@@ -36,11 +36,8 @@
void Watchdog() {
// Safety mechanism: Turn infinite deadlock into finite test failure
- usleep(10000000);
- // CHECK-NOT: Timeout! Deadlock detected.
- puts("Timeout! Deadlock detected.");
- fflush(stdout);
- _exit(1);
+ sleep(60);
+ _exit(0);
}
int main(int argc, char **argv) {
|
10s looks not enough. With highly parallel test execution on VMs it's very possible that Asan report will have no enough time to produce output. I can reproduce locally 1s is not always enough, but likely my workstation is faster then buildbot. Additionally, don't use puts/CHECK to validate timeout. We can exit with 0 and it should violate "not" expectation. Follow up to llvm#131756.
10s looks not enough. With highly parallel test execution on VMs it's very possible that Asan report will have no enough time to produce output. I can reproduce locally 1s is not always enough, but likely my workstation is faster then buildbot. Additionally, don't use puts/CHECK to validate timeout. We can exit with 0 and it should violate "not" expectation. Follow up to llvm#131756.
10s looks not enough. With highly parallel test execution on VMs it's very possible that Asan report will have no enough time to produce output. I can reproduce locally 1s is not always enough, but likely my workstation is faster then buildbot. Additionally, don't use puts/CHECK to validate timeout. We can exit with 0 and it should violate "not" expectation. Follow up to llvm#131756.
10s looks not enough. With highly parallel test execution on VMs it's very possible that Asan report will have no enough time to produce output. I can reproduce locally 1s is not always enough, but likely my workstation is faster then buildbot. Additionally, don't use puts/CHECK to validate timeout. We can exit with 0 and it should violate "not" expectation. Follow up to llvm#131756.
10s looks not enough. With highly parallel test execution on VMs it's very possible that Asan report will have no enough time to produce output. I can reproduce locally 1s is not always enough, but likely my workstation is faster then buildbot. Additionally, don't use puts/CHECK to validate timeout. We can exit with 0 and it should violate "not" expectation. Follow up to llvm#131756.
10s looks not enough. With highly parallel test
execution on VMs it's very possible that Asan
report will have no enough time to produce output.
I can reproduce locally 1s is not always enough,
but likely my workstation is faster then buildbot.
Additionally, don't use puts/CHECK to validate
timeout. We can exit with 0 and it should violate
"not" expectation.
Follow up to #131756.