Eugene Kliuchnikov
Eugene Kliuchnikov
#4060 re-enables SVE that was not working before. So, the problem then is that there are no easy-to-use levers to control codegen... Going to add a bunch of "on-by-default" options,...
After #4396 it easy to tune codegen. E.g. if SVE2 is not used, add `-DJPEGXL_ENABLE_HWY_SVE2=false` and it won't be generated (NB, SVE2 has 2 flavors...).
Will take a look soon, perhaps we could shave some fat not caused by target-specific code.
(for x86, but should be relevant) symbols in libjxl_dec over 10KiB: ``` jxl::N_EMU128::(anonymous namespace)::LowestFrequenciesFromDC(jxl::AcStrategyType, float const*, unsigned long, float*, float*) jxl::N_EMU128::(anonymous namespace)::TransformToPixels(jxl::AcStrategyType, float*, float*, unsigned long, float*) jxl::Status jxl::detail::DecodeModularChannelMAANS(jxl::BitReader*, jxl::ANSSymbolReader*,...
Complete list of dupes (mangled): ``` 2 _ZN3jxl4jpegL7kXMPTagE 2 _ZN3jxl6detailL10CanToneMapERK16JxlColorEncoding 2 _ZN3jxl6detailL13ICCComputeMD5ERKSt6vectorIhSaIhEEPh 2 _ZN3jxl6detailL14FinalizeICCTagEPSt6vectorIhSaIhEEPmS5_ 2 _ZN3jxl6detailL14WriteICCUint32EjmPSt6vectorIhSaIhEE 2 _ZN3jxl6detailL15CreateICCXYZTagERKSt5arrayIfLm3EEPSt6vectorIhSaIhEE 2 _ZN3jxl6detailL16AddToICCTagTableEPKcmmPSt6vectorIhSaIhEEPS3_ImSaImEE 2 _ZN3jxl6detailL16CreateICCChadTagERKSt5arrayIS1_IfLm3EELm3EEPSt6vectorIhSaIhEE 2 _ZN3jxl6detailL16CreateICCMlucTagERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPSt6vectorIhSaIhEE 2 _ZN3jxl6detailL18CreateICCRGBMatrixEddddddddRSt5arrayIS1_IfLm3EELm3EE 2 _ZN3jxl6detailL20CreateICCCurvCurvTagERKSt6vectorItSaItEEPS1_IhSaIhEE 2 _ZN3jxl6detailL20CreateICCCurvParaTagERKSt6vectorIfSaIfEEmPS1_IhSaIhEE...
Adding `-DJPEGXL_ENABLE_TRANSCODE_JPEG=false` makes decoder 120KB smaller (~11%).
Another option is to use LTO (hmm, why he have not done it already?) It reduces lean (EMU128 only) libjxl_dec by 79.5KB (~7.5%)
@mo271 I've fixed test expectation; could you rubber-stamp, please
That one fails because threshold has been lowered and now do not cover 2 dim variants. Will fix after lunch.
All green now. @mo271 PTAL, thanks.