Fix for limit_range_end when not writing vcd
authorMiodrag Milanovic <mmicko@gmail.com>
Fri, 28 Jan 2022 11:15:14 +0000 (12:15 +0100)
committerMiodrag Milanovic <mmicko@gmail.com>
Fri, 28 Jan 2022 11:15:14 +0000 (12:15 +0100)
libs/fst/fstapi.cc

index 3ceafb109d6d6076d34eb58fca52b89b53087d40..0b8f491465ad1f6023bfc8a9980272d027621d9d 100644 (file)
@@ -5198,6 +5198,15 @@ int fstReaderIterBlocks2(void *ctx,
                     }
                     previous_time = time_table[i];
                 }
+            } else {
+                if (time_table[i] != previous_time) {
+                    if (xc->limit_range_valid) {
+                        if (time_table[i] > xc->limit_range_end) {
+                            break;
+                        }
+                    }
+                    previous_time = time_table[i];
+                }
             }
 
             while (tc_head[i]) {