Pale Moon x86-64 SSE2/AVX2
-
back2themoon
- Knows the dark side

- Posts: 3281
- Joined: 2012-08-19, 20:32
Re: Pale Moon x86-64 SSE2/AVX2
Great, thank you both. 
Improve Pale Moon performance • Safe Mode / clean profile test info
How to auto-fill passwords • How to apply user agent overrides
Information to include when asking for support
Using: SSE2 build (thanks Nuck-TH) • W10 Pro x64
How to auto-fill passwords • How to apply user agent overrides
Information to include when asking for support
Using: SSE2 build (thanks Nuck-TH) • W10 Pro x64
-
UCyborg
- Board Warrior

- Posts: 1010
- Joined: 2019-01-10, 09:37
- Location: Slovenia
Re: Pale Moon x86-64 SSE2/AVX2
How does Firefox handle it?
It has media.av1.use-dav1d pref.
Not that I think AV1 is a good idea with 20 years old PC.
It has media.av1.use-dav1d pref.
Not that I think AV1 is a good idea with 20 years old PC.
The Merovingian wrote:Choice is an illusion, created between those with power, and those without.
-
Nuck-TH
- Project Contributor

- Posts: 350
- Joined: 2020-03-02, 16:04
Re: Pale Moon x86-64 SSE2/AVX2
A few pages ago there was some discussion about AVX and mention that some relatively recent Intel CPUs lack it.
-
Drugwash
- Lunatic

- Posts: 467
- Joined: 2016-01-28, 12:08
- Location: Ploieşti, Romania
Re: Pale Moon x86-64 SSE2/AVX2
No idea but maybe it falls back to safer code if it has the ability to detect the running CPU's capabilities at runtime. Although that would mean to build and provide two different versions of the dav1d decoder. Or simply disable dav1d/AV1 capability altogether if CPU can't handle AVX and the dav1d decoder was built with AVX capability. Or maybe they have another method.
I also see there is a vaapitest executable in its folder for the videocard.
I would've expected for Pale Moon's build script(s) to detect CPU configuration in .mozconfig and automatically enable the --enable-libaom fallback if --enable-av1 was enabled in a SSE2 configuration, but that is not the case. On the other hand the script did throw an error when --enable-libaom was active and --enable-av1 was disabled. Hm.
Because of this I'll have to rebuild 34.3.0, and I've not yet decided whether to enable the libaom fallback or just disable AV1 completely - seeing I don't playback videos in the browser anyway.
-
Moonchild
- Project founder

- Posts: 39467
- Joined: 2011-08-28, 17:27
- Location: Sweden
Re: Pale Moon x86-64 SSE2/AVX2
That would be assuming you're always building binaries on the machine you're going to use them on. And that's just not the case. Build machine CPU capabilities should have no bearing on the configuration. The builder determines the target configuration, not the hardware.
"Praise from a narcissistic person is always a poison dart. They don't share the stage, so discernment matters." - Dr. Ramani
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite
-
Drugwash
- Lunatic

- Posts: 467
- Joined: 2016-01-28, 12:08
- Location: Ploieşti, Romania
Re: Pale Moon x86-64 SSE2/AVX2
Maybe I got this wrong but wouldn't an option like ac_add_options --enable-optimize="-O2 -msse2 -mfpmath=sse -w" imply the binaries are built for usage on SSE2 machines, that is without any AVX/AVX2 capability?
Otherwise there would be no point in having separate AVX and SSE2 builds (official or not).
I mean logically, if the binary is built without AVX capabilities why would any of its dependent libraries have AVX dependency?
And if that's the case, couldn't the building script(s) detect that option and if necessary correct any (minor) user errors automatically, such as in this case? With warnings - for user's learning - in order to minimize any such issues in the future.
This kinda ties into one of our previous discussions regarding improvement of the building environment in order to avoid errors and oversights.
My apologies if I somehow didn't understand the situation correctly.
Now, just for clarification: while I built PM using the SSE option as above, and enabled AV1 without also enabling libaom, what would happen if I tried to view/play an AV1 video file in this browser, on my SSE2-only machine? Would it just refuse to play, would it throw a player error, or would it crash the whole browser? If it wouldn't crash then I'd rather avoid sitting idle around my notebook for another 2+ hours.
Not that I'm usually playing videos in browser - as previously mentioned - but one doesn't know what they may stumble upon on some random page.
I mean logically, if the binary is built without AVX capabilities why would any of its dependent libraries have AVX dependency?
And if that's the case, couldn't the building script(s) detect that option and if necessary correct any (minor) user errors automatically, such as in this case? With warnings - for user's learning - in order to minimize any such issues in the future.
This kinda ties into one of our previous discussions regarding improvement of the building environment in order to avoid errors and oversights.
My apologies if I somehow didn't understand the situation correctly.
Now, just for clarification: while I built PM using the SSE option as above, and enabled AV1 without also enabling libaom, what would happen if I tried to view/play an AV1 video file in this browser, on my SSE2-only machine? Would it just refuse to play, would it throw a player error, or would it crash the whole browser? If it wouldn't crash then I'd rather avoid sitting idle around my notebook for another 2+ hours.
Not that I'm usually playing videos in browser - as previously mentioned - but one doesn't know what they may stumble upon on some random page.
-
Moonchild
- Project founder

- Posts: 39467
- Joined: 2011-08-28, 17:27
- Location: Sweden
Re: Pale Moon x86-64 SSE2/AVX2
Theoretically, yes, but then you're asking the build system to be aware of and respond to every compiler option a user might be passing in the optimization flags. For every compiler supported, on every OS supported. That would be neither simple nor very maintainable.
Asking the person building to pass the correct/logical configuration parameters in their mozconfig is simply the most common sense solution.
"Praise from a narcissistic person is always a poison dart. They don't share the stage, so discernment matters." - Dr. Ramani
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite
-
Drugwash
- Lunatic

- Posts: 467
- Joined: 2016-01-28, 12:08
- Location: Ploieşti, Romania
Re: Pale Moon x86-64 SSE2/AVX2
Well then, I wasn't so far off.
That may be true, unfortunately. Too many compilers, too many operating system versions. Ironically, none even remotely close to perfection otherwise there wouldn't be so many to begin with.
Also true... if the person knew all configuration intricacies of the said project (be it Pale Moon or anything else). If there wasn't the tiny mention of libaom on the Release Notes page I and maybe others would've scratched our heads looking for a fix - or just banged those heads against the wall in desperation. (I do have a flair for the dramatic
So... should I rebuild or would it just be a minor hitch? I could let it do its job over night.
-
back2themoon
- Knows the dark side

- Posts: 3281
- Joined: 2012-08-19, 20:32
Re: Pale Moon x86-64 SSE2/AVX2
Isn't there a risk for system crashes (and quite the ugly ones) with CPU instruction mismatches?
Improve Pale Moon performance • Safe Mode / clean profile test info
How to auto-fill passwords • How to apply user agent overrides
Information to include when asking for support
Using: SSE2 build (thanks Nuck-TH) • W10 Pro x64
How to auto-fill passwords • How to apply user agent overrides
Information to include when asking for support
Using: SSE2 build (thanks Nuck-TH) • W10 Pro x64
-
Drugwash
- Lunatic

- Posts: 467
- Joined: 2016-01-28, 12:08
- Location: Ploieşti, Romania
Re: Pale Moon x86-64 SSE2/AVX2
Dunno, so far I haven't had such ugly crashes - knock on wood.back2themoon wrote: ↑2026-06-03, 17:21Isn't there a risk for system crashes (and quite the ugly ones) with CPU instruction mismatches?
-
Nuck-TH
- Project Contributor

- Posts: 350
- Joined: 2020-03-02, 16:04
Re: Pale Moon x86-64 SSE2/AVX2
It does, but there can be overrides for some compiler options for certain source files/their parts.Drugwash wrote: ↑2026-06-03, 15:50Maybe I got this wrong but wouldn't an option like ac_add_options --enable-optimize="-O2 -msse2 -mfpmath=sse -w" imply the binaries are built for usage on SSE2 machines, that is without any AVX/AVX2 capability?Otherwise there would be no point in having separate AVX and SSE2 builds (official or not).
And there is matter of inline assembly, which is common in codecs where hand optimizations are done. Ideally they are guarded by #ifs, but in case of dav1d this apparently isn't the case. Making and maintaining patches that will do just that isn't viable, and tbh isn't even very useful.
Due to above it will crash with illegal instruction error, but since that code is confined to av1 decoder, it will happen only when av1 playback is attempted.Drugwash wrote: ↑2026-06-03, 15:50Now, just for clarification: while I built PM using the SSE option as above, and enabled AV1 without also enabling libaom, what would happen if I tried to view/play an AV1 video file in this browser, on my SSE2-only machine? Would it just refuse to play, would it throw a player error, or would it crash the whole browser? If it wouldn't crash then I'd rather avoid sitting idle around my notebook for another 2+ hours.
Not that I'm usually playing videos in browser - as previously mentioned - but one doesn't know what they may stumble upon on some random page.
Cpus aren't that stupid. For ages there are ways to catch attempt of executing unknown instructions.back2themoon wrote: ↑2026-06-03, 17:21Isn't there a risk for system crashes (and quite the ugly ones) with CPU instruction mismatches?
On non-AVX cpu it will crash with illegal instruction error.
If it built into 32bit binary and run on AVX capable cpu it will either produce some incorrect results or outright crash because AVX instructions are made with assumption that they are used from 64bit mode. Why they aren't trapped as illegal in legacy(32bit) mode is anyone's guess...
-
Drugwash
- Lunatic

- Posts: 467
- Joined: 2016-01-28, 12:08
- Location: Ploieşti, Romania
Re: Pale Moon x86-64 SSE2/AVX2
Granted, but here we're talking about the main setting for the whole of the project, and I believe this is what would have to be considered if it were to tweak other settings on this base. The individual options for parts of the project shouldn't have any say in this unless they pertain to the very settings that would be tweaked on this occasion.
This is quite bad. [Deleted by moderator.]
This is obvious, but my question was whether it would crash the whole browser or just the player in its respective tab where the video was attempted open. A system crash would be very unlikely in my humble opinion but we never know. In my case Cinnamon is quite flaky itself, and used to crash pretty often in the past before I tweaked a few system files and installed some backports. By the way, mine is a 64bit system not 32bit, so it's one least thing to worry about.
Anyway, all things seem to indicate a rebuild would be indicated, and most likely with AV1 disabled completely. Will fire it up before I go to bed tonight.
Thank you all, and sorry for the slight hijacking.
-
back2themoon
- Knows the dark side

- Posts: 3281
- Joined: 2012-08-19, 20:32
Re: Pale Moon x86-64 SSE2/AVX2
Yes, perhaps the "ugly" crashes in such occasions are only related to deeper-level stuff e.g. system drivers.
Don't know really, but Nvidia has messed up on something like this. And yes, I got that treatment. System backups are good things.
Don't know really, but Nvidia has messed up on something like this. And yes, I got that treatment. System backups are good things.
Improve Pale Moon performance • Safe Mode / clean profile test info
How to auto-fill passwords • How to apply user agent overrides
Information to include when asking for support
Using: SSE2 build (thanks Nuck-TH) • W10 Pro x64
How to auto-fill passwords • How to apply user agent overrides
Information to include when asking for support
Using: SSE2 build (thanks Nuck-TH) • W10 Pro x64
-
Moonchild
- Project founder

- Posts: 39467
- Joined: 2011-08-28, 17:27
- Location: Sweden
Re: Pale Moon x86-64 SSE2/AVX2
The application would crash (on any reasonable OS anyway). If a CPU encounters an illegal instruction for its hardware then there is no sensible way to continue execution in that process, and the only option is to exit with an error. Unless video playback would be handled entirely externally (e.g. using an out-of-process plugin) and in a fault-tolerant manner, there's no way the browser can recover and continue execution.
"Praise from a narcissistic person is always a poison dart. They don't share the stage, so discernment matters." - Dr. Ramani
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite
-
UCyborg
- Board Warrior

- Posts: 1010
- Joined: 2019-01-10, 09:37
- Location: Slovenia
Re: Pale Moon x86-64 SSE2/AVX2
Firefox seems to have less hiccups with AV1 than Pale Moon, though there doesn't seem be any practical difference with media.av1.use-dav1d. Maybe it's decided at runtime whether to use it or not dependnig on CPU?
The Merovingian wrote:Choice is an illusion, created between those with power, and those without.
-
UCyborg
- Board Warrior

- Posts: 1010
- Joined: 2019-01-10, 09:37
- Location: Slovenia
Re: Pale Moon x86-64 SSE2/AVX2
And PotPlayer mentions using libdav1d on my AVXless CPU.
No crashes, though 1920x1080 video loads the CPU fully.
No crashes, though 1920x1080 video loads the CPU fully.
You do not have the required permissions to view the files attached to this post.
The Merovingian wrote:Choice is an illusion, created between those with power, and those without.