Open Nooshu opened 3 years ago
Also occurs on Android Firefox 91.4.0 (Build #2015831131) Tried various levels of compression etc - all produce these weird artefacts.
Huh, it doesn't happen for me on OSX, but it does happen on my Pixel 5.
Given that M1 Macs (which @Nooshu has) and the Pixel 5 are ARM-based, I wonder if that's the common element here.
Saving the WebP with the artifacts to disk and opening it in Chrome also shows the artifacts, implying that the generated WebP is in fact broken (and not just FF’s built-in decoder).
This kinda implies that FF has an arm64 code gen bug in their Wasm engine. I’ll try and build a repro and report it to FF
On my M1, I can confirm it reproduces on Firefox but not Chrome nor Safari.
I see that the pinch zoom UI is broken on Firefox Android, so I'll go fix that. https://github.com/GoogleChromeLabs/squoosh/issues/1146
On further inspection, the bug goes away if I disable Wasm SIMD in about:config
, so it seems to be specifically about SIMD instructions on arm64.
Built a reproduction case: https://sedate-entertaining-card.glitch.me/
This seems to be fixed in Firefox Nightly, so it’s a matter of waiting :)
I realise it probably means adding a UA-sniff, but should we bypass SIMD in Firefox for a bit?
I think it's already fixed in Firefox 92 which will be released later today. (I can only say "I think" because I could only test once on 92 before my Firefox Beta switched to 93)
FF 93 ships today. If that fixes it, that’s good enough. If not, we might wanna ship a workaround.
(I’m also wondering if we should add some debug flags to Squoosh that force-enable/force-disable Wasm features.)
Was the upstream fix backported to 91ESR? Might be worth reporting to upstream still from that perspective (eg in case the fix was accidental or otherwise without knowledge of this glitch, thus perhaps not backported).
It looks like https://bugzilla.mozilla.org/show_bug.cgi?id=1720650 (colored artifacts on ARM64 devices in connection with WASM/SIMD). If it has the same cause, then yes, it's fixed in Firefox ESR 91.1. Unfortunately I don't own such a device and can't verify.
Good find @cadeyrn. I agree that's the same issue.
Describe the bug Converting this PNG to WebP in latest FF (91.0.2) generates a whole bunch of colouful artifacts in the image. I've tested Chrome and it works fine.
To Reproduce Steps to reproduce the behavior:
Expected behavior Output image look similar to JPEG / AVIF versions.
Version:
Is your issue related to the quality of image compression? Yes
Original image
Output image from Squoosh (WebP not supported by GH, screenshot below)
Additional context, screenshots, screencasts
PNG to WebP
PNG to MozJPEG
PNG to AVIF