mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-10-31 19:52:31 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			13 lines
		
	
	
	
		
			203 B
		
	
	
	
		
			Text
		
	
	
	
	
	
			
		
		
	
	
			13 lines
		
	
	
	
		
			203 B
		
	
	
	
		
			Text
		
	
	
	
	
	
| read_verilog <<EOT
 | |
| 
 | |
| module t(input [3:0] A, input [3:0] B, input [3:0] C, input S, output [3:0] Y);
 | |
| 
 | |
| wire [3:0] t = A + C;
 | |
| 
 | |
| assign Y = S ? A + B : {4{t[0]}};
 | |
| 
 | |
| endmodule
 | |
| 
 | |
| EOT
 | |
| 
 | |
| equiv_opt -assert opt_share
 |