model: don't print 'uninitialized' ModelActions in trace output
authorBrian Norris <banorris@uci.edu>
Wed, 6 Mar 2013 02:36:58 +0000 (18:36 -0800)
committerBrian Norris <banorris@uci.edu>
Wed, 6 Mar 2013 02:36:58 +0000 (18:36 -0800)
If we proliferate a large number of atomic objects, we can generate a
lot of fake 'uninitialized' ModelActions. Don't print these in traces,
as it just clutters the output.

model.cc

index d15a094f7d8049e1a1e81ed8ac78527b6d1ca66a..cd703edf329ef3245b8bcded411c540b3ac3ab22 100644 (file)
--- a/model.cc
+++ b/model.cc
@@ -2814,7 +2814,9 @@ static void print_list(action_list_t *list)
        unsigned int hash = 0;
 
        for (it = list->begin(); it != list->end(); it++) {
-               (*it)->print();
+               const ModelAction *act = *it;
+               if (act->get_seq_number() > 0)
+                       act->print();
                hash = hash^(hash<<3)^((*it)->hash());
        }
        model_print("HASH %u\n", hash);