-
Notifications
You must be signed in to change notification settings - Fork 139
/
parameter.h
779 lines (671 loc) · 19.8 KB
/
parameter.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
/*****************************************************************************
* CACTI 7.0
* SOFTWARE LICENSE AGREEMENT
* Copyright 2015 Hewlett-Packard Development Company, L.P.
* All Rights Reserved
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met: redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer;
* redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution;
* neither the name of the copyright holders nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.”
*
***************************************************************************/
#ifndef __PARAMETER_H__
#define __PARAMETER_H__
#include "area.h"
#include "const.h"
#include "cacti_interface.h"
#include "io.h"
// parameters which are functions of certain device technology
/**
class TechnologyParameter
{
public:
class DeviceType
{
public:
double C_g_ideal;
double C_fringe;
double C_overlap;
double C_junc; // C_junc_area
double C_junc_sidewall;
double l_phy;
double l_elec;
double R_nch_on;
double R_pch_on;
double Vdd;
double Vth;
double Vcc_min;//allowed min vcc; for memory cell it is the lowest vcc for data retention. for logic it is the vcc to balance the leakage reduction and wakeup latency
double I_on_n;
double I_on_p;
double I_off_n;
double I_off_p;
double I_g_on_n;
double I_g_on_p;
double C_ox;
double t_ox;
double n_to_p_eff_curr_drv_ratio;
double long_channel_leakage_reduction;
double Mobility_n;
DeviceType(): C_g_ideal(0), C_fringe(0), C_overlap(0), C_junc(0),
C_junc_sidewall(0), l_phy(0), l_elec(0), R_nch_on(0), R_pch_on(0),
Vdd(0), Vth(0), Vcc_min(0),
I_on_n(0), I_on_p(0), I_off_n(0), I_off_p(0),I_g_on_n(0),I_g_on_p(0),
C_ox(0), t_ox(0), n_to_p_eff_curr_drv_ratio(0), long_channel_leakage_reduction(0),
Mobility_n(0) { };
void reset()
{
C_g_ideal = 0;
C_fringe = 0;
C_overlap = 0;
C_junc = 0;
l_phy = 0;
l_elec = 0;
R_nch_on = 0;
R_pch_on = 0;
Vdd = 0;
Vth = 0;
Vcc_min = 0;
I_on_n = 0;
I_on_p = 0;
I_off_n = 0;
I_off_p = 0;
I_g_on_n = 0;
I_g_on_p = 0;
C_ox = 0;
t_ox = 0;
n_to_p_eff_curr_drv_ratio = 0;
long_channel_leakage_reduction = 0;
Mobility_n = 0;
}
void display(uint32_t indent = 0);
};
class InterconnectType
{
public:
double pitch;
double R_per_um;
double C_per_um;
double horiz_dielectric_constant;
double vert_dielectric_constant;
double aspect_ratio;
double miller_value;
double ild_thickness;
InterconnectType(): pitch(0), R_per_um(0), C_per_um(0) { };
void reset()
{
pitch = 0;
R_per_um = 0;
C_per_um = 0;
horiz_dielectric_constant = 0;
vert_dielectric_constant = 0;
aspect_ratio = 0;
miller_value = 0;
ild_thickness = 0;
}
void display(uint32_t indent = 0);
};
class MemoryType
{
public:
double b_w;
double b_h;
double cell_a_w;
double cell_pmos_w;
double cell_nmos_w;
double Vbitpre;
double Vbitfloating;//voltage when floating bitline is supported
void reset()
{
b_w = 0; //fs and tech
b_h = 0; //fs and tech
cell_a_w = 0; // ram_cell_tech_type
cell_pmos_w = 0; //fs
cell_nmos_w = 0;
Vbitpre = 0;
Vbitfloating = 0;
}
void display(uint32_t indent = 0);
};
class ScalingFactor
{
public:
double logic_scaling_co_eff;
double core_tx_density;
double long_channel_leakage_reduction;
ScalingFactor(): logic_scaling_co_eff(0), core_tx_density(0),
long_channel_leakage_reduction(0) { };
void reset()
{
logic_scaling_co_eff= 0;
core_tx_density = 0;
long_channel_leakage_reduction= 0;
}
void display(uint32_t indent = 0);
};
double ram_wl_stitching_overhead_; //fs
double min_w_nmos_; //fs
double max_w_nmos_; //fs
double max_w_nmos_dec; //fs+ ram_cell_tech_type
double unit_len_wire_del; //wire_inside_mat
double FO4; //fs
double kinv; //fs
double vpp; //input
double w_sense_en;//fs
double w_sense_n; //fs
double w_sense_p; //fs
double sense_delay; // input
double sense_dy_power; //input
double w_iso; //fs
double w_poly_contact; //fs
double spacing_poly_to_poly; //fs
double spacing_poly_to_contact;//fs
//CACTI3DD TSV params
double tsv_parasitic_capacitance_fine;
double tsv_parasitic_resistance_fine;
double tsv_minimum_area_fine;
double tsv_parasitic_capacitance_coarse;
double tsv_parasitic_resistance_coarse;
double tsv_minimum_area_coarse;
//fs
double w_comp_inv_p1;
double w_comp_inv_p2;
double w_comp_inv_p3;
double w_comp_inv_n1;
double w_comp_inv_n2;
double w_comp_inv_n3;
double w_eval_inv_p;
double w_eval_inv_n;
double w_comp_n;
double w_comp_p;
double dram_cell_I_on; //ram_cell_tech_type
double dram_cell_Vdd;
double dram_cell_I_off_worst_case_len_temp;
double dram_cell_C;
double gm_sense_amp_latch; // depends on many things
double w_nmos_b_mux;//fs
double w_nmos_sa_mux;//fs
double w_pmos_bl_precharge;//fs
double w_pmos_bl_eq;//fs
double MIN_GAP_BET_P_AND_N_DIFFS;//fs
double MIN_GAP_BET_SAME_TYPE_DIFFS;//fs
double HPOWERRAIL;//fs
double cell_h_def;//fs
double chip_layout_overhead; //input
double macro_layout_overhead;
double sckt_co_eff;
double fringe_cap;//input
uint64_t h_dec; //ram_cell_tech_type
DeviceType sram_cell; // SRAM cell transistor
DeviceType dram_acc; // DRAM access transistor
DeviceType dram_wl; // DRAM wordline transistor
DeviceType peri_global; // peripheral global
DeviceType cam_cell; // SRAM cell transistor
DeviceType sleep_tx; // Sleep transistor cell transistor
InterconnectType wire_local;
InterconnectType wire_inside_mat;
InterconnectType wire_outside_mat;
ScalingFactor scaling_factor;
MemoryType sram;
MemoryType dram;
MemoryType cam;
void display(uint32_t indent = 0);
void reset()
{
dram_cell_Vdd = 0;
dram_cell_I_on = 0;
dram_cell_C = 0;
vpp = 0;
sense_delay = 0;
sense_dy_power = 0;
fringe_cap = 0;
// horiz_dielectric_constant = 0;
// vert_dielectric_constant = 0;
// aspect_ratio = 0;
// miller_value = 0;
// ild_thickness = 0;
dram_cell_I_off_worst_case_len_temp = 0;
sram_cell.reset();
dram_acc.reset();
dram_wl.reset();
peri_global.reset();
cam_cell.reset();
sleep_tx.reset();
scaling_factor.reset();
wire_local.reset();
wire_inside_mat.reset();
wire_outside_mat.reset();
sram.reset();
dram.reset();
cam.reset();
chip_layout_overhead = 0;
macro_layout_overhead = 0;
sckt_co_eff = 0;
}
};
**/
//ali
class DeviceType
{
public:
double C_g_ideal;
double C_fringe;
double C_overlap;
double C_junc; // C_junc_area
double C_junc_sidewall;
double l_phy;
double l_elec;
double R_nch_on;
double R_pch_on;
double Vdd;
double Vth;
double Vcc_min;//allowed min vcc; for memory cell it is the lowest vcc for data retention. for logic it is the vcc to balance the leakage reduction and wakeup latency
double I_on_n;
double I_on_p;
double I_off_n;
double I_off_p;
double I_g_on_n;
double I_g_on_p;
double C_ox;
double t_ox;
double n_to_p_eff_curr_drv_ratio;
double long_channel_leakage_reduction;
double Mobility_n;
// auxilary parameters
double Vdsat;
double gmp_to_gmn_multiplier;
DeviceType(): C_g_ideal(0), C_fringe(0), C_overlap(0), C_junc(0),
C_junc_sidewall(0), l_phy(0), l_elec(0), R_nch_on(0), R_pch_on(0),
Vdd(0), Vth(0), Vcc_min(0),
I_on_n(0), I_on_p(0), I_off_n(0), I_off_p(0),I_g_on_n(0),I_g_on_p(0),
C_ox(0), t_ox(0), n_to_p_eff_curr_drv_ratio(0), long_channel_leakage_reduction(0),
Mobility_n(0) { reset();};
void assign(const string & in_file, int tech_flavor, unsigned int temp);
void interpolate(double alpha, const DeviceType& dev1, const DeviceType& dev2);
void reset()
{
C_g_ideal=0;
C_fringe=0;
C_overlap=0;
C_junc=0; // C_junc_area
C_junc_sidewall=0;
l_phy=0;
l_elec=0;
R_nch_on=0;
R_pch_on=0;
Vdd=0;
Vth=0;
Vcc_min=0;//allowed min vcc, for memory cell it is the lowest vcc for data retention. for logic it is the vcc to balance the leakage reduction and wakeup latency
I_on_n=0;
I_on_p=0;
I_off_n=0;
I_off_p=0;
I_g_on_n=0;
I_g_on_p=0;
C_ox=0;
t_ox=0;
n_to_p_eff_curr_drv_ratio=0;
long_channel_leakage_reduction=0;
Mobility_n=0;
// auxilary parameters
Vdsat=0;
gmp_to_gmn_multiplier=0;
}
void display(uint32_t indent = 0) const;
bool isEqual(const DeviceType & dev);
};
class InterconnectType
{
public:
double pitch;
double R_per_um;
double C_per_um;
double horiz_dielectric_constant;
double vert_dielectric_constant;
double aspect_ratio;
double miller_value;
double ild_thickness;
//auxilary parameters
double wire_width;
double wire_thickness;
double wire_spacing;
double barrier_thickness;
double dishing_thickness;
double alpha_scatter;
double fringe_cap;
InterconnectType(): pitch(0), R_per_um(0), C_per_um(0) { reset(); };
void reset()
{
pitch=0;
R_per_um=0;
C_per_um=0;
horiz_dielectric_constant=0;
vert_dielectric_constant=0;
aspect_ratio=0;
miller_value=0;
ild_thickness=0;
//auxilary parameters
wire_width=0;
wire_thickness=0;
wire_spacing=0;
barrier_thickness=0;
dishing_thickness=0;
alpha_scatter=0;
fringe_cap=0;
}
void assign(const string & in_file, int projection_type, int tech_flavor);
void interpolate(double alpha, const InterconnectType & inter1, const InterconnectType & inter2);
void display(uint32_t indent = 0);
bool isEqual(const InterconnectType & inter);
};
class MemoryType
{
public:
double b_w;
double b_h;
double cell_a_w;
double cell_pmos_w;
double cell_nmos_w;
double Vbitpre;
double Vbitfloating;//voltage when floating bitline is supported
// needed to calculate b_w b_h
double area_cell;
double asp_ratio_cell;
MemoryType(){reset();}
void reset()
{
b_w=0;
b_h=0;
cell_a_w=0;
cell_pmos_w=0;
cell_nmos_w=0;
Vbitpre=0;
Vbitfloating=0;
}
void assign(const string & in_file, int tech_flavor, int cell_type); // sram(0),cam(1),dram(2)
void interpolate(double alpha, const MemoryType& dev1, const MemoryType& dev2);
void display(uint32_t indent = 0) const;
bool isEqual(const MemoryType & mem);
};
class ScalingFactor
{
public:
double logic_scaling_co_eff;
double core_tx_density;
double long_channel_leakage_reduction;
ScalingFactor(): logic_scaling_co_eff(0), core_tx_density(0),
long_channel_leakage_reduction(0) { reset(); };
void reset()
{
logic_scaling_co_eff=0;
core_tx_density=0;
long_channel_leakage_reduction=0;
}
void assign(const string & in_file);
void interpolate(double alpha, const ScalingFactor& dev1, const ScalingFactor& dev2);
void display(uint32_t indent = 0);
bool isEqual(const ScalingFactor & scal);
};
// parameters which are functions of certain device technology
class TechnologyParameter
{
public:
double ram_wl_stitching_overhead_; //fs
double min_w_nmos_; //fs
double max_w_nmos_; //fs
double max_w_nmos_dec; //fs+ ram_cell_tech_type
double unit_len_wire_del; //wire_inside_mat
double FO4; //fs
double kinv; //fs
double vpp; //input
double w_sense_en;//fs
double w_sense_n; //fs
double w_sense_p; //fs
double sense_delay; // input
double sense_dy_power; //input
double w_iso; //fs
double w_poly_contact; //fs
double spacing_poly_to_poly; //fs
double spacing_poly_to_contact;//fs
//CACTI3D auxilary variables
double tsv_pitch;
double tsv_diameter;
double tsv_length;
double tsv_dielec_thickness;
double tsv_contact_resistance;
double tsv_depletion_width;
double tsv_liner_dielectric_constant;
//CACTI3DD TSV params
double tsv_parasitic_capacitance_fine;
double tsv_parasitic_resistance_fine;
double tsv_minimum_area_fine;
double tsv_parasitic_capacitance_coarse;
double tsv_parasitic_resistance_coarse;
double tsv_minimum_area_coarse;
//fs
double w_comp_inv_p1;
double w_comp_inv_p2;
double w_comp_inv_p3;
double w_comp_inv_n1;
double w_comp_inv_n2;
double w_comp_inv_n3;
double w_eval_inv_p;
double w_eval_inv_n;
double w_comp_n;
double w_comp_p;
double dram_cell_I_on; //ram_cell_tech_type
double dram_cell_Vdd;
double dram_cell_I_off_worst_case_len_temp;
double dram_cell_C;
double gm_sense_amp_latch; // depends on many things
double w_nmos_b_mux;//fs
double w_nmos_sa_mux;//fs
double w_pmos_bl_precharge;//fs
double w_pmos_bl_eq;//fs
double MIN_GAP_BET_P_AND_N_DIFFS;//fs
double MIN_GAP_BET_SAME_TYPE_DIFFS;//fs
double HPOWERRAIL;//fs
double cell_h_def;//fs
double chip_layout_overhead; //input
double macro_layout_overhead;
double sckt_co_eff;
double fringe_cap;//input
uint64_t h_dec; //ram_cell_tech_type
DeviceType sram_cell; // SRAM cell transistor
DeviceType dram_acc; // DRAM access transistor
DeviceType dram_wl; // DRAM wordline transistor
DeviceType peri_global; // peripheral global
DeviceType cam_cell; // SRAM cell transistor
DeviceType sleep_tx; // Sleep transistor cell transistor
InterconnectType wire_local;
InterconnectType wire_inside_mat;
InterconnectType wire_outside_mat;
ScalingFactor scaling_factor;
MemoryType sram;
MemoryType dram;
MemoryType cam;
void display(uint32_t indent = 0);
bool isEqual(const TechnologyParameter & tech);
void find_upper_and_lower_tech(double technology, int &tech_lo, string& in_file_lo, int &tech_hi, string& in_file_hi);
void assign_tsv(const string & in_file);
void init(double technology, bool is_tag);
TechnologyParameter()
{
reset();
}
void reset()
{
ram_wl_stitching_overhead_ =0; //fs
min_w_nmos_ =0; //fs
max_w_nmos_ =0; //fs
max_w_nmos_dec =0; //fs+ ram_cell_tech_type
unit_len_wire_del =0; //wire_inside_mat
FO4 =0; //fs
kinv =0; //fs
vpp =0; //input
w_sense_en =0;//fs
w_sense_n =0; //fs
w_sense_p =0; //fs
sense_delay =0; // input
sense_dy_power =0; //input
w_iso =0; //fs
w_poly_contact =0; //fs
spacing_poly_to_poly =0; //fs
spacing_poly_to_contact =0;//fs
//CACTI3D auxilary variables
tsv_pitch =0;
tsv_diameter =0;
tsv_length =0;
tsv_dielec_thickness =0;
tsv_contact_resistance =0;
tsv_depletion_width =0;
tsv_liner_dielectric_constant =0;
//CACTI3DD TSV params
tsv_parasitic_capacitance_fine =0;
tsv_parasitic_resistance_fine =0;
tsv_minimum_area_fine =0;
tsv_parasitic_capacitance_coarse =0;
tsv_parasitic_resistance_coarse =0;
tsv_minimum_area_coarse =0;
//fs
w_comp_inv_p1 =0;
w_comp_inv_p2 =0;
w_comp_inv_p3 =0;
w_comp_inv_n1 =0;
w_comp_inv_n2 =0;
w_comp_inv_n3 =0;
w_eval_inv_p =0;
w_eval_inv_n =0;
w_comp_n =0;
w_comp_p =0;
dram_cell_I_on =0; //ram_cell_tech_type
dram_cell_Vdd =0;
dram_cell_I_off_worst_case_len_temp =0;
dram_cell_C =0;
gm_sense_amp_latch =0; // depends on many things
w_nmos_b_mux =0;//fs
w_nmos_sa_mux =0;//fs
w_pmos_bl_precharge =0;//fs
w_pmos_bl_eq =0;//fs
MIN_GAP_BET_P_AND_N_DIFFS =0;//fs
MIN_GAP_BET_SAME_TYPE_DIFFS =0;//fs
HPOWERRAIL =0;//fs
cell_h_def =0;//fs
chip_layout_overhead = 0;
macro_layout_overhead = 0;
sckt_co_eff = 0;
fringe_cap=0;//input
h_dec=0; //ram_cell_tech_type
sram_cell.reset();
dram_acc.reset();
dram_wl.reset();
peri_global.reset();
cam_cell.reset();
sleep_tx.reset();
scaling_factor.reset();
wire_local.reset();
wire_inside_mat.reset();
wire_outside_mat.reset();
sram.reset();
dram.reset();
cam.reset();
}
};
//end ali
class DynamicParameter
{
public:
bool is_tag;
bool pure_ram;
bool pure_cam;
bool fully_assoc;
int tagbits;
int num_subarrays; // only for leakage computation -- the number of subarrays per bank
int num_mats; // only for leakage computation -- the number of mats per bank
double Nspd;
int Ndwl;
int Ndbl;
int Ndcm;
int deg_bl_muxing;
int deg_senseamp_muxing_non_associativity;
int Ndsam_lev_1;
int Ndsam_lev_2;
Wire_type wtype; // merge from cacti-7 code to cacti3d code.
int number_addr_bits_mat; // per port
int number_subbanks_decode; // per_port
int num_di_b_bank_per_port;
int num_do_b_bank_per_port;
int num_di_b_mat;
int num_do_b_mat;
int num_di_b_subbank;
int num_do_b_subbank;
int num_si_b_mat;
int num_so_b_mat;
int num_si_b_subbank;
int num_so_b_subbank;
int num_si_b_bank_per_port;
int num_so_b_bank_per_port;
int number_way_select_signals_mat;
int num_act_mats_hor_dir;
int num_act_mats_hor_dir_sl;
bool is_dram;
double V_b_sense;
unsigned int num_r_subarray;
unsigned int num_c_subarray;
int tag_num_r_subarray;//: fully associative cache tag and data must be computed together, data and tag must be separate
int tag_num_c_subarray;
int data_num_r_subarray;
int data_num_c_subarray;
int num_mats_h_dir;
int num_mats_v_dir;
uint32_t ram_cell_tech_type;
double dram_refresh_period;
DynamicParameter();
DynamicParameter(
bool is_tag_,
int pure_ram_,
int pure_cam_,
double Nspd_,
unsigned int Ndwl_,
unsigned int Ndbl_,
unsigned int Ndcm_,
unsigned int Ndsam_lev_1_,
unsigned int Ndsam_lev_2_,
Wire_type wt, // merged from cacti-7 to cacti3d
bool is_main_mem_);
int use_inp_params;
unsigned int num_rw_ports;
unsigned int num_rd_ports;
unsigned int num_wr_ports;
unsigned int num_se_rd_ports; // number of single ended read ports
unsigned int num_search_ports;
unsigned int out_w;// == nr_bits_out
bool is_main_mem;
Area cell, cam_cell;//cell is the sram_cell in both nomal cache/ram and FA.
bool is_valid;
private:
void ECC_adjustment();
void init_CAM();
void init_FA();
bool calc_subarr_rc(unsigned int cap); //to calculate and check subarray rows and columns
};
extern InputParameter * g_ip;
extern TechnologyParameter g_tp;
#endif