Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(173)

Unified Diff: unit_test/planar_test.cc

Issue 2438893002: HalfFloat avx2 unpack bug fix. (Closed)
Patch Set: test use random Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« source/row_gcc.cc ('K') | « source/row_gcc.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: unit_test/planar_test.cc
diff --git a/unit_test/planar_test.cc b/unit_test/planar_test.cc
index c552c4a595695d21e088418535e960f42ce2467e..a2eb1faac0efafd1e861fd474f9111f6b7dfdbd8 100644
--- a/unit_test/planar_test.cc
+++ b/unit_test/planar_test.cc
@@ -2099,8 +2099,8 @@ int TestHalfFloatPlane(int benchmark_width, int benchmark_height,
MaskCpuFlags(disable_cpu_flags);
double c_time = get_time();
for (j = 0; j < benchmark_iterations; j++) {
- HalfFloatPlane((uint16*)orig_y, benchmark_width * 2,
- (uint16*)dst_c, benchmark_width * 2,
+ HalfFloatPlane(reinterpret_cast<uint16*>(orig_y), benchmark_width * 2,
+ reinterpret_cast<uint16*>(dst_c), benchmark_width * 2,
scale, benchmark_width, benchmark_height);
}
c_time = (get_time() - c_time) / benchmark_iterations;
@@ -2109,8 +2109,8 @@ int TestHalfFloatPlane(int benchmark_width, int benchmark_height,
MaskCpuFlags(benchmark_cpu_info);
double opt_time = get_time();
for (j = 0; j < benchmark_iterations; j++) {
- HalfFloatPlane((uint16*)orig_y, benchmark_width * 2,
- (uint16*)dst_opt, benchmark_width * 2,
+ HalfFloatPlane(reinterpret_cast<uint16*>(orig_y), benchmark_width * 2,
+ reinterpret_cast<uint16*>(dst_opt), benchmark_width * 2,
scale, benchmark_width, benchmark_height);
}
opt_time = (get_time() - opt_time) / benchmark_iterations;
« source/row_gcc.cc ('K') | « source/row_gcc.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698