mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-11-04 13:29:12 +00:00 
			
		
		
		
	Fix opt_rmdff handling of $_DFFSR_???_ and $_DLATCHSR_???_, fixes #816
Signed-off-by: Clifford Wolf <clifford@clifford.at>
This commit is contained in:
		
							parent
							
								
									31fea5eb33
								
							
						
					
					
						commit
						2da4c9c8f0
					
				
					 1 changed files with 7 additions and 6 deletions
				
			
		| 
						 | 
				
			
			@ -174,8 +174,6 @@ bool handle_dffsr(RTLIL::Module *mod, RTLIL::Cell *cell)
 | 
			
		|||
			cell->unsetParam("\\CLR_POLARITY");
 | 
			
		||||
			cell->unsetPort("\\SET");
 | 
			
		||||
			cell->unsetPort("\\CLR");
 | 
			
		||||
 | 
			
		||||
			return true;
 | 
			
		||||
		}
 | 
			
		||||
		else
 | 
			
		||||
		{
 | 
			
		||||
| 
						 | 
				
			
			@ -186,11 +184,12 @@ bool handle_dffsr(RTLIL::Module *mod, RTLIL::Cell *cell)
 | 
			
		|||
			cell->unsetParam("\\CLR_POLARITY");
 | 
			
		||||
			cell->unsetPort("\\SET");
 | 
			
		||||
			cell->unsetPort("\\CLR");
 | 
			
		||||
 | 
			
		||||
			return true;
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		return true;
 | 
			
		||||
	}
 | 
			
		||||
	else
 | 
			
		||||
 | 
			
		||||
	if (!hasreset)
 | 
			
		||||
	{
 | 
			
		||||
		IdString new_type;
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			@ -207,8 +206,10 @@ bool handle_dffsr(RTLIL::Module *mod, RTLIL::Cell *cell)
 | 
			
		|||
		cell->unsetPort("\\S");
 | 
			
		||||
		cell->unsetPort("\\R");
 | 
			
		||||
 | 
			
		||||
		return did_something;
 | 
			
		||||
		return true;
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	return did_something;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
bool handle_dlatch(RTLIL::Module *mod, RTLIL::Cell *dlatch)
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue