Skip to content

Commit 40280e1

Browse files
Revert "[ibex_tracer] Use static variables in always/final blocks"
This reverts commit 5da1679. > This change is not supported by the version of sv2v used for the example > synthesis flow, so revert it for a quick fix while in draft.
1 parent 149ce5e commit 40280e1

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

rtl/ibex_tracer.sv

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -740,18 +740,19 @@ module ibex_tracer (
740740
// as a blocking assignment to xx. They then complain about the mixture with that an the
741741
// non-blocking assignment we use when opening the file. The bug is fixed with recent versions
742742
// of Verilator, but this hack is probably worth it for now.
743-
static int fh = file_handle;
743+
int fh = file_handle;
744744
$fclose(fh);
745745
end
746746
end
747747

748748
// log execution
749749
always @(posedge clk_i) begin
750750
if (rvfi_valid && trace_log_enable) begin
751-
static int fh = file_handle;
751+
752+
int fh = file_handle;
752753

753754
if (fh == 32'h0) begin
754-
static string file_name_base = "trace_core";
755+
string file_name_base = "trace_core";
755756
void'($value$plusargs("ibex_tracer_file_base=%s", file_name_base));
756757
$sformat(file_name, "%s_%h.log", file_name_base, hart_id_i);
757758

0 commit comments

Comments
 (0)