From 630a5bdf06d59b8340fb4bfc0e692cbcf094026a Mon Sep 17 00:00:00 2001 From: mzuenni Date: Thu, 10 Jul 2025 17:40:18 +0200 Subject: run with sanitizer --- test/math/kthperm.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'test/math/kthperm.cpp') diff --git a/test/math/kthperm.cpp b/test/math/kthperm.cpp index 16691b9..1bf8db3 100644 --- a/test/math/kthperm.cpp +++ b/test/math/kthperm.cpp @@ -2,9 +2,9 @@ #include #include -void stress_test() { +void stress_test(int LIM) { ll queries = 0; - for (ll i = 0; i < 10'000; i++) { + for (int i = 0; i < LIM; i++) { int n = Random::integer(1, 100); vector expected(n); iota(all(expected), 0); @@ -32,7 +32,8 @@ void performance_test() { } int main() { - stress_test(); - performance_test(); + stress_test(1'000); + if (!sanitize) stress_test(10'000); + if (!sanitize) performance_test(); } -- cgit v1.2.3