Commit | Line | Data |
---|---|---|
86530b38 AT |
1 | // ========== Copyright Header Begin ========================================== |
2 | // | |
3 | // OpenSPARC T2 Processor File: n2_com_dp_64x80_cust.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 OUTFLOP_n2_com_dp_64x80_cust TRUE | |
36 | ||
37 | ||
38 | ||
39 | // define module name here | |
40 | // ********* DON'T TOUCH NEXT LINE ********* | |
41 | module n2_com_dp_64x80_cust ( | |
42 | wr_adr, | |
43 | wr_en, | |
44 | rd_adr, | |
45 | rd_en, | |
46 | din, | |
47 | dout, | |
48 | rdclk, | |
49 | wrclk, | |
50 | scan_in, | |
51 | tcu_pce_ov, | |
52 | tcu_aclk, | |
53 | tcu_bclk, | |
54 | tcu_array_wr_inhibit, | |
55 | tcu_se_scancollar_in, | |
56 | tcu_se_scancollar_out, | |
57 | bist_clk_mux_sel, | |
58 | rd_pce, | |
59 | wr_pce, | |
60 | scan_out); | |
61 | wire rd_lce; | |
62 | wire wr_lce; | |
63 | wire rdclk_in; | |
64 | wire wrclk_in; | |
65 | wire rdclk_free; | |
66 | wire wrclk_free; | |
67 | wire rdclk_out; | |
68 | wire dff_wr_addr_scanin; | |
69 | wire dff_wr_addr_scanout; | |
70 | wire [5:0] wr_adr_d1; | |
71 | wire [5:1] dff_rd_addr_scan; | |
72 | wire dff_rd_addr_scanin; | |
73 | wire dff_rd_addr_scanout; | |
74 | wire [5:0] rd_adr_d1; | |
75 | wire [5:0] rd_adr_mq_l_unused; | |
76 | wire [5:0] rd_adr_q_unused; | |
77 | wire [5:0] rd_adr_q_l_unused; | |
78 | wire dff_rd_en_scanin; | |
79 | wire dff_rd_en_scanout; | |
80 | wire rd_en_d1; | |
81 | wire rd_en_mq_l_unused; | |
82 | wire rd_en_q_unused; | |
83 | wire rd_en_q_l_unused; | |
84 | wire dff_wr_en_scanin; | |
85 | wire dff_wr_en_scanout; | |
86 | wire wr_en_d1; | |
87 | wire [39:1] dff_din_hi_scan; | |
88 | wire dff_din_hi_scanin; | |
89 | wire dff_din_hi_scanout; | |
90 | wire [79:0] din_d1; | |
91 | wire [39:1] dff_din_lo_scan; | |
92 | wire dff_din_lo_scanin; | |
93 | wire dff_din_lo_scanout; | |
94 | wire wr_inh_; | |
95 | wire rd_en_d1_qual; | |
96 | wire wr_en_d1_qual; | |
97 | wire [79:0] local_dout; | |
98 | wire dff_dout_scanin; | |
99 | wire dff_dout_scanout; | |
100 | ||
101 | input [5:0] wr_adr; | |
102 | input wr_en; | |
103 | input [5:0] rd_adr; | |
104 | input rd_en; | |
105 | input [79:0] din; | |
106 | output [79:0] dout; | |
107 | input rdclk; | |
108 | input wrclk; | |
109 | input scan_in; | |
110 | input tcu_pce_ov; | |
111 | input tcu_aclk; | |
112 | input tcu_bclk; | |
113 | input tcu_array_wr_inhibit; | |
114 | input tcu_se_scancollar_in; | |
115 | ||
116 | input tcu_se_scancollar_out; | |
117 | ||
118 | input bist_clk_mux_sel; | |
119 | input rd_pce; | |
120 | input wr_pce; | |
121 | output scan_out; | |
122 | ||
123 | // synopsys translate_off | |
124 | ||
125 | wire pce_ov = tcu_pce_ov; | |
126 | wire siclk = tcu_aclk; | |
127 | wire soclk = tcu_bclk; | |
128 | //================================================ | |
129 | // Clock headers | |
130 | //================================================ | |
131 | cl_mc1_bistlatch_4x rd_pce_lat ( | |
132 | .l2clk (rdclk), | |
133 | .pce (rd_pce), | |
134 | .pce_ov (pce_ov), | |
135 | .lce (rd_lce) | |
136 | ); | |
137 | cl_mc1_bistlatch_4x wr_pce_lat ( | |
138 | .l2clk (wrclk), | |
139 | .pce (wr_pce), | |
140 | .pce_ov (pce_ov), | |
141 | .lce (wr_lce) | |
142 | ); | |
143 | cl_mc1_bistl1hdr_8x rch_in ( | |
144 | .l2clk (rdclk), | |
145 | .se (tcu_se_scancollar_in), | |
146 | .clksel (bist_clk_mux_sel), | |
147 | .bistclk(rdclk), | |
148 | .lce (rd_lce), | |
149 | .l1clk (rdclk_in) | |
150 | ); | |
151 | cl_mc1_bistl1hdr_8x wch_in ( | |
152 | .l2clk (wrclk), | |
153 | .se (tcu_se_scancollar_in), | |
154 | .clksel (bist_clk_mux_sel), | |
155 | .bistclk(rdclk), | |
156 | .lce (wr_lce), | |
157 | .l1clk (wrclk_in) | |
158 | ); | |
159 | cl_mc1_bistl1hdr_8x rch_free ( | |
160 | .l2clk (rdclk), | |
161 | .se (1'b0), | |
162 | .clksel (bist_clk_mux_sel), | |
163 | .bistclk(rdclk), | |
164 | .lce (rd_lce), | |
165 | .l1clk (rdclk_free) | |
166 | ); | |
167 | cl_mc1_bistl1hdr_8x wch_free ( | |
168 | .l2clk (wrclk), | |
169 | .se (1'b0), | |
170 | .clksel (bist_clk_mux_sel), | |
171 | .bistclk(rdclk), | |
172 | .lce (wr_lce), | |
173 | .l1clk (wrclk_free) | |
174 | ); | |
175 | ||
176 | cl_mc1_bistl1hdr_8x rch_out ( | |
177 | .l2clk (rdclk), | |
178 | .se (tcu_se_scancollar_out), | |
179 | .clksel (bist_clk_mux_sel), | |
180 | .bistclk(rdclk), | |
181 | .lce (rd_lce), | |
182 | .l1clk (rdclk_out) | |
183 | ); | |
184 | ||
185 | /////////////////////////////////////////////////////////////// | |
186 | // Flop the inputs // | |
187 | /////////////////////////////////////////////////////////////// | |
188 | n2_com_dp_64x80_cust_msff_ctl_macro__width_6 dff_wr_addr ( | |
189 | .scan_in (dff_wr_addr_scanin), | |
190 | .scan_out (dff_wr_addr_scanout), | |
191 | .l1clk (wrclk_in), | |
192 | .din (wr_adr[5:0]), | |
193 | .dout (wr_adr_d1[5:0]), | |
194 | .siclk(siclk), | |
195 | .soclk(soclk) | |
196 | ); | |
197 | n2_com_dp_64x80_cust_sram_msff_mo_macro__fs_1__width_6 dff_rd_addr ( | |
198 | .scan_in ({dff_rd_addr_scan[5:1],dff_rd_addr_scanin}), | |
199 | .scan_out ({dff_rd_addr_scanout,dff_rd_addr_scan[5:1]}), | |
200 | .l1clk (rdclk_in), | |
201 | .and_clk (rdclk_in), | |
202 | .d (rd_adr[5:0]), | |
203 | .mq (rd_adr_d1[5:0]), | |
204 | .mq_l (rd_adr_mq_l_unused[5:0]), | |
205 | .q (rd_adr_q_unused[5:0]), | |
206 | .q_l (rd_adr_q_l_unused[5:0]), | |
207 | .siclk(siclk), | |
208 | .soclk(soclk) | |
209 | ); | |
210 | n2_com_dp_64x80_cust_sram_msff_mo_macro__width_1 dff_rd_en ( | |
211 | .scan_in (dff_rd_en_scanin), | |
212 | .scan_out (dff_rd_en_scanout), | |
213 | .l1clk (rdclk_in), | |
214 | .and_clk (rdclk_in), | |
215 | .d (rd_en), | |
216 | .mq (rd_en_d1), | |
217 | .mq_l (rd_en_mq_l_unused), | |
218 | .q (rd_en_q_unused), | |
219 | .q_l (rd_en_q_l_unused), | |
220 | .siclk(siclk), | |
221 | .soclk(soclk) | |
222 | ); | |
223 | n2_com_dp_64x80_cust_msff_ctl_macro__width_1 dff_wr_en ( | |
224 | .scan_in (dff_wr_en_scanin), | |
225 | .scan_out (dff_wr_en_scanout), | |
226 | .l1clk (wrclk_in), | |
227 | .din (wr_en), | |
228 | .dout (wr_en_d1), | |
229 | .siclk(siclk), | |
230 | .soclk(soclk) | |
231 | ); | |
232 | n2_com_dp_64x80_cust_msff_ctl_macro__fs_1__width_40 dff_din_hi ( | |
233 | .scan_in ({dff_din_hi_scan[39:1],dff_din_hi_scanin}), | |
234 | .scan_out ({dff_din_hi_scanout,dff_din_hi_scan[39:1]}), | |
235 | .l1clk (wrclk_in), | |
236 | .din (din[79:40]), | |
237 | .dout (din_d1[79:40]), | |
238 | .siclk(siclk), | |
239 | .soclk(soclk) | |
240 | ); | |
241 | n2_com_dp_64x80_cust_msff_ctl_macro__fs_1__width_40 dff_din_lo ( | |
242 | .scan_in ({dff_din_lo_scan[39:1],dff_din_lo_scanin}), | |
243 | .scan_out ({dff_din_lo_scanout,dff_din_lo_scan[39:1]}), | |
244 | .l1clk (wrclk_in), | |
245 | .din (din[39:0]), | |
246 | .dout (din_d1[39:0]), | |
247 | .siclk(siclk), | |
248 | .soclk(soclk) | |
249 | ); | |
250 | n2_com_dp_64x80_cust_inv_macro__width_1 wr_inh_inv ( | |
251 | .din (tcu_array_wr_inhibit), | |
252 | .dout (wr_inh_) | |
253 | ); | |
254 | n2_com_dp_64x80_cust_and_macro__width_2 enable_qual ( | |
255 | .din0 ({2{wr_inh_}}), | |
256 | .din1 ({rd_en_d1,wr_en_d1}), | |
257 | .dout ({rd_en_d1_qual,wr_en_d1_qual}) | |
258 | ); | |
259 | n2_com_dp_64x80_cust_n2_com_array_macro__rows_64__width_80__z_array array ( | |
260 | .rclk (rdclk_free), | |
261 | .wclk (wrclk_free), | |
262 | .wr_adr (wr_adr_d1[5:0]), | |
263 | .wr_en (wr_en_d1_qual), | |
264 | .rd_adr (rd_adr_d1[5:0]), | |
265 | .rd_en (rd_en_d1_qual), | |
266 | .din (din_d1[79:0]), | |
267 | .dout (local_dout[79:0]) | |
268 | ); | |
269 | ||
270 | n2_com_dp_64x80_cust_msff_ctl_macro__width_80 dff_dout ( | |
271 | .scan_in (dff_dout_scanin), | |
272 | .scan_out (dff_dout_scanout), | |
273 | .l1clk (rdclk_out), | |
274 | .din (local_dout[79:0]), | |
275 | .dout (dout[79:0]), | |
276 | .siclk(siclk), | |
277 | .soclk(soclk) | |
278 | ); | |
279 | ||
280 | ||
281 | supply0 vss; | |
282 | supply1 vdd; | |
283 | ||
284 | // fixscan start: | |
285 | assign dff_wr_addr_scanin = scan_in ; | |
286 | assign dff_rd_addr_scanin = dff_wr_addr_scanout ; | |
287 | assign dff_wr_en_scanin = dff_rd_addr_scanout ; | |
288 | assign dff_rd_en_scanin = dff_wr_en_scanout ; | |
289 | assign dff_din_lo_scanin = dff_rd_en_scanout ; | |
290 | assign dff_din_hi_scanin = dff_din_lo_scanout ; | |
291 | assign dff_dout_scanin = dff_din_hi_scanout ; | |
292 | assign scan_out = dff_dout_scanout ; | |
293 | // fixscan end: | |
294 | ||
295 | // synopsys translate_on | |
296 | ||
297 | endmodule | |
298 | ||
299 | ||
300 | ||
301 | ||
302 | ||
303 | ||
304 | ||
305 | // any PARAMS parms go into naming of macro | |
306 | ||
307 | module n2_com_dp_64x80_cust_msff_ctl_macro__width_6 ( | |
308 | din, | |
309 | l1clk, | |
310 | scan_in, | |
311 | siclk, | |
312 | soclk, | |
313 | dout, | |
314 | scan_out); | |
315 | wire [5:0] fdin; | |
316 | wire [4:0] so; | |
317 | ||
318 | input [5:0] din; | |
319 | input l1clk; | |
320 | input scan_in; | |
321 | ||
322 | ||
323 | input siclk; | |
324 | input soclk; | |
325 | ||
326 | output [5:0] dout; | |
327 | output scan_out; | |
328 | assign fdin[5:0] = din[5:0]; | |
329 | ||
330 | ||
331 | ||
332 | ||
333 | ||
334 | ||
335 | dff #(6) d0_0 ( | |
336 | .l1clk(l1clk), | |
337 | .siclk(siclk), | |
338 | .soclk(soclk), | |
339 | .d(fdin[5:0]), | |
340 | .si({scan_in,so[4:0]}), | |
341 | .so({so[4:0],scan_out}), | |
342 | .q(dout[5:0]) | |
343 | ); | |
344 | ||
345 | ||
346 | ||
347 | ||
348 | ||
349 | ||
350 | ||
351 | ||
352 | ||
353 | ||
354 | ||
355 | ||
356 | endmodule | |
357 | ||
358 | ||
359 | ||
360 | ||
361 | ||
362 | ||
363 | ||
364 | ||
365 | ||
366 | // | |
367 | // macro for cl_mc1_sram_msff_mo_{16,8,4}x flops | |
368 | // | |
369 | // | |
370 | ||
371 | ||
372 | ||
373 | ||
374 | ||
375 | module n2_com_dp_64x80_cust_sram_msff_mo_macro__fs_1__width_6 ( | |
376 | d, | |
377 | scan_in, | |
378 | l1clk, | |
379 | and_clk, | |
380 | siclk, | |
381 | soclk, | |
382 | mq, | |
383 | mq_l, | |
384 | scan_out, | |
385 | q, | |
386 | q_l); | |
387 | input [5:0] d; | |
388 | input [5:0] scan_in; | |
389 | input l1clk; | |
390 | input and_clk; | |
391 | input siclk; | |
392 | input soclk; | |
393 | output [5:0] mq; | |
394 | output [5:0] mq_l; | |
395 | output [5:0] scan_out; | |
396 | output [5:0] q; | |
397 | output [5:0] q_l; | |
398 | ||
399 | ||
400 | ||
401 | ||
402 | ||
403 | ||
404 | new_dlata #(6) d0_0 ( | |
405 | .d(d[5:0]), | |
406 | .si(scan_in[5:0]), | |
407 | .so(scan_out[5:0]), | |
408 | .l1clk(l1clk), | |
409 | .and_clk(and_clk), | |
410 | .siclk(siclk), | |
411 | .soclk(soclk), | |
412 | .q(q[5:0]), | |
413 | .q_l(q_l[5:0]), | |
414 | .mq(mq[5:0]), | |
415 | .mq_l(mq_l[5:0]) | |
416 | ); | |
417 | ||
418 | ||
419 | ||
420 | ||
421 | ||
422 | ||
423 | ||
424 | ||
425 | ||
426 | ||
427 | //place::generic_place($width,$stack,$left); | |
428 | ||
429 | endmodule | |
430 | ||
431 | ||
432 | ||
433 | ||
434 | ||
435 | // | |
436 | // macro for cl_mc1_sram_msff_mo_{16,8,4}x flops | |
437 | // | |
438 | // | |
439 | ||
440 | ||
441 | ||
442 | ||
443 | ||
444 | module n2_com_dp_64x80_cust_sram_msff_mo_macro__width_1 ( | |
445 | d, | |
446 | scan_in, | |
447 | l1clk, | |
448 | and_clk, | |
449 | siclk, | |
450 | soclk, | |
451 | mq, | |
452 | mq_l, | |
453 | scan_out, | |
454 | q, | |
455 | q_l); | |
456 | input [0:0] d; | |
457 | input scan_in; | |
458 | input l1clk; | |
459 | input and_clk; | |
460 | input siclk; | |
461 | input soclk; | |
462 | output [0:0] mq; | |
463 | output [0:0] mq_l; | |
464 | output scan_out; | |
465 | output [0:0] q; | |
466 | output [0:0] q_l; | |
467 | ||
468 | ||
469 | ||
470 | ||
471 | ||
472 | ||
473 | new_dlata #(1) d0_0 ( | |
474 | .d(d[0:0]), | |
475 | .si(scan_in), | |
476 | .so(scan_out), | |
477 | .l1clk(l1clk), | |
478 | .and_clk(and_clk), | |
479 | .siclk(siclk), | |
480 | .soclk(soclk), | |
481 | .q(q[0:0]), | |
482 | .q_l(q_l[0:0]), | |
483 | .mq(mq[0:0]), | |
484 | .mq_l(mq_l[0:0]) | |
485 | ); | |
486 | ||
487 | ||
488 | ||
489 | ||
490 | ||
491 | ||
492 | ||
493 | ||
494 | ||
495 | ||
496 | //place::generic_place($width,$stack,$left); | |
497 | ||
498 | endmodule | |
499 | ||
500 | ||
501 | ||
502 | ||
503 | ||
504 | ||
505 | ||
506 | ||
507 | ||
508 | // any PARAMS parms go into naming of macro | |
509 | ||
510 | module n2_com_dp_64x80_cust_msff_ctl_macro__width_1 ( | |
511 | din, | |
512 | l1clk, | |
513 | scan_in, | |
514 | siclk, | |
515 | soclk, | |
516 | dout, | |
517 | scan_out); | |
518 | wire [0:0] fdin; | |
519 | ||
520 | input [0:0] din; | |
521 | input l1clk; | |
522 | input scan_in; | |
523 | ||
524 | ||
525 | input siclk; | |
526 | input soclk; | |
527 | ||
528 | output [0:0] dout; | |
529 | output scan_out; | |
530 | assign fdin[0:0] = din[0:0]; | |
531 | ||
532 | ||
533 | ||
534 | ||
535 | ||
536 | ||
537 | dff #(1) d0_0 ( | |
538 | .l1clk(l1clk), | |
539 | .siclk(siclk), | |
540 | .soclk(soclk), | |
541 | .d(fdin[0:0]), | |
542 | .si(scan_in), | |
543 | .so(scan_out), | |
544 | .q(dout[0:0]) | |
545 | ); | |
546 | ||
547 | ||
548 | ||
549 | ||
550 | ||
551 | ||
552 | ||
553 | ||
554 | ||
555 | ||
556 | ||
557 | ||
558 | endmodule | |
559 | ||
560 | ||
561 | ||
562 | ||
563 | ||
564 | ||
565 | ||
566 | ||
567 | ||
568 | ||
569 | ||
570 | ||
571 | ||
572 | // any PARAMS parms go into naming of macro | |
573 | ||
574 | module n2_com_dp_64x80_cust_msff_ctl_macro__fs_1__width_40 ( | |
575 | din, | |
576 | l1clk, | |
577 | scan_in, | |
578 | siclk, | |
579 | soclk, | |
580 | dout, | |
581 | scan_out); | |
582 | wire [39:0] fdin; | |
583 | ||
584 | input [39:0] din; | |
585 | input l1clk; | |
586 | input [39:0] scan_in; | |
587 | ||
588 | ||
589 | input siclk; | |
590 | input soclk; | |
591 | ||
592 | output [39:0] dout; | |
593 | output [39:0] scan_out; | |
594 | assign fdin[39:0] = din[39:0]; | |
595 | ||
596 | ||
597 | ||
598 | ||
599 | ||
600 | ||
601 | dff #(40) d0_0 ( | |
602 | .l1clk(l1clk), | |
603 | .siclk(siclk), | |
604 | .soclk(soclk), | |
605 | .d(fdin[39:0]), | |
606 | .si(scan_in[39:0]), | |
607 | .so(scan_out[39:0]), | |
608 | .q(dout[39:0]) | |
609 | ); | |
610 | ||
611 | ||
612 | ||
613 | ||
614 | ||
615 | ||
616 | ||
617 | ||
618 | ||
619 | ||
620 | ||
621 | ||
622 | endmodule | |
623 | ||
624 | ||
625 | ||
626 | ||
627 | ||
628 | ||
629 | ||
630 | ||
631 | ||
632 | // | |
633 | // invert macro | |
634 | // | |
635 | // | |
636 | ||
637 | ||
638 | ||
639 | ||
640 | ||
641 | module n2_com_dp_64x80_cust_inv_macro__width_1 ( | |
642 | din, | |
643 | dout); | |
644 | input [0:0] din; | |
645 | output [0:0] dout; | |
646 | ||
647 | ||
648 | ||
649 | ||
650 | ||
651 | ||
652 | inv #(1) d0_0 ( | |
653 | .in(din[0:0]), | |
654 | .out(dout[0:0]) | |
655 | ); | |
656 | ||
657 | ||
658 | ||
659 | ||
660 | ||
661 | ||
662 | ||
663 | ||
664 | ||
665 | endmodule | |
666 | ||
667 | ||
668 | ||
669 | ||
670 | ||
671 | // | |
672 | // and macro for ports = 2,3,4 | |
673 | // | |
674 | // | |
675 | ||
676 | ||
677 | ||
678 | ||
679 | ||
680 | module n2_com_dp_64x80_cust_and_macro__width_2 ( | |
681 | din0, | |
682 | din1, | |
683 | dout); | |
684 | input [1:0] din0; | |
685 | input [1:0] din1; | |
686 | output [1:0] dout; | |
687 | ||
688 | ||
689 | ||
690 | ||
691 | ||
692 | ||
693 | and2 #(2) d0_0 ( | |
694 | .in0(din0[1:0]), | |
695 | .in1(din1[1:0]), | |
696 | .out(dout[1:0]) | |
697 | ); | |
698 | ||
699 | ||
700 | ||
701 | ||
702 | ||
703 | ||
704 | ||
705 | ||
706 | ||
707 | endmodule | |
708 | ||
709 | ||
710 | ||
711 | ||
712 | ||
713 | ||
714 | ||
715 | ||
716 | ||
717 | ||
718 | module n2_com_dp_64x80_cust_n2_com_array_macro__rows_64__width_80__z_array ( | |
719 | rclk, | |
720 | wclk, | |
721 | rd_adr, | |
722 | rd_en, | |
723 | wr_en, | |
724 | wr_adr, | |
725 | din, | |
726 | dout); | |
727 | ||
728 | input rclk; | |
729 | input wclk; | |
730 | input [5:0] rd_adr; | |
731 | input rd_en; | |
732 | input wr_en; | |
733 | input [5:0] wr_adr; | |
734 | input [80-1:0] din; | |
735 | output [80-1:0] dout; | |
736 | ||
737 | ||
738 | ||
739 | reg [80-1:0] mem[64-1:0]; | |
740 | reg [80-1:0] local_dout; | |
741 | ||
742 | `ifndef NOINITMEM | |
743 | // Emulate reset | |
744 | integer i; | |
745 | initial begin | |
746 | for (i=0; i<64; i=i+1) begin | |
747 | mem[i] = 80'b0; | |
748 | end | |
749 | local_dout = 80'b0; | |
750 | end | |
751 | `endif | |
752 | ////////////////////// | |
753 | // Read/write array | |
754 | ////////////////////// | |
755 | always @(negedge wclk) begin | |
756 | if (wr_en) begin | |
757 | mem[wr_adr] <= din; | |
758 | ||
759 | ||
760 | end | |
761 | end | |
762 | always @(rclk or rd_en or wr_en or rd_adr or wr_adr) begin | |
763 | if (rclk) begin | |
764 | if (rd_en) begin | |
765 | if (wr_en & (wr_adr[5:0] == rd_adr[5:0])) | |
766 | local_dout[80-1:0] <= 80'hx; | |
767 | else | |
768 | local_dout[80-1:0] <= mem[rd_adr] ; | |
769 | end | |
770 | else | |
771 | local_dout[80-1:0] <= ~(80'h0); | |
772 | end | |
773 | end | |
774 | assign dout[80-1:0] = local_dout[80-1:0]; | |
775 | supply0 vss; | |
776 | supply1 vdd; | |
777 | ||
778 | ||
779 | ||
780 | ||
781 | endmodule | |
782 | ||
783 | ||
784 | ||
785 | ||
786 | ||
787 | ||
788 | // any PARAMS parms go into naming of macro | |
789 | ||
790 | module n2_com_dp_64x80_cust_msff_ctl_macro__width_80 ( | |
791 | din, | |
792 | l1clk, | |
793 | scan_in, | |
794 | siclk, | |
795 | soclk, | |
796 | dout, | |
797 | scan_out); | |
798 | wire [79:0] fdin; | |
799 | wire [78:0] so; | |
800 | ||
801 | input [79:0] din; | |
802 | input l1clk; | |
803 | input scan_in; | |
804 | ||
805 | ||
806 | input siclk; | |
807 | input soclk; | |
808 | ||
809 | output [79:0] dout; | |
810 | output scan_out; | |
811 | assign fdin[79:0] = din[79:0]; | |
812 | ||
813 | ||
814 | ||
815 | ||
816 | ||
817 | ||
818 | dff #(80) d0_0 ( | |
819 | .l1clk(l1clk), | |
820 | .siclk(siclk), | |
821 | .soclk(soclk), | |
822 | .d(fdin[79:0]), | |
823 | .si({scan_in,so[78:0]}), | |
824 | .so({so[78:0],scan_out}), | |
825 | .q(dout[79:0]) | |
826 | ); | |
827 | ||
828 | ||
829 | ||
830 | ||
831 | ||
832 | ||
833 | ||
834 | ||
835 | ||
836 | ||
837 | ||
838 | ||
839 | endmodule | |
840 | ||
841 | ||
842 | ||
843 | ||
844 | ||
845 | ||
846 | ||
847 |