Page 1 of 1

How optimized is the linux version?

Posted: 2014-02-08, 20:43
by Roranicus
First of all, huge thanks to access2godzilla for making the linux version. I'm sure I'm not the only one who was waiting for something like this. It works fine so far (on linux Mint 15, Xfce edition) and I'll definitely post here if I encounter any problems.

Now, I was wondering how much of the optimisation palemoon was initially built for still applies under linux? I'm not that technical so I'm not sure if the changes Moonchild made only work under windows. I might do some benchmarking tests later, since I have both browsers installed (firefox and palemoon), but I thought I'd ask about it first. I'd assume removing things like accessibility options or parental control would have the same effect in any OS, but palemoon is also often cited as being optimized specifically for windows.

Sorry for the noobish question, but I was curious how much of the initial improvements Moonchild made transfered over to the linux build.

Re: How optimized is the linux version?

Posted: 2014-02-09, 08:35
by Moonchild
Good question!

@access2godzilla: If you haven't done so yet, make sure to make the minimum processor architecture i686 + SSE2 in your compiler flags. (I believe that's -msse2 for gcc)

Re: How optimized is the linux version?

Posted: 2014-02-09, 13:37
by jumba
I see these build flags on about:buildconfig for the linux PM,

gcc

Code: Select all

-Wall -Wpointer-arith -Wdeclaration-after-statement -Werror=return-type -Wtype-limits -Wempty-body -Wsign-compare -Wno-unused -Wcast-align -std=gnu99 -fgnu89-inline -fno-strict-aliasing -ffunction-sections -fdata-sections -pthread -pipe -DNDEBUG -DTRIMMED -O3 -msse2 -s -mfpmath=sse -fomit-frame-pointer
g++

Code: Select all

-Wall -Wpointer-arith -Woverloaded-virtual -Werror=return-type -Wtype-limits -Wempty-body -Wsign-compare -Wno-invalid-offsetof -Wcast-align -fno-exceptions -fno-strict-aliasing -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -std=gnu++0x -pthread -pipe -DNDEBUG -DTRIMMED -O3 -msse2 -s -mfpmath=sse -fomit-frame-pointer 

Re: How optimized is the linux version?

Posted: 2014-02-09, 13:43
by Moonchild
Looks all good then!

Re: How optimized is the linux version?

Posted: 2014-02-09, 14:32
by access2godzilla
Pale Moon uses SSE and SSE2 optimisations throughout the whole codebase (and not restricted to only some parts of code; unlike Firefox).

Some multithreaded code is disabled, though.

@Moonchild, could you please have a look at GetNumberofProcessors()/GetNumberofLogicalProcessors() in gfx/2d/Blur.cpp and work on a proper solution there?
I think GetNumberofLogicalProcessors() is the same as PR_GetNumberofProcessors() (which is defined in the actual Mozilla codebase).

Re: How optimized is the linux version?

Posted: 2014-02-09, 16:44
by Moonchild
access2godzilla wrote: could you please have a look at GetNumberofProcessors()/GetNumberofLogicalProcessors() in gfx/2d/Blur.cpp and work on a proper solution there?
I'll see what I can do - I've never poked at calling the NSPR functions directly (which that is one of). Since it's a separate library (and usually system-installed on *nix) it may be more trouble than it's worth for at most a few % gain in heavy gfx manipulations. The biggest multi-core gain on Windows is achieved through the compiler (and MSVC is obviously Windows-only), although gcc does build a proper threaded model itself it's not parallelized the same way, regardless of this function.

Re: How optimized is the linux version?

Posted: 2014-02-09, 18:28
by jumba
I did some benchmarks on various browser benchmarking sites. They seem to test javascript performance mostly. Anyway here are the results

Browser versions:
PM: 24.3.1
FX: 27.0
FX-esr: 24.3.0

Browser PM FX FX-esr
Peacekeeper 1942 2354 1971
BrowserMark 3953 4228 4010
ClubCompy 9558 10383 9233
Octane 10217 9539 9251
HTML5-bench 6399 7530 7196
Web Latency bench 3.2 2.7 3.0
Points, higher is better

Browser PM FX FX-esr
SunSpider 261.1 244.3 261.7
KrakenJS 2592.2 2071.7 2691.6
Ms, lower is better

It seems that there are some improvements made to Firefox javascript engine after the 24 version.

Re: How optimized is the linux version?

Posted: 2014-02-09, 19:11
by Moonchild
Jumba: I'm curious how PM/Win on WINE factors in there, for comparison!

JS speed is no longer a speed limiting factor for a browser, by the way. So, the most interesting scores (even though I really don't care much about synthetic benchmark scores anymore) would be hybrid tests and networking. Seems PM scores good on those.
In the current developments even a less outstanding score on benchmarks wouldn't make a difference considering the overall more sane feature set (and soon enough, a better UI overall) ;-)

Re: How optimized is the linux version?

Posted: 2014-02-09, 21:58
by Roranicus
Thanks, that seems to clarify things. I did some benchmarking tests myself, between FF ESR and PM and got similar results. :thumbup:

Re: How optimized is the linux version?

Posted: 2014-02-10, 17:49
by jumba
Moonchild wrote:Jumba: I'm curious how PM/Win on WINE factors in there, for comparison!
Here you go! :)
I also added benchmarks for PM on windows 8.1 on the same pc.

Browser: PM FX FX-esr PM/win32-wine PM/win32-windows8.1x64
PeaceKeeper 1942 2354 1971 1518 1814
BrowserMark 3953 4228 4010 3319 4081
ClubCompy 9558 10383 9233 7445 9138
Octane 10217 9539 9251 10185 11507
HTML5-bench 6399 7530 7196 4520 7737
Web Latency bench 3.2 2.7 3.0 2.6 3.8
Points, higher is better

Browser: PM FX FX-esr PM/win32-wine PM/win32-windows8.1x64
SunSpider 261.1 244.3 261.7 313.8 255.0
KrakenJS 2592.2 2071.7 2691.6 3037.1 2751.0
Ms, lower is better

Re: How optimized is the linux version?

Posted: 2014-02-10, 18:46
by Moonchild
Very interesting results :)
I'd say that the Windows version on WINE definitely holds its own against a native Linux version. Of course it performs a little poorer on graphics-heavy benchmarks but that's also not really the kind of abuse you'd get in normal browsing ;)

Thanks for taking the time to test this.

Re: How optimized is the linux version?

Posted: 2014-02-15, 14:55
by MozillaUser233
Moonchild wrote:Very interesting results :)
I'd say that the Windows version on WINE definitely holds its own against a native Linux version.
I was thinking about porting over to linux then using a vm on linux for windows for gaming and came accross this, which is very interesting wich costs a pretty penny which I dont have and am stuck on windows :p.

http://forums.linuxmint.com/viewtopic.php?f=42&t=112013

I wonder how windows version on Xen hypervisor would stack up.

Costs a pretty penny, you need VT-d support on both the processor and board, plus a few graphics cards I think. I just skimmed through it.