Add BUILD.gn and initial modifications for build
Changes are described in README.fuchsia
Change-Id: If48dbf016679e7f428e2934ed481ae94d0625e27
diff --git a/BUILD.gn b/BUILD.gn
new file mode 100644
index 0000000..61b1b41
--- /dev/null
+++ b/BUILD.gn
@@ -0,0 +1,189 @@
+# Copyright 2016 The Fuchsia Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+# Do not use the targets in this file unless you need a certain libjpeg
+# implementation. Use the meta target //third_party:jpeg instead.
+
+if (current_cpu == "arm") {
+ import("//build/config/arm.gni")
+}
+
+if (current_cpu == "x86" || current_cpu == "x64") {
+ import("//third_party/yasm/yasm_assemble.gni")
+ yasm_assemble("simd_asm") {
+ defines = []
+ if (current_cpu == "x86") {
+ sources = [
+ "simd/jccolor-mmx.asm",
+ "simd/jccolor-sse2.asm",
+ "simd/jcgray-mmx.asm",
+ "simd/jcgray-sse2.asm",
+ "simd/jchuff-sse2.asm",
+ "simd/jcsample-mmx.asm",
+ "simd/jcsample-sse2.asm",
+ "simd/jdcolor-mmx.asm",
+ "simd/jdcolor-sse2.asm",
+ "simd/jdmerge-mmx.asm",
+ "simd/jdmerge-sse2.asm",
+ "simd/jdsample-mmx.asm",
+ "simd/jdsample-sse2.asm",
+ "simd/jfdctflt-3dn.asm",
+ "simd/jfdctflt-sse.asm",
+ "simd/jfdctfst-mmx.asm",
+ "simd/jfdctfst-sse2.asm",
+ "simd/jfdctint-mmx.asm",
+ "simd/jfdctint-sse2.asm",
+ "simd/jidctflt-3dn.asm",
+ "simd/jidctflt-sse.asm",
+ "simd/jidctflt-sse2.asm",
+ "simd/jidctfst-mmx.asm",
+ "simd/jidctfst-sse2.asm",
+ "simd/jidctint-mmx.asm",
+ "simd/jidctint-sse2.asm",
+ "simd/jidctred-mmx.asm",
+ "simd/jidctred-sse2.asm",
+ "simd/jquant-3dn.asm",
+ "simd/jquant-mmx.asm",
+ "simd/jquant-sse.asm",
+ "simd/jquantf-sse2.asm",
+ "simd/jquanti-sse2.asm",
+ "simd/jsimdcpu.asm",
+ ]
+ defines += [
+ "__x86__",
+ "PIC",
+ ]
+ } else if (current_cpu == "x64") {
+ sources = [
+ "simd/jccolor-sse2-64.asm",
+ "simd/jcgray-sse2-64.asm",
+ "simd/jchuff-sse2-64.asm",
+ "simd/jcsample-sse2-64.asm",
+ "simd/jdcolor-sse2-64.asm",
+ "simd/jdmerge-sse2-64.asm",
+ "simd/jdsample-sse2-64.asm",
+ "simd/jfdctflt-sse-64.asm",
+ "simd/jfdctfst-sse2-64.asm",
+ "simd/jfdctint-sse2-64.asm",
+ "simd/jidctflt-sse2-64.asm",
+ "simd/jidctfst-sse2-64.asm",
+ "simd/jidctint-sse2-64.asm",
+ "simd/jidctred-sse2-64.asm",
+ "simd/jquantf-sse2-64.asm",
+ "simd/jquanti-sse2-64.asm",
+ ]
+ defines += [
+ "__x86_64__",
+ "PIC",
+ ]
+ }
+ if (is_linux || is_android) {
+ defines += [ "ELF" ]
+ include_dirs = [ "linux" ]
+ }
+ }
+}
+static_library("simd") {
+ if (current_cpu == "x86") {
+ deps = [
+ ":simd_asm",
+ ]
+ sources = [
+ "simd/jsimd_i386.c",
+ ]
+ } else if (current_cpu == "x64") {
+ deps = [
+ ":simd_asm",
+ ]
+ sources = [
+ "simd/jsimd_x86_64.c",
+ ]
+ } else if (current_cpu == "arm" && arm_version >= 7 &&
+ (arm_use_neon || arm_optionally_use_neon)) {
+ sources = [
+ "simd/jsimd_arm.c",
+ "simd/jsimd_arm_neon.S",
+ ]
+ } else if (current_cpu == "arm64") {
+ sources = [
+ "simd/jsimd_arm64.c",
+ "simd/jsimd_arm64_neon.S",
+ ]
+ } else {
+ sources = [
+ "jsimd_none.c",
+ ]
+ }
+}
+config("libjpeg_config") {
+ include_dirs = [ "." ]
+}
+static_library("libjpeg") {
+ sources = [
+ "jcapimin.c",
+ "jcapistd.c",
+ "jccoefct.c",
+ "jccolor.c",
+ "jcdctmgr.c",
+ "jchuff.c",
+ "jchuff.h",
+ "jcinit.c",
+ "jcmainct.c",
+ "jcmarker.c",
+ "jcmaster.c",
+ "jcomapi.c",
+ "jconfig.h",
+ "jcparam.c",
+ "jcphuff.c",
+ "jcprepct.c",
+ "jcsample.c",
+ "jdapimin.c",
+ "jdapistd.c",
+ "jdatadst.c",
+ "jdatasrc.c",
+ "jdcoefct.c",
+ "jdcolor.c",
+ "jdct.h",
+ "jddctmgr.c",
+ "jdhuff.c",
+ "jdhuff.h",
+ "jdinput.c",
+ "jdmainct.c",
+ "jdmarker.c",
+ "jdmaster.c",
+ "jdmerge.c",
+ "jdphuff.c",
+ "jdpostct.c",
+ "jdsample.c",
+ "jerror.c",
+ "jerror.h",
+ "jfdctflt.c",
+ "jfdctfst.c",
+ "jfdctint.c",
+ "jidctflt.c",
+ "jidctfst.c",
+ "jidctint.c",
+ "jidctred.c",
+ "jinclude.h",
+ "jmemmgr.c",
+ "jmemnobs.c",
+ "jmemsys.h",
+ "jmorecfg.h",
+ "jpegint.h",
+ "jpeglib.h",
+ "jquant1.c",
+ "jquant2.c",
+ "jutils.c",
+ "jversion.h",
+ ]
+ defines = [
+ "WITH_SIMD",
+ "NO_GETENV",
+ ]
+ configs += [ ":libjpeg_config" ]
+ public_configs = [ ":libjpeg_config" ]
+
+ deps = [
+ ":simd",
+ ]
+}
diff --git a/README.fuchsia b/README.fuchsia
new file mode 100644
index 0000000..a0539e0
--- /dev/null
+++ b/README.fuchsia
@@ -0,0 +1,30 @@
+Name: libjpeg-turbo
+URL: https://github.com/libjpeg-turbo/libjpeg-turbo/
+Version: 1.5.0
+License: Custom license
+License File: LICENSE.md
+Security Critical: yes
+License Android Compatible: yes
+
+Description:
+This consists of the components:
+* libjpeg-turbo 1.5.0
+* This file (README.fuchsia)
+* A build file (BUILD.gn)
+* Deleted unused directories: cmakescripts, doc, java, md5, release, sharedlib,
+ testimages, and win
+* Patched header files used by Chromium
+
+We applied the following changes which are not merged to upstream:
+
+* Added the 'private_extern' flags on Mac (or the 'hidden' flags on Linux) to
+ all the global symbols in '.asm' files to prevent making them external ones.
+ http://crbug.com/608347
+* Fix libjpeg_turbo svn r64 libjpeg6b compat issue: make the fast path Huffman
+ decoder fallback to slow decoding if the Huffman decoding bit sentinel > 16,
+ this to match the exact behavior of jpeg_huff_decode().
+ http://crbug.com/398235
+* Fixed an issue with the ARM NEON build.
+ http://crbug.com/451035
+* Configuration files jconfig.h and jconfigint.h
+ http://crbug.com/608347
diff --git a/jconfig.h b/jconfig.h
new file mode 100644
index 0000000..fe4a437
--- /dev/null
+++ b/jconfig.h
@@ -0,0 +1,71 @@
+/* jconfig.h. Generated from jconfig.h.in by configure. */
+/* Version ID for the JPEG library.
+ * Might be useful for tests like "#if JPEG_LIB_VERSION >= 60".
+ */
+#define JPEG_LIB_VERSION 62
+
+/* libjpeg-turbo version */
+#define LIBJPEG_TURBO_VERSION 1.4.2
+
+/* Support arithmetic encoding */
+/* #define C_ARITH_CODING_SUPPORTED 1 */
+
+/* Support arithmetic decoding */
+/* #define D_ARITH_CODING_SUPPORTED 1 */
+
+/*
+ * Define BITS_IN_JSAMPLE as either
+ * 8 for 8-bit sample values (the usual setting)
+ * 12 for 12-bit sample values
+ * Only 8 and 12 are legal data precisions for lossy JPEG according to the
+ * JPEG standard, and the IJG code does not support anything else!
+ * We do not support run-time selection of data precision, sorry.
+ */
+
+#define BITS_IN_JSAMPLE 8 /* use 8 or 12 */
+
+/* Define to 1 if you have the <locale.h> header file. */
+#define HAVE_LOCALE_H 1
+
+/* Define to 1 if you have the <stddef.h> header file. */
+#define HAVE_STDDEF_H 1
+
+/* Define to 1 if you have the <stdlib.h> header file. */
+#define HAVE_STDLIB_H 1
+
+/* Define to 1 if the system has the type `unsigned char'. */
+#define HAVE_UNSIGNED_CHAR 1
+
+/* Define to 1 if the system has the type `unsigned short'. */
+#define HAVE_UNSIGNED_SHORT 1
+
+/* Compiler does not support pointers to undefined structures. */
+/* #undef INCOMPLETE_TYPES_BROKEN */
+
+/* Support in-memory source/destination managers */
+/* #undef MEM_SRCDST_SUPPORTED */
+
+/* Define if you have BSD-like bzero and bcopy in <strings.h> rather than
+ memset/memcpy in <string.h>. */
+/* #undef NEED_BSD_STRINGS */
+
+/* Define if you need to include <sys/types.h> to get size_t. */
+/* #undef NEED_SYS_TYPES_H 1 */
+
+/* Define if your (broken) compiler shifts signed values as if they were
+ unsigned. */
+/* #undef RIGHT_SHIFT_IS_UNSIGNED */
+
+/* Use accelerated SIMD routines. */
+#define WITH_SIMD 1
+
+/* Define to 1 if type `char' is unsigned and you are not using gcc. */
+#ifndef __CHAR_UNSIGNED__
+/* # undef __CHAR_UNSIGNED__ */
+#endif
+
+/* Define to empty if `const' does not conform to ANSI C. */
+/* #undef const */
+
+/* Define to `unsigned int' if <sys/types.h> does not define. */
+/* #undef size_t */
diff --git a/jconfigint.h b/jconfigint.h
new file mode 100644
index 0000000..99bfd4f
--- /dev/null
+++ b/jconfigint.h
@@ -0,0 +1,27 @@
+/* jconfigint.h. Generated from jconfigint.h.in by configure. */
+/* libjpeg-turbo build number */
+#define BUILD ""
+
+/* How to obtain function inlining. */
+#ifndef INLINE
+#if defined(__GNUC__)
+#define INLINE inline __attribute__((always_inline))
+#elif defined(_MSC_VER)
+#define INLINE __forceinline
+#else
+#define INLINE
+#endif
+#endif
+
+/* Define to the full name of this package. */
+#define PACKAGE_NAME "libjpeg-turbo"
+
+/* Version number of package */
+#define VERSION "1.4.90"
+
+/* The size of `size_t', as computed by sizeof. */
+#if __WORDSIZE==64 || defined(_WIN64)
+#define SIZEOF_SIZE_T 8
+#else
+#define SIZEOF_SIZE_T 4
+#endif
diff --git a/jdhuff.c b/jdhuff.c
index 338f2a4..3c6fdaf 100644
--- a/jdhuff.c
+++ b/jdhuff.c
@@ -669,7 +669,7 @@
d_derived_tbl *actbl = entropy->ac_cur_tbls[blkn];
register int s, k, r, l;
- HUFF_DECODE_FAST(s, l, dctbl);
+ HUFF_DECODE_FAST(s, l, dctbl, slow_decode_mcu);
if (s) {
FILL_BIT_BUFFER_FAST
r = GET_BITS(s);
@@ -687,7 +687,7 @@
if (entropy->ac_needed[blkn] && block) {
for (k = 1; k < DCTSIZE2; k++) {
- HUFF_DECODE_FAST(s, l, actbl);
+ HUFF_DECODE_FAST(s, l, actbl, slow_decode_mcu);
r = s >> 4;
s &= 15;
@@ -706,7 +706,7 @@
} else {
for (k = 1; k < DCTSIZE2; k++) {
- HUFF_DECODE_FAST(s, l, actbl);
+ HUFF_DECODE_FAST(s, l, actbl, slow_decode_mcu);
r = s >> 4;
s &= 15;
@@ -723,6 +723,7 @@
}
if (cinfo->unread_marker != 0) {
+slow_decode_mcu:
cinfo->unread_marker = 0;
return FALSE;
}
diff --git a/jdhuff.h b/jdhuff.h
index 87d4465..3f15d71 100644
--- a/jdhuff.h
+++ b/jdhuff.h
@@ -208,7 +208,7 @@
} \
}
-#define HUFF_DECODE_FAST(s,nb,htbl) \
+#define HUFF_DECODE_FAST(s,nb,htbl,slowlabel) \
FILL_BIT_BUFFER_FAST; \
s = PEEK_BITS(HUFF_LOOKAHEAD); \
s = htbl->lookup[s]; \
@@ -225,7 +225,9 @@
s |= GET_BITS(1); \
nb++; \
} \
- s = htbl->pub->huffval[ (int) (s + htbl->valoffset[nb]) & 0xFF ]; \
+ if (nb > 16) \
+ goto slowlabel; \
+ s = htbl->pub->huffval[ (int) (s + htbl->valoffset[nb]) ]; \
}
/* Out-of-line case for Huffman code fetching */
diff --git a/simd/jccolext-mmx.asm b/simd/jccolext-mmx.asm
index 96a0372..bfc9eca 100644
--- a/simd/jccolext-mmx.asm
+++ b/simd/jccolext-mmx.asm
@@ -39,7 +39,7 @@
%define gotptr wk(0)-SIZEOF_POINTER ; void * gotptr
align 16
- global EXTN(jsimd_rgb_ycc_convert_mmx)
+ global EXTN(jsimd_rgb_ycc_convert_mmx) PRIVATE
EXTN(jsimd_rgb_ycc_convert_mmx):
push ebp
diff --git a/simd/jccolext-sse2-64.asm b/simd/jccolext-sse2-64.asm
index 8e4642d..a8142c6 100644
--- a/simd/jccolext-sse2-64.asm
+++ b/simd/jccolext-sse2-64.asm
@@ -38,7 +38,7 @@
align 16
- global EXTN(jsimd_rgb_ycc_convert_sse2)
+ global EXTN(jsimd_rgb_ycc_convert_sse2) PRIVATE
EXTN(jsimd_rgb_ycc_convert_sse2):
push rbp
diff --git a/simd/jccolext-sse2.asm b/simd/jccolext-sse2.asm
index cc38e98..0101460 100644
--- a/simd/jccolext-sse2.asm
+++ b/simd/jccolext-sse2.asm
@@ -38,7 +38,7 @@
align 16
- global EXTN(jsimd_rgb_ycc_convert_sse2)
+ global EXTN(jsimd_rgb_ycc_convert_sse2) PRIVATE
EXTN(jsimd_rgb_ycc_convert_sse2):
push ebp
diff --git a/simd/jccolor-mmx.asm b/simd/jccolor-mmx.asm
index c4e6d88..ffb394c 100644
--- a/simd/jccolor-mmx.asm
+++ b/simd/jccolor-mmx.asm
@@ -36,7 +36,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_rgb_ycc_convert_mmx)
+ global EXTN(jconst_rgb_ycc_convert_mmx) PRIVATE
EXTN(jconst_rgb_ycc_convert_mmx):
diff --git a/simd/jccolor-sse2-64.asm b/simd/jccolor-sse2-64.asm
index bd2188b..2aeaa25 100644
--- a/simd/jccolor-sse2-64.asm
+++ b/simd/jccolor-sse2-64.asm
@@ -35,7 +35,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_rgb_ycc_convert_sse2)
+ global EXTN(jconst_rgb_ycc_convert_sse2) PRIVATE
EXTN(jconst_rgb_ycc_convert_sse2):
diff --git a/simd/jccolor-sse2.asm b/simd/jccolor-sse2.asm
index 13124d1..b750b65 100644
--- a/simd/jccolor-sse2.asm
+++ b/simd/jccolor-sse2.asm
@@ -35,7 +35,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_rgb_ycc_convert_sse2)
+ global EXTN(jconst_rgb_ycc_convert_sse2) PRIVATE
EXTN(jconst_rgb_ycc_convert_sse2):
diff --git a/simd/jcgray-mmx.asm b/simd/jcgray-mmx.asm
index 0819b6c..046cec7 100644
--- a/simd/jcgray-mmx.asm
+++ b/simd/jcgray-mmx.asm
@@ -32,7 +32,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_rgb_gray_convert_mmx)
+ global EXTN(jconst_rgb_gray_convert_mmx) PRIVATE
EXTN(jconst_rgb_gray_convert_mmx):
diff --git a/simd/jcgray-sse2-64.asm b/simd/jcgray-sse2-64.asm
index bafd302..e0c3a8b 100644
--- a/simd/jcgray-sse2-64.asm
+++ b/simd/jcgray-sse2-64.asm
@@ -31,7 +31,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_rgb_gray_convert_sse2)
+ global EXTN(jconst_rgb_gray_convert_sse2) PRIVATE
EXTN(jconst_rgb_gray_convert_sse2):
diff --git a/simd/jcgray-sse2.asm b/simd/jcgray-sse2.asm
index 5b0b466..d9813a2 100644
--- a/simd/jcgray-sse2.asm
+++ b/simd/jcgray-sse2.asm
@@ -31,7 +31,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_rgb_gray_convert_sse2)
+ global EXTN(jconst_rgb_gray_convert_sse2) PRIVATE
EXTN(jconst_rgb_gray_convert_sse2):
diff --git a/simd/jcgryext-mmx.asm b/simd/jcgryext-mmx.asm
index 1c1b8d8..1f74713 100644
--- a/simd/jcgryext-mmx.asm
+++ b/simd/jcgryext-mmx.asm
@@ -40,7 +40,7 @@
%define gotptr wk(0)-SIZEOF_POINTER ; void * gotptr
align 16
- global EXTN(jsimd_rgb_gray_convert_mmx)
+ global EXTN(jsimd_rgb_gray_convert_mmx) PRIVATE
EXTN(jsimd_rgb_gray_convert_mmx):
push ebp
diff --git a/simd/jcgryext-sse2-64.asm b/simd/jcgryext-sse2-64.asm
index 541355a..33e1749 100644
--- a/simd/jcgryext-sse2-64.asm
+++ b/simd/jcgryext-sse2-64.asm
@@ -38,7 +38,7 @@
align 16
- global EXTN(jsimd_rgb_gray_convert_sse2)
+ global EXTN(jsimd_rgb_gray_convert_sse2) PRIVATE
EXTN(jsimd_rgb_gray_convert_sse2):
push rbp
diff --git a/simd/jcgryext-sse2.asm b/simd/jcgryext-sse2.asm
index cd16dd1..2441ceb 100644
--- a/simd/jcgryext-sse2.asm
+++ b/simd/jcgryext-sse2.asm
@@ -40,7 +40,7 @@
align 16
- global EXTN(jsimd_rgb_gray_convert_sse2)
+ global EXTN(jsimd_rgb_gray_convert_sse2) PRIVATE
EXTN(jsimd_rgb_gray_convert_sse2):
push ebp
diff --git a/simd/jchuff-sse2-64.asm b/simd/jchuff-sse2-64.asm
index b1144d1..b86b576 100644
--- a/simd/jchuff-sse2-64.asm
+++ b/simd/jchuff-sse2-64.asm
@@ -26,7 +26,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_huff_encode_one_block)
+ global EXTN(jconst_huff_encode_one_block) PRIVATE
EXTN(jconst_huff_encode_one_block):
@@ -183,7 +183,7 @@
%define buffer rax
align 16
- global EXTN(jsimd_huff_encode_one_block_sse2)
+ global EXTN(jsimd_huff_encode_one_block_sse2) PRIVATE
EXTN(jsimd_huff_encode_one_block_sse2):
push rbp
diff --git a/simd/jchuff-sse2.asm b/simd/jchuff-sse2.asm
index 36d1f2d..cf8f8c6 100644
--- a/simd/jchuff-sse2.asm
+++ b/simd/jchuff-sse2.asm
@@ -26,7 +26,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_huff_encode_one_block)
+ global EXTN(jconst_huff_encode_one_block) PRIVATE
EXTN(jconst_huff_encode_one_block):
@@ -179,7 +179,7 @@
%define put_bits edi
align 16
- global EXTN(jsimd_huff_encode_one_block_sse2)
+ global EXTN(jsimd_huff_encode_one_block_sse2) PRIVATE
EXTN(jsimd_huff_encode_one_block_sse2):
push ebp
diff --git a/simd/jcsample-mmx.asm b/simd/jcsample-mmx.asm
index 6cd544e..77ea06e 100644
--- a/simd/jcsample-mmx.asm
+++ b/simd/jcsample-mmx.asm
@@ -39,7 +39,7 @@
%define output_data(b) (b)+28 ; JSAMPARRAY output_data
align 16
- global EXTN(jsimd_h2v1_downsample_mmx)
+ global EXTN(jsimd_h2v1_downsample_mmx) PRIVATE
EXTN(jsimd_h2v1_downsample_mmx):
push ebp
@@ -181,7 +181,7 @@
%define output_data(b) (b)+28 ; JSAMPARRAY output_data
align 16
- global EXTN(jsimd_h2v2_downsample_mmx)
+ global EXTN(jsimd_h2v2_downsample_mmx) PRIVATE
EXTN(jsimd_h2v2_downsample_mmx):
push ebp
diff --git a/simd/jcsample-sse2-64.asm b/simd/jcsample-sse2-64.asm
index 40ee15f..281a97f 100644
--- a/simd/jcsample-sse2-64.asm
+++ b/simd/jcsample-sse2-64.asm
@@ -40,7 +40,7 @@
; r15 = JSAMPARRAY output_data
align 16
- global EXTN(jsimd_h2v1_downsample_sse2)
+ global EXTN(jsimd_h2v1_downsample_sse2) PRIVATE
EXTN(jsimd_h2v1_downsample_sse2):
push rbp
@@ -184,7 +184,7 @@
; r15 = JSAMPARRAY output_data
align 16
- global EXTN(jsimd_h2v2_downsample_sse2)
+ global EXTN(jsimd_h2v2_downsample_sse2) PRIVATE
EXTN(jsimd_h2v2_downsample_sse2):
push rbp
diff --git a/simd/jcsample-sse2.asm b/simd/jcsample-sse2.asm
index 83c9d15..ac02e21 100644
--- a/simd/jcsample-sse2.asm
+++ b/simd/jcsample-sse2.asm
@@ -39,7 +39,7 @@
%define output_data(b) (b)+28 ; JSAMPARRAY output_data
align 16
- global EXTN(jsimd_h2v1_downsample_sse2)
+ global EXTN(jsimd_h2v1_downsample_sse2) PRIVATE
EXTN(jsimd_h2v1_downsample_sse2):
push ebp
@@ -194,7 +194,7 @@
%define output_data(b) (b)+28 ; JSAMPARRAY output_data
align 16
- global EXTN(jsimd_h2v2_downsample_sse2)
+ global EXTN(jsimd_h2v2_downsample_sse2) PRIVATE
EXTN(jsimd_h2v2_downsample_sse2):
push ebp
diff --git a/simd/jdcolext-mmx.asm b/simd/jdcolext-mmx.asm
index 21e34f6..3702420 100644
--- a/simd/jdcolext-mmx.asm
+++ b/simd/jdcolext-mmx.asm
@@ -39,7 +39,7 @@
%define gotptr wk(0)-SIZEOF_POINTER ; void * gotptr
align 16
- global EXTN(jsimd_ycc_rgb_convert_mmx)
+ global EXTN(jsimd_ycc_rgb_convert_mmx) PRIVATE
EXTN(jsimd_ycc_rgb_convert_mmx):
push ebp
diff --git a/simd/jdcolext-sse2-64.asm b/simd/jdcolext-sse2-64.asm
index 4634066..0adf076 100644
--- a/simd/jdcolext-sse2-64.asm
+++ b/simd/jdcolext-sse2-64.asm
@@ -38,7 +38,7 @@
%define WK_NUM 2
align 16
- global EXTN(jsimd_ycc_rgb_convert_sse2)
+ global EXTN(jsimd_ycc_rgb_convert_sse2) PRIVATE
EXTN(jsimd_ycc_rgb_convert_sse2):
push rbp
diff --git a/simd/jdcolext-sse2.asm b/simd/jdcolext-sse2.asm
index 682aef3..0c5190a 100644
--- a/simd/jdcolext-sse2.asm
+++ b/simd/jdcolext-sse2.asm
@@ -40,7 +40,7 @@
%define gotptr wk(0)-SIZEOF_POINTER ; void * gotptr
align 16
- global EXTN(jsimd_ycc_rgb_convert_sse2)
+ global EXTN(jsimd_ycc_rgb_convert_sse2) PRIVATE
EXTN(jsimd_ycc_rgb_convert_sse2):
push ebp
diff --git a/simd/jdcolor-mmx.asm b/simd/jdcolor-mmx.asm
index 4e58031..6bb44b8 100644
--- a/simd/jdcolor-mmx.asm
+++ b/simd/jdcolor-mmx.asm
@@ -34,7 +34,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_ycc_rgb_convert_mmx)
+ global EXTN(jconst_ycc_rgb_convert_mmx) PRIVATE
EXTN(jconst_ycc_rgb_convert_mmx):
diff --git a/simd/jdcolor-sse2-64.asm b/simd/jdcolor-sse2-64.asm
index d2bf210..ed7b93d 100644
--- a/simd/jdcolor-sse2-64.asm
+++ b/simd/jdcolor-sse2-64.asm
@@ -34,7 +34,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_ycc_rgb_convert_sse2)
+ global EXTN(jconst_ycc_rgb_convert_sse2) PRIVATE
EXTN(jconst_ycc_rgb_convert_sse2):
diff --git a/simd/jdcolor-sse2.asm b/simd/jdcolor-sse2.asm
index 7ff5d05..b166598 100644
--- a/simd/jdcolor-sse2.asm
+++ b/simd/jdcolor-sse2.asm
@@ -34,7 +34,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_ycc_rgb_convert_sse2)
+ global EXTN(jconst_ycc_rgb_convert_sse2) PRIVATE
EXTN(jconst_ycc_rgb_convert_sse2):
diff --git a/simd/jdmerge-mmx.asm b/simd/jdmerge-mmx.asm
index ee58bff..86482c4 100644
--- a/simd/jdmerge-mmx.asm
+++ b/simd/jdmerge-mmx.asm
@@ -34,7 +34,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_merged_upsample_mmx)
+ global EXTN(jconst_merged_upsample_mmx) PRIVATE
EXTN(jconst_merged_upsample_mmx):
diff --git a/simd/jdmerge-sse2-64.asm b/simd/jdmerge-sse2-64.asm
index 244bd40..ab03d47 100644
--- a/simd/jdmerge-sse2-64.asm
+++ b/simd/jdmerge-sse2-64.asm
@@ -34,7 +34,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_merged_upsample_sse2)
+ global EXTN(jconst_merged_upsample_sse2) PRIVATE
EXTN(jconst_merged_upsample_sse2):
diff --git a/simd/jdmerge-sse2.asm b/simd/jdmerge-sse2.asm
index 236de5a..12f59ec 100644
--- a/simd/jdmerge-sse2.asm
+++ b/simd/jdmerge-sse2.asm
@@ -34,7 +34,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_merged_upsample_sse2)
+ global EXTN(jconst_merged_upsample_sse2) PRIVATE
EXTN(jconst_merged_upsample_sse2):
diff --git a/simd/jdmrgext-mmx.asm b/simd/jdmrgext-mmx.asm
index 63f45cf..f429511 100644
--- a/simd/jdmrgext-mmx.asm
+++ b/simd/jdmrgext-mmx.asm
@@ -39,7 +39,7 @@
%define gotptr wk(0)-SIZEOF_POINTER ; void * gotptr
align 16
- global EXTN(jsimd_h2v1_merged_upsample_mmx)
+ global EXTN(jsimd_h2v1_merged_upsample_mmx) PRIVATE
EXTN(jsimd_h2v1_merged_upsample_mmx):
push ebp
@@ -408,7 +408,7 @@
%define output_buf(b) (b)+20 ; JSAMPARRAY output_buf
align 16
- global EXTN(jsimd_h2v2_merged_upsample_mmx)
+ global EXTN(jsimd_h2v2_merged_upsample_mmx) PRIVATE
EXTN(jsimd_h2v2_merged_upsample_mmx):
push ebp
diff --git a/simd/jdmrgext-sse2-64.asm b/simd/jdmrgext-sse2-64.asm
index ad74c5f..8c3ff3d 100644
--- a/simd/jdmrgext-sse2-64.asm
+++ b/simd/jdmrgext-sse2-64.asm
@@ -38,7 +38,7 @@
%define WK_NUM 3
align 16
- global EXTN(jsimd_h2v1_merged_upsample_sse2)
+ global EXTN(jsimd_h2v1_merged_upsample_sse2) PRIVATE
EXTN(jsimd_h2v1_merged_upsample_sse2):
push rbp
@@ -445,7 +445,7 @@
; r13 = JSAMPARRAY output_buf
align 16
- global EXTN(jsimd_h2v2_merged_upsample_sse2)
+ global EXTN(jsimd_h2v2_merged_upsample_sse2) PRIVATE
EXTN(jsimd_h2v2_merged_upsample_sse2):
push rbp
diff --git a/simd/jdmrgext-sse2.asm b/simd/jdmrgext-sse2.asm
index b50f698..456e0d0 100644
--- a/simd/jdmrgext-sse2.asm
+++ b/simd/jdmrgext-sse2.asm
@@ -40,7 +40,7 @@
%define gotptr wk(0)-SIZEOF_POINTER ; void * gotptr
align 16
- global EXTN(jsimd_h2v1_merged_upsample_sse2)
+ global EXTN(jsimd_h2v1_merged_upsample_sse2) PRIVATE
EXTN(jsimd_h2v1_merged_upsample_sse2):
push ebp
@@ -463,7 +463,7 @@
%define output_buf(b) (b)+20 ; JSAMPARRAY output_buf
align 16
- global EXTN(jsimd_h2v2_merged_upsample_sse2)
+ global EXTN(jsimd_h2v2_merged_upsample_sse2) PRIVATE
EXTN(jsimd_h2v2_merged_upsample_sse2):
push ebp
diff --git a/simd/jdsample-mmx.asm b/simd/jdsample-mmx.asm
index 5e4fa7a..bdd9239 100644
--- a/simd/jdsample-mmx.asm
+++ b/simd/jdsample-mmx.asm
@@ -21,7 +21,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_fancy_upsample_mmx)
+ global EXTN(jconst_fancy_upsample_mmx) PRIVATE
EXTN(jconst_fancy_upsample_mmx):
@@ -57,7 +57,7 @@
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
align 16
- global EXTN(jsimd_h2v1_fancy_upsample_mmx)
+ global EXTN(jsimd_h2v1_fancy_upsample_mmx) PRIVATE
EXTN(jsimd_h2v1_fancy_upsample_mmx):
push ebp
@@ -215,7 +215,7 @@
%define gotptr wk(0)-SIZEOF_POINTER ; void *gotptr
align 16
- global EXTN(jsimd_h2v2_fancy_upsample_mmx)
+ global EXTN(jsimd_h2v2_fancy_upsample_mmx) PRIVATE
EXTN(jsimd_h2v2_fancy_upsample_mmx):
push ebp
@@ -541,7 +541,7 @@
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
align 16
- global EXTN(jsimd_h2v1_upsample_mmx)
+ global EXTN(jsimd_h2v1_upsample_mmx) PRIVATE
EXTN(jsimd_h2v1_upsample_mmx):
push ebp
@@ -642,7 +642,7 @@
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
align 16
- global EXTN(jsimd_h2v2_upsample_mmx)
+ global EXTN(jsimd_h2v2_upsample_mmx) PRIVATE
EXTN(jsimd_h2v2_upsample_mmx):
push ebp
diff --git a/simd/jdsample-sse2-64.asm b/simd/jdsample-sse2-64.asm
index 1faaed6..9feb524 100644
--- a/simd/jdsample-sse2-64.asm
+++ b/simd/jdsample-sse2-64.asm
@@ -22,7 +22,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_fancy_upsample_sse2)
+ global EXTN(jconst_fancy_upsample_sse2) PRIVATE
EXTN(jconst_fancy_upsample_sse2):
@@ -58,7 +58,7 @@
; r13 = JSAMPARRAY *output_data_ptr
align 16
- global EXTN(jsimd_h2v1_fancy_upsample_sse2)
+ global EXTN(jsimd_h2v1_fancy_upsample_sse2) PRIVATE
EXTN(jsimd_h2v1_fancy_upsample_sse2):
push rbp
@@ -200,7 +200,7 @@
%define WK_NUM 4
align 16
- global EXTN(jsimd_h2v2_fancy_upsample_sse2)
+ global EXTN(jsimd_h2v2_fancy_upsample_sse2) PRIVATE
EXTN(jsimd_h2v2_fancy_upsample_sse2):
push rbp
@@ -497,7 +497,7 @@
; r13 = JSAMPARRAY *output_data_ptr
align 16
- global EXTN(jsimd_h2v1_upsample_sse2)
+ global EXTN(jsimd_h2v1_upsample_sse2) PRIVATE
EXTN(jsimd_h2v1_upsample_sse2):
push rbp
@@ -586,7 +586,7 @@
; r13 = JSAMPARRAY *output_data_ptr
align 16
- global EXTN(jsimd_h2v2_upsample_sse2)
+ global EXTN(jsimd_h2v2_upsample_sse2) PRIVATE
EXTN(jsimd_h2v2_upsample_sse2):
push rbp
diff --git a/simd/jdsample-sse2.asm b/simd/jdsample-sse2.asm
index 1d0059e..1a33f13 100644
--- a/simd/jdsample-sse2.asm
+++ b/simd/jdsample-sse2.asm
@@ -21,7 +21,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_fancy_upsample_sse2)
+ global EXTN(jconst_fancy_upsample_sse2) PRIVATE
EXTN(jconst_fancy_upsample_sse2):
@@ -57,7 +57,7 @@
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
align 16
- global EXTN(jsimd_h2v1_fancy_upsample_sse2)
+ global EXTN(jsimd_h2v1_fancy_upsample_sse2) PRIVATE
EXTN(jsimd_h2v1_fancy_upsample_sse2):
push ebp
@@ -213,7 +213,7 @@
%define gotptr wk(0)-SIZEOF_POINTER ; void *gotptr
align 16
- global EXTN(jsimd_h2v2_fancy_upsample_sse2)
+ global EXTN(jsimd_h2v2_fancy_upsample_sse2) PRIVATE
EXTN(jsimd_h2v2_fancy_upsample_sse2):
push ebp
@@ -537,7 +537,7 @@
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
align 16
- global EXTN(jsimd_h2v1_upsample_sse2)
+ global EXTN(jsimd_h2v1_upsample_sse2) PRIVATE
EXTN(jsimd_h2v1_upsample_sse2):
push ebp
@@ -636,7 +636,7 @@
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
align 16
- global EXTN(jsimd_h2v2_upsample_sse2)
+ global EXTN(jsimd_h2v2_upsample_sse2) PRIVATE
EXTN(jsimd_h2v2_upsample_sse2):
push ebp
diff --git a/simd/jfdctflt-3dn.asm b/simd/jfdctflt-3dn.asm
index 2191618..e4f3a60 100644
--- a/simd/jfdctflt-3dn.asm
+++ b/simd/jfdctflt-3dn.asm
@@ -26,7 +26,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_fdct_float_3dnow)
+ global EXTN(jconst_fdct_float_3dnow) PRIVATE
EXTN(jconst_fdct_float_3dnow):
@@ -54,7 +54,7 @@
%define WK_NUM 2
align 16
- global EXTN(jsimd_fdct_float_3dnow)
+ global EXTN(jsimd_fdct_float_3dnow) PRIVATE
EXTN(jsimd_fdct_float_3dnow):
push ebp
diff --git a/simd/jfdctflt-sse-64.asm b/simd/jfdctflt-sse-64.asm
index 4b64ea4..ab09999 100644
--- a/simd/jfdctflt-sse-64.asm
+++ b/simd/jfdctflt-sse-64.asm
@@ -37,7 +37,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_fdct_float_sse)
+ global EXTN(jconst_fdct_float_sse) PRIVATE
EXTN(jconst_fdct_float_sse):
@@ -64,7 +64,7 @@
%define WK_NUM 2
align 16
- global EXTN(jsimd_fdct_float_sse)
+ global EXTN(jsimd_fdct_float_sse) PRIVATE
EXTN(jsimd_fdct_float_sse):
push rbp
diff --git a/simd/jfdctflt-sse.asm b/simd/jfdctflt-sse.asm
index e7ede26..cd407d4 100644
--- a/simd/jfdctflt-sse.asm
+++ b/simd/jfdctflt-sse.asm
@@ -36,7 +36,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_fdct_float_sse)
+ global EXTN(jconst_fdct_float_sse) PRIVATE
EXTN(jconst_fdct_float_sse):
@@ -64,7 +64,7 @@
%define WK_NUM 2
align 16
- global EXTN(jsimd_fdct_float_sse)
+ global EXTN(jsimd_fdct_float_sse) PRIVATE
EXTN(jsimd_fdct_float_sse):
push ebp
diff --git a/simd/jfdctfst-mmx.asm b/simd/jfdctfst-mmx.asm
index eb2eb9c..29ca846 100644
--- a/simd/jfdctfst-mmx.asm
+++ b/simd/jfdctfst-mmx.asm
@@ -51,7 +51,7 @@
%define CONST_SHIFT (16 - PRE_MULTIPLY_SCALE_BITS - CONST_BITS)
alignz 16
- global EXTN(jconst_fdct_ifast_mmx)
+ global EXTN(jconst_fdct_ifast_mmx) PRIVATE
EXTN(jconst_fdct_ifast_mmx):
@@ -79,7 +79,7 @@
%define WK_NUM 2
align 16
- global EXTN(jsimd_fdct_ifast_mmx)
+ global EXTN(jsimd_fdct_ifast_mmx) PRIVATE
EXTN(jsimd_fdct_ifast_mmx):
push ebp
diff --git a/simd/jfdctfst-sse2-64.asm b/simd/jfdctfst-sse2-64.asm
index 4c96685..1d412dc 100644
--- a/simd/jfdctfst-sse2-64.asm
+++ b/simd/jfdctfst-sse2-64.asm
@@ -52,7 +52,7 @@
%define CONST_SHIFT (16 - PRE_MULTIPLY_SCALE_BITS - CONST_BITS)
alignz 16
- global EXTN(jconst_fdct_ifast_sse2)
+ global EXTN(jconst_fdct_ifast_sse2) PRIVATE
EXTN(jconst_fdct_ifast_sse2):
@@ -79,7 +79,7 @@
%define WK_NUM 2
align 16
- global EXTN(jsimd_fdct_ifast_sse2)
+ global EXTN(jsimd_fdct_ifast_sse2) PRIVATE
EXTN(jsimd_fdct_ifast_sse2):
push rbp
diff --git a/simd/jfdctfst-sse2.asm b/simd/jfdctfst-sse2.asm
index 54856a2..3068b4e 100644
--- a/simd/jfdctfst-sse2.asm
+++ b/simd/jfdctfst-sse2.asm
@@ -51,7 +51,7 @@
%define CONST_SHIFT (16 - PRE_MULTIPLY_SCALE_BITS - CONST_BITS)
alignz 16
- global EXTN(jconst_fdct_ifast_sse2)
+ global EXTN(jconst_fdct_ifast_sse2) PRIVATE
EXTN(jconst_fdct_ifast_sse2):
@@ -79,7 +79,7 @@
%define WK_NUM 2
align 16
- global EXTN(jsimd_fdct_ifast_sse2)
+ global EXTN(jsimd_fdct_ifast_sse2) PRIVATE
EXTN(jsimd_fdct_ifast_sse2):
push ebp
diff --git a/simd/jfdctint-mmx.asm b/simd/jfdctint-mmx.asm
index 9142ad8..ff06a4a 100644
--- a/simd/jfdctint-mmx.asm
+++ b/simd/jfdctint-mmx.asm
@@ -65,7 +65,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_fdct_islow_mmx)
+ global EXTN(jconst_fdct_islow_mmx) PRIVATE
EXTN(jconst_fdct_islow_mmx):
@@ -100,7 +100,7 @@
%define WK_NUM 2
align 16
- global EXTN(jsimd_fdct_islow_mmx)
+ global EXTN(jsimd_fdct_islow_mmx) PRIVATE
EXTN(jsimd_fdct_islow_mmx):
push ebp
diff --git a/simd/jfdctint-sse2-64.asm b/simd/jfdctint-sse2-64.asm
index 9a0ca0f..361e88f 100644
--- a/simd/jfdctint-sse2-64.asm
+++ b/simd/jfdctint-sse2-64.asm
@@ -66,7 +66,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_fdct_islow_sse2)
+ global EXTN(jconst_fdct_islow_sse2) PRIVATE
EXTN(jconst_fdct_islow_sse2):
@@ -100,7 +100,7 @@
%define WK_NUM 6
align 16
- global EXTN(jsimd_fdct_islow_sse2)
+ global EXTN(jsimd_fdct_islow_sse2) PRIVATE
EXTN(jsimd_fdct_islow_sse2):
push rbp
diff --git a/simd/jfdctint-sse2.asm b/simd/jfdctint-sse2.asm
index db9d0bb..fcbbb23 100644
--- a/simd/jfdctint-sse2.asm
+++ b/simd/jfdctint-sse2.asm
@@ -65,7 +65,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_fdct_islow_sse2)
+ global EXTN(jconst_fdct_islow_sse2) PRIVATE
EXTN(jconst_fdct_islow_sse2):
@@ -100,7 +100,7 @@
%define WK_NUM 6
align 16
- global EXTN(jsimd_fdct_islow_sse2)
+ global EXTN(jsimd_fdct_islow_sse2) PRIVATE
EXTN(jsimd_fdct_islow_sse2):
push ebp
diff --git a/simd/jidctflt-3dn.asm b/simd/jidctflt-3dn.asm
index 99356f2..786ebdc 100644
--- a/simd/jidctflt-3dn.asm
+++ b/simd/jidctflt-3dn.asm
@@ -26,7 +26,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_idct_float_3dnow)
+ global EXTN(jconst_idct_float_3dnow) PRIVATE
EXTN(jconst_idct_float_3dnow):
@@ -62,7 +62,7 @@
; FAST_FLOAT workspace[DCTSIZE2]
align 16
- global EXTN(jsimd_idct_float_3dnow)
+ global EXTN(jsimd_idct_float_3dnow) PRIVATE
EXTN(jsimd_idct_float_3dnow):
push ebp
diff --git a/simd/jidctflt-sse.asm b/simd/jidctflt-sse.asm
index 4d4af2f..e91957b 100644
--- a/simd/jidctflt-sse.asm
+++ b/simd/jidctflt-sse.asm
@@ -36,7 +36,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_idct_float_sse)
+ global EXTN(jconst_idct_float_sse) PRIVATE
EXTN(jconst_idct_float_sse):
@@ -72,7 +72,7 @@
; FAST_FLOAT workspace[DCTSIZE2]
align 16
- global EXTN(jsimd_idct_float_sse)
+ global EXTN(jsimd_idct_float_sse) PRIVATE
EXTN(jsimd_idct_float_sse):
push ebp
diff --git a/simd/jidctflt-sse2-64.asm b/simd/jidctflt-sse2-64.asm
index bdda05d..c84ec1e 100644
--- a/simd/jidctflt-sse2-64.asm
+++ b/simd/jidctflt-sse2-64.asm
@@ -37,7 +37,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_idct_float_sse2)
+ global EXTN(jconst_idct_float_sse2) PRIVATE
EXTN(jconst_idct_float_sse2):
@@ -73,7 +73,7 @@
; FAST_FLOAT workspace[DCTSIZE2]
align 16
- global EXTN(jsimd_idct_float_sse2)
+ global EXTN(jsimd_idct_float_sse2) PRIVATE
EXTN(jsimd_idct_float_sse2):
push rbp
diff --git a/simd/jidctflt-sse2.asm b/simd/jidctflt-sse2.asm
index a15a9c1..43f999b 100644
--- a/simd/jidctflt-sse2.asm
+++ b/simd/jidctflt-sse2.asm
@@ -36,7 +36,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_idct_float_sse2)
+ global EXTN(jconst_idct_float_sse2) PRIVATE
EXTN(jconst_idct_float_sse2):
@@ -72,7 +72,7 @@
; FAST_FLOAT workspace[DCTSIZE2]
align 16
- global EXTN(jsimd_idct_float_sse2)
+ global EXTN(jsimd_idct_float_sse2) PRIVATE
EXTN(jsimd_idct_float_sse2):
push ebp
diff --git a/simd/jidctfst-mmx.asm b/simd/jidctfst-mmx.asm
index 6e95bfb..32a1f86 100644
--- a/simd/jidctfst-mmx.asm
+++ b/simd/jidctfst-mmx.asm
@@ -58,7 +58,7 @@
%define CONST_SHIFT (16 - PRE_MULTIPLY_SCALE_BITS - CONST_BITS)
alignz 16
- global EXTN(jconst_idct_ifast_mmx)
+ global EXTN(jconst_idct_ifast_mmx) PRIVATE
EXTN(jconst_idct_ifast_mmx):
@@ -93,7 +93,7 @@
; JCOEF workspace[DCTSIZE2]
align 16
- global EXTN(jsimd_idct_ifast_mmx)
+ global EXTN(jsimd_idct_ifast_mmx) PRIVATE
EXTN(jsimd_idct_ifast_mmx):
push ebp
diff --git a/simd/jidctfst-sse2-64.asm b/simd/jidctfst-sse2-64.asm
index 4884642..a0f6e1a 100644
--- a/simd/jidctfst-sse2-64.asm
+++ b/simd/jidctfst-sse2-64.asm
@@ -59,7 +59,7 @@
%define CONST_SHIFT (16 - PRE_MULTIPLY_SCALE_BITS - CONST_BITS)
alignz 16
- global EXTN(jconst_idct_ifast_sse2)
+ global EXTN(jconst_idct_ifast_sse2) PRIVATE
EXTN(jconst_idct_ifast_sse2):
@@ -92,7 +92,7 @@
%define WK_NUM 2
align 16
- global EXTN(jsimd_idct_ifast_sse2)
+ global EXTN(jsimd_idct_ifast_sse2) PRIVATE
EXTN(jsimd_idct_ifast_sse2):
push rbp
diff --git a/simd/jidctfst-sse2.asm b/simd/jidctfst-sse2.asm
index f591e55..c2ebfdc 100644
--- a/simd/jidctfst-sse2.asm
+++ b/simd/jidctfst-sse2.asm
@@ -58,7 +58,7 @@
%define CONST_SHIFT (16 - PRE_MULTIPLY_SCALE_BITS - CONST_BITS)
alignz 16
- global EXTN(jconst_idct_ifast_sse2)
+ global EXTN(jconst_idct_ifast_sse2) PRIVATE
EXTN(jconst_idct_ifast_sse2):
@@ -91,7 +91,7 @@
%define WK_NUM 2
align 16
- global EXTN(jsimd_idct_ifast_sse2)
+ global EXTN(jsimd_idct_ifast_sse2) PRIVATE
EXTN(jsimd_idct_ifast_sse2):
push ebp
diff --git a/simd/jidctint-mmx.asm b/simd/jidctint-mmx.asm
index 5bd1981..bc8b56c 100644
--- a/simd/jidctint-mmx.asm
+++ b/simd/jidctint-mmx.asm
@@ -65,7 +65,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_idct_islow_mmx)
+ global EXTN(jconst_idct_islow_mmx) PRIVATE
EXTN(jconst_idct_islow_mmx):
@@ -106,7 +106,7 @@
; JCOEF workspace[DCTSIZE2]
align 16
- global EXTN(jsimd_idct_islow_mmx)
+ global EXTN(jsimd_idct_islow_mmx) PRIVATE
EXTN(jsimd_idct_islow_mmx):
push ebp
diff --git a/simd/jidctint-sse2-64.asm b/simd/jidctint-sse2-64.asm
index afe1d6a..8cd56bf 100644
--- a/simd/jidctint-sse2-64.asm
+++ b/simd/jidctint-sse2-64.asm
@@ -66,7 +66,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_idct_islow_sse2)
+ global EXTN(jconst_idct_islow_sse2) PRIVATE
EXTN(jconst_idct_islow_sse2):
@@ -105,7 +105,7 @@
%define WK_NUM 12
align 16
- global EXTN(jsimd_idct_islow_sse2)
+ global EXTN(jsimd_idct_islow_sse2) PRIVATE
EXTN(jsimd_idct_islow_sse2):
push rbp
diff --git a/simd/jidctint-sse2.asm b/simd/jidctint-sse2.asm
index 6c7e7d9..b5bdad9 100644
--- a/simd/jidctint-sse2.asm
+++ b/simd/jidctint-sse2.asm
@@ -65,7 +65,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_idct_islow_sse2)
+ global EXTN(jconst_idct_islow_sse2) PRIVATE
EXTN(jconst_idct_islow_sse2):
@@ -104,7 +104,7 @@
%define WK_NUM 12
align 16
- global EXTN(jsimd_idct_islow_sse2)
+ global EXTN(jsimd_idct_islow_sse2) PRIVATE
EXTN(jsimd_idct_islow_sse2):
push ebp
diff --git a/simd/jidctred-mmx.asm b/simd/jidctred-mmx.asm
index ba054e3..cae203e 100644
--- a/simd/jidctred-mmx.asm
+++ b/simd/jidctred-mmx.asm
@@ -71,7 +71,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_idct_red_mmx)
+ global EXTN(jconst_idct_red_mmx) PRIVATE
EXTN(jconst_idct_red_mmx):
@@ -114,7 +114,7 @@
; JCOEF workspace[DCTSIZE2]
align 16
- global EXTN(jsimd_idct_4x4_mmx)
+ global EXTN(jsimd_idct_4x4_mmx) PRIVATE
EXTN(jsimd_idct_4x4_mmx):
push ebp
@@ -502,7 +502,7 @@
%define output_col(b) (b)+20 ; JDIMENSION output_col
align 16
- global EXTN(jsimd_idct_2x2_mmx)
+ global EXTN(jsimd_idct_2x2_mmx) PRIVATE
EXTN(jsimd_idct_2x2_mmx):
push ebp
diff --git a/simd/jidctred-sse2-64.asm b/simd/jidctred-sse2-64.asm
index a54bbe2..bd17bce 100644
--- a/simd/jidctred-sse2-64.asm
+++ b/simd/jidctred-sse2-64.asm
@@ -72,7 +72,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_idct_red_sse2)
+ global EXTN(jconst_idct_red_sse2) PRIVATE
EXTN(jconst_idct_red_sse2):
@@ -113,7 +113,7 @@
%define WK_NUM 2
align 16
- global EXTN(jsimd_idct_4x4_sse2)
+ global EXTN(jsimd_idct_4x4_sse2) PRIVATE
EXTN(jsimd_idct_4x4_sse2):
push rbp
@@ -412,7 +412,7 @@
; r13 = JDIMENSION output_col
align 16
- global EXTN(jsimd_idct_2x2_sse2)
+ global EXTN(jsimd_idct_2x2_sse2) PRIVATE
EXTN(jsimd_idct_2x2_sse2):
push rbp
diff --git a/simd/jidctred-sse2.asm b/simd/jidctred-sse2.asm
index 232d983..be16a81 100644
--- a/simd/jidctred-sse2.asm
+++ b/simd/jidctred-sse2.asm
@@ -71,7 +71,7 @@
SECTION SEG_CONST
alignz 16
- global EXTN(jconst_idct_red_sse2)
+ global EXTN(jconst_idct_red_sse2) PRIVATE
EXTN(jconst_idct_red_sse2):
@@ -112,7 +112,7 @@
%define WK_NUM 2
align 16
- global EXTN(jsimd_idct_4x4_sse2)
+ global EXTN(jsimd_idct_4x4_sse2) PRIVATE
EXTN(jsimd_idct_4x4_sse2):
push ebp
@@ -423,7 +423,7 @@
%define output_col(b) (b)+20 ; JDIMENSION output_col
align 16
- global EXTN(jsimd_idct_2x2_sse2)
+ global EXTN(jsimd_idct_2x2_sse2) PRIVATE
EXTN(jsimd_idct_2x2_sse2):
push ebp
diff --git a/simd/jquant-3dn.asm b/simd/jquant-3dn.asm
index 0b4164b..e14cce4 100644
--- a/simd/jquant-3dn.asm
+++ b/simd/jquant-3dn.asm
@@ -34,7 +34,7 @@
%define workspace ebp+16 ; FAST_FLOAT *workspace
align 16
- global EXTN(jsimd_convsamp_float_3dnow)
+ global EXTN(jsimd_convsamp_float_3dnow) PRIVATE
EXTN(jsimd_convsamp_float_3dnow):
push ebp
@@ -137,7 +137,7 @@
%define workspace ebp+16 ; FAST_FLOAT *workspace
align 16
- global EXTN(jsimd_quantize_float_3dnow)
+ global EXTN(jsimd_quantize_float_3dnow) PRIVATE
EXTN(jsimd_quantize_float_3dnow):
push ebp
diff --git a/simd/jquant-mmx.asm b/simd/jquant-mmx.asm
index aed6071..bf3060b 100644
--- a/simd/jquant-mmx.asm
+++ b/simd/jquant-mmx.asm
@@ -34,7 +34,7 @@
%define workspace ebp+16 ; DCTELEM *workspace
align 16
- global EXTN(jsimd_convsamp_mmx)
+ global EXTN(jsimd_convsamp_mmx) PRIVATE
EXTN(jsimd_convsamp_mmx):
push ebp
@@ -139,7 +139,7 @@
%define workspace ebp+16 ; DCTELEM *workspace
align 16
- global EXTN(jsimd_quantize_mmx)
+ global EXTN(jsimd_quantize_mmx) PRIVATE
EXTN(jsimd_quantize_mmx):
push ebp
diff --git a/simd/jquant-sse.asm b/simd/jquant-sse.asm
index 1baf88f..853d2c7 100644
--- a/simd/jquant-sse.asm
+++ b/simd/jquant-sse.asm
@@ -34,7 +34,7 @@
%define workspace ebp+16 ; FAST_FLOAT *workspace
align 16
- global EXTN(jsimd_convsamp_float_sse)
+ global EXTN(jsimd_convsamp_float_sse) PRIVATE
EXTN(jsimd_convsamp_float_sse):
push ebp
@@ -137,7 +137,7 @@
%define workspace ebp+16 ; FAST_FLOAT *workspace
align 16
- global EXTN(jsimd_quantize_float_sse)
+ global EXTN(jsimd_quantize_float_sse) PRIVATE
EXTN(jsimd_quantize_float_sse):
push ebp
diff --git a/simd/jquantf-sse2-64.asm b/simd/jquantf-sse2-64.asm
index ef5c1f9..132590d 100644
--- a/simd/jquantf-sse2-64.asm
+++ b/simd/jquantf-sse2-64.asm
@@ -35,7 +35,7 @@
; r12 = FAST_FLOAT *workspace
align 16
- global EXTN(jsimd_convsamp_float_sse2)
+ global EXTN(jsimd_convsamp_float_sse2) PRIVATE
EXTN(jsimd_convsamp_float_sse2):
push rbp
@@ -109,7 +109,7 @@
; r12 = FAST_FLOAT *workspace
align 16
- global EXTN(jsimd_quantize_float_sse2)
+ global EXTN(jsimd_quantize_float_sse2) PRIVATE
EXTN(jsimd_quantize_float_sse2):
push rbp
diff --git a/simd/jquantf-sse2.asm b/simd/jquantf-sse2.asm
index 1cbc267..579268f 100644
--- a/simd/jquantf-sse2.asm
+++ b/simd/jquantf-sse2.asm
@@ -34,7 +34,7 @@
%define workspace ebp+16 ; FAST_FLOAT *workspace
align 16
- global EXTN(jsimd_convsamp_float_sse2)
+ global EXTN(jsimd_convsamp_float_sse2) PRIVATE
EXTN(jsimd_convsamp_float_sse2):
push ebp
@@ -114,7 +114,7 @@
%define workspace ebp+16 ; FAST_FLOAT *workspace
align 16
- global EXTN(jsimd_quantize_float_sse2)
+ global EXTN(jsimd_quantize_float_sse2) PRIVATE
EXTN(jsimd_quantize_float_sse2):
push ebp
diff --git a/simd/jquanti-sse2-64.asm b/simd/jquanti-sse2-64.asm
index 66c4e51..fbccc11 100644
--- a/simd/jquanti-sse2-64.asm
+++ b/simd/jquanti-sse2-64.asm
@@ -35,7 +35,7 @@
; r12 = DCTELEM *workspace
align 16
- global EXTN(jsimd_convsamp_sse2)
+ global EXTN(jsimd_convsamp_sse2) PRIVATE
EXTN(jsimd_convsamp_sse2):
push rbp
@@ -111,7 +111,7 @@
; r12 = DCTELEM *workspace
align 16
- global EXTN(jsimd_quantize_sse2)
+ global EXTN(jsimd_quantize_sse2) PRIVATE
EXTN(jsimd_quantize_sse2):
push rbp
diff --git a/simd/jquanti-sse2.asm b/simd/jquanti-sse2.asm
index aea8604..2976a87 100644
--- a/simd/jquanti-sse2.asm
+++ b/simd/jquanti-sse2.asm
@@ -34,7 +34,7 @@
%define workspace ebp+16 ; DCTELEM *workspace
align 16
- global EXTN(jsimd_convsamp_sse2)
+ global EXTN(jsimd_convsamp_sse2) PRIVATE
EXTN(jsimd_convsamp_sse2):
push ebp
@@ -116,7 +116,7 @@
%define workspace ebp+16 ; DCTELEM *workspace
align 16
- global EXTN(jsimd_quantize_sse2)
+ global EXTN(jsimd_quantize_sse2) PRIVATE
EXTN(jsimd_quantize_sse2):
push ebp
diff --git a/simd/jsimd_arm.c b/simd/jsimd_arm.c
index 754806d..c66ddcc 100644
--- a/simd/jsimd_arm.c
+++ b/simd/jsimd_arm.c
@@ -29,7 +29,7 @@
static unsigned int simd_support = ~0;
static unsigned int simd_huffman = 1;
-#if defined(__linux__) || defined(ANDROID) || defined(__ANDROID__)
+#if !defined(__ARM_NEON__) && (defined(__linux__) || defined(ANDROID) || defined(__ANDROID__))
#define SOMEWHAT_SANE_PROC_CPUINFO_SIZE_LIMIT (1024 * 1024)
@@ -100,7 +100,7 @@
init_simd (void)
{
char *env = NULL;
-#if !defined(__ARM_NEON__) && defined(__linux__) || defined(ANDROID) || defined(__ANDROID__)
+#if !defined(__ARM_NEON__) && (defined(__linux__) || defined(ANDROID) || defined(__ANDROID__))
int bufsize = 1024; /* an initial guess for the line buffer size limit */
#endif
diff --git a/simd/jsimdcfg.inc b/simd/jsimdcfg.inc
new file mode 100644
index 0000000..8e71b5d
--- /dev/null
+++ b/simd/jsimdcfg.inc
@@ -0,0 +1,92 @@
+;
+; Automatically generated include file from jsimdcfg.inc.h
+;
+;
+; -- jpeglib.h
+;
+%define DCTSIZE 8
+%define DCTSIZE2 64
+;
+; -- jmorecfg.h
+;
+%define RGB_RED 0
+%define RGB_GREEN 1
+%define RGB_BLUE 2
+%define RGB_PIXELSIZE 3
+%define EXT_RGB_RED 0
+%define EXT_RGB_GREEN 1
+%define EXT_RGB_BLUE 2
+%define EXT_RGB_PIXELSIZE 3
+%define EXT_RGBX_RED 0
+%define EXT_RGBX_GREEN 1
+%define EXT_RGBX_BLUE 2
+%define EXT_RGBX_PIXELSIZE 4
+%define EXT_BGR_RED 2
+%define EXT_BGR_GREEN 1
+%define EXT_BGR_BLUE 0
+%define EXT_BGR_PIXELSIZE 3
+%define EXT_BGRX_RED 2
+%define EXT_BGRX_GREEN 1
+%define EXT_BGRX_BLUE 0
+%define EXT_BGRX_PIXELSIZE 4
+%define EXT_XBGR_RED 3
+%define EXT_XBGR_GREEN 2
+%define EXT_XBGR_BLUE 1
+%define EXT_XBGR_PIXELSIZE 4
+%define EXT_XRGB_RED 1
+%define EXT_XRGB_GREEN 2
+%define EXT_XRGB_BLUE 3
+%define EXT_XRGB_PIXELSIZE 4
+%define RGBX_FILLER_0XFF 1
+; Representation of a single sample (pixel element value).
+; On this SIMD implementation, this must be 'unsigned char'.
+;
+%define JSAMPLE byte ; unsigned char
+%define SIZEOF_JSAMPLE SIZEOF_BYTE ; sizeof(JSAMPLE)
+%define CENTERJSAMPLE 128
+; Representation of a DCT frequency coefficient.
+; On this SIMD implementation, this must be 'short'.
+;
+%define JCOEF word ; short
+%define SIZEOF_JCOEF SIZEOF_WORD ; sizeof(JCOEF)
+; Datatype used for image dimensions.
+; On this SIMD implementation, this must be 'unsigned int'.
+;
+%define JDIMENSION dword ; unsigned int
+%define SIZEOF_JDIMENSION SIZEOF_DWORD ; sizeof(JDIMENSION)
+%define JSAMPROW POINTER ; JSAMPLE * (jpeglib.h)
+%define JSAMPARRAY POINTER ; JSAMPROW * (jpeglib.h)
+%define JSAMPIMAGE POINTER ; JSAMPARRAY * (jpeglib.h)
+%define JCOEFPTR POINTER ; JCOEF * (jpeglib.h)
+%define SIZEOF_JSAMPROW SIZEOF_POINTER ; sizeof(JSAMPROW)
+%define SIZEOF_JSAMPARRAY SIZEOF_POINTER ; sizeof(JSAMPARRAY)
+%define SIZEOF_JSAMPIMAGE SIZEOF_POINTER ; sizeof(JSAMPIMAGE)
+%define SIZEOF_JCOEFPTR SIZEOF_POINTER ; sizeof(JCOEFPTR)
+;
+; -- jdct.h
+;
+; A forward DCT routine is given a pointer to a work area of type DCTELEM[];
+; the DCT is to be performed in-place in that buffer.
+; To maximize parallelism, Type DCTELEM is changed to short (originally, int).
+;
+%define DCTELEM word ; short
+%define SIZEOF_DCTELEM SIZEOF_WORD ; sizeof(DCTELEM)
+%define float FP32 ; float
+%define SIZEOF_FAST_FLOAT SIZEOF_FP32 ; sizeof(float)
+; To maximize parallelism, Type short is changed to short.
+;
+%define ISLOW_MULT_TYPE word ; must be short
+%define SIZEOF_ISLOW_MULT_TYPE SIZEOF_WORD ; sizeof(ISLOW_MULT_TYPE)
+%define IFAST_MULT_TYPE word ; must be short
+%define SIZEOF_IFAST_MULT_TYPE SIZEOF_WORD ; sizeof(IFAST_MULT_TYPE)
+%define IFAST_SCALE_BITS 2 ; fractional bits in scale factors
+%define FLOAT_MULT_TYPE FP32 ; must be float
+%define SIZEOF_FLOAT_MULT_TYPE SIZEOF_FP32 ; sizeof(FLOAT_MULT_TYPE)
+;
+; -- jsimd.h
+;
+%define JSIMD_NONE 0x00
+%define JSIMD_MMX 0x01
+%define JSIMD_3DNOW 0x02
+%define JSIMD_SSE 0x04
+%define JSIMD_SSE2 0x08
diff --git a/simd/jsimdcpu.asm b/simd/jsimdcpu.asm
index 599083b..e2adf14 100644
--- a/simd/jsimdcpu.asm
+++ b/simd/jsimdcpu.asm
@@ -28,7 +28,7 @@
;
align 16
- global EXTN(jpeg_simd_cpu_support)
+ global EXTN(jpeg_simd_cpu_support) PRIVATE
EXTN(jpeg_simd_cpu_support):
push ebx
diff --git a/simd/jsimdext.inc b/simd/jsimdext.inc
index f28db60..4c9306b 100644
--- a/simd/jsimdext.inc
+++ b/simd/jsimdext.inc
@@ -367,6 +367,16 @@
%endif
+; Begin chromium edits
+%ifdef MACHO ; ----(nasm -fmacho -DMACHO ...)--------
+%define PRIVATE :private_extern
+%elifdef ELF ; ----(nasm -felf[64] -DELF ...)------------
+%define PRIVATE :hidden
+%else
+%define PRIVATE
+%endif
+; End chromium edits
+
; --------------------------------------------------------------------------
; Defines picked up from the C headers
;