data/full_repos/permissive/458134463/Modules/nextPC_tb.v
1: b'%Warning-STMTDLY: data/full_repos/permissive/458134463/Modules/nextPC_tb.v:13: Unsupported: Ignoring delay on this delayed statement.\n forever #2 clock = ~clock;\n         ^\n                  ... Use "/* verilator lint_off STMTDLY */" and lint_on around source to disable this message.\n%Warning-STMTDLY: data/full_repos/permissive/458134463/Modules/nextPC_tb.v:21: Unsupported: Ignoring delay on this delayed statement.\n#8;\n^\n%Warning-STMTDLY: data/full_repos/permissive/458134463/Modules/nextPC_tb.v:24: Unsupported: Ignoring delay on this delayed statement.\n#4 \n^\n%Warning-STMTDLY: data/full_repos/permissive/458134463/Modules/nextPC_tb.v:27: Unsupported: Ignoring delay on this delayed statement.\n#4;\n^\n%Error: data/full_repos/permissive/458134463/Modules/nextPC_tb.v:35: Can\'t find definition of \'NextPC\' in dotted variable: \'next.NextPC\'\n if(next.NextPC > 40)\n         ^~~~~~\n%Error: Exiting due to 1 error(s), 4 warning(s)\n        ... See the manual and https://verilator.org for more assistance.\n'
module nextPC_tb();

reg branch, clock;
reg [31:0] branchAddress;

wire [31:0] nextPC;


nextPC next(branch, branchAddress, nextPC, clock);

initial begin
	clock = 1'b0;
	forever #2 clock = ~clock;
end


initial begin

branch        = 1'b0;
branchAddress = 32'd24;
#8;

branch = 1'b1;
#4 

branch = 1'b0;
#4;
end

always @(posedge clock) begin
	$display("Time: %3d | Clock: %1b | Branch: %1b\nBranch Address: %32b (%2h)\nNext PC       : %32b (%2h)\n", 
			$time, clock, branch, 
			branchAddress, branchAddress,
			nextPC, nextPC);
	if(next.NextPC > 40)
		$finish;
end

endmodule
module nextPC_tb();


reg branch, clock;
reg [31:0] branchAddress;

wire [31:0] nextPC;


nextPC next(branch, branchAddress, nextPC, clock);

initial begin
	clock = 1'b0;
	forever #2 clock = ~clock;
end


initial begin

branch        = 1'b0;
branchAddress = 32'd24;
#8;

branch = 1'b1;
#4 

branch = 1'b0;
#4;
end

always @(posedge clock) begin
	$display("Time: %3d | Clock: %1b | Branch: %1b\nBranch Address: %32b (%2h)\nNext PC       : %32b (%2h)\n", 
			$time, clock, branch, 
			branchAddress, branchAddress,
			nextPC, nextPC);
	if(next.NextPC > 40)
		$finish;
end

endmodule