Initial commit of OpenSPARC T2 design and verification files.
[OpenSPARC-T2-DV] / design / sys / iop / l2t / rtl / l2t_snpd_dp.v
CommitLineData
86530b38
AT
1// ========== Copyright Header Begin ==========================================
2//
3// OpenSPARC T2 Processor File: l2t_snpd_dp.v
4// Copyright (C) 1995-2007 Sun Microsystems, Inc. All Rights Reserved
5// 4150 Network Circle, Santa Clara, California 95054, U.S.A.
6//
7// * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
8//
9// This program is free software; you can redistribute it and/or modify
10// it under the terms of the GNU General Public License as published by
11// the Free Software Foundation; version 2 of the License.
12//
13// This program is distributed in the hope that it will be useful,
14// but WITHOUT ANY WARRANTY; without even the implied warranty of
15// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16// GNU General Public License for more details.
17//
18// You should have received a copy of the GNU General Public License
19// along with this program; if not, write to the Free Software
20// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21//
22// For the avoidance of doubt, and except that if any non-GPL license
23// choice is available it will apply instead, Sun elects to use only
24// the General Public License version 2 (GPLv2) at this time for any
25// software where a choice of GPL license versions is made
26// available with the language indicating that GPLv2 or any later version
27// may be used, or where a choice of which version of the GPL is applied is
28// otherwise unspecified.
29//
30// Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
31// CA 95054 USA or visit www.sun.com if you need additional information or
32// have any questions.
33//
34// ========== Copyright Header End ============================================
35`define IQ_SIZE 8
36`define OQ_SIZE 12
37`define TAG_WIDTH 28
38`define TAG_WIDTH_LESS1 27
39`define TAG_WIDTHr 28r
40`define TAG_WIDTHc 28c
41`define TAG_WIDTH6 22
42`define TAG_WIDTH6r 22r
43`define TAG_WIDTH6c 22c
44
45
46`define MBD_WIDTH 106 // BS and SR 11/12/03 N2 Xbar Packet format change
47
48// BS and SR 11/12/03 N2 Xbar Packet format change
49
50`define MBD_ECC_HI 105
51`define MBD_ECC_HI_PLUS1 106
52`define MBD_ECC_HI_PLUS5 110
53`define MBD_ECC_LO 100
54`define MBD_EVICT 99
55`define MBD_DEP 98
56`define MBD_TECC 97
57`define MBD_ENTRY_HI 96
58`define MBD_ENTRY_LO 93
59
60`define MBD_POISON 92
61`define MBD_RDMA_HI 91
62`define MBD_RDMA_LO 90
63`define MBD_RQ_HI 89
64`define MBD_RQ_LO 85
65`define MBD_NC 84
66`define MBD_RSVD 83
67`define MBD_CP_HI 82
68`define MBD_CP_LO 80
69`define MBD_TH_HI 79
70`define MBD_TH_LO 77
71`define MBD_BF_HI 76
72`define MBD_BF_LO 74
73`define MBD_WY_HI 73
74`define MBD_WY_LO 72
75`define MBD_SZ_HI 71
76`define MBD_SZ_LO 64
77`define MBD_DATA_HI 63
78`define MBD_DATA_LO 0
79
80// BS and SR 11/12/03 N2 Xbar Packet format change
81`define L2_FBF 40
82`define L2_MBF 39
83`define L2_SNP 38
84`define L2_CTRUE 37
85`define L2_EVICT 36
86`define L2_DEP 35
87`define L2_TECC 34
88`define L2_ENTRY_HI 33
89`define L2_ENTRY_LO 29
90
91`define L2_POISON 28
92`define L2_RDMA_HI 27
93`define L2_RDMA_LO 26
94// BS and SR 11/12/03 N2 Xbar Packet format change , maps to bits [128:104] of PCXS packet , ther than RSVD bit
95`define L2_RQTYP_HI 25
96`define L2_RQTYP_LO 21
97`define L2_NC 20
98`define L2_RSVD 19
99`define L2_CPUID_HI 18
100`define L2_CPUID_LO 16
101`define L2_TID_HI 15
102`define L2_TID_LO 13
103`define L2_BUFID_HI 12
104`define L2_BUFID_LO 10
105`define L2_L1WY_HI 9
106`define L2_L1WY_LO 8
107`define L2_SZ_HI 7
108`define L2_SZ_LO 0
109
110
111`define ERR_MEU 63
112`define ERR_MEC 62
113`define ERR_RW 61
114`define ERR_ASYNC 60
115`define ERR_TID_HI 59 // PRM needs to change to reflect this : TID will be bits [59:54] instead of [58:54]
116`define ERR_TID_LO 54
117`define ERR_LDAC 53
118`define ERR_LDAU 52
119`define ERR_LDWC 51
120`define ERR_LDWU 50
121`define ERR_LDRC 49
122`define ERR_LDRU 48
123`define ERR_LDSC 47
124`define ERR_LDSU 46
125`define ERR_LTC 45
126`define ERR_LRU 44
127`define ERR_LVU 43
128`define ERR_DAC 42
129`define ERR_DAU 41
130`define ERR_DRC 40
131`define ERR_DRU 39
132`define ERR_DSC 38
133`define ERR_DSU 37
134`define ERR_VEC 36
135`define ERR_VEU 35
136`define ERR_LVC 34
137`define ERR_SYN_HI 31
138`define ERR_SYN_LO 0
139
140
141
142`define ERR_MEND 51
143`define ERR_NDRW 50
144`define ERR_NDSP 49
145`define ERR_NDDM 48
146`define ERR_NDVCID_HI 45
147`define ERR_NDVCID_LO 40
148`define ERR_NDADR_HI 39
149`define ERR_NDADR_LO 4
150
151
152// Phase 2 : SIU Inteface and format change
153
154`define JBI_HDR_SZ 26 // BS and SR 11/12/03 N2 Xbar Packet format change
155`define JBI_HDR_SZ_LESS1 25 // BS and SR 11/12/03 N2 Xbar Packet format change
156`define JBI_HDR_SZ4 23
157`define JBI_HDR_SZc 27c
158`define JBI_HDR_SZ4c 23c
159
160`define JBI_ADDR_LO 0
161`define JBI_ADDR_HI 7
162`define JBI_SZ_LO 8
163`define JBI_SZ_HI 15
164// `define JBI_RSVD 16 NOt used
165`define JBI_CTAG_LO 16
166`define JBI_CTAG_HI 23
167`define JBI_RQ_RD 24
168`define JBI_RQ_WR8 25
169`define JBI_RQ_WR64 26
170`define JBI_OPES_LO 27 // 0 = 30, P=29, E=28, S=27
171`define JBI_OPES_HI 30
172`define JBI_RQ_POISON 31
173`define JBI_ENTRY_LO 32
174`define JBI_ENTRY_HI 33
175
176// Phase 2 : SIU Inteface and format change
177// BS and SR 11/12/03 N2 Xbar Packet format change :
178`define JBINST_SZ_LO 0
179`define JBINST_SZ_HI 7
180// `define JBINST_RSVD 8 NOT used
181`define JBINST_CTAG_LO 8
182`define JBINST_CTAG_HI 15
183`define JBINST_RQ_RD 16
184`define JBINST_RQ_WR8 17
185`define JBINST_RQ_WR64 18
186`define JBINST_OPES_LO 19 // 0 = 22, P=21, E=20, S=19
187`define JBINST_OPES_HI 22
188`define JBINST_ENTRY_LO 23
189`define JBINST_ENTRY_HI 24
190`define JBINST_POISON 25
191
192
193`define ST_REQ_ST 1
194`define LD_REQ_ST 2
195`define IDLE 0
196
197
198
199
200module l2t_snpd_dp (
201 tcu_pce_ov,
202 tcu_aclk,
203 tcu_bclk,
204 tcu_scan_en,
205 tcu_clk_stop,
206 scan_out,
207 snpd_snpq_arbdp_addr_px2,
208 snpd_snpq_arbdp_inst_px2,
209 snpd_snpq_arbdp_data_px2,
210 snpd_ecc_px2,
211 snpd_rq_winv_s1,
212 snpd_rdmatag_wr_addr_s2,
213 l2clk,
214 scan_in,
215 sii_l2t_req,
216 sii_l2b_ecc,
217 snp_hdr1_wen0_s0,
218 snp_hdr2_wen0_s1,
219 snp_snp_data1_wen0_s2,
220 snp_snp_data2_wen0_s3,
221 snp_hdr1_wen1_s0,
222 snp_hdr2_wen1_s1,
223 snp_snp_data1_wen1_s2,
224 snp_snp_data2_wen1_s3,
225 snp_wr_ptr,
226 snp_rd_ptr,
227 snp_rdmad_wr_entry_s2,
228 l2t_mb2_wdata,
229 l2t_mb2_run,
230 l2t_siu_delay);
231wire stop;
232wire pce_ov;
233wire siclk;
234wire soclk;
235wire se;
236wire l2t_siu_delay_n;
237wire ff_siu_req_delay_scanin;
238wire ff_siu_req_delay_scanout;
239wire [31:0] rdmat_sii_req_dely;
240wire [31:0] muxed_dly_rdmat_sii_req;
241wire ff_siu_ecc_delay_scanin;
242wire ff_siu_ecc_delay_scanout;
243wire [6:0] sii_l2b_ecc_delay;
244wire [6:0] muxed_dly_rdmat_sii_ecc;
245wire ff_siu_req_scanin;
246wire ff_siu_req_scanout;
247wire [31:0] rdmat_sii_req_buf;
248wire ff_siu_ecc_scanin;
249wire ff_siu_ecc_scanout;
250wire [6:0] sii_l2b_ecc_d1;
251wire ff_MERGED_scanin;
252wire ff_MERGED_scanout;
253wire [6:0] instr0_ecc;
254wire ff_instr0_entry_scanin;
255wire ff_instr0_entry_scanout;
256wire ff_addr0_2_scanin;
257wire ff_addr0_2_scanout;
258wire ff_data0_1_scanin;
259wire ff_data0_1_scanout;
260wire ff_data0_2_scanin;
261wire ff_data0_2_scanout;
262wire ff_addr1_1_MERGED_scanin;
263wire ff_addr1_1_MERGED_scanout;
264wire [6:0] instr1_ecc;
265wire ff_instr1_entry_scanin;
266wire ff_instr1_entry_scanout;
267wire ff_addr1_2_scanin;
268wire ff_addr1_2_scanout;
269wire ff_data1_1_scanin;
270wire ff_data1_1_scanout;
271wire ff_data1_2_scanin;
272wire ff_data1_2_scanout;
273wire l2t_mb2_run_r1_n;
274wire snp_wr_ptr_n;
275wire l2t_mb2_run_r1;
276wire [39:6] snpd_rdmatag_wr_addr_s2_fnl;
277wire [7:0] l2t_mb2_wdata_r3;
278wire ff_snp_rd_ptr_d1_5_MERGED_scanin;
279wire ff_snp_rd_ptr_d1_5_MERGED_scanout;
280wire [7:0] l2t_mb2_wdata_r1;
281wire [7:0] l2t_mb2_wdata_r2;
282wire snp_rd_ptr_n;
283wire snp_rd_ptr_d1_5;
284wire snp_rd_ptr_d1_n;
285wire snp_rd_ptr_d1_1_n;
286wire [39:0] snpd_snpq_arbdp_addr_px2_unbuff;
287wire snp_rd_ptr_d1_5_n;
288wire snp_rd_ptr_d1_2_n;
289wire snp_rd_ptr_d1_3_n;
290
291
292input tcu_pce_ov;
293input tcu_aclk;
294input tcu_bclk;
295input tcu_scan_en;
296input tcu_clk_stop;
297
298output scan_out;
299
300// to the arbiter
301output [39:0] snpd_snpq_arbdp_addr_px2;
302output [`JBI_HDR_SZ-1:0] snpd_snpq_arbdp_inst_px2; // this bus has grown by 1 bit since 2.0
303output [63:0] snpd_snpq_arbdp_data_px2;
304output [6:0] snpd_ecc_px2;
305
306// to snp
307output snpd_rq_winv_s1; // to snp ctl;
308
309// to rdmatag
310output [39:6] snpd_rdmatag_wr_addr_s2 ;
311
312input l2clk;
313input scan_in;
314
315// from siu
316input [31:0] sii_l2t_req; // Phase 2 : SIU inteface and packet format change 2/7/04
317input [ 6:0] sii_l2b_ecc; // RAS implementation 10/14/04
318
319 // from snp
320input snp_hdr1_wen0_s0, snp_hdr2_wen0_s1, snp_snp_data1_wen0_s2, snp_snp_data2_wen0_s3 ;
321input snp_hdr1_wen1_s0, snp_hdr2_wen1_s1, snp_snp_data1_wen1_s2, snp_snp_data2_wen1_s3 ;
322input snp_wr_ptr;
323input snp_rd_ptr;
324input [1:0] snp_rdmad_wr_entry_s2;
325
326// mb2 controller
327
328input [7:0] l2t_mb2_wdata;
329input l2t_mb2_run;
330
331// from cpu
332
333input l2t_siu_delay;
334
335
336assign stop = tcu_clk_stop;
337assign pce_ov = tcu_pce_ov;
338assign siclk = tcu_aclk;
339assign soclk = tcu_bclk;
340assign se = tcu_scan_en;
341
342
343
344wire [`JBI_HDR_SZ-1:0] instr0;
345wire [`JBI_HDR_SZ-1:0] instr1;
346wire [39:0] addr0;
347wire [39:0] addr1;
348wire [63:0] data0;
349wire [63:0] data1;
350
351wire snp_rd_ptr_d1, snp_rd_ptr_d1_1, snp_rd_ptr_d1_2, snp_rd_ptr_d1_3 ;
352
353wire snp_rd_ptr_d1_4;
354
355//////////////////////////////////////////////////////////////////////////////////////////////////
356// data path is 92 bits wide.
357// address = 40 bits
358// header = 20 bits
359// data = 64 bits/2
360//////////////////////////////////////////////////////////////////////////////////////////////////
361// Phase 2 : SIU inteface and packet format change 2/7/04
362// In cycle 1 write 24 bits of header and 8 bits of address.
363// WRI WR8 RDD
364//[31] = don't care [31] = don't care [31] = don't care
365//[30] = 'O'rdered bit [30] = 'O'rdered bit [30] = 'O'rdered bit
366//[29] = 'P'osted bit [29] = 'P'osted bit [29] = 'P'osted bit
367//[28] = 'E'rror bit [28] = 'E'rror bit [28] = 'E'rror bit
368//[27] = 'S'ource bit (DMU/NIU) [27] = 'S'ource bit (DMU/NIU) [27] = 'S'ource bit (DMU/NIU)
369//[26:24] = 3'b100 for WRI [26:24] = 3'b010 for WR8 [26:24] = 3'b001 for RDD
370//[23:08] = Tag bits[15:0] [23:16] = Don't care [23:08] = Tag bits[15:0]
371//[7:0] = Address[39:32] [15:8] = Bytemasks[7:0] [7:0] = Address[39:32]
372// [7:0] = Address[39:32]
373//////////////////////////////////////////////////////////////////////////////////////////////////
374
375l2t_snpd_dp_inv_macro__width_1 inv_l2t_siu_delay
376 (
377 .dout (l2t_siu_delay_n),
378 .din (l2t_siu_delay)
379 );
380
381
382l2t_snpd_dp_msff_macro__stack_32c__width_32 ff_siu_req_delay
383 (
384 .scan_in(ff_siu_req_delay_scanin),
385 .scan_out(ff_siu_req_delay_scanout),
386 .dout(rdmat_sii_req_dely[31:0]),
387 .din(sii_l2t_req[31:0]),
388 .clk(l2clk),
389 .en(1'b1),
390 .se(se),
391 .siclk(siclk),
392 .soclk(soclk),
393 .pce_ov(pce_ov),
394 .stop(stop)
395 );
396
397
398l2t_snpd_dp_mux_macro__dmux_8x__mux_aonpe__ports_2__stack_34c__width_32 mux_rdmat_sii_req_dely
399 (
400 .dout (muxed_dly_rdmat_sii_req[31:0]),
401 .din0 (sii_l2t_req[31:0]),
402 .din1 (rdmat_sii_req_dely[31:0]),
403 .sel0 (l2t_siu_delay_n),
404 .sel1 (l2t_siu_delay)
405 );
406
407l2t_snpd_dp_msff_macro__stack_8c__width_7 ff_siu_ecc_delay
408 (
409 .scan_in(ff_siu_ecc_delay_scanin),
410 .scan_out(ff_siu_ecc_delay_scanout),
411 .din(sii_l2b_ecc[6:0]),
412 .dout(sii_l2b_ecc_delay[6:0]),
413 .clk(l2clk),
414 .en(1'b1),
415 .se(se),
416 .siclk(siclk),
417 .soclk(soclk),
418 .pce_ov(pce_ov),
419 .stop(stop)
420 );
421
422
423l2t_snpd_dp_mux_macro__dmux_8x__mux_aonpe__ports_2__stack_8c__width_7 mux_siu_ecc_dly
424 (
425 .dout (muxed_dly_rdmat_sii_ecc[6:0]),
426 .din0 (sii_l2b_ecc[6:0]),
427 .din1 (sii_l2b_ecc_delay[6:0]),
428 .sel0 (l2t_siu_delay_n),
429 .sel1 (l2t_siu_delay)
430 );
431
432
433
434// Phase 2 : SIU inteface and packet format change 2/7/04
435// This adds the 1 cycle delay to the req bus from SIU hence lining
436// up timing
437
438l2t_snpd_dp_msff_macro__stack_32c__width_32 ff_siu_req
439 (
440 .scan_in(ff_siu_req_scanin),
441 .scan_out(ff_siu_req_scanout),
442 .dout(rdmat_sii_req_buf[31:0]),
443 .din(muxed_dly_rdmat_sii_req[31:0]),
444 .clk(l2clk),
445 .en(1'b1),
446 .se(se),
447 .siclk(siclk),
448 .soclk(soclk),
449 .pce_ov(pce_ov),
450 .stop(stop)
451 );
452
453l2t_snpd_dp_msff_macro__stack_7c__width_7 ff_siu_ecc
454 (
455 .scan_in(ff_siu_ecc_scanin),
456 .scan_out(ff_siu_ecc_scanout),
457 .din(muxed_dly_rdmat_sii_ecc[6:0]),
458 .dout(sii_l2b_ecc_d1[6:0]),
459 .clk(l2clk),
460 .en(1'b1),
461 .se(se),
462 .siclk(siclk),
463 .soclk(soclk),
464 .pce_ov(pce_ov),
465 .stop(stop)
466 );
467
468
469l2t_snpd_dp_msff_macro__stack_39c__width_39 ff_MERGED
470 (
471 .scan_in(ff_MERGED_scanin),
472 .scan_out(ff_MERGED_scanout),
473 .din({sii_l2b_ecc_d1[6:0],rdmat_sii_req_buf[`JBI_RQ_POISON],rdmat_sii_req_buf[`JBI_OPES_HI:`JBI_SZ_LO],rdmat_sii_req_buf[`JBI_ADDR_HI:`JBI_ADDR_LO]}),
474 .clk(l2clk),
475 .dout({instr0_ecc[6:0],instr0[`JBI_HDR_SZ-1],instr0[`JBI_HDR_SZ-4:0],addr0[39:32]}),
476 .en(snp_hdr1_wen0_s0),
477 .se(se),
478 .siclk(siclk),
479 .soclk(soclk),
480 .pce_ov(pce_ov),
481 .stop(stop)
482 );
483
484// Phase 2 : SIU inteface and packet format change 2/7/04
485
486l2t_snpd_dp_msff_macro__stack_2c__width_2 ff_instr0_entry
487 (
488 .scan_in(ff_instr0_entry_scanin),
489 .scan_out(ff_instr0_entry_scanout),
490 .din(snp_rdmad_wr_entry_s2[1:0]), .clk(l2clk),
491 .dout(instr0[`JBI_HDR_SZ-2:`JBI_HDR_SZ-3]),
492 .en(snp_snp_data1_wen0_s2),
493 .se(se),
494 .siclk(siclk),
495 .soclk(soclk),
496 .pce_ov(pce_ov),
497 .stop(stop)
498 );
499
500// 32 bits of addr <31:0>
501// cycle s2
502
503l2t_snpd_dp_msff_macro__stack_32c__width_32 ff_addr0_2
504 (
505 .scan_in(ff_addr0_2_scanin),
506 .scan_out(ff_addr0_2_scanout),
507 .din(rdmat_sii_req_buf[31:0]), .clk(l2clk),
508 .dout(addr0[31:0]),
509 .en(snp_hdr2_wen0_s1),
510 .se(se),
511 .siclk(siclk),
512 .soclk(soclk),
513 .pce_ov(pce_ov),
514 .stop(stop)
515
516 );
517
518// 32 bits of data <63:32>
519// cycle s3
520
521l2t_snpd_dp_msff_macro__dmsff_16x__stack_32c__width_32 ff_data0_1
522 (
523 .scan_in(ff_data0_1_scanin),
524 .scan_out(ff_data0_1_scanout),
525 .din(rdmat_sii_req_buf[31:0]), .clk(l2clk),
526 .dout(data0[63:32]),
527 .en(snp_snp_data1_wen0_s2),
528 .se(se),
529 .siclk(siclk),
530 .soclk(soclk),
531 .pce_ov(pce_ov),
532 .stop(stop)
533 );
534
535
536// 32 bits of data <31:0>
537// cycle s4
538
539
540l2t_snpd_dp_msff_macro__dmsff_16x__stack_32c__width_32 ff_data0_2
541 (
542 .scan_in(ff_data0_2_scanin),
543 .scan_out(ff_data0_2_scanout),
544 .din(rdmat_sii_req_buf[31:0]), .clk(l2clk),
545 .dout(data0[31:0]),
546 .en(snp_snp_data2_wen0_s3),
547 .se(se),
548 .siclk(siclk),
549 .soclk(soclk),
550 .pce_ov(pce_ov),
551 .stop(stop)
552 );
553
554// In cycle 1 write 24 bits of header and 8 bits of address.
555// Header = wr64 wr8 rd CTAG<11:0> RSVD SZ<7:0>
556// address : 7:0
557// size : 15:8
558// rsvd : 16
559// ctag : 28:17
560// rd : 29
561// wr8 : 30
562// wr64 : 31
563// cycle s1
564
565l2t_snpd_dp_msff_macro__stack_39c__width_39 ff_addr1_1_MERGED
566 (
567 .scan_in(ff_addr1_1_MERGED_scanin),
568 .scan_out(ff_addr1_1_MERGED_scanout),
569 .din({sii_l2b_ecc_d1[6:0],rdmat_sii_req_buf[`JBI_OPES_HI:`JBI_SZ_LO],rdmat_sii_req_buf[`JBI_ADDR_HI:`JBI_ADDR_LO],rdmat_sii_req_buf[`JBI_RQ_POISON]}),
570 .clk(l2clk),
571 .dout({instr1_ecc[6:0],instr1[`JBI_HDR_SZ-4:0],addr1[39:32],instr1[`JBI_HDR_SZ-1]}),
572 .en(snp_hdr1_wen1_s0),
573 .se(se),
574 .siclk(siclk),
575 .soclk(soclk),
576 .pce_ov(pce_ov),
577 .stop(stop)
578 );
579
580// Phase 2 : SIU inteface and packet format change 2/7/04
581
582l2t_snpd_dp_msff_macro__stack_2c__width_2 ff_instr1_entry
583 (
584 .scan_in(ff_instr1_entry_scanin),
585 .scan_out(ff_instr1_entry_scanout),
586 .din(snp_rdmad_wr_entry_s2[1:0]), .clk(l2clk),
587 .dout(instr1[`JBI_HDR_SZ-2:`JBI_HDR_SZ-3]),
588 .en(snp_snp_data1_wen1_s2),
589 .se(se),
590 .siclk(siclk),
591 .soclk(soclk),
592 .pce_ov(pce_ov),
593 .stop(stop)
594 );
595
596
597
598// 32 bits of addr <31:0>
599// cycle s2
600
601
602l2t_snpd_dp_msff_macro__stack_32c__width_32 ff_addr1_2
603 (.din(rdmat_sii_req_buf[31:0]), .clk(l2clk),
604 .scan_in(ff_addr1_2_scanin),
605 .scan_out(ff_addr1_2_scanout),
606 .dout(addr1[31:0]),
607 .en(snp_hdr2_wen1_s1),
608 .se(se),
609 .siclk(siclk),
610 .soclk(soclk),
611 .pce_ov(pce_ov),
612 .stop(stop)
613 );
614
615
616
617// 32 bits of data <63:32>
618// cycle s3
619
620l2t_snpd_dp_msff_macro__dmsff_16x__stack_32c__width_32 ff_data1_1
621 (
622 .scan_in(ff_data1_1_scanin),
623 .scan_out(ff_data1_1_scanout),
624 .din(rdmat_sii_req_buf[31:0]), .clk(l2clk),
625 .dout(data1[63:32]),
626 .en(snp_snp_data1_wen1_s2),
627 .se(se),
628 .siclk(siclk),
629 .soclk(soclk),
630 .pce_ov(pce_ov),
631 .stop(stop)
632 );
633
634// 32 bits of data <31:0>
635// cycle s4
636
637l2t_snpd_dp_msff_macro__dmsff_16x__stack_32c__width_32 ff_data1_2
638 (
639 .scan_in(ff_data1_2_scanin),
640 .scan_out(ff_data1_2_scanout),
641 .din(rdmat_sii_req_buf[31:0]), .clk(l2clk),
642 .dout(data1[31:0]),
643 .en(snp_snp_data2_wen1_s3),
644 .se(se),
645 .siclk(siclk),
646 .soclk(soclk),
647 .pce_ov(pce_ov),
648 .stop(stop)
649 );
650
651
652
653
654/////////////////////////////////////////////////
655// A 34 bit mux is used to mux out the address
656// of the request that is being sent from the siu.
657// Hence wr ptr is used for this mux.
658// If this request happens to be a WR64, the
659// address is written into the rdma tags.
660/////////////////////////////////////////////////
661
662l2t_snpd_dp_inv_macro__width_2 snp_wr_ptr_inv_slice
663 (
664 .dout ({l2t_mb2_run_r1_n,snp_wr_ptr_n}),
665 .din ({l2t_mb2_run_r1,snp_wr_ptr})
666 );
667
668
669l2t_snpd_dp_mux_macro__dmux_8x__mux_aonpe__ports_2__stack_35c__width_35 mux_MERGED
670 (.dout ({snpd_rdmatag_wr_addr_s2_fnl[39:6],snpd_rq_winv_s1}) ,
671 .din0({addr0[39:6],instr0[`JBINST_RQ_WR64]}), // entry0
672 .din1({addr1[39:6],instr1[`JBINST_RQ_WR64]}), // entry1
673 .sel0(snp_wr_ptr_n), // entry 0 is being written
674 .sel1(snp_wr_ptr)) ; // entry 1 is being written
675
676l2t_snpd_dp_mux_macro__dmux_8x__mux_aonpe__ports_2__stack_34c__width_34 mux_snpd_rdmatag_wr_addr_s2
677 (
678 .dout (snpd_rdmatag_wr_addr_s2[39:6]),
679 .din0 (snpd_rdmatag_wr_addr_s2_fnl[39:6]),
680 .din1 ({l2t_mb2_wdata_r3[1:0],{4{l2t_mb2_wdata_r3[7:0]}}}),
681 .sel0 (l2t_mb2_run_r1_n),
682 .sel1 (l2t_mb2_run_r1)
683 );
684
685
686
687
688/////////////////////////////////////////////////
689// The snp q output is a mux between the
690// entry0 and entry1.
691//
692// rd pointer is updated when arb_snpsel_c1
693//
694/////////////////////////////////////////////////
695
696
697l2t_snpd_dp_msff_macro__dmsff_32x__stack_32c__width_32 ff_snp_rd_ptr_d1_5_MERGED
698 (
699 .scan_in(ff_snp_rd_ptr_d1_5_MERGED_scanin),
700 .scan_out(ff_snp_rd_ptr_d1_5_MERGED_scanout),
701 .din({l2t_mb2_wdata[7:0],l2t_mb2_wdata_r1[7:0],l2t_mb2_wdata_r2[7:0],
702 l2t_mb2_run,snp_rd_ptr,snp_rd_ptr,snp_rd_ptr,
703 snp_rd_ptr,snp_rd_ptr,snp_rd_ptr,snp_rd_ptr_n}),
704 .clk(l2clk),
705 .dout({l2t_mb2_wdata_r1[7:0],l2t_mb2_wdata_r2[7:0],l2t_mb2_wdata_r3[7:0],
706 l2t_mb2_run_r1,snp_rd_ptr_d1_5,
707 snp_rd_ptr_d1_4,snp_rd_ptr_d1_3,snp_rd_ptr_d1_2,
708 snp_rd_ptr_d1_1,snp_rd_ptr_d1,snp_rd_ptr_d1_n}),
709 .en(1'b1),
710 .se(se),
711 .siclk(siclk),
712 .soclk(soclk),
713 .pce_ov(pce_ov),
714 .stop(stop)
715 );
716
717l2t_snpd_dp_inv_macro__width_1 snp_rd_ptr_inv_slice
718 (
719 .dout (snp_rd_ptr_n ),
720 .din (snp_rd_ptr )
721 );
722
723
724l2t_snpd_dp_mux_macro__dmux_8x__mux_aonpe__ports_2__stack_27c__width_26 mux_instr_px2
725 (.dout (snpd_snpq_arbdp_inst_px2[`JBI_HDR_SZ-1:0]),
726 .din0(instr0[`JBI_HDR_SZ-1:0]), // entry0
727 .din1(instr1[`JBI_HDR_SZ-1:0]), // entry1
728 .sel0(snp_rd_ptr_d1_n), // entry 0 is being written
729 .sel1(snp_rd_ptr_d1)) ; // entry 1 is being written
730
731l2t_snpd_dp_mux_macro__dmux_8x__mux_aonpe__ports_2__stack_7c__width_7 mux_snp_ecc_px2
732 (.dout (snpd_ecc_px2[6:0]),
733 .din0 (instr0_ecc[6:0]), // entry0
734 .din1 (instr1_ecc[6:0]), // entry1
735 .sel0 (snp_rd_ptr_d1_n), // entry 0 is being written
736 .sel1 (snp_rd_ptr_d1)) ; // entry 1 is being written
737
738
739
740
741
742
743
744// Change 6/13/2003
745// 1) use an 8x flop for snp_rd_ptr_d1_4, snp_rd_ptr_d1_5
746// The above signals can be used for the more critical address bits <17:8>
747// transmit the selects close to the affected bits before flopping them so
748// as to save time in PX2.
749// 2) The 2-1 addr mux ( use a 2x mux) can be performed between ~addr0 and ~addr1.
750// The result can be driven using a 40x buffer
751
752
753l2t_snpd_dp_inv_macro__width_1 snp_rd_ptr_d1_1_inv_slice
754 (
755 .dout (snp_rd_ptr_d1_1_n ),
756 .din (snp_rd_ptr_d1_1 )
757 );
758
759//buff_macro buff_snpd_snpq_arbdp_addr_px2_1 (width=30,stack=30c,dbuff=32x)
760// (
761// .dout ({snpd_snpq_arbdp_addr_px2[39:18],snpd_snpq_arbdp_addr_px2[7:0]}) ,
762// .din ({snpd_snpq_arbdp_addr_px2_unbuff[39:18],snpd_snpq_arbdp_addr_px2_unbuff[7:0]}) ,
763// );
764
765assign snpd_snpq_arbdp_addr_px2[39:0] = snpd_snpq_arbdp_addr_px2_unbuff[39:0];
766
767
768l2t_snpd_dp_mux_macro__dmux_32x__mux_pgpe__ports_2__stack_30c__width_30 mux_addr_px2_39_18_MERGED
769 (
770 .dout ({snpd_snpq_arbdp_addr_px2_unbuff[39:18],snpd_snpq_arbdp_addr_px2_unbuff[7:0]}) ,
771 .din0({addr0[39:18],addr0[7:0]}), // entry0
772 .din1({addr1[39:18],addr1[7:0]}), // entry1
773 .sel0(snp_rd_ptr_d1_1_n) // entry 0 is being read
774 ); // entry 1 is being read
775
776l2t_snpd_dp_mux_macro__dmux_32x__mux_pgpe__ports_2__stack_5c__width_5 mux_addr_px2_17_13
777 (.dout (snpd_snpq_arbdp_addr_px2_unbuff[17:13]) ,
778 .din0(addr1[17:13]), // entry1
779 .din1(addr0[17:13]), // entry0
780 .sel0(snp_rd_ptr_d1_4) // entry 0 is being read
781 ) ; // entry 1 is being read
782
783l2t_snpd_dp_inv_macro__width_1 snp_rd_ptr_d1_5_inv_slice
784 (
785 .dout (snp_rd_ptr_d1_5_n ),
786 .din (snp_rd_ptr_d1_5 )
787 );
788
789l2t_snpd_dp_mux_macro__dmux_32x__mux_pgpe__ports_2__stack_5c__width_5 mux_addr_px2_12_8
790 (.dout (snpd_snpq_arbdp_addr_px2_unbuff[12:8]) ,
791 .din0(addr0[12:8]), // entry0
792 .din1(addr1[12:8]), // entry1
793 .sel0(snp_rd_ptr_d1_5_n) // entry 0 is being read
794 ) ; // entry 1 is being read
795
796l2t_snpd_dp_inv_macro__width_1 snp_rd_ptr_d1_2_inv_slice
797 (
798 .dout (snp_rd_ptr_d1_2_n ),
799 .din (snp_rd_ptr_d1_2 )
800 );
801
802
803l2t_snpd_dp_mux_macro__dmux_32x__mux_pgpe__ports_2__stack_32c__width_32 mux_data_px2_0
804 (.dout (snpd_snpq_arbdp_data_px2[31:0]) ,
805 .din0(data0[31:0]), // entry0
806 .din1(data1[31:0]), // entry1
807 .sel0(snp_rd_ptr_d1_2_n) // entry 0 is being written
808 ) ; // entry 1 is being written
809
810
811l2t_snpd_dp_inv_macro__width_1 snp_rd_ptr_d1_3_inv_slice
812 (
813 .dout (snp_rd_ptr_d1_3_n ),
814 .din (snp_rd_ptr_d1_3 )
815 );
816
817
818l2t_snpd_dp_mux_macro__dmux_32x__mux_pgpe__ports_2__stack_32c__width_32 mux_data_px2_1
819 (
820 .dout (snpd_snpq_arbdp_data_px2[63:32]) ,
821 .din0(data0[63:32]), // entry0
822 .din1(data1[63:32]), // entry1
823 .sel0(snp_rd_ptr_d1_3_n) // entry 0 is being written
824 );
825
826//buff_macro buff_snpd_snpq_arbdp_data_px2_1 (width=32,stack=32c,dbuff=32x)
827// (
828// .dout (snpd_snpq_arbdp_data_px2[63:32]),
829// .din (snpd_snpq_arbdp_data_px2_unbuff[63:32])
830// );
831//
832//buff_macro buff_snpd_snpq_arbdp_data_px2_2 (width=32,stack=32c,dbuff=32x)
833// (
834// .dout (snpd_snpq_arbdp_data_px2[31:0]),
835// .din (snpd_snpq_arbdp_data_px2_unbuff[31:0])
836// );
837//
838
839
840
841
842
843
844
845// fixscan start:
846assign ff_siu_req_delay_scanin = scan_in ;
847assign ff_siu_ecc_delay_scanin = ff_siu_req_delay_scanout ;
848assign ff_siu_req_scanin = ff_siu_ecc_delay_scanout ;
849assign ff_siu_ecc_scanin = ff_siu_req_scanout ;
850assign ff_MERGED_scanin = ff_siu_ecc_scanout ;
851assign ff_instr0_entry_scanin = ff_MERGED_scanout ;
852assign ff_addr0_2_scanin = ff_instr0_entry_scanout ;
853assign ff_data0_1_scanin = ff_addr0_2_scanout ;
854assign ff_data0_2_scanin = ff_data0_1_scanout ;
855assign ff_addr1_1_MERGED_scanin = ff_data0_2_scanout ;
856assign ff_instr1_entry_scanin = ff_addr1_1_MERGED_scanout;
857assign ff_addr1_2_scanin = ff_instr1_entry_scanout ;
858assign ff_data1_1_scanin = ff_addr1_2_scanout ;
859assign ff_data1_2_scanin = ff_data1_1_scanout ;
860assign ff_snp_rd_ptr_d1_5_MERGED_scanin = ff_data1_2_scanout ;
861assign scan_out = ff_snp_rd_ptr_d1_5_MERGED_scanout;
862// fixscan end:
863endmodule
864
865
866
867
868//
869// invert macro
870//
871//
872
873
874
875
876
877module l2t_snpd_dp_inv_macro__width_1 (
878 din,
879 dout);
880 input [0:0] din;
881 output [0:0] dout;
882
883
884
885
886
887
888inv #(1) d0_0 (
889.in(din[0:0]),
890.out(dout[0:0])
891);
892
893
894
895
896
897
898
899
900
901endmodule
902
903
904
905
906
907
908
909
910
911// any PARAMS parms go into naming of macro
912
913module l2t_snpd_dp_msff_macro__stack_32c__width_32 (
914 din,
915 clk,
916 en,
917 se,
918 scan_in,
919 siclk,
920 soclk,
921 pce_ov,
922 stop,
923 dout,
924 scan_out);
925wire l1clk;
926wire siclk_out;
927wire soclk_out;
928wire [30:0] so;
929
930 input [31:0] din;
931
932
933 input clk;
934 input en;
935 input se;
936 input scan_in;
937 input siclk;
938 input soclk;
939 input pce_ov;
940 input stop;
941
942
943
944 output [31:0] dout;
945
946
947 output scan_out;
948
949
950
951
952cl_dp1_l1hdr_8x c0_0 (
953.l2clk(clk),
954.pce(en),
955.aclk(siclk),
956.bclk(soclk),
957.l1clk(l1clk),
958 .se(se),
959 .pce_ov(pce_ov),
960 .stop(stop),
961 .siclk_out(siclk_out),
962 .soclk_out(soclk_out)
963);
964dff #(32) d0_0 (
965.l1clk(l1clk),
966.siclk(siclk_out),
967.soclk(soclk_out),
968.d(din[31:0]),
969.si({scan_in,so[30:0]}),
970.so({so[30:0],scan_out}),
971.q(dout[31:0])
972);
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993endmodule
994
995
996
997
998
999
1000
1001
1002
1003// general mux macro for pass-gate and and-or muxes with/wout priority encoders
1004// also for pass-gate with decoder
1005
1006
1007
1008
1009
1010// any PARAMS parms go into naming of macro
1011
1012module l2t_snpd_dp_mux_macro__dmux_8x__mux_aonpe__ports_2__stack_34c__width_32 (
1013 din0,
1014 sel0,
1015 din1,
1016 sel1,
1017 dout);
1018wire buffout0;
1019wire buffout1;
1020
1021 input [31:0] din0;
1022 input sel0;
1023 input [31:0] din1;
1024 input sel1;
1025 output [31:0] dout;
1026
1027
1028
1029
1030
1031cl_dp1_muxbuff2_8x c0_0 (
1032 .in0(sel0),
1033 .in1(sel1),
1034 .out0(buffout0),
1035 .out1(buffout1)
1036);
1037mux2s #(32) d0_0 (
1038 .sel0(buffout0),
1039 .sel1(buffout1),
1040 .in0(din0[31:0]),
1041 .in1(din1[31:0]),
1042.dout(dout[31:0])
1043);
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057endmodule
1058
1059
1060
1061
1062
1063
1064// any PARAMS parms go into naming of macro
1065
1066module l2t_snpd_dp_msff_macro__stack_8c__width_7 (
1067 din,
1068 clk,
1069 en,
1070 se,
1071 scan_in,
1072 siclk,
1073 soclk,
1074 pce_ov,
1075 stop,
1076 dout,
1077 scan_out);
1078wire l1clk;
1079wire siclk_out;
1080wire soclk_out;
1081wire [5:0] so;
1082
1083 input [6:0] din;
1084
1085
1086 input clk;
1087 input en;
1088 input se;
1089 input scan_in;
1090 input siclk;
1091 input soclk;
1092 input pce_ov;
1093 input stop;
1094
1095
1096
1097 output [6:0] dout;
1098
1099
1100 output scan_out;
1101
1102
1103
1104
1105cl_dp1_l1hdr_8x c0_0 (
1106.l2clk(clk),
1107.pce(en),
1108.aclk(siclk),
1109.bclk(soclk),
1110.l1clk(l1clk),
1111 .se(se),
1112 .pce_ov(pce_ov),
1113 .stop(stop),
1114 .siclk_out(siclk_out),
1115 .soclk_out(soclk_out)
1116);
1117dff #(7) d0_0 (
1118.l1clk(l1clk),
1119.siclk(siclk_out),
1120.soclk(soclk_out),
1121.d(din[6:0]),
1122.si({scan_in,so[5:0]}),
1123.so({so[5:0],scan_out}),
1124.q(dout[6:0])
1125);
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146endmodule
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156// general mux macro for pass-gate and and-or muxes with/wout priority encoders
1157// also for pass-gate with decoder
1158
1159
1160
1161
1162
1163// any PARAMS parms go into naming of macro
1164
1165module l2t_snpd_dp_mux_macro__dmux_8x__mux_aonpe__ports_2__stack_8c__width_7 (
1166 din0,
1167 sel0,
1168 din1,
1169 sel1,
1170 dout);
1171wire buffout0;
1172wire buffout1;
1173
1174 input [6:0] din0;
1175 input sel0;
1176 input [6:0] din1;
1177 input sel1;
1178 output [6:0] dout;
1179
1180
1181
1182
1183
1184cl_dp1_muxbuff2_8x c0_0 (
1185 .in0(sel0),
1186 .in1(sel1),
1187 .out0(buffout0),
1188 .out1(buffout1)
1189);
1190mux2s #(7) d0_0 (
1191 .sel0(buffout0),
1192 .sel1(buffout1),
1193 .in0(din0[6:0]),
1194 .in1(din1[6:0]),
1195.dout(dout[6:0])
1196);
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210endmodule
1211
1212
1213
1214
1215
1216
1217// any PARAMS parms go into naming of macro
1218
1219module l2t_snpd_dp_msff_macro__stack_7c__width_7 (
1220 din,
1221 clk,
1222 en,
1223 se,
1224 scan_in,
1225 siclk,
1226 soclk,
1227 pce_ov,
1228 stop,
1229 dout,
1230 scan_out);
1231wire l1clk;
1232wire siclk_out;
1233wire soclk_out;
1234wire [5:0] so;
1235
1236 input [6:0] din;
1237
1238
1239 input clk;
1240 input en;
1241 input se;
1242 input scan_in;
1243 input siclk;
1244 input soclk;
1245 input pce_ov;
1246 input stop;
1247
1248
1249
1250 output [6:0] dout;
1251
1252
1253 output scan_out;
1254
1255
1256
1257
1258cl_dp1_l1hdr_8x c0_0 (
1259.l2clk(clk),
1260.pce(en),
1261.aclk(siclk),
1262.bclk(soclk),
1263.l1clk(l1clk),
1264 .se(se),
1265 .pce_ov(pce_ov),
1266 .stop(stop),
1267 .siclk_out(siclk_out),
1268 .soclk_out(soclk_out)
1269);
1270dff #(7) d0_0 (
1271.l1clk(l1clk),
1272.siclk(siclk_out),
1273.soclk(soclk_out),
1274.d(din[6:0]),
1275.si({scan_in,so[5:0]}),
1276.so({so[5:0],scan_out}),
1277.q(dout[6:0])
1278);
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299endmodule
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313// any PARAMS parms go into naming of macro
1314
1315module l2t_snpd_dp_msff_macro__stack_39c__width_39 (
1316 din,
1317 clk,
1318 en,
1319 se,
1320 scan_in,
1321 siclk,
1322 soclk,
1323 pce_ov,
1324 stop,
1325 dout,
1326 scan_out);
1327wire l1clk;
1328wire siclk_out;
1329wire soclk_out;
1330wire [37:0] so;
1331
1332 input [38:0] din;
1333
1334
1335 input clk;
1336 input en;
1337 input se;
1338 input scan_in;
1339 input siclk;
1340 input soclk;
1341 input pce_ov;
1342 input stop;
1343
1344
1345
1346 output [38:0] dout;
1347
1348
1349 output scan_out;
1350
1351
1352
1353
1354cl_dp1_l1hdr_8x c0_0 (
1355.l2clk(clk),
1356.pce(en),
1357.aclk(siclk),
1358.bclk(soclk),
1359.l1clk(l1clk),
1360 .se(se),
1361 .pce_ov(pce_ov),
1362 .stop(stop),
1363 .siclk_out(siclk_out),
1364 .soclk_out(soclk_out)
1365);
1366dff #(39) d0_0 (
1367.l1clk(l1clk),
1368.siclk(siclk_out),
1369.soclk(soclk_out),
1370.d(din[38:0]),
1371.si({scan_in,so[37:0]}),
1372.so({so[37:0],scan_out}),
1373.q(dout[38:0])
1374);
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395endmodule
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409// any PARAMS parms go into naming of macro
1410
1411module l2t_snpd_dp_msff_macro__stack_2c__width_2 (
1412 din,
1413 clk,
1414 en,
1415 se,
1416 scan_in,
1417 siclk,
1418 soclk,
1419 pce_ov,
1420 stop,
1421 dout,
1422 scan_out);
1423wire l1clk;
1424wire siclk_out;
1425wire soclk_out;
1426wire [0:0] so;
1427
1428 input [1:0] din;
1429
1430
1431 input clk;
1432 input en;
1433 input se;
1434 input scan_in;
1435 input siclk;
1436 input soclk;
1437 input pce_ov;
1438 input stop;
1439
1440
1441
1442 output [1:0] dout;
1443
1444
1445 output scan_out;
1446
1447
1448
1449
1450cl_dp1_l1hdr_8x c0_0 (
1451.l2clk(clk),
1452.pce(en),
1453.aclk(siclk),
1454.bclk(soclk),
1455.l1clk(l1clk),
1456 .se(se),
1457 .pce_ov(pce_ov),
1458 .stop(stop),
1459 .siclk_out(siclk_out),
1460 .soclk_out(soclk_out)
1461);
1462dff #(2) d0_0 (
1463.l1clk(l1clk),
1464.siclk(siclk_out),
1465.soclk(soclk_out),
1466.d(din[1:0]),
1467.si({scan_in,so[0:0]}),
1468.so({so[0:0],scan_out}),
1469.q(dout[1:0])
1470);
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491endmodule
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505// any PARAMS parms go into naming of macro
1506
1507module l2t_snpd_dp_msff_macro__dmsff_16x__stack_32c__width_32 (
1508 din,
1509 clk,
1510 en,
1511 se,
1512 scan_in,
1513 siclk,
1514 soclk,
1515 pce_ov,
1516 stop,
1517 dout,
1518 scan_out);
1519wire l1clk;
1520wire siclk_out;
1521wire soclk_out;
1522wire [30:0] so;
1523
1524 input [31:0] din;
1525
1526
1527 input clk;
1528 input en;
1529 input se;
1530 input scan_in;
1531 input siclk;
1532 input soclk;
1533 input pce_ov;
1534 input stop;
1535
1536
1537
1538 output [31:0] dout;
1539
1540
1541 output scan_out;
1542
1543
1544
1545
1546cl_dp1_l1hdr_8x c0_0 (
1547.l2clk(clk),
1548.pce(en),
1549.aclk(siclk),
1550.bclk(soclk),
1551.l1clk(l1clk),
1552 .se(se),
1553 .pce_ov(pce_ov),
1554 .stop(stop),
1555 .siclk_out(siclk_out),
1556 .soclk_out(soclk_out)
1557);
1558dff #(32) d0_0 (
1559.l1clk(l1clk),
1560.siclk(siclk_out),
1561.soclk(soclk_out),
1562.d(din[31:0]),
1563.si({scan_in,so[30:0]}),
1564.so({so[30:0],scan_out}),
1565.q(dout[31:0])
1566);
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587endmodule
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597//
1598// invert macro
1599//
1600//
1601
1602
1603
1604
1605
1606module l2t_snpd_dp_inv_macro__width_2 (
1607 din,
1608 dout);
1609 input [1:0] din;
1610 output [1:0] dout;
1611
1612
1613
1614
1615
1616
1617inv #(2) d0_0 (
1618.in(din[1:0]),
1619.out(dout[1:0])
1620);
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630endmodule
1631
1632
1633
1634
1635
1636// general mux macro for pass-gate and and-or muxes with/wout priority encoders
1637// also for pass-gate with decoder
1638
1639
1640
1641
1642
1643// any PARAMS parms go into naming of macro
1644
1645module l2t_snpd_dp_mux_macro__dmux_8x__mux_aonpe__ports_2__stack_35c__width_35 (
1646 din0,
1647 sel0,
1648 din1,
1649 sel1,
1650 dout);
1651wire buffout0;
1652wire buffout1;
1653
1654 input [34:0] din0;
1655 input sel0;
1656 input [34:0] din1;
1657 input sel1;
1658 output [34:0] dout;
1659
1660
1661
1662
1663
1664cl_dp1_muxbuff2_8x c0_0 (
1665 .in0(sel0),
1666 .in1(sel1),
1667 .out0(buffout0),
1668 .out1(buffout1)
1669);
1670mux2s #(35) d0_0 (
1671 .sel0(buffout0),
1672 .sel1(buffout1),
1673 .in0(din0[34:0]),
1674 .in1(din1[34:0]),
1675.dout(dout[34:0])
1676);
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690endmodule
1691
1692
1693// general mux macro for pass-gate and and-or muxes with/wout priority encoders
1694// also for pass-gate with decoder
1695
1696
1697
1698
1699
1700// any PARAMS parms go into naming of macro
1701
1702module l2t_snpd_dp_mux_macro__dmux_8x__mux_aonpe__ports_2__stack_34c__width_34 (
1703 din0,
1704 sel0,
1705 din1,
1706 sel1,
1707 dout);
1708wire buffout0;
1709wire buffout1;
1710
1711 input [33:0] din0;
1712 input sel0;
1713 input [33:0] din1;
1714 input sel1;
1715 output [33:0] dout;
1716
1717
1718
1719
1720
1721cl_dp1_muxbuff2_8x c0_0 (
1722 .in0(sel0),
1723 .in1(sel1),
1724 .out0(buffout0),
1725 .out1(buffout1)
1726);
1727mux2s #(34) d0_0 (
1728 .sel0(buffout0),
1729 .sel1(buffout1),
1730 .in0(din0[33:0]),
1731 .in1(din1[33:0]),
1732.dout(dout[33:0])
1733);
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747endmodule
1748
1749
1750
1751
1752
1753
1754// any PARAMS parms go into naming of macro
1755
1756module l2t_snpd_dp_msff_macro__dmsff_32x__stack_32c__width_32 (
1757 din,
1758 clk,
1759 en,
1760 se,
1761 scan_in,
1762 siclk,
1763 soclk,
1764 pce_ov,
1765 stop,
1766 dout,
1767 scan_out);
1768wire l1clk;
1769wire siclk_out;
1770wire soclk_out;
1771wire [30:0] so;
1772
1773 input [31:0] din;
1774
1775
1776 input clk;
1777 input en;
1778 input se;
1779 input scan_in;
1780 input siclk;
1781 input soclk;
1782 input pce_ov;
1783 input stop;
1784
1785
1786
1787 output [31:0] dout;
1788
1789
1790 output scan_out;
1791
1792
1793
1794
1795cl_dp1_l1hdr_8x c0_0 (
1796.l2clk(clk),
1797.pce(en),
1798.aclk(siclk),
1799.bclk(soclk),
1800.l1clk(l1clk),
1801 .se(se),
1802 .pce_ov(pce_ov),
1803 .stop(stop),
1804 .siclk_out(siclk_out),
1805 .soclk_out(soclk_out)
1806);
1807dff #(32) d0_0 (
1808.l1clk(l1clk),
1809.siclk(siclk_out),
1810.soclk(soclk_out),
1811.d(din[31:0]),
1812.si({scan_in,so[30:0]}),
1813.so({so[30:0],scan_out}),
1814.q(dout[31:0])
1815);
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836endmodule
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846// general mux macro for pass-gate and and-or muxes with/wout priority encoders
1847// also for pass-gate with decoder
1848
1849
1850
1851
1852
1853// any PARAMS parms go into naming of macro
1854
1855module l2t_snpd_dp_mux_macro__dmux_8x__mux_aonpe__ports_2__stack_27c__width_26 (
1856 din0,
1857 sel0,
1858 din1,
1859 sel1,
1860 dout);
1861wire buffout0;
1862wire buffout1;
1863
1864 input [25:0] din0;
1865 input sel0;
1866 input [25:0] din1;
1867 input sel1;
1868 output [25:0] dout;
1869
1870
1871
1872
1873
1874cl_dp1_muxbuff2_8x c0_0 (
1875 .in0(sel0),
1876 .in1(sel1),
1877 .out0(buffout0),
1878 .out1(buffout1)
1879);
1880mux2s #(26) d0_0 (
1881 .sel0(buffout0),
1882 .sel1(buffout1),
1883 .in0(din0[25:0]),
1884 .in1(din1[25:0]),
1885.dout(dout[25:0])
1886);
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900endmodule
1901
1902
1903// general mux macro for pass-gate and and-or muxes with/wout priority encoders
1904// also for pass-gate with decoder
1905
1906
1907
1908
1909
1910// any PARAMS parms go into naming of macro
1911
1912module l2t_snpd_dp_mux_macro__dmux_8x__mux_aonpe__ports_2__stack_7c__width_7 (
1913 din0,
1914 sel0,
1915 din1,
1916 sel1,
1917 dout);
1918wire buffout0;
1919wire buffout1;
1920
1921 input [6:0] din0;
1922 input sel0;
1923 input [6:0] din1;
1924 input sel1;
1925 output [6:0] dout;
1926
1927
1928
1929
1930
1931cl_dp1_muxbuff2_8x c0_0 (
1932 .in0(sel0),
1933 .in1(sel1),
1934 .out0(buffout0),
1935 .out1(buffout1)
1936);
1937mux2s #(7) d0_0 (
1938 .sel0(buffout0),
1939 .sel1(buffout1),
1940 .in0(din0[6:0]),
1941 .in1(din1[6:0]),
1942.dout(dout[6:0])
1943);
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957endmodule
1958
1959
1960// general mux macro for pass-gate and and-or muxes with/wout priority encoders
1961// also for pass-gate with decoder
1962
1963
1964
1965
1966
1967// any PARAMS parms go into naming of macro
1968
1969module l2t_snpd_dp_mux_macro__dmux_32x__mux_pgpe__ports_2__stack_30c__width_30 (
1970 din0,
1971 din1,
1972 sel0,
1973 dout);
1974wire psel0_unused;
1975wire psel1;
1976
1977 input [29:0] din0;
1978 input [29:0] din1;
1979 input sel0;
1980 output [29:0] dout;
1981
1982
1983
1984
1985
1986cl_dp1_penc2_8x c0_0 (
1987 .sel0(sel0),
1988 .psel0(psel0_unused),
1989 .psel1(psel1)
1990);
1991
1992mux2e #(30) d0_0 (
1993 .sel(psel1),
1994 .in0(din0[29:0]),
1995 .in1(din1[29:0]),
1996.dout(dout[29:0])
1997);
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011endmodule
2012
2013
2014// general mux macro for pass-gate and and-or muxes with/wout priority encoders
2015// also for pass-gate with decoder
2016
2017
2018
2019
2020
2021// any PARAMS parms go into naming of macro
2022
2023module l2t_snpd_dp_mux_macro__dmux_32x__mux_pgpe__ports_2__stack_5c__width_5 (
2024 din0,
2025 din1,
2026 sel0,
2027 dout);
2028wire psel0_unused;
2029wire psel1;
2030
2031 input [4:0] din0;
2032 input [4:0] din1;
2033 input sel0;
2034 output [4:0] dout;
2035
2036
2037
2038
2039
2040cl_dp1_penc2_8x c0_0 (
2041 .sel0(sel0),
2042 .psel0(psel0_unused),
2043 .psel1(psel1)
2044);
2045
2046mux2e #(5) d0_0 (
2047 .sel(psel1),
2048 .in0(din0[4:0]),
2049 .in1(din1[4:0]),
2050.dout(dout[4:0])
2051);
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065endmodule
2066
2067
2068// general mux macro for pass-gate and and-or muxes with/wout priority encoders
2069// also for pass-gate with decoder
2070
2071
2072
2073
2074
2075// any PARAMS parms go into naming of macro
2076
2077module l2t_snpd_dp_mux_macro__dmux_32x__mux_pgpe__ports_2__stack_32c__width_32 (
2078 din0,
2079 din1,
2080 sel0,
2081 dout);
2082wire psel0_unused;
2083wire psel1;
2084
2085 input [31:0] din0;
2086 input [31:0] din1;
2087 input sel0;
2088 output [31:0] dout;
2089
2090
2091
2092
2093
2094cl_dp1_penc2_8x c0_0 (
2095 .sel0(sel0),
2096 .psel0(psel0_unused),
2097 .psel1(psel1)
2098);
2099
2100mux2e #(32) d0_0 (
2101 .sel(psel1),
2102 .in0(din0[31:0]),
2103 .in1(din1[31:0]),
2104.dout(dout[31:0])
2105);
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119endmodule
2120