summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Schleef <ds@bigkitten.com>2008-03-16 18:58:49 -0700
committerDavid Schleef <ds@bigkitten.com>2008-03-16 18:58:49 -0700
commitba4855b50c5b840e88b330362e9d094810427315 (patch)
tree020895f2b0a37e0704830ffd600d770ee3720c40
parent301ac278cb7341eb3a515434fd9ef3403abce24c (diff)
Check n==0 case.
-rw-r--r--liboil/amd64/wavelet.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/liboil/amd64/wavelet.c b/liboil/amd64/wavelet.c
index 9785fa2..1ee7ba7 100644
--- a/liboil/amd64/wavelet.c
+++ b/liboil/amd64/wavelet.c
@@ -1770,6 +1770,7 @@ lshift_s16_mmx(int16_t *d1, int16_t *s1, int16_t *s3_1, int n)
n--;
}
n >>= 2;
+ if (n == 0) return;
__asm__ __volatile__ ("\n"
" movzwl 0(%[s3_1]), %%ecx\n"
" movd %%ecx, %%mm1\n"
@@ -1800,6 +1801,7 @@ lshift_s16_mmx_2(int16_t *d1, int16_t *s1, int16_t *s3_1, int n)
n--;
}
n >>= 3;
+ if (n == 0) return;
__asm__ __volatile__ ("\n"
" movzwl 0(%[s3_1]), %%ecx\n"
" movd %%ecx, %%mm1\n"