BugFix: when a node in schedule got exchanged, it is turned into Bad: do not set...
[libfirm] / ir / be / beschedrand.c
index 8524abb..8fc409e 100644 (file)
@@ -1,9 +1,12 @@
 /**
  * Trivial node selector.
- * @author Christian Wuerdig
+ * @author Matthias Braun
  * @date   29.08.2006
  * @cvs-id $Id$
  */
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 
 #include <stdlib.h>
 
@@ -53,7 +56,10 @@ static ir_node *random_select(void *block_env, nodeset *ready_set, nodeset *live
 
 static void *random_init_graph(const list_sched_selector_t *vtab, const arch_env_t *arch_env, ir_graph *irg)
 {
-       srand(time(0));
+       /* Using time(NULL) as a seed here gives really random results,
+          but is NOT deterministic which makes debugging impossible.
+          Moreover no-one want non-deterministic compilers ... */
+       srand(0x4711);
        return (void *)arch_env;
 }