data/full_repos/permissive/153414067/random.v
[Errno 2] No such file or directory: 'preprocess.output'
data/verilator_xmls/8f445cf3-27df-471a-81f6-3e231670aaa1.xml
module random(
	input [6:0] max,
	input trigger,
	input clk,
	
	output reg [6:0] out
    );
	 
	 reg [6:0] cntr = 7'b0;
	 
	 always @ (posedge clk)
	 begin
		if (cntr == max) cntr <= 7'b0;
		else cntr <= cntr + 1'b1;
		if (trigger) out <= cntr;
	 end

endmodule
module random(
	input [6:0] max,
	input trigger,
	input clk,
	
	output reg [6:0] out
    );

	 
	 reg [6:0] cntr = 7'b0;
	 
	 always @ (posedge clk)
	 begin
		if (cntr == max) cntr <= 7'b0;
		else cntr <= cntr + 1'b1;
		if (trigger) out <= cntr;
	 end

endmodule