summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfoxit <bo_xu@foxitsoftware.com>2014-06-08 16:35:48 -0700
committerfoxit <bo_xu@foxitsoftware.com>2014-06-08 16:35:48 -0700
commit0db35e84407fe41f1ba9c19628a9fcfc9cc8f462 (patch)
treee5b59377f01620c98e66831b4c65a1b7fe22076e
parentd68f9a3e646555e292a1f184560149e8a3e629ac (diff)
downloadpdfium-chromium/2042.tar.xz
Use none SSE functions when data is not 16 byte alignedchromium/2043chromium/2042chromium/2041
BUG= R=jabdelmalek@google.com Review URL: https://codereview.chromium.org/318593002
-rw-r--r--core/src/fxcodec/fx_libopenjpeg/libopenjpeg20/dwt.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/core/src/fxcodec/fx_libopenjpeg/libopenjpeg20/dwt.c b/core/src/fxcodec/fx_libopenjpeg/libopenjpeg20/dwt.c
index e1f8a337d4..5f710e87b2 100644
--- a/core/src/fxcodec/fx_libopenjpeg/libopenjpeg20/dwt.c
+++ b/core/src/fxcodec/fx_libopenjpeg/libopenjpeg20/dwt.c
@@ -140,7 +140,9 @@ static void opj_v4dwt_interleave_h(opj_v4dwt_t* restrict w, OPJ_FLOAT32* restric
static void opj_v4dwt_interleave_v(opj_v4dwt_t* restrict v , OPJ_FLOAT32* restrict a , OPJ_INT32 x, OPJ_INT32 nb_elts_read);
-#ifdef __SSE__
+//#ifdef __SSE__
+// Disable __SSE__ due to bug http://crbug.com/373619. Should enable this after adding aligned malloc in memory manager
+#if 0
static void opj_v4dwt_decode_step1_sse(opj_v4_t* w, OPJ_INT32 count, const __m128 c);
static void opj_v4dwt_decode_step2_sse(opj_v4_t* l, opj_v4_t* w, OPJ_INT32 k, OPJ_INT32 m, __m128 c);
@@ -671,8 +673,9 @@ void opj_v4dwt_interleave_v(opj_v4dwt_t* restrict v , OPJ_FLOAT32* restrict a ,
}
}
-#ifdef __SSE__
-
+//#ifdef __SSE__
+// Disable __SSE__ due to bug http://crbug.com/373619. Should enable this after adding aligned malloc in memory manager
+#if 0
void opj_v4dwt_decode_step1_sse(opj_v4_t* w, OPJ_INT32 count, const __m128 c){
__m128* restrict vw = (__m128*) w;
OPJ_INT32 i;
@@ -808,7 +811,10 @@ void opj_v4dwt_decode(opj_v4dwt_t* restrict dwt)
a = 1;
b = 0;
}
-#ifdef __SSE__
+
+//#ifdef __SSE__
+// Disable __SSE__ due to bug http://crbug.com/373619. Should enable this after adding aligned malloc in memory manager
+#if 0
opj_v4dwt_decode_step1_sse(dwt->wavelet+a, dwt->sn, _mm_set1_ps(opj_K));
opj_v4dwt_decode_step1_sse(dwt->wavelet+b, dwt->dn, _mm_set1_ps(opj_c13318));
opj_v4dwt_decode_step2_sse(dwt->wavelet+b, dwt->wavelet+a+1, dwt->sn, opj_int_min(dwt->sn, dwt->dn-a), _mm_set1_ps(opj_dwt_delta));