#include "sn_network.h"
#include "sn_random.h"
+#include "histogram.h"
#if !defined(__GNUC__) || !__GNUC__
# define __attribute__(x) /**/
static _Bool do_loop = 1;
static uint64_t max_iterations = 0;
+static histogram_t *histogram;
+
static void sigint_handler (int signal __attribute__((unused)))
{
do_loop = 0;
best_solution = sn_network_clone (next);
}
+ hist_account (histogram, sn_network_get_comparator_num (next));
+
sn_network_destroy (n);
n = next;
iteration_counter++;
struct sigaction sigint_action;
struct sigaction sigterm_action;
+ histogram = hist_create ();
+
read_options (argc, argv);
if (initial_input_file == NULL)
exit_usage (argv[0], EXIT_FAILURE);
random_walk (start_network);
start_network = NULL;
+ hist_print (histogram);
+ hist_destroy (histogram);
+ histogram = NULL;
+
if (best_solution != NULL)
{
if (best_output_file != NULL)