added reset to ws

This commit is contained in:
felsabbagh3 2019-10-21 12:03:07 -04:00
parent 99586279d9
commit 85004899bd
3 changed files with 21 additions and 8 deletions

View file

@ -3,6 +3,7 @@
module VX_fetch (
input wire clk,
input wire reset,
VX_wstall_inter VX_wstall,
VX_join_inter VX_join,
input wire schedule_delay,
@ -27,6 +28,7 @@ module VX_fetch (
wire[31:0] warp_pc;
VX_warp_scheduler warp_scheduler(
.clk (clk),
.reset (reset),
.stall (pipe_stall),
// Wspawn
.wspawn (VX_warp_ctl.wspawn),

View file

@ -41,6 +41,7 @@ VX_join_inter VX_join();
VX_fetch vx_fetch(
.clk (clk),
.reset (reset),
.VX_wstall (VX_wstall),
.VX_join (VX_join),
.schedule_delay (schedule_delay),

View file

@ -2,6 +2,7 @@
module VX_warp_scheduler (
input wire clk, // Clock
input wire reset,
input wire stall,
// Wspawn
input wire wspawn,
@ -90,16 +91,24 @@ module VX_warp_scheduler (
/* verilator lint_on UNUSED */
reg[1:0] start;
initial begin
warp_pcs[0] = (32'h80000000 - 4);
start = 0;
warp_active[0] = 1; // Activating first warp
visible_active[0] = 1; // Activating first warp
thread_masks[0][0] = 1; // Activating first thread in first warp
end
// initial begin
// warp_pcs[0] = (32'h80000000 - 4);
// start = 0;
// warp_active[0] = 1; // Activating first warp
// visible_active[0] = 1; // Activating first warp
// thread_masks[0][0] = 1; // Activating first thread in first warp
// end
always @(posedge clk) begin
always @(posedge clk or posedge reset) begin
if (reset) begin
warp_pcs[0] = (32'h80000000 - 4);
start = 0;
warp_active[0] = 1; // Activating first warp
visible_active[0] = 1; // Activating first warp
thread_masks[0][0] = 1; // Activating first thread in first warp
end
// Wsapwning warps
if (wspawn && found_wspawn) begin
warp_pcs[warp_to_wsapwn] <= wsapwn_pc;
@ -183,6 +192,7 @@ module VX_warp_scheduler (
wire pop = is_join && correct_warp_j;
VX_generic_stack #(.WIDTH(1+32+`NT), .DEPTH($clog2(`NT))) ipdom_stack(
.clk (clk),
.reset(reset),
.push (push),
.pop (pop),
.d (d),