mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-10-31 03:32:29 +00:00 
			
		
		
		
	Fixed finish_addr handling in $readmemh/$readmemb
This commit is contained in:
		
							parent
							
								
									75bf7416f0
								
							
						
					
					
						commit
						fe9315b7a1
					
				
					 1 changed files with 3 additions and 3 deletions
				
			
		|  | @ -2468,12 +2468,12 @@ AstNode *AstNode::readmem(bool is_readmemh, std::string mem_filename, AstNode *m | |||
| 				block->children.back()->children[0]->id2ast = memory; | ||||
| 			} | ||||
| 
 | ||||
| 			if ((cursor == finish_addr) || (increment > 0 && cursor > range_max) || (increment < 0 && cursor < range_min)) | ||||
| 				break; | ||||
| 			cursor += increment; | ||||
| 			if ((cursor == finish_addr+increment) || (increment > 0 && cursor > range_max) || (increment < 0 && cursor < range_min)) | ||||
| 				break; | ||||
| 		} | ||||
| 
 | ||||
| 		if ((cursor == finish_addr) || (increment > 0 && cursor > range_max) || (increment < 0 && cursor < range_min)) | ||||
| 		if ((cursor == finish_addr+increment) || (increment > 0 && cursor > range_max) || (increment < 0 && cursor < range_min)) | ||||
| 			break; | ||||
| 	} | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue