Line 43... |
Line 43... |
output [M-1:0][N-1:0] cfg; // the generated configuration
|
output [M-1:0][N-1:0] cfg; // the generated configuration
|
wire [N-1:0][M-1:0] scfg;
|
wire [N-1:0][M-1:0] scfg;
|
|
|
wire [M-1:0][N-1:0] hs; // match results
|
wire [M-1:0][N-1:0] hs; // match results
|
wire [M-1:0][N-1:0] blk; // blockage
|
wire [M-1:0][N-1:0] blk; // blockage
|
wire [N-1:0][M-1:0] cblk; // shuffled blockage
|
wire [N-1:0][M-1:0] sblk; // shuffled blockage
|
wire [M-1:0] rblk; // resource blockage
|
wire [M-1:0] rbi; // resource blockage
|
wire [N-1:0] cblk; // client blockage
|
wire [N-1:0] cbi; // client blockage
|
wire [N-1:0] cg, cm; // client requests
|
wire [N-1:0] cg, cm; // client requests
|
wire [M-1:0] rg, rm; // resource requests
|
wire [M-1:0] rg, rm; // resource requests
|
|
|
input rst_n; // active low reset
|
input rst_n; // active low reset
|
|
|
Line 80... |
Line 80... |
.rg ( rg[i] ),
|
.rg ( rg[i] ),
|
.cg ( cg[j] )
|
.cg ( cg[j] )
|
);
|
);
|
|
|
// shuffle the blockage
|
// shuffle the blockage
|
assign cblk[j][i] = blk[i][j];
|
assign sblk[j][i] = blk[i][j];
|
|
|
// shuffle the configuration
|
// shuffle the configuration
|
assign scfg[j][i] = cfg[i][j];
|
assign scfg[j][i] = cfg[i][j];
|
|
|
// store the match results
|
// store the match results
|
Line 95... |
Line 95... |
|
|
// combine the row blockage and generate input requests
|
// combine the row blockage and generate input requests
|
for(i=0; i<M; i++) begin: RB
|
for(i=0; i<M; i++) begin: RB
|
assign rbi[i] = (|blk[i]) & rst_n;
|
assign rbi[i] = (|blk[i]) & rst_n;
|
and AND_RG (rm[i], r[i], ~ra[i], rst_n);
|
and AND_RG (rm[i], r[i], ~ra[i], rst_n);
|
ra[i] = |cfg[i];
|
assign ra[i] = |cfg[i];
|
end
|
end
|
|
|
// combine the column blockage and generate input requests
|
// combine the column blockage and generate input requests
|
for(j=0; j<N; j++) begin: CB
|
for(j=0; j<N; j++) begin: CB
|
assign cbi[j] = (|cblk[j]) & rst_n;
|
assign cbi[j] = (|sblk[j]) & rst_n;
|
and AND_CG (cm[j], c[j], ~ca[j], rst_n);
|
and AND_CG (cm[j], c[j], ~ca[j], rst_n);
|
assign ca[j] = |scfg[j];
|
assign ca[j] = |scfg[j];
|
end
|
end
|
endgenerate
|
endgenerate
|
|
|