From 1acc6be3ce12f483c9467393c2f310d687ff84fb Mon Sep 17 00:00:00 2001 From: samuelkcrow Date: Wed, 2 Mar 2022 16:38:39 -0800 Subject: [PATCH] call create() function from sram/__init__ --- compiler/characterize_existing.py | 1 - compiler/func_sim_existing.py | 1 - compiler/gen_stimulus.py | 1 - compiler/openram.py | 7 ++----- compiler/sram/sram.py | 2 ++ 5 files changed, 4 insertions(+), 8 deletions(-) diff --git a/compiler/characterize_existing.py b/compiler/characterize_existing.py index c8456b9f..73a7c235 100755 --- a/compiler/characterize_existing.py +++ b/compiler/characterize_existing.py @@ -49,7 +49,6 @@ c = sram_config(word_size=OPTS.word_size, # Initialize and create the sram object from sram import sram s = sram(name=OPTS.output_name, sram_config=c) -s.create() # Characterize the design start_time = datetime.datetime.now() diff --git a/compiler/func_sim_existing.py b/compiler/func_sim_existing.py index ec89c3d7..0d693e91 100755 --- a/compiler/func_sim_existing.py +++ b/compiler/func_sim_existing.py @@ -54,7 +54,6 @@ c = sram_config(word_size=OPTS.word_size, # Initialize and create the sram object from sram import sram s = sram(name=OPTS.output_name, sram_config=c) -s.create() # Generate stimulus and run functional simulation on the design start_time = datetime.datetime.now() diff --git a/compiler/gen_stimulus.py b/compiler/gen_stimulus.py index d69d867d..c9b4e350 100755 --- a/compiler/gen_stimulus.py +++ b/compiler/gen_stimulus.py @@ -60,7 +60,6 @@ OPTS.openram_temp = OPTS.output_path from sram import sram s = sram(name=OPTS.output_name, sram_config=c) -s.create() from characterizer import delay import tech diff --git a/compiler/openram.py b/compiler/openram.py index 74f80128..240a3f9f 100755 --- a/compiler/openram.py +++ b/compiler/openram.py @@ -72,13 +72,10 @@ debug.print_raw("Output files are: ") for path in output_files: debug.print_raw(path) - +# Initialize the SRAM s = sram(name=OPTS.output_name, sram_config=c) -# Actually build the SRAM -s.create() - -# Output the files for the resulting SRAM +# Generate and output the files for the resulting SRAM s.save() # Delete temp files etc. diff --git a/compiler/sram/sram.py b/compiler/sram/sram.py index fdc8ec76..afa8cd58 100644 --- a/compiler/sram/sram.py +++ b/compiler/sram/sram.py @@ -40,6 +40,8 @@ class sram(): from design import design design.name_map=[] + self.create() + def create(self): debug.info(2, "create sram of size {0} with {1} num of words {2} banks".format(self.word_size, self.num_words,