summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2023-02-09 01:47:32 +0000
committerSam James <sam@gentoo.org>2023-02-09 01:47:32 +0000
commit4fd20b57bf481919243b099f0d3179ea38ce23ce (patch)
treeae70d1db4219831b26e08cdcb794088b8a9ad9bd /media-libs
parentnet-p2p/transmission: convert keepdir /var/lib/transmission to tmpfiles (diff)
downloadgentoo-4fd20b57bf481919243b099f0d3179ea38ce23ce.tar.gz
gentoo-4fd20b57bf481919243b099f0d3179ea38ce23ce.tar.bz2
gentoo-4fd20b57bf481919243b099f0d3179ea38ce23ce.zip
media-libs/libjpeg-turbo: add 2.1.5.1, drop 2.1.5-r1
Closes: https://bugs.gentoo.org/893552 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'media-libs')
-rw-r--r--media-libs/libjpeg-turbo/Manifest2
-rw-r--r--media-libs/libjpeg-turbo/files/2.1.5-initialize-simd_support-before-every-use.patch437
-rw-r--r--media-libs/libjpeg-turbo/libjpeg-turbo-2.1.5.1.ebuild (renamed from media-libs/libjpeg-turbo/libjpeg-turbo-2.1.5-r1.ebuild)4
3 files changed, 1 insertions, 442 deletions
diff --git a/media-libs/libjpeg-turbo/Manifest b/media-libs/libjpeg-turbo/Manifest
index 152fb21c687d..04caa7c7ede8 100644
--- a/media-libs/libjpeg-turbo/Manifest
+++ b/media-libs/libjpeg-turbo/Manifest
@@ -1,4 +1,4 @@
DIST libjpeg-turbo-2.1.3.tar.gz 2260756 BLAKE2B 87ef47105e66b2ee918e95962ac59963b6adea5b49ab0db692810aee0a13a215a0ef7fe0b549ecd5151274549e12d09eb0b42439bf0a4bc1ad2c4e62dcceb77c SHA512 975c9835de7d70c6c8c5a1959adfa18f7f956bc9946fde8f1b40c1d853245c38a3118ac06b93841ec3e90be6945c38d687d062b371496c2ee9b5638d7f60418d
DIST libjpeg-turbo-2.1.4.tar.gz 2261822 BLAKE2B 80ffd77d58a37eae0bdc1868d994f34ea52c13e2624c720b1d0b6ec4d6d14b16911163ccd4009c8d6eda214f31e1fff78bb7eb4739ae6589d0fd8c7008c0e972 SHA512 511f065767c022da06b6c36299686fa44f83441646f7e33b766c6cfab03f91b0e6bfa456962184071dadaed4057ba9a29cba685383f3eb86a4370a1a53731a70
-DIST libjpeg-turbo-2.1.5.tar.gz 2264471 BLAKE2B c65de2717ddc33447064412738b2db94a92693faad18f29f14c5c368d9eb4c617fe447a6f9428d9a101458dec0c65abc527e20632571eaa727d98cd5435241d4 SHA512 ceab6d1c3c46d2816b06402e3b912e950d887fc8a6fb32fa6876f4aaa663b4769d8f4c50e1b967addf6704d0760ca14ed723d55e0312d7ca69e7f2a91484c0dc
+DIST libjpeg-turbo-2.1.5.1.tar.gz 2264936 BLAKE2B 9583a0a91e45347d651de6bf5192a23bfe4e64cef67cdbb18f5b578b424fc46fc114e5649e93a467906cf047948e43a11b6d17b48c47f879c51cff1a4ef356ff SHA512 86a7248d064043b26b09755633ef4872a2a6133c9e677a9fe4be6645b2e0fde102cf01e09119967b3b6b85f4cb93f3f7c49ec4973944d5eff99b5b90ce8b0be6
DIST libjpeg8_8d-2.debian.tar.gz 14764 BLAKE2B e93d12afa062da28b717b540492221f70e8d9ccf3885371647cf85a2937f938ca723d4a27d5e1c5d79c26aa25dddf69b38754558851a1704172e8b52baf8e17c SHA512 8c5959fb7583a2d61e9442187f67b91b45e72d9dd30db3360d583a3b5d8e1a908db5659f760bdd455b3056e6ae3535b2fd3b847df3d58b140a1816b754003675
diff --git a/media-libs/libjpeg-turbo/files/2.1.5-initialize-simd_support-before-every-use.patch b/media-libs/libjpeg-turbo/files/2.1.5-initialize-simd_support-before-every-use.patch
deleted file mode 100644
index 8533427938d0..000000000000
--- a/media-libs/libjpeg-turbo/files/2.1.5-initialize-simd_support-before-every-use.patch
+++ /dev/null
@@ -1,437 +0,0 @@
-https://bugs.gentoo.org/893552
-https://github.com/libjpeg-turbo/libjpeg-turbo/commit/4e028ecd63aaa13c8a14937f9f1e9a272ed4b543
-https://github.com/libjpeg-turbo/libjpeg-turbo/issues/649
-
-From 4e028ecd63aaa13c8a14937f9f1e9a272ed4b543 Mon Sep 17 00:00:00 2001
-From: DRC <information@libjpeg-turbo.org>
-Date: Thu, 2 Feb 2023 08:55:37 -0600
-Subject: [PATCH] SIMD/x86: Initialize simd_support before every use
-
-As long as a libjpeg instance is only used by one thread at a time, a
-program is technically within its rights to call jpeg_start_*compress()
-in one thread and jpeg_(read|write)_*(), with the same libjpeg instance,
-in a second thread. However, because the various jsimd_can*() functions
-are called within the body of jpeg_start_*compress() and simd_support is
-now thread-local (due to f579cc11b33e5bfeb9931e37cc74b4a33c95d2e6), that
-led to a situation in which simd_support was initialized in the first
-thread but not the second. The uninitialized value of simd_support is
-0xFFFFFFFF, which the second thread interpreted to mean that it could
-use any instruction set, and when it attempted to use AVX2 instructions
-on a CPU that didn't support them, an illegal instruction error
-occurred.
-
-This issue was known to affect libvips.
-
-This commit modifies the i386 and x86-64 SIMD dispatchers so that the
-various jsimd_*() functions always call init_simd(), if simd_support is
-uninitialized, prior to dispatching based on the value of simd_support.
-Note that the other SIMD dispatchers don't need this, because only the
-x86 SIMD extensions currently support multiple instruction sets.
-
-This patch has been verified to be performance-neutral to within
-+/- 0.4% with 32-bit and 64-bit code running on a 2.8 GHz Intel Xeon
-W3530 and a 3.6 GHz Intel Xeon W2123.
-
-Fixes #649
---- a/simd/i386/jsimd.c
-+++ b/simd/i386/jsimd.c
-@@ -2,7 +2,7 @@
- * jsimd_i386.c
- *
- * Copyright 2009 Pierre Ossman <ossman@cendio.se> for Cendio AB
-- * Copyright (C) 2009-2011, 2013-2014, 2016, 2018, 2022, D. R. Commander.
-+ * Copyright (C) 2009-2011, 2013-2014, 2016, 2018, 2022-2023, D. R. Commander.
- * Copyright (C) 2015-2016, 2018, 2022, Matthieu Darbois.
- *
- * Based on the x86 SIMD extension for IJG JPEG library,
-@@ -158,6 +158,9 @@ jsimd_rgb_ycc_convert(j_compress_ptr cinfo, JSAMPARRAY input_buf,
- void (*sse2fct) (JDIMENSION, JSAMPARRAY, JSAMPIMAGE, JDIMENSION, int);
- void (*mmxfct) (JDIMENSION, JSAMPARRAY, JSAMPIMAGE, JDIMENSION, int);
-
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- switch (cinfo->in_color_space) {
- case JCS_EXT_RGB:
- avx2fct = jsimd_extrgb_ycc_convert_avx2;
-@@ -217,6 +220,9 @@ jsimd_rgb_gray_convert(j_compress_ptr cinfo, JSAMPARRAY input_buf,
- void (*sse2fct) (JDIMENSION, JSAMPARRAY, JSAMPIMAGE, JDIMENSION, int);
- void (*mmxfct) (JDIMENSION, JSAMPARRAY, JSAMPIMAGE, JDIMENSION, int);
-
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- switch (cinfo->in_color_space) {
- case JCS_EXT_RGB:
- avx2fct = jsimd_extrgb_gray_convert_avx2;
-@@ -276,6 +282,9 @@ jsimd_ycc_rgb_convert(j_decompress_ptr cinfo, JSAMPIMAGE input_buf,
- void (*sse2fct) (JDIMENSION, JSAMPIMAGE, JDIMENSION, JSAMPARRAY, int);
- void (*mmxfct) (JDIMENSION, JSAMPIMAGE, JDIMENSION, JSAMPARRAY, int);
-
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- switch (cinfo->out_color_space) {
- case JCS_EXT_RGB:
- avx2fct = jsimd_ycc_extrgb_convert_avx2;
-@@ -379,6 +388,9 @@ GLOBAL(void)
- jsimd_h2v2_downsample(j_compress_ptr cinfo, jpeg_component_info *compptr,
- JSAMPARRAY input_data, JSAMPARRAY output_data)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_h2v2_downsample_avx2(cinfo->image_width, cinfo->max_v_samp_factor,
- compptr->v_samp_factor,
-@@ -399,6 +411,9 @@ GLOBAL(void)
- jsimd_h2v1_downsample(j_compress_ptr cinfo, jpeg_component_info *compptr,
- JSAMPARRAY input_data, JSAMPARRAY output_data)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_h2v1_downsample_avx2(cinfo->image_width, cinfo->max_v_samp_factor,
- compptr->v_samp_factor,
-@@ -461,6 +476,9 @@ GLOBAL(void)
- jsimd_h2v2_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_h2v2_upsample_avx2(cinfo->max_v_samp_factor, cinfo->output_width,
- input_data, output_data_ptr);
-@@ -476,6 +494,9 @@ GLOBAL(void)
- jsimd_h2v1_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_h2v1_upsample_avx2(cinfo->max_v_samp_factor, cinfo->output_width,
- input_data, output_data_ptr);
-@@ -537,6 +558,9 @@ GLOBAL(void)
- jsimd_h2v2_fancy_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_h2v2_fancy_upsample_avx2(cinfo->max_v_samp_factor,
- compptr->downsampled_width, input_data,
-@@ -555,6 +579,9 @@ GLOBAL(void)
- jsimd_h2v1_fancy_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_h2v1_fancy_upsample_avx2(cinfo->max_v_samp_factor,
- compptr->downsampled_width, input_data,
-@@ -623,6 +650,9 @@ jsimd_h2v2_merged_upsample(j_decompress_ptr cinfo, JSAMPIMAGE input_buf,
- void (*sse2fct) (JDIMENSION, JSAMPIMAGE, JDIMENSION, JSAMPARRAY);
- void (*mmxfct) (JDIMENSION, JSAMPIMAGE, JDIMENSION, JSAMPARRAY);
-
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- switch (cinfo->out_color_space) {
- case JCS_EXT_RGB:
- avx2fct = jsimd_h2v2_extrgb_merged_upsample_avx2;
-@@ -681,6 +711,9 @@ jsimd_h2v1_merged_upsample(j_decompress_ptr cinfo, JSAMPIMAGE input_buf,
- void (*sse2fct) (JDIMENSION, JSAMPIMAGE, JDIMENSION, JSAMPARRAY);
- void (*mmxfct) (JDIMENSION, JSAMPIMAGE, JDIMENSION, JSAMPARRAY);
-
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- switch (cinfo->out_color_space) {
- case JCS_EXT_RGB:
- avx2fct = jsimd_h2v1_extrgb_merged_upsample_avx2;
-@@ -785,6 +818,9 @@ GLOBAL(void)
- jsimd_convsamp(JSAMPARRAY sample_data, JDIMENSION start_col,
- DCTELEM *workspace)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_convsamp_avx2(sample_data, start_col, workspace);
- else if (simd_support & JSIMD_SSE2)
-@@ -797,6 +833,9 @@ GLOBAL(void)
- jsimd_convsamp_float(JSAMPARRAY sample_data, JDIMENSION start_col,
- FAST_FLOAT *workspace)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_SSE2)
- jsimd_convsamp_float_sse2(sample_data, start_col, workspace);
- else if (simd_support & JSIMD_SSE)
-@@ -867,6 +906,9 @@ jsimd_can_fdct_float(void)
- GLOBAL(void)
- jsimd_fdct_islow(DCTELEM *data)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_fdct_islow_avx2(data);
- else if (simd_support & JSIMD_SSE2)
-@@ -878,6 +920,9 @@ jsimd_fdct_islow(DCTELEM *data)
- GLOBAL(void)
- jsimd_fdct_ifast(DCTELEM *data)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if ((simd_support & JSIMD_SSE2) && IS_ALIGNED_SSE(jconst_fdct_islow_sse2))
- jsimd_fdct_ifast_sse2(data);
- else
-@@ -887,6 +932,9 @@ jsimd_fdct_ifast(DCTELEM *data)
- GLOBAL(void)
- jsimd_fdct_float(FAST_FLOAT *data)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if ((simd_support & JSIMD_SSE) && IS_ALIGNED_SSE(jconst_fdct_float_sse))
- jsimd_fdct_float_sse(data);
- else if (simd_support & JSIMD_3DNOW)
-@@ -942,6 +990,9 @@ jsimd_can_quantize_float(void)
- GLOBAL(void)
- jsimd_quantize(JCOEFPTR coef_block, DCTELEM *divisors, DCTELEM *workspace)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_quantize_avx2(coef_block, divisors, workspace);
- else if (simd_support & JSIMD_SSE2)
-@@ -954,6 +1005,9 @@ GLOBAL(void)
- jsimd_quantize_float(JCOEFPTR coef_block, FAST_FLOAT *divisors,
- FAST_FLOAT *workspace)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_SSE2)
- jsimd_quantize_float_sse2(coef_block, divisors, workspace);
- else if (simd_support & JSIMD_SSE)
-@@ -1017,6 +1071,9 @@ jsimd_idct_2x2(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JCOEFPTR coef_block, JSAMPARRAY output_buf,
- JDIMENSION output_col)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if ((simd_support & JSIMD_SSE2) && IS_ALIGNED_SSE(jconst_idct_red_sse2))
- jsimd_idct_2x2_sse2(compptr->dct_table, coef_block, output_buf,
- output_col);
-@@ -1029,6 +1086,9 @@ jsimd_idct_4x4(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JCOEFPTR coef_block, JSAMPARRAY output_buf,
- JDIMENSION output_col)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if ((simd_support & JSIMD_SSE2) && IS_ALIGNED_SSE(jconst_idct_red_sse2))
- jsimd_idct_4x4_sse2(compptr->dct_table, coef_block, output_buf,
- output_col);
-@@ -1123,6 +1183,9 @@ jsimd_idct_islow(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JCOEFPTR coef_block, JSAMPARRAY output_buf,
- JDIMENSION output_col)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_idct_islow_avx2(compptr->dct_table, coef_block, output_buf,
- output_col);
-@@ -1139,6 +1202,9 @@ jsimd_idct_ifast(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JCOEFPTR coef_block, JSAMPARRAY output_buf,
- JDIMENSION output_col)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if ((simd_support & JSIMD_SSE2) && IS_ALIGNED_SSE(jconst_idct_ifast_sse2))
- jsimd_idct_ifast_sse2(compptr->dct_table, coef_block, output_buf,
- output_col);
-@@ -1152,6 +1218,9 @@ jsimd_idct_float(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JCOEFPTR coef_block, JSAMPARRAY output_buf,
- JDIMENSION output_col)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if ((simd_support & JSIMD_SSE2) && IS_ALIGNED_SSE(jconst_idct_float_sse2))
- jsimd_idct_float_sse2(compptr->dct_table, coef_block, output_buf,
- output_col);
---- a/simd/x86_64/jsimd.c
-+++ b/simd/x86_64/jsimd.c
-@@ -2,7 +2,7 @@
- * jsimd_x86_64.c
- *
- * Copyright 2009 Pierre Ossman <ossman@cendio.se> for Cendio AB
-- * Copyright (C) 2009-2011, 2014, 2016, 2018, 2022, D. R. Commander.
-+ * Copyright (C) 2009-2011, 2014, 2016, 2018, 2022-2023, D. R. Commander.
- * Copyright (C) 2015-2016, 2018, 2022, Matthieu Darbois.
- *
- * Based on the x86 SIMD extension for IJG JPEG library,
-@@ -145,6 +145,9 @@ jsimd_rgb_ycc_convert(j_compress_ptr cinfo, JSAMPARRAY input_buf,
- void (*avx2fct) (JDIMENSION, JSAMPARRAY, JSAMPIMAGE, JDIMENSION, int);
- void (*sse2fct) (JDIMENSION, JSAMPARRAY, JSAMPIMAGE, JDIMENSION, int);
-
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- switch (cinfo->in_color_space) {
- case JCS_EXT_RGB:
- avx2fct = jsimd_extrgb_ycc_convert_avx2;
-@@ -194,6 +197,9 @@ jsimd_rgb_gray_convert(j_compress_ptr cinfo, JSAMPARRAY input_buf,
- void (*avx2fct) (JDIMENSION, JSAMPARRAY, JSAMPIMAGE, JDIMENSION, int);
- void (*sse2fct) (JDIMENSION, JSAMPARRAY, JSAMPIMAGE, JDIMENSION, int);
-
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- switch (cinfo->in_color_space) {
- case JCS_EXT_RGB:
- avx2fct = jsimd_extrgb_gray_convert_avx2;
-@@ -243,6 +249,9 @@ jsimd_ycc_rgb_convert(j_decompress_ptr cinfo, JSAMPIMAGE input_buf,
- void (*avx2fct) (JDIMENSION, JSAMPIMAGE, JDIMENSION, JSAMPARRAY, int);
- void (*sse2fct) (JDIMENSION, JSAMPIMAGE, JDIMENSION, JSAMPARRAY, int);
-
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- switch (cinfo->out_color_space) {
- case JCS_EXT_RGB:
- avx2fct = jsimd_ycc_extrgb_convert_avx2;
-@@ -333,6 +342,9 @@ GLOBAL(void)
- jsimd_h2v2_downsample(j_compress_ptr cinfo, jpeg_component_info *compptr,
- JSAMPARRAY input_data, JSAMPARRAY output_data)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_h2v2_downsample_avx2(cinfo->image_width, cinfo->max_v_samp_factor,
- compptr->v_samp_factor,
-@@ -349,6 +361,9 @@ GLOBAL(void)
- jsimd_h2v1_downsample(j_compress_ptr cinfo, jpeg_component_info *compptr,
- JSAMPARRAY input_data, JSAMPARRAY output_data)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_h2v1_downsample_avx2(cinfo->image_width, cinfo->max_v_samp_factor,
- compptr->v_samp_factor,
-@@ -403,6 +418,9 @@ GLOBAL(void)
- jsimd_h2v2_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_h2v2_upsample_avx2(cinfo->max_v_samp_factor, cinfo->output_width,
- input_data, output_data_ptr);
-@@ -415,6 +433,9 @@ GLOBAL(void)
- jsimd_h2v1_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_h2v1_upsample_avx2(cinfo->max_v_samp_factor, cinfo->output_width,
- input_data, output_data_ptr);
-@@ -469,6 +490,9 @@ GLOBAL(void)
- jsimd_h2v2_fancy_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_h2v2_fancy_upsample_avx2(cinfo->max_v_samp_factor,
- compptr->downsampled_width, input_data,
-@@ -483,6 +507,9 @@ GLOBAL(void)
- jsimd_h2v1_fancy_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_h2v1_fancy_upsample_avx2(cinfo->max_v_samp_factor,
- compptr->downsampled_width, input_data,
-@@ -542,6 +569,9 @@ jsimd_h2v2_merged_upsample(j_decompress_ptr cinfo, JSAMPIMAGE input_buf,
- void (*avx2fct) (JDIMENSION, JSAMPIMAGE, JDIMENSION, JSAMPARRAY);
- void (*sse2fct) (JDIMENSION, JSAMPIMAGE, JDIMENSION, JSAMPARRAY);
-
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- switch (cinfo->out_color_space) {
- case JCS_EXT_RGB:
- avx2fct = jsimd_h2v2_extrgb_merged_upsample_avx2;
-@@ -590,6 +620,9 @@ jsimd_h2v1_merged_upsample(j_decompress_ptr cinfo, JSAMPIMAGE input_buf,
- void (*avx2fct) (JDIMENSION, JSAMPIMAGE, JDIMENSION, JSAMPARRAY);
- void (*sse2fct) (JDIMENSION, JSAMPIMAGE, JDIMENSION, JSAMPARRAY);
-
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- switch (cinfo->out_color_space) {
- case JCS_EXT_RGB:
- avx2fct = jsimd_h2v1_extrgb_merged_upsample_avx2;
-@@ -679,6 +712,9 @@ GLOBAL(void)
- jsimd_convsamp(JSAMPARRAY sample_data, JDIMENSION start_col,
- DCTELEM *workspace)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_convsamp_avx2(sample_data, start_col, workspace);
- else
-@@ -748,6 +784,9 @@ jsimd_can_fdct_float(void)
- GLOBAL(void)
- jsimd_fdct_islow(DCTELEM *data)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_fdct_islow_avx2(data);
- else
-@@ -809,6 +848,9 @@ jsimd_can_quantize_float(void)
- GLOBAL(void)
- jsimd_quantize(JCOEFPTR coef_block, DCTELEM *divisors, DCTELEM *workspace)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_quantize_avx2(coef_block, divisors, workspace);
- else
-@@ -963,6 +1005,9 @@ jsimd_idct_islow(j_decompress_ptr cinfo, jpeg_component_info *compptr,
- JCOEFPTR coef_block, JSAMPARRAY output_buf,
- JDIMENSION output_col)
- {
-+ if (simd_support == ~0U)
-+ init_simd();
-+
- if (simd_support & JSIMD_AVX2)
- jsimd_idct_islow_avx2(compptr->dct_table, coef_block, output_buf,
- output_col);
diff --git a/media-libs/libjpeg-turbo/libjpeg-turbo-2.1.5-r1.ebuild b/media-libs/libjpeg-turbo/libjpeg-turbo-2.1.5.1.ebuild
index e38d1e2aa16e..713c9e844e83 100644
--- a/media-libs/libjpeg-turbo/libjpeg-turbo-2.1.5-r1.ebuild
+++ b/media-libs/libjpeg-turbo/libjpeg-turbo-2.1.5.1.ebuild
@@ -41,10 +41,6 @@ BDEPEND="
x64-cygwin? ( ${ASM_DEPEND} )
"
-PATCHES=(
- "${FILESDIR}/2.1.5-initialize-simd_support-before-every-use.patch"
-)
-
MULTILIB_WRAPPED_HEADERS=( /usr/include/jconfig.h )
src_prepare() {