| 
					
				 | 
			
			
				@@ -1885,20 +1885,19 @@ void _starpu_update_perfmodel_history(struct _starpu_job *j, struct starpu_perfm 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				STARPU_HG_DISABLE_CHECKING(entry->nsample); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				STARPU_HG_DISABLE_CHECKING(entry->mean); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				/* Do not take the first measurement into account, it is very often quite bogus */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				/* For history-based, do not take the first measurement into account, it is very often quite bogus */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				/* TODO: it'd be good to use a better estimation heuristic, like the median, or latest n values, etc. */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				//entry->mean = 0; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				//entry->sum = 0; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				- 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				//entry->deviation = 0.0; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				//entry->sum2 = 0; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				if (model->type != STARPU_HISTORY_BASED) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					entry->sum = measured; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					entry->sum2 = measured*measured; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					entry->nsample = 1; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					entry->mean = measured; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				entry->size = _starpu_job_get_data_size(model, arch, impl, j); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				entry->flops = j->task->flops; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				entry->footprint = key; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				//entry->nsample = 0; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				//entry->nerror = 0; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				insert_history_entry(entry, list, &per_arch_model->history); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			} 
			 |