mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-10-31 11:42:30 +00:00 
			
		
		
		
	Improve EDIF lib_cell_ports scan
This commit is contained in:
		
							parent
							
								
									fb9e12761b
								
							
						
					
					
						commit
						cff3195caa
					
				
					 1 changed files with 9 additions and 1 deletions
				
			
		|  | @ -192,6 +192,14 @@ struct EdifBackend : public Backend { | ||||||
| 
 | 
 | ||||||
| 		for (auto module : design->modules()) | 		for (auto module : design->modules()) | ||||||
| 		{ | 		{ | ||||||
|  | 			lib_cell_ports[module->name]; | ||||||
|  | 
 | ||||||
|  | 			for (auto port : module->ports) | ||||||
|  | 			{ | ||||||
|  | 				Wire *wire = module->wire(port); | ||||||
|  | 				lib_cell_ports[module->name][port] = std::max(lib_cell_ports[module->name][port], GetSize(wire)); | ||||||
|  | 			} | ||||||
|  | 
 | ||||||
| 			if (module->get_blackbox_attribute()) | 			if (module->get_blackbox_attribute()) | ||||||
| 				continue; | 				continue; | ||||||
| 
 | 
 | ||||||
|  | @ -208,7 +216,7 @@ struct EdifBackend : public Backend { | ||||||
| 				if (design->module(cell->type) == nullptr || design->module(cell->type)->get_blackbox_attribute()) { | 				if (design->module(cell->type) == nullptr || design->module(cell->type)->get_blackbox_attribute()) { | ||||||
| 					lib_cell_ports[cell->type]; | 					lib_cell_ports[cell->type]; | ||||||
| 					for (auto p : cell->connections()) | 					for (auto p : cell->connections()) | ||||||
| 						lib_cell_ports[cell->type][p.first] = GetSize(p.second); | 						lib_cell_ports[cell->type][p.first] = std::max(lib_cell_ports[cell->type][p.first], GetSize(p.second)); | ||||||
| 				} | 				} | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue