]> granicus.if.org Git - libjpeg-turbo/commitdiff
Fix a bug in the AltiVec downsampling routines uncovered during additional testing...
authorDRC <dcommander@users.sourceforge.net>
Wed, 14 Jan 2015 08:31:54 +0000 (08:31 +0000)
committerDRC <dcommander@users.sourceforge.net>
Wed, 14 Jan 2015 08:31:54 +0000 (08:31 +0000)
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@1499 632fc199-4ca6-4c93-a231-07263d6284db

simd/jcsample-altivec.c

index 58ae4496e9904da5e2845d8f7f65b5cb2e6dee47..517e2bed70dac17da69904210d4e8eb6da115da5 100644 (file)
@@ -64,7 +64,7 @@ jsimd_h2v1_downsample_altivec (JDIMENSION image_width, int max_v_samp_factor,
       outl = vec_add(outl, pw_bias);
       outl = vec_sr(outl, pw_one);
 
-      if (outcol > 16) {
+      if (outcol > 8) {
         next0 = vec_ld(16, inptr);
         next0 = vec_perm(next0, next0, even_odd_index);
         next0e = (__vector unsigned short)vec_mergeh(pb_zero, next0);
@@ -132,7 +132,7 @@ jsimd_h2v2_downsample_altivec (JDIMENSION image_width, int max_v_samp_factor,
       outl = vec_add(outl, pw_bias);
       outl = vec_sr(outl, pw_two);
 
-      if (outcol > 16) {
+      if (outcol > 8) {
         next0 = vec_ld(16, inptr0);
         next0 = vec_perm(next0, next0, even_odd_index);
         next0e = (__vector unsigned short)vec_mergeh(pb_zero, next0);