Skip to content

Commit

Permalink
Make latch_map_file truly optional (#869)
Browse files Browse the repository at this point in the history
Right now if a technology doesn't specify the latch map file, "techmap
-map None" is written into the generated tcl.
  • Loading branch information
edwardcwang authored Jun 27, 2024
1 parent 5475322 commit eb86e88
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion hammer/synthesis/yosys/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ def init_environment(self) -> bool:

def syn_generic(self) -> bool:
# TODO: is there a better way to do this? like self.get_setting()
if self._database.has_setting("synthesis.yosys.latch_map_file"):
if self._database.has_setting("synthesis.yosys.latch_map_file") and self.get_setting('synthesis.yosys.latch_map_file') is not None:
latch_map = f"techmap -map {self.get_setting('synthesis.yosys.latch_map_file')}"
else: # TODO: make the else case better
latch_map = ""
Expand Down

0 comments on commit eb86e88

Please sign in to comment.