mirror of
https://github.com/VLSIDA/OpenRAM.git
synced 2026-09-04 00:40:09 +02:00
Removing unused tech parms. Simplifying redundant parms.
This commit is contained in:
@@ -259,7 +259,7 @@ class delay(simulation):
|
||||
"""Sets important names for characterization such as Sense amp enable and internal bit nets."""
|
||||
|
||||
port = self.read_ports[0]
|
||||
self.graph.get_all_paths('{}{}'.format(tech.spice["clk"], port),
|
||||
self.graph.get_all_paths('{}{}'.format("clk", port),
|
||||
'{}{}_{}'.format(self.dout_name, port, self.probe_data))
|
||||
|
||||
self.sen_name = self.get_sen_name(self.graph.all_paths)
|
||||
@@ -1291,7 +1291,7 @@ class delay(simulation):
|
||||
self.create_measurement_names()
|
||||
|
||||
port = self.read_ports[0]
|
||||
self.graph.get_all_paths('{}{}'.format(tech.spice["clk"], port),
|
||||
self.graph.get_all_paths('{}{}'.format("clk", port),
|
||||
'{}{}_{}'.format(self.dout_name, port, self.probe_data))
|
||||
|
||||
# Select the path with the bitline (bl)
|
||||
|
||||
@@ -336,10 +336,10 @@ class setup_hold():
|
||||
for self.related_input_slew in related_slews:
|
||||
for self.constrained_input_slew in constrained_slews:
|
||||
# convert from ps to ns
|
||||
LH_setup.append(tech.spice["msflop_setup"]/1e3)
|
||||
HL_setup.append(tech.spice["msflop_setup"]/1e3)
|
||||
LH_hold.append(tech.spice["msflop_hold"]/1e3)
|
||||
HL_hold.append(tech.spice["msflop_hold"]/1e3)
|
||||
LH_setup.append(tech.spice["dff_setup"]/1e3)
|
||||
HL_setup.append(tech.spice["dff_setup"]/1e3)
|
||||
LH_hold.append(tech.spice["dff_hold"]/1e3)
|
||||
HL_hold.append(tech.spice["dff_hold"]/1e3)
|
||||
|
||||
times = {"setup_times_LH": LH_setup,
|
||||
"setup_times_HL": HL_setup,
|
||||
|
||||
@@ -46,7 +46,7 @@ class simulation():
|
||||
""" sets feasible timing parameters """
|
||||
self.period = tech.spice["feasible_period"]
|
||||
self.slew = tech.spice["rise_time"]*2
|
||||
self.load = tech.spice["msflop_in_cap"]*4
|
||||
self.load = tech.spice["dff_in_cap"]*4
|
||||
|
||||
self.v_high = self.vdd_voltage - tech.spice["v_threshold_typical"]
|
||||
self.v_low = tech.spice["v_threshold_typical"]
|
||||
@@ -301,7 +301,7 @@ class simulation():
|
||||
pin_names.append("WEB{0}".format(port))
|
||||
|
||||
for port in range(total_ports):
|
||||
pin_names.append("{0}{1}".format(tech.spice["clk"], port))
|
||||
pin_names.append("{0}{1}".format("clk", port))
|
||||
|
||||
if self.write_size:
|
||||
for port in write_index:
|
||||
@@ -312,7 +312,7 @@ class simulation():
|
||||
for i in range(dbits):
|
||||
pin_names.append("{0}{1}_{2}".format(dout_name,read_output, i))
|
||||
|
||||
pin_names.append("{0}".format(tech.spice["vdd_name"]))
|
||||
pin_names.append("{0}".format(tech.spice["gnd_name"]))
|
||||
pin_names.append("{0}".format("vdd"))
|
||||
pin_names.append("{0}".format("gnd"))
|
||||
return pin_names
|
||||
|
||||
|
||||
@@ -24,12 +24,12 @@ class stimuli():
|
||||
""" Class for providing stimuli functions """
|
||||
|
||||
def __init__(self, stim_file, corner):
|
||||
self.vdd_name = tech.spice["vdd_name"]
|
||||
self.gnd_name = tech.spice["gnd_name"]
|
||||
self.vdd_name = "vdd"
|
||||
self.gnd_name = "gnd"
|
||||
self.pmos_name = tech.spice["pmos"]
|
||||
self.nmos_name = tech.spice["nmos"]
|
||||
self.tx_width = tech.spice["minwidth_tx"]
|
||||
self.tx_length = tech.spice["channel"]
|
||||
self.tx_width = tech.drc["minwidth_tx"]
|
||||
self.tx_length = tech.drc["minlength_channel"]
|
||||
|
||||
self.sf = stim_file
|
||||
|
||||
|
||||
@@ -157,7 +157,7 @@ class bitcell_array(design.design):
|
||||
bl_wire = self.gen_bl_wire()
|
||||
cell_load = 2 * bl_wire.return_input_cap()
|
||||
bl_swing = OPTS.rbl_delay_percentage
|
||||
freq = spice["default_event_rate"]
|
||||
freq = spice["default_event_frequency"]
|
||||
bitline_dynamic = self.calc_dynamic_power(corner, cell_load, freq, swing=bl_swing)
|
||||
|
||||
#Calculate the bitcell power which currently only includes leakage
|
||||
|
||||
@@ -33,9 +33,9 @@ class dff(design.design):
|
||||
def analytical_power(self, corner, load):
|
||||
"""Returns dynamic and leakage power. Results in nW"""
|
||||
c_eff = self.calculate_effective_capacitance(load)
|
||||
freq = spice["default_event_rate"]
|
||||
freq = spice["default_event_frequency"]
|
||||
power_dyn = self.calc_dynamic_power(corner, c_eff, freq)
|
||||
power_leak = spice["msflop_leakage"]
|
||||
power_leak = spice["dff_leakage"]
|
||||
|
||||
total_power = self.return_power(power_dyn, power_leak)
|
||||
return total_power
|
||||
@@ -44,8 +44,8 @@ class dff(design.design):
|
||||
"""Computes effective capacitance. Results in fF"""
|
||||
from tech import parameter
|
||||
c_load = load
|
||||
c_para = spice["flop_para_cap"]#ff
|
||||
transition_prob = spice["flop_transition_prob"]
|
||||
c_para = spice["dff_out_cap"]#ff
|
||||
transition_prob = 0.5
|
||||
return transition_prob*(c_load + c_para)
|
||||
|
||||
def get_clk_cin(self):
|
||||
@@ -57,4 +57,4 @@ class dff(design.design):
|
||||
def build_graph(self, graph, inst_name, port_nets):
|
||||
"""Adds edges based on inputs/outputs. Overrides base class function."""
|
||||
self.add_graph_edges(graph, port_nets)
|
||||
|
||||
|
||||
|
||||
@@ -382,7 +382,7 @@ class replica_bitcell_array(design.design):
|
||||
bl_wire = self.gen_bl_wire()
|
||||
cell_load = 2 * bl_wire.return_input_cap()
|
||||
bl_swing = OPTS.rbl_delay_percentage
|
||||
freq = spice["default_event_rate"]
|
||||
freq = spice["default_event_frequency"]
|
||||
bitline_dynamic = self.calc_dynamic_power(corner, cell_load, freq, swing=bl_swing)
|
||||
|
||||
#Calculate the bitcell power which currently only includes leakage
|
||||
|
||||
@@ -258,7 +258,7 @@ class pinv(pgate.pgate):
|
||||
def analytical_power(self, corner, load):
|
||||
"""Returns dynamic and leakage power. Results in nW"""
|
||||
c_eff = self.calculate_effective_capacitance(load)
|
||||
freq = spice["default_event_rate"]
|
||||
freq = spice["default_event_frequency"]
|
||||
power_dyn = self.calc_dynamic_power(corner, c_eff, freq)
|
||||
power_leak = spice["inv_leakage"]
|
||||
|
||||
@@ -269,7 +269,7 @@ class pinv(pgate.pgate):
|
||||
"""Computes effective capacitance. Results in fF"""
|
||||
c_load = load
|
||||
c_para = spice["min_tx_drain_c"]*(self.nmos_size/parameter["min_tx_size"])#ff
|
||||
transition_prob = spice["inv_transition_prob"]
|
||||
transition_prob = 0.5
|
||||
return transition_prob*(c_load + c_para)
|
||||
|
||||
def input_load(self):
|
||||
|
||||
@@ -233,7 +233,7 @@ class pnand2(pgate.pgate):
|
||||
def analytical_power(self, corner, load):
|
||||
"""Returns dynamic and leakage power. Results in nW"""
|
||||
c_eff = self.calculate_effective_capacitance(load)
|
||||
freq = spice["default_event_rate"]
|
||||
freq = spice["default_event_frequency"]
|
||||
power_dyn = self.calc_dynamic_power(corner, c_eff, freq)
|
||||
power_leak = spice["nand2_leakage"]
|
||||
|
||||
@@ -244,7 +244,7 @@ class pnand2(pgate.pgate):
|
||||
"""Computes effective capacitance. Results in fF"""
|
||||
c_load = load
|
||||
c_para = spice["min_tx_drain_c"]*(self.nmos_size/parameter["min_tx_size"])#ff
|
||||
transition_prob = spice["nand2_transition_prob"]
|
||||
transition_prob = 0.1875
|
||||
return transition_prob*(c_load + c_para)
|
||||
|
||||
def input_load(self):
|
||||
|
||||
@@ -246,7 +246,7 @@ class pnand3(pgate.pgate):
|
||||
def analytical_power(self, corner, load):
|
||||
"""Returns dynamic and leakage power. Results in nW"""
|
||||
c_eff = self.calculate_effective_capacitance(load)
|
||||
freq = spice["default_event_rate"]
|
||||
freq = spice["default_event_frequency"]
|
||||
power_dyn = self.calc_dynamic_power(corner, c_eff, freq)
|
||||
power_leak = spice["nand3_leakage"]
|
||||
|
||||
@@ -257,7 +257,7 @@ class pnand3(pgate.pgate):
|
||||
"""Computes effective capacitance. Results in fF"""
|
||||
c_load = load
|
||||
c_para = spice["min_tx_drain_c"]*(self.nmos_size/parameter["min_tx_size"])#ff
|
||||
transition_prob = spice["nand3_transition_prob"]
|
||||
transition_prob = 0.1094
|
||||
return transition_prob*(c_load + c_para)
|
||||
|
||||
def input_load(self):
|
||||
|
||||
@@ -230,7 +230,7 @@ class pnor2(pgate.pgate):
|
||||
def analytical_power(self, corner, load):
|
||||
"""Returns dynamic and leakage power. Results in nW"""
|
||||
c_eff = self.calculate_effective_capacitance(load)
|
||||
freq = spice["default_event_rate"]
|
||||
freq = spice["default_event_frequency"]
|
||||
power_dyn = self.calc_dynamic_power(corner, c_eff, freq)
|
||||
power_leak = spice["nor2_leakage"]
|
||||
|
||||
@@ -241,7 +241,7 @@ class pnor2(pgate.pgate):
|
||||
"""Computes effective capacitance. Results in fF"""
|
||||
c_load = load
|
||||
c_para = spice["min_tx_drain_c"]*(self.nmos_size/parameter["min_tx_size"])#ff
|
||||
transition_prob = spice["nor2_transition_prob"]
|
||||
transition_prob = 0.1875
|
||||
return transition_prob*(c_load + c_para)
|
||||
|
||||
def build_graph(self, graph, inst_name, port_nets):
|
||||
|
||||
@@ -54,7 +54,7 @@ class timing_sram_test(openram_test):
|
||||
corner = (OPTS.process_corners[0], OPTS.supply_voltages[0], OPTS.temperatures[0])
|
||||
d = delay(s.s, tempspice, corner)
|
||||
import tech
|
||||
loads = [tech.spice["msflop_in_cap"]*4]
|
||||
loads = [tech.spice["dff_in_cap"]*4]
|
||||
slews = [tech.spice["rise_time"]*2]
|
||||
data, port_data = d.analyze(probe_address, probe_data, slews, loads)
|
||||
#Combine info about port into all data
|
||||
|
||||
@@ -49,7 +49,7 @@ class model_delay_test(openram_test):
|
||||
corner = (OPTS.process_corners[0], OPTS.supply_voltages[0], OPTS.temperatures[0])
|
||||
d = delay(s.s, tempspice, corner)
|
||||
import tech
|
||||
loads = [tech.spice["msflop_in_cap"]*4]
|
||||
loads = [tech.spice["dff_in_cap"]*4]
|
||||
slews = [tech.spice["rise_time"]*2]
|
||||
|
||||
# Run a spice characterization
|
||||
|
||||
@@ -47,7 +47,7 @@ class timing_sram_test(openram_test):
|
||||
corner = (OPTS.process_corners[0], OPTS.supply_voltages[0], OPTS.temperatures[0])
|
||||
d = delay(s.s, tempspice, corner)
|
||||
import tech
|
||||
loads = [tech.spice["msflop_in_cap"]*4]
|
||||
loads = [tech.spice["dff_in_cap"]*4]
|
||||
slews = [tech.spice["rise_time"]*2]
|
||||
data, port_data = d.analyze(probe_address, probe_data, slews, loads)
|
||||
#Combine info about port into all data
|
||||
|
||||
Reference in New Issue
Block a user