When doing some profiling with m87 Skia (the current version we are using), I noticed that JPEG decoding using libjpeg-turbo is not using NEON at all.
It appears (from long ago) that the NEON source files were disabled on iOS probably from compiler compatibility issues...
} else if (current_cpu == "arm64" && !is_mac && !is_ios && !is_win) {
sources += [
"../externals/libjpeg-turbo/simd/arm/arm64/jsimd.c",
"../externals/libjpeg-turbo/simd/arm/arm64/jsimd_neon.S",
"../externals/libjpeg-turbo/simd/arm/common/jcsample-neon.c",
"../externals/libjpeg-turbo/simd/arm/common/jdcolor-neon.c",
"../externals/libjpeg-turbo/simd/arm/common/jdmerge-neon.c",
"../externals/libjpeg-turbo/simd/arm/common/jdsample-neon.c",
"../externals/libjpeg-turbo/simd/arm/common/jidctfst-neon.c",
"../externals/libjpeg-turbo/simd/arm/common/jidctint-neon.c",
"../externals/libjpeg-turbo/simd/arm/common/jidctred-neon.c",
]
}
Removing the "!is_ios" check still compiles fine and JPEG decoding is about 2x faster on my test case and shows NEON usage. in the profiler.
Is this a change that can be made in Skia please?
Thank you.