mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-10-31 03:32:29 +00:00 
			
		
		
		
	Merge pull request #4802 from povik/abc9-box-repeat
Adjust `abc9_ops -prep_box` to allow repeated invocation
This commit is contained in:
		
						commit
						f7ad003a6f
					
				
					 1 changed files with 2 additions and 4 deletions
				
			
		|  | @ -969,13 +969,10 @@ void prep_box(RTLIL::Design *design) | |||
| 		if (it == module->attributes.end()) | ||||
| 			continue; | ||||
| 		bool box = it->second.as_bool(); | ||||
| 		module->attributes.erase(it); | ||||
| 		if (!box) | ||||
| 			continue; | ||||
| 
 | ||||
| 		auto r = module->attributes.insert(ID::abc9_box_id); | ||||
| 		if (!r.second) | ||||
| 			continue; | ||||
| 		r.first->second = abc9_box_id++; | ||||
| 
 | ||||
| 		if (module->get_bool_attribute(ID::abc9_flop)) { | ||||
|  | @ -1097,8 +1094,9 @@ void prep_box(RTLIL::Design *design) | |||
| 			ss << std::endl; | ||||
| 
 | ||||
| 			auto &t = timing.setup_module(module); | ||||
| 			if (t.comb.empty()) | ||||
| 			if (t.comb.empty() && !outputs.empty() && !inputs.empty()) { | ||||
| 				log_error("Module '%s' with (* abc9_box *) has no timing (and thus no connectivity) information.\n", log_id(module)); | ||||
| 			} | ||||
| 
 | ||||
| 			for (const auto &o : outputs) { | ||||
| 				first = true; | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue