This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: [RFA:] No timeout for ext/pb_ds/regression/hash_data_map_rand.cc
- From: Hans-Peter Nilsson <hans-peter dot nilsson at axis dot com>
- To: bkoz at redhat dot com
- Cc: hans-peter dot nilsson at axis dot com, libstdc++ at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org, janis187 at us dot ibm dot com
- Date: Tue, 6 Feb 2007 13:15:14 +0100
- Subject: Re: [RFA:] No timeout for ext/pb_ds/regression/hash_data_map_rand.cc
> Date: Tue, 06 Feb 2007 11:37:04 +0100
> From: Benjamin Kosnik <bkoz@redhat.com>
Thanks for the reviews!
> > For background, see
> > <URL:http://gcc.gnu.org/ml/gcc-patches/2007-02/msg00450.html>.
> > libstdc++-v3:
> > * testsuite/ext/pb_ds/regression/hash_data_map_rand.cc: Use only 5
> > iterations for simulator targets.
>
> This is ok, but please check into both gcc and gcc-4_2-branch.
Will do, with PR testsuite/28870 at the top, these and the
23_containers/set/modifiers/16728.cc. (It doesn't *solve* the
timeouts for non-simulator setups, but helps with the #ifndef's
and at least there are enough hints that people can add
dg-options with "-DITERATIONS=whatever" for various "old
hardware" or perhaps a "target old_iron" to catch them all,
whenever new old hardware is introduced. :)
> Perhaps you should just do them all at the same time...
Yup, particularly as most time-out one way or the other. :)
I didn't realize they were all twisty little test-cases, all
similar, at the time; I just picked one from the grep "timed
out" on the testsuite .log and then I myself timed out.
On an unloaded amd64 system (3200+, 2 GHz) for src/sim/cris and
cris-axis-elf, we get these times:
tree_data_map_rand: 14m
tree_no_data_map_rand: 4m43s
trie_data_map_rand: 12m
hash_no_data_map_rand: 3m15s
trie_no_data_map_rand: 3m49s
For consistency and because I guess it'd still time out on e.g. an unloaded
400 MHz P3, I also did:
priority_queue_rand: 54s
For reference, I intend to also have a look at (at least) the
following timeouts:
27_io/basic_stringbuf/overflow/char/1.cc
27_io/objects/char/10.cc
27_io/objects/char/12048-1.cc
27_io/objects/char/12048-2.cc
27_io/objects/char/12048-3.cc
27_io/objects/char/12048-4.cc
27_io/objects/char/6.cc
To wit, those tests not timing out directly, do it when e.g. running a similar
test-round in parallel.
Will commit to trunk and 4.2 when/if I get ok on the
check_effective_target_simulator bits posted in the original
patch.
* testsuite/ext/pb_ds/regression/tree_data_map_rand.cc: Use only 5
iterations for simulator targets.
* testsuite/ext/pb_ds/regression/tree_no_data_map_rand.cc: Ditto.
* testsuite/ext/pb_ds/regression/trie_data_map_rand.cc: Ditto.
* testsuite/ext/pb_ds/regression/trie_no_data_map_rand.cc: Ditto.
* testsuite/ext/pb_ds/regression/hash_no_data_map_rand.cc: Ditto.
* testsuite/ext/pb_ds/regression/priority_queue_rand.cc: Ditto.
Index: testsuite/ext/pb_ds/regression/priority_queue_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/priority_queue_rand.cc (revision 121581)
+++ testsuite/ext/pb_ds/regression/priority_queue_rand.cc (working copy)
@@ -48,11 +48,19 @@
#include <regression/rand/priority_queue/rand_regression_test.hpp>
#include <regression/priority_queue/common_type.hpp>
+// This can take long on simulators, timing out the test.
+// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
+#ifndef ITERATIONS
+#define ITERATIONS 5000
+#endif
+#ifndef KEYS
+#define KEYS 10000
+#endif
int
main(int argc, char* a_p_argv[])
{
using namespace pb_ds::test;
- return rand_regression_test(5000, 10000,
+ return rand_regression_test(ITERATIONS, KEYS,
"tree_no_data_map_rand_regression_test",
pq_tl_t());
}
Index: testsuite/ext/pb_ds/regression/hash_no_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/hash_no_data_map_rand.cc (revision 121581)
+++ testsuite/ext/pb_ds/regression/hash_no_data_map_rand.cc (working copy)
@@ -48,13 +48,21 @@
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/assoc/common_type.hpp>
+// This can take long on simulators, timing out the test.
+// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
+#ifndef ITERATIONS
+#define ITERATIONS 5000
+#endif
+#ifndef KEYS
+#define KEYS 10000
+#endif
int
main(int argc, char* a_p_argv[])
{
using namespace pb_ds::test;
typedef hash_set_tl_t map_tl_t;
- return rand_regression_test(5000, 10000,
+ return rand_regression_test(ITERATIONS, KEYS,
"hash_no_data_map_rand_regression_test",
map_tl_t());
}
Index: testsuite/ext/pb_ds/regression/trie_no_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/trie_no_data_map_rand.cc (revision 121581)
+++ testsuite/ext/pb_ds/regression/trie_no_data_map_rand.cc (working copy)
@@ -48,13 +48,21 @@
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/assoc/common_type.hpp>
+// This can take long on simulators, timing out the test.
+// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
+#ifndef ITERATIONS
+#define ITERATIONS 5000
+#endif
+#ifndef KEYS
+#define KEYS 10000
+#endif
int
main(int argc, char* a_p_argv[])
{
using namespace pb_ds::test;
typedef trie_set_tl_t map_tl_t;
- return rand_regression_test(5000, 10000,
+ return rand_regression_test(ITERATIONS, KEYS,
"trie_no_data_map_rand_regression_test",
map_tl_t());
}
Index: testsuite/ext/pb_ds/regression/trie_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/trie_data_map_rand.cc (revision 121581)
+++ testsuite/ext/pb_ds/regression/trie_data_map_rand.cc (working copy)
@@ -48,13 +48,21 @@
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/assoc/common_type.hpp>
+// This can take long on simulators, timing out the test.
+// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
+#ifndef ITERATIONS
+#define ITERATIONS 5000
+#endif
+#ifndef KEYS
+#define KEYS 10000
+#endif
int
main(int argc, char* a_p_argv[])
{
using namespace pb_ds::test;
typedef trie_map_tl_t map_tl_t;
- return rand_regression_test(5000, 10000,
+ return rand_regression_test(ITERATIONS, KEYS,
"trie_data_map_rand_regression_test",
map_tl_t());
}
Index: testsuite/ext/pb_ds/regression/tree_no_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/tree_no_data_map_rand.cc (revision 121581)
+++ testsuite/ext/pb_ds/regression/tree_no_data_map_rand.cc (working copy)
@@ -48,13 +48,21 @@
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/assoc/common_type.hpp>
+// This can take long on simulators, timing out the test.
+// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
+#ifndef ITERATIONS
+#define ITERATIONS 5000
+#endif
+#ifndef KEYS
+#define KEYS 10000
+#endif
int
main(int argc, char* a_p_argv[])
{
using namespace pb_ds::test;
typedef tree_set_tl_t map_tl_t;
- return rand_regression_test(5000, 10000,
+ return rand_regression_test(ITERATIONS, KEYS,
"tree_no_data_map_rand_regression_test",
map_tl_t());
}
Index: testsuite/ext/pb_ds/regression/tree_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/tree_data_map_rand.cc (revision 121581)
+++ testsuite/ext/pb_ds/regression/tree_data_map_rand.cc (working copy)
@@ -48,13 +48,21 @@
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/assoc/common_type.hpp>
+// This can take long on simulators, timing out the test.
+// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
+#ifndef ITERATIONS
+#define ITERATIONS 5000
+#endif
+#ifndef KEYS
+#define KEYS 10000
+#endif
int
main(int argc, char* a_p_argv[])
{
using namespace pb_ds::test;
typedef tree_map_tl_t map_tl_t;
- return rand_regression_test(5000, 10000,
+ return rand_regression_test(ITERATIONS, KEYS,
"tree_data_map_rand_regression_test",
map_tl_t());
}
brgds, H-P