소스 검색

Fix distance to diagonal computation

Samuel Thibault 6 년 전
부모
커밋
44b3dc0657
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      tests/datawizard/variable_size.c

+ 1 - 1
tests/datawizard/variable_size.c

@@ -100,7 +100,7 @@ void variable_size_data_register(starpu_data_handle_t *handleptr, unsigned x, un
 	};
 
 	/* Simulate that tiles close to the diagonal are more dense */
-	interface.size = FULLSIZE * (starpu_lrand48() % 1024 + 1024) / 2048. * (N-sqrt(abs(x-y)*N)) / N;
+	interface.size = FULLSIZE * (starpu_lrand48() % 1024 + 1024) / 2048. * (N-sqrt(abs((int)x-(int)y)*N)) / N;
 	/* Round to page size */
 	interface.size -= interface.size & (65536-1);