Example #1
0
 def get_default_args(**kw):
     default_dict = {
         "precision":
         fixed_point(32, 0),
         "target":
         VHDLBackend(),
         "output_file":
         "mult_array.vhd",
         "entity_name":
         "mult_array",
         "language":
         VHDL_Code,
         "Method":
         ReductionMethod.Wallace_4to2,
         "pipelined":
         False,
         "dummy_mode":
         False,
         "booth_mode":
         False,
         "method":
         ReductionMethod.Wallace,
         "op_expr":
         multiplication_descriptor_parser("FS9.0xFS13.0"),
         "stage_height_limit": [None],
         "passes": [
             ("beforepipelining:size_datapath"),
             ("beforepipelining:rtl_legalize"),
             ("beforepipelining:unify_pipeline_stages"),
         ],
     }
     default_dict.update(kw)
     return DefaultEntityArgTemplate(**default_dict)
Example #2
0
 def get_default_args(**kw):
     default_mapping = {
         "extra_digit": 0,
         "sign_magnitude": False,
         "pipelined": False
     }
     default_mapping.update(kw)
     return DefaultEntityArgTemplate(**default_mapping)
Example #3
0
 def get_default_args(**kw):
     root_arg = {
         "entity_name": "new_entity_pass",
         "output_file": "ut_entity_pass.c",
         "width": 32,
         "precision": ML_Int32
     }
     root_arg.update(kw)
     return DefaultEntityArgTemplate(**root_arg)
Example #4
0
 def get_default_args(width=32, entity_name="my_lzc", **kw):
     return DefaultEntityArgTemplate(precision=ML_Int32,
                                     debug_flag=False,
                                     target=vhdl_backend.VHDLBackend(),
                                     output_file="my_lzc.vhd",
                                     entity_name=entity_name,
                                     language=VHDL_Code,
                                     width=width,
                                     **kw)
Example #5
0
 def get_default_args(**kw):
     default_dict = {
         "precision": ML_Binary32,
         "target": VHDLBackend(),
         "output_file": "my_fp_div.vhd",
         "entity_name": "my_fp_div",
         "language": VHDL_Code,
         "pipelined": False,
     }
     default_dict.update(kw)
     return DefaultEntityArgTemplate(**default_dict)
Example #6
0
 def get_default_args(**kw):
     default_dict = {
         "precision": ML_Int32,
         "debug_flag": False,
         "target": VHDLBackend(),
         "output_file": "ut_rtl_report.vhd",
         "entity_name": "ut_rtl_report",
         "language": VHDL_Code,
     }
     default_dict.update(kw)
     return DefaultEntityArgTemplate(**default_dict)
Example #7
0
 def get_default_args(**kw):
     default_arg_map = {
         "precision": HdlVirtualFormat(ML_Binary32),
         "pipelined": False,
         "output_file": "fp_adder.vhd",
         "entity_name": "fp_adder",
         "language": VHDL_Code,
         "passes": [("beforecodegen:size_datapath")],
     }
     default_arg_map.update(**kw)
     return DefaultEntityArgTemplate(**default_arg_map)
 def get_default_args(width=32, **kw):
     """ generate default argument template """
     return DefaultEntityArgTemplate(
         precision=ML_Int32,
         debug_flag=False,
         target=VHDLBackend(),
         output_file="ut_fixed_point_position.vhd",
         entity_name="ut_fixed_point_position",
         language=VHDL_Code,
         width=width,
         passes=[("beforecodegen:size_datapath")],
     )
Example #9
0
 def get_default_args(width=32, **kw):
     """ generate default argument template """
     return DefaultEntityArgTemplate(
         precision=ML_Int32,
         debug_flag=False,
         target=VHDLBackend(),
         output_file="my_adapative_entity.vhd",
         entity_name="my_adaptative_entity",
         language=VHDL_Code,
         width=width,
         passes=[("beforecodegen:size_datapath"),
                 ("beforecodegen:rtl_legalize"), ("beforecodegen:dump")],
     )
Example #10
0
 def get_default_args(**kw):
     default_arg_map = {
         "io_formats": {
             "scale": HdlVirtualFormat(ML_Binary32),
             "quantized_input": FIX32,
             "offset_input": FIX32,
             "result": FIX32
         },
         "pipelined": False,
         "output_file": "dequantizer.vhd",
         "entity_name": "dequantizer",
         "language": VHDL_Code,
         "passes": ["beforecodegen:size_datapath", "beforecodegen:rtl_legalize"],
     }
     default_arg_map.update(**kw)
     return DefaultEntityArgTemplate(**default_arg_map)
Example #11
0
 def get_default_args(width=32, **kw):
     """ generate default argument template """
     return DefaultEntityArgTemplate(
         precision=ML_Int32,
         debug_flag=False,
         target=VHDLBackend(),
         output_file="ut_sub_component.vhd",
         entity_name="ut_sub_component",
         language=VHDL_Code,
         width=width,
         passes=[
             ("beforepipelining:size_datapath"),
             ("beforepipelining:rtl_legalize"),
             ("beforepipelining:unify_pipeline_stages"),
             ],
     )
Example #12
0
 def get_default_args(**kw):
     """ generate default argument structure for BipartiteApprox """
     default_dict = {
         "target":
         VHDLBackend(),
         "output_file":
         "my_bipartite_approx.vhd",
         "entity_name":
         "my_bipartie_approx",
         "language":
         VHDL_Code,
         "function":
         lambda x: 1.0 / x,
         "interval":
         Interval(1, 2),
         "pipelined":
         False,
         "precision":
         fixed_point(1, 15, signed=False),
         "disable_sub_testing":
         False,
         "disable_sv_testing":
         False,
         "alpha":
         6,
         "beta":
         5,
         "gamma":
         5,
         "guard_bits":
         3,
         "passes": [
             "beforepipelining:size_datapath",
             "beforepipelining:rtl_legalize",
             "beforepipelining:unify_pipeline_stages"
         ],
     }
     default_dict.update(kw)
     return DefaultEntityArgTemplate(**default_dict)