mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-10-31 11:42:30 +00:00 
			
		
		
		
	silence some more warnings, undo mistaken addition
This commit is contained in:
		
							parent
							
								
									8f77494263
								
							
						
					
					
						commit
						79a1b691ea
					
				
					 2 changed files with 6 additions and 7 deletions
				
			
		|  | @ -388,8 +388,6 @@ public: | ||||||
| 			case DriveType::MULTIPLE: | 			case DriveType::MULTIPLE: | ||||||
| 				inner = multiple_.hash(); | 				inner = multiple_.hash(); | ||||||
| 				break; | 				break; | ||||||
| 			default: |  | ||||||
| 				log_abort(); |  | ||||||
| 		} | 		} | ||||||
| 		return mkhash((unsigned int)type_, inner); | 		return mkhash((unsigned int)type_, inner); | ||||||
| 	} | 	} | ||||||
|  | @ -1028,6 +1026,7 @@ public: | ||||||
| 			case DriveType::MULTIPLE: | 			case DriveType::MULTIPLE: | ||||||
| 				return multiple_.size(); | 				return multiple_.size(); | ||||||
| 		} | 		} | ||||||
|  | 		log_abort(); | ||||||
| 	} | 	} | ||||||
| }; | }; | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -1729,8 +1729,8 @@ void MemContents::check() { | ||||||
| 		log_assert(!it->second.empty()); | 		log_assert(!it->second.empty()); | ||||||
| 		log_assert(it->second.size() % _data_width == 0); | 		log_assert(it->second.size() % _data_width == 0); | ||||||
| 		auto end1 = _range_end(it); | 		auto end1 = _range_end(it); | ||||||
| 		log_assert(_range_begin(it) < (1<<_addr_width)); | 		log_assert(_range_begin(it) < (addr_t)(1<<_addr_width)); | ||||||
| 		log_assert(end1 <= (1<<_addr_width)); | 		log_assert(end1 <= (addr_t)(1<<_addr_width)); | ||||||
| 		if(++it == _values.end()) | 		if(++it == _values.end()) | ||||||
| 			break; | 			break; | ||||||
| 		// check that ranges neither overlap nor touch
 | 		// check that ranges neither overlap nor touch
 | ||||||
|  | @ -1760,7 +1760,7 @@ bool MemContents::_range_overlaps(std::map<addr_t, RTLIL::Const>::iterator it, a | ||||||
| 
 | 
 | ||||||
| std::map<addr_t, RTLIL::Const>::iterator MemContents::_range_at(addr_t addr) const { | std::map<addr_t, RTLIL::Const>::iterator MemContents::_range_at(addr_t addr) const { | ||||||
| 	// allow addr == 1<<_addr_width (which will just return end())
 | 	// allow addr == 1<<_addr_width (which will just return end())
 | ||||||
| 	log_assert(addr <= 1<<_addr_width); | 	log_assert(addr <= (addr_t)(1<<_addr_width)); | ||||||
| 	// get the first range with base > addr
 | 	// get the first range with base > addr
 | ||||||
| 	// (we use const_cast since map::iterators are only passed around internally and not exposed to the user
 | 	// (we use const_cast since map::iterators are only passed around internally and not exposed to the user
 | ||||||
| 	// and using map::iterator in both the const and non-const case simplifies the code a little,
 | 	// and using map::iterator in both the const and non-const case simplifies the code a little,
 | ||||||
|  | @ -1879,8 +1879,8 @@ std::map<addr_t, RTLIL::Const>::iterator MemContents::_reserve_range(addr_t begi | ||||||
| 
 | 
 | ||||||
| void MemContents::insert_concatenated(addr_t addr, RTLIL::Const const &values) { | void MemContents::insert_concatenated(addr_t addr, RTLIL::Const const &values) { | ||||||
| 	addr_t words = (values.size() + _data_width - 1) / _data_width; | 	addr_t words = (values.size() + _data_width - 1) / _data_width; | ||||||
| 	log_assert(addr < 1<<_addr_width); | 	log_assert(addr < (addr_t)(1<<_addr_width)); | ||||||
| 	log_assert(words <= (1<<_addr_width) - addr); | 	log_assert(words <= (addr_t)(1<<_addr_width) - addr); | ||||||
| 	auto it = _reserve_range(addr, addr + words); | 	auto it = _reserve_range(addr, addr + words); | ||||||
| 	auto to_begin = _range_data(it, addr); | 	auto to_begin = _range_data(it, addr); | ||||||
| 	std::copy(values.bits.begin(), values.bits.end(), to_begin); | 	std::copy(values.bits.begin(), values.bits.end(), to_begin); | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue