mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-10-31 11:42:30 +00:00 
			
		
		
		
	Added ranged case check
This commit is contained in:
		
							parent
							
								
									53a4f0fb56
								
							
						
					
					
						commit
						d8cefec169
					
				
					 2 changed files with 27 additions and 0 deletions
				
			
		
							
								
								
									
										11
									
								
								tests/verific/range_case.sv
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								tests/verific/range_case.sv
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,11 @@ | ||||||
|  | module top(input clk, input signed [3:0] sel_w , output reg out); | ||||||
|  | 
 | ||||||
|  | always @ (posedge clk) | ||||||
|  | begin | ||||||
|  |     case (sel_w) inside | ||||||
|  |         [-4:3] : out <= 1'b1; | ||||||
|  |         [4:5] : out <= 1'b0; | ||||||
|  |     endcase | ||||||
|  | end | ||||||
|  | 
 | ||||||
|  | endmodule | ||||||
							
								
								
									
										16
									
								
								tests/verific/range_case.ys
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								tests/verific/range_case.ys
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,16 @@ | ||||||
|  | verific -cfg db_abstract_case_statement_synthesis 0 | ||||||
|  | read -sv range_case.sv | ||||||
|  | verific -import top  | ||||||
|  | proc | ||||||
|  | rename top gold | ||||||
|  | 
 | ||||||
|  | verific -cfg db_abstract_case_statement_synthesis 1 | ||||||
|  | read -sv range_case.sv | ||||||
|  | verific -import top  | ||||||
|  | proc | ||||||
|  | rename top gate | ||||||
|  | 
 | ||||||
|  | miter -equiv -flatten -make_assert gold gate miter | ||||||
|  | prep -top miter | ||||||
|  | clk2fflogic | ||||||
|  | sat -set-init-zero -tempinduct -prove-asserts -verify | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue