def test_linear_dfg(): Component.reset_ids() cwd = Path(f"{__file__}").parent base_path = f"{cwd}/test_dfgs" dfg_name = "linear_dfg.json" file_path = f"{base_path}/{dfg_name}" with open(f'{cwd}/config.json') as config_file: data = json.load(config_file) new_arch = TablaTemplate(data) test_sched = Schedule() test_sched.load_dfg(file_path) test_sched.schedule_graph(new_arch) validate_instructions(new_arch)
def test_class(): Component.reset_ids() base_path = "./test_dfgs" package_name = "class_dfg" dfg_name = f"{package_name}.json" file_path = f"{base_path}/{dfg_name}" with open('config.json') as config_file: data = json.load(config_file) new_arch = TablaTemplate(data) test_sched = Schedule() test_sched.load_dfg(file_path) test_sched.schedule_graph(new_arch) validate_instructions(new_arch) generate_pe_instructions(test_sched, new_arch, package_name)
def test_reco(): Component.reset_ids() cwd = Path(f"{__file__}").parent base_path = f"{cwd}/test_dfgs" package_name = "reco_dfg" dfg_name = f"{package_name}.json" file_path = f"{base_path}/{dfg_name}" with open(f'{cwd}/config.json') as config_file: data = json.load(config_file) new_arch = TablaTemplate(data) test_sched = Schedule(optimize=False) test_sched.load_dfg(file_path) test_sched.schedule_graph(new_arch) validate_instructions(new_arch) generate_pe_instructions(test_sched, new_arch, package_name)