Please create an account to participate in the Slashdot moderation system

 



Forgot your password?
typodupeerror
×
Firefox Mozilla Chrome Communications Network Networking Software The Internet Windows

Firefox Takes the Next Step Towards Rolling Out Multi-Process To Everyone (arstechnica.com) 154

An anonymous reader quotes a report from Ars Technica: With Firefox 50, Mozilla has rolled out the first major piece of its new multi-process architecture. Edge, Internet Explorer, Chrome, and Safari all have a multiple process design that separates their rendering engine -- the part of the browser that reads and interprets HTML, CSS, and JavaScript -- from the browser frame. They do this for stability reasons (if the rendering process crashes, it doesn't kill the entire browser) and security reasons (the rendering process can be run in a low-privilege sandbox, so exploitable flaws in the rendering engine are harder to take advantage of). Moreover, these browsers can all create multiple rendering engine processes and use different processes for different tabs. This means that the scope of a crash is narrowed even further, typically to a single tab. Internet Explorer and Chrome both implemented this long ago, in 2009. Firefox, however, has not offered a similar design. Although work on a multi-process browser was started in 2009, under the codename Electrolysis, that work was suspended between 2011 and 2013 as priorities within the organization shifted. In response, Mozilla started switching to a new extension system in 2015 that opened the door to a multi-process design. The first stage of Firefox's move to multi-process involves separating the browser shell from a single rendering process that's used by every tab. In Firefox 48, that feature was enabled for a small number of users who used no extensions. Firefox 49 was rolled out to include users running a limited selection of extensions. Now, in Firefox 50, a separate renderer process is used for most users and most extensions. Developers are now able to mark their extensions as explicitly multi-process compatible. Firefox 51 will extend this even further to cover all extensions, except those that are explicitly marked as incompatible. Mozilla says that, even with the limited changes made in Firefox 50, responsiveness of the browser has improved by 400 percent due to the separation between the renderer and the browser shell. During page loads, responsiveness will increase to 700 percent.
This discussion has been archived. No new comments can be posted.

Firefox Takes the Next Step Towards Rolling Out Multi-Process To Everyone

Comments Filter:
  • by hyades1 ( 1149581 ) <hyades1@hotmail.com> on Wednesday December 21, 2016 @09:50PM (#53534973)

    Isn't that the browser a lot of people used to use before the developers decided to wreck just about everything they liked in order to turn it into some kind of inferior imitation of Chrome?

    • by mlts ( 1038732 )

      I wouldn't say splitting stuff into different processes is wrecking Firefox. In fact, the Edge browser will end up being split off into a completely separate Hyper-V VM (Windows Defender Application Guard.) The advantage of separating at this level is that malware has a layer between it and hardware, where it can't just flash bogus firmware to a keyboard because the keyboard input is virtualized, for example.

      The more separation between the browser and the rest of the OS, the better. The ideal would be so

      • by grcumb ( 781340 ) on Wednesday December 21, 2016 @10:48PM (#53535191) Homepage Journal

        I wouldn't say splitting stuff into different processes is wrecking Firefox.

        Every single grizzled, grey-haired veteran of the Browser Wars is putting on his best Comic Book Guy expression right now, and saying, "Multi-process vs multi-threaded, is it? You are discussing the virtues of a multi-process software application from a security perspective? How... interesting."[*]

        --------------
        [*] The decade-long turf-war between supporters of multi-process architectures and adherents of the multi-threaded heresy is legendary, for those who survived it. It consisted largely of a bunch of jaded old fucks warning each succeeding generation of new kids that multi-threaded sounds like a better optimisation, but if you just live with the extra few cycles required to spawn each new process, you get software that's way easier to manage. And successive generations of way-too-fucking-clever comp-sci grads yelling, 'Fine, gramps, but it won't matter how secure your apps are, 'cause no one's gonna buy them!!' and then rage-fragging a few more newbs before going back to coding their magnum opus. Then the SystemD singularity did for the Linux community what Trump did to the electorate, and all the old fucks quietly barred the door to their cabin in the woods, and cleaned their shotgun.[**]

        [**] And then Netscap^H^H^H^H^H^HFirefox announces that multi-process is cool and more secure.

        • by fisted ( 2295862 )

          Netscap^H^H^H^H^H^HFirefox announces that [...]

          What is this NFirefox? I hadn't heard about it yet. New firefox? Next firefox?

          That said, am I the only one who does NOT want multi-process simply because it's annoying as fuck already that firefox hogs ONE core? I don't want it to hog EVERY core, for resource waste, noise and temperature reasons.

        • by Bongo ( 13261 )

          Heh. I'll always remember Jerry Pournelle writing in Byte: "I'm not sure I want to share cycles even with myself" back when preemptive multi tasking was a strange new fangled thing in PCs.

        • Is systemd insecure? Oh yes, yes it is [agwa.name]. It can be crashed in one tweet.
        • Exactly. Multi-Process means nothing if its coded poorly. Insofar as saying multi-process equals extra security, speed, robust interace but without the right goals (and actually building it well) will just complicate matters. 30 years of SW engineering says this is an ongoing fad that keeps coming back.
        • I wouldn't really characterize it as any sort of turf war... insofar as I know, there was never any turf war. Each has its uses.

          In terms of security, don't forget user account separation. Why trust the application to secure the environment for you? I don't. I segregate browser use cases into separate dummy user accounts and start independent instances of the browser with a simple ssh localhost -l dummy1 -n chrome .... (or whatever, all bound up into a GUI button).

          After all, the browser is only part of t

      • by Anonymous Coward

        Missing the point. The minimum requirements to use Chrome is 256MB RAM per tab. This includes things like nw.js (chromium webview) where as Firefox didn't do this and required 256MB for the entire browser.

        The entire sand boxing , one-thread per tab, thing is killing the "mobile" experience, and destroying the desktop experience where things like Twitter and Slack require 64-bit processors because they are constantly increasing the size of the webview DOM with no Garbage collection. Like I do not know how an

    • by Anonymous Coward

      And each update starts the infuriating process of finding a set of addons that give me my old browser back.

      • That's what actually drove me away. I simply couldn't be bothered. Apparently a lot of people agreed, because the number of people using Firefox has crashed since they decided productivity-oriented people needed to spend time reconfiguring a basic internet tool every few weeks instead of just...using it.

        • Firefox 50.1 has taken its trickle of rendering and tab cleanup to be measured in furlongs per fortnight. It has become horrifically slow, not the reverse using common add-ins.

          Worse, some pages simply die or are rendered incorrectly if at all.

          While I used Firefox loyally, especially for its debug qualities, I might actually be forced to change because it is stunningly slow even on fast hardware. It's like I leaped back to 1998.

    • Re:Firefox...hmmm (Score:5, Insightful)

      by Motherfucking Shit ( 636021 ) on Wednesday December 21, 2016 @10:58PM (#53535237) Journal

      It's coming back, albeit gradually. They're getting rid of bloatware like Hello, Pocket is easy to disable, and Classic Theme Restorer still works fine even though it shouldn't have to exist. Going from 47 to 50, memory usage has dropped for me. I still see some hiccups. Ghostery doesn't work properly for me in 50.x (its dialog is blank). According to the Add-on Compatibility Reporter, about half my addons are "Not compatible with multiprocess," so I won't turn that on. And something changed between 50.0.2 and 50.1 that causes brief freezes when I'm scrolling.

      I at least feel like they're finally moving the project in a good direction, being a good browser instead of trying to be an entire OS.

      • I did the sucky thing by just sidestepping the whole problem...I switched to Pale Moon. They just quit supporting XP, though, so my oldest computer will have to move over to Opera.

        • WHY are you still using windows XP?

          no updates, no security and many apps already fail to run on it...

          If the machine is old, switch to linux... if you really want windows, at least use the windows 7

      • ...Classic Theme Restorer still works fine even though it shouldn't have to exist....

        "...even though it shouldn't have to exist...." --- this

        .
        So long as statements such as the one I quoted need to exist, Firefox is not coming back.

        The developers still appear to think they know better, as they slowly turn Firefox into a Chrome clone.

        Mozilla had the golden ring, but they dropped it.

    • Isn't that the browser a lot of people used to use before the developers decided to wreck just about everything they liked in order to turn it into some kind of inferior imitation of Chrome?

      Nicely put. Yes, that would be the one.

    • Re:Firefox...hmmm (Score:4, Informative)

      by MSG ( 12810 ) on Thursday December 22, 2016 @12:29AM (#53535465)

      No, it's the browser people use because they want to sync their bookmarks *and* have extensions on a mobile device.

    • Re:Firefox...hmmm (Score:5, Insightful)

      by sremick ( 91371 ) on Thursday December 22, 2016 @10:02AM (#53537125)

      Chrome? Isn't that the trojan that gets bundled with every unrelated download one finds on the internet, and then once it gets sneaks onto a user's computer and tricks the user into making it their default browser, arrogantly takes over the computer spawning a dozen background processes that exhaust all available CPU and RAM, bringing everything to a crawl?

      I've been in IT for decades, and have been rather ambivalent about Firefox-vs-Chrome until just recently, mainly just being content as long as users weren't using IE. However, despite any influence from me, I've seen countless longtime Chrome fans abandoning it and coming back to Firefox because of the background process/CPU/RAM issue I mention above. This is also being seen on both Windows and Mac platforms... it's not specific to either OS. At my work, Firefox continues to be the deployed browser of choice to all the many thousands of computers we manage because Chrome is an ass and thinks you don't want to use your computer for anything but web browsing.

      • by Anonymous Coward

        Even when the background processes weren't resource hogs, they were still very sleazy about resisting removal. On Macs, Google's "updater" would be installed in several places and would repopulate all of these locations if any of them were removed, malware-style.

    • Isn't that the browser a lot of people used to use before the developers decided to wreck just about everything they liked in order to turn it into some kind of inferior imitation of Chrome?

      Yeap! (it's projected to be an PERFECT Chrome clone as of version 7517576215751257!)

  • by Anonymous Coward

    The main question is how many DNS queries can it launch at once to pull in all the crazy bits that advertisers use. This goes back to the "how fast can it render" question. Well first it needs to pull in all the stuff and badly written web code, especially advertisements, pull in stuff from all over the place that often require multiple fetches from a myriad of different sites to get all the elements needed to render a page,

    ((browsers should give each page a score for how easy it was to assemble))

    • by Anonymous Coward

      responsiveness of the browser has improved by 400 percent due to the separation between the renderer and the browser shell.

      Unfortunately, the amount of crap on web pages has increased by 500 percent.

    • Unbound or PiHole and send those to a nginx server that returns a 204.

    • I'd love to see the browser do an end-run around all that - I wouldn't think it would be too hard for at least 80% of cases: just load everything hosted on the same server / subnet as the page itself first. That should quickly give you enough information to render the page reasonably well unless the page designer specifically attempted to avoid it, and the rest can be loaded in at a more leisurely pace. That just leaves the challenge of avoiding constantly reflowing the page as new components load in. Wo

      • by Merk42 ( 1906718 )
        There's also the issue of CDNs.
        • Is there really though?

          If embedded content is identified by relative address, or an address on the same server name, it's logically on the same server, regardless of where it's physically located. That much should be trivial to load first.

          Of course once you've finished loading all the "local" content, then if ads are served from the same CDN, that would make them harder to prescreen by subnet for delayed loading, but by the same token they should be served much more quickly as well, so it's probably not an

          • by Merk42 ( 1906718 )

            Is there really though?

            ...if ads are served from the same CDN, that would make them harder to prescreen by subnet for delayed loading...

            That's what I'm saying. The content from the same server is one thing.
            What if there is some CDN, (e.g. Akamai), that is used for both serving images AND ads? How would the browser know the difference if it's only looking at the server?

            • Why would it need to? The point is not to avoid loading ads, but to get the important content loaded as quickly as possible so that the page can be rendered nicely, and ad networks often have ugly delays that interfere with that goal. If the ads and images are served by the same CDN, then most likely either both will be served promptly, or both will be delayed. Either way there's limited advantage to distinguishing between the two.

              I also suspect that that it's common practice to link images by relative a

    • by DonaId Trump ( 4811527 ) on Wednesday December 21, 2016 @11:44PM (#53535399)
      We're going to fix that problem in my first 100 days in office, believe me. DNS is low energy and high latency, SAD! Did you know there are DNS servers in Mexico and CHY-NA, folks? I'm going to make it ILLEGAL and force every link on the cyber to go through my new URL shortening service, HTTP://BIG.LY. I'm appointing Barron to run it so you know it's going to be the best!
      • So if Trump wants us to buy American and hire American, and Toyota is Japanese, then why is the featured product on big.ly's front page a toy Yoda [big.ly]? I guess even though Toyota is Japanese, the company hires Americans to build vehicles right here in America.

      • Kinda of a funny question. Don't people realize that they can just run a caching DNS service on their workstation or in-home server? I do! It takes care of the problem just like that. No way I would *ever* trust my ISP's DNS service. Or anyone else's for that matter.

        -Matt

  • One of the issues today is sleeping or stopping of the processes of tabs that haven't been used in a while. I don't believe Chrome does this and would suspect it is one of the causes of making it heavy in terms of resources?

    • Re: (Score:2, Interesting)

      by Anonymous Coward

      It's actually something they're investigating for Firefox right now, and one of their focuses for the whole Project Quantum thing seems to be to try to reduce the amount of CPU usage that background tabs get (unless it's somehow clear that they're supposed to be working in the background without being slowed down too much). Hard to say what the results will be at this early stage, but there's a lot of interesting stuff that seems possible now that they've rewritten most of the browser to support e10s.

    • by 0ld_d0g ( 923931 )

      How do you define a background tab? I (and I suspect many others) have spotify or youtube or netflix or some other media playing in the b/g. Allocating CPU cycles to threads and processes is the job of the OS, not the browser.

      • In this case, the browser design is likely to provide a hint to how the process are being used. The OS doesn't have that contextual information, so for it is just another process. While not perfect, there are likely to be hints that can be used. For example a browser that just relaunched with 30 tabs open (I have seen that), may want to default to only spawning processes, representing tab that have been visited by the user in the current session.

  • by rsilvergun ( 571051 ) on Wednesday December 21, 2016 @10:29PM (#53535101)
    last I heard they were going to break it with version 40 sometime in August. There's a ton of work that'll have to be done to make it work properly in a multi-process environment. More or less a full re-write. To say nothing of having to redo all my UI components. Here's hoping they get cross compatibility with Chrome so I can at least get some code reuse out of it.
  • by Anonymous Coward

    I'd say the most important thing they need to fix is the popup blocker. Whether one tab crashes or they all crash in one go, isn't really a problem I'm bothered with. What I am bothered with is the way I still get popups.

    • by tepples ( 727027 )

      Firefox's pop-up blocker requires pop-ups to be initiated by a user event, in particular a click. If you don't want pop-ups, then don't click on the page.

  • Not all rosy (Score:2, Interesting)

    by markdavis ( 642305 )

    Unfortunately there are some users who are going to be greatly adversely affected by Firefox moving to full multi-process. I am one of those. At work we make use of Firefox under Linux thin client environments, running on a centralized server. This type of change opens the door for Firefox to completely overrun all our CPU resources, no matter what we throw on it. Why? Because I am certain the Firefox developers won't give us an "off" switch for this new functionality (or if they do, it will be taken a

    • Re:Not all rosy (Score:5, Informative)

      by trparky ( 846769 ) on Wednesday December 21, 2016 @10:52PM (#53535217) Homepage
      You can control how many sub-processes are created by the browser using an entry at the about:config screen. If you set it to one it will only spawn one sub-process. This will of course negate the whole idea of having sub-processes since all tabs would be running in one rendering sub-process but it would fix your issue.
      • by tepples ( 727027 )

        I've been using Firefox 51 from the firefox-next PPA in Xubuntu on a 1-core, 2-thread Atom N450 laptop for a couple weeks now. Even if all tabs run in one process, scrolling still runs smoothly because it's in a separate process, though occasionally I outrun the rendered portion and there's a delay before the blank part fills in.

    • I suggest you look at cgroups. Instead of relying on the processes to play nice with resources, you can specify the resources you want allocated to each user. For instance, if each user has cpu.shares=1024, then it'll fully balance - if user A starts an old firefox and it's running singlethreaded, and user B starts a new firefox and it spawns 50 processes, you'll see user A's process consuming 50% of CPU, and user B's flock consuming 1% CPU each.

      In this way you specify what you want to achieve (user B doe

      • by Anonymous Coward

        Vote parent up, way up. UNIX has its roots as a fine-grained resource accounting and limiting system (memory and CPU time used to be a thing you could charge a lot for!). Linux inherits that tradition and has layered stuff like cgroups on top of it to make it easy to manage.

        I mean -honestly-, how did GPP think decent multi-tenant VPSs hosts handled resource constraints between competing clients? Cron jobs that pinned VMs to specific cores and killed "runaway" processes?

    • I'm curious, in what way does turning threads into processes overrun CPU resources? Threads can peg the CPU meter on multiple cores just as easily as processes can. Is it a page table thing or an OS scheduler thing or what?

      It seems to me that you have an operating-system level problem. If nice and ulimit and the OS scheduler aren't cutting it, then they need to be improved or replaced.

    • Oh please can the hardware run IE 8 and Chrome 1.0 circa 2009?

      If yes then you're fine. Firefox is now catching up to IE 8 security and performance which is why I left it

      • >"Oh please can the hardware run IE 8 and Chrome 1.0 circa 2009? If yes then you're fine. Firefox is now catching up to IE 8 security and performance which is why I left it"

        That is ridiculous.

        1) Running IE under Linux is not realistic.
        2) Saying Firefox security and performance is at 2009 levels is just completely false.
        3) Implying that I could use Chrome to do what Firefox does is equally false... especially Chrome 1.

  • Hey, maybe we should give Mozilla more money, so that they can spend it on community education projects and saving hungry children instead of fixing their browser.

  • It's still atrociously slow, atrociously. Infact there's a either a bug with one of my plugins or something but I've deliberately endured it for nearly 8 weeks, hoping my feedback data is going in the bloody logs somewhere to help.

    I run about 6 or 7 plugins which are all fairly common and I have run the same ones for 3 to 5 years. They worked fine on my last profile rebuild but this most recent one was broken /out of the gate/

    It's so bad i'm using chrome primarily. Firefox performance frustrates me absol

    • by narcc ( 412956 )

      they seriously need a scrum or party or a bonus or something and the whole fucking team *STOPS* for 3 weeks solid and focuses on NOTHING but performance, performance, performance.

      Take a look at Servo [youtube.com], Stylo, and Quantum. Here's a longer talk that goes over some of the you can expect. [youtube.com]

    • I run about 6 or 7 plugins which are all fairly common and I have run the same ones for 3 to 5 years.

      Plugins or addons?

      See if you have perf issues running firefox in "safe mode"...
      https://support.mozilla.org/en... [mozilla.org]

      Otherwise, try a full browser refresh, which will reset it to "factory defaults".

      I'm on a really old Athlon X2 cpu with less than 4gig of ram (WinXP), and firefox runs beautifully...
      But what I tend to do is unusual, I run a bunch of different sites under different Firefox profiles.
      So mail would be under a separate profile (and process), and Google sites (like the memory hogging Google Maps) would

  • Noticed this - in the past, the browser would idle at 80-115% CPU usage, now it see it rest at 180-250% CPU usage.

    Giving it the Restart command also seems faster - shutting down and coming back up is now less than a minute most times!
    (hey, it frees up 4-7 gigabytes of physical ram, and several gigabytes of diskspace, and makes pretty much everything run faster for a while)

  • I use Firefox in several windows, each having several tabs. When I need to do a restart, all I do is kill firefox.exe, do stuff & restart, start firefox and all windows and tabs come back after I click restore. Now that's useful. Great things never last long, I guess.
  • I make no pretensions that the current work isn't mere Chrome-catch-up, but if they had listened to community in 2007 they might not have had to catch up. In the days of $350M revenue from Google, "patches welcome" was an obsolete response - management simply failed to properly manage the engineering process.

    from #392073:

    L A Walsh 2007-08-13 11:41:59 PDT
    User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6
    Build Identifier: Mozilla/5.0 (Windows; U; Wind

  • by Merk42 ( 1906718 )
    I didn't read TFS but since this is Slashdot and the subject is Firefox. One of two things is wrong:

    Change happened, and as we all know, any change is bad. That's why people leave Firefox for Chrome! Stupid Mozilla!
    Change didn't happen, why won't you change ${thing}? That's why people leave Firefox for Chrome! Stupid Mozilla!

    Of course if I were calling the shots it'd be the most perfect browser ever, but I won't even so much as file a bug report even though it is FOSS. That way I don't have to come to t
  • by m.dillon ( 147925 ) on Thursday December 22, 2016 @12:37PM (#53538281) Homepage

    I'm glad they're finally giving each tab its own process. Of course, if they didn't they'd wind up in the dust bin of history... its about the minimum of work they need to do just to keep Firefox relevant. There is much more they need to do in addition. Honestly, Firefox's biggest competition here, after fixing the tab problem, is going to be chrome 55 with its significantly improved (reduced) memory footprint.

    The interesting thing about giving each tab its own process is that although this increases the total amount of memory used by the browser, it also has the effect of reducing the memory fragmentation that forces the OS to keep almost every byte of it in core (Firefox is best known for this effect). With the process separation, the OS will have a much easier time paging out unused memory without nominal browser operation forcing every single last page back in. THAT is a big deal, and is one of the reasons why chrome is so much more usable than firefox.

    I regularly leave my browser(s) running for weeks. Process sizes generally bloat up during that time, to the point where the browser is consuming ~8GB+ of ram. With Firefox the horrid memory management in-browser forces most of that to stay in core. With chrome, most of it gets paged out and stays out. This makes chrome far more usable, particularly considering the fact that my workstation runs from a SSD and has a relatively large (~60G) swap partition configured.

    But these days I'm a chrome user. Firefox has been too buggy for at least the last 4 years. It crashes on all sorts of things, taking the whole browser out with it. And after all this time they *STILL* can't fix the idiotic pop-up windows. Disable popups only disables some of them. That and the bugs is the main reason why I stopped using Firefox.

    In terms of sandboxing... also a good thing. In addition to the work the browser does, I also segregate my browser instances into multiple dummy user accounts (that my GUI buttons can just ssh into from my main account), and run multiple instances of the browser from those. One for unsecure browsing, one for browsing important accounts, and one with the most bulletproof setup I can think of (no video group access, no direct X server access)... which is slow, but about as safe as its possible to be in an X environment.

    People often forget about user account separation. It's a bit sad.

    -Matt

  • There seems to be a lot of confusion about processes and cores and cpu use. I'm going to clarify some of this for people (I should konw after all!).

    A process can be thought of as a memory management context. The memory image used by the program. But a process is not limited to just one cpu. A process can be multi-threaded. In a multi-threaded process, all threads share the same memory context but each is scheduled independently by the schedluer, so one process can in fact easily use all available cpu r

    • by epine ( 68316 )

      (1) Bad interaction between the browser and the sound device (the intermediate streaming libraries have been known to cause problems in the past).

      I'm running Firefox on PC-BSD and I can pretty much confirm your observations on resident set and the weird audio bug.

      I experience terrible slowdowns after visiting various multimedia sites that take a browser restart to clear up. I've long suspected the audio, because audio has been a weird duck in other regards, as well. (I've got a current problem that any Yo

  • please use the proper wording here on /., to avoid unnecessary slashvertisements...
  • I checked about:support and saw that multiprocess windows was not enabled. Installed the Add-on Compatibility Reporter and saw that WoT (yeah, privacy, blah blah spyware blah blah) and Ubuntu Modifications add-ons were incompatible with multiprocess. Disabled those two and ... wow. The speedup and responsiveness improvement is substantial. I also disabled WoT on my Windows 10 laptop, and the speedup there was also improvement there.

    Part of it could be "Yeah, running fewer add-ons, of course it'll be fa

  • This (50.1) is the flakiest release in a long, long time for me. I have to quit the browser and restart it several times a day because it begins to choke for no apparent reason.

Algebraic symbols are used when you do not know what you are talking about. -- Philippe Schnoebelen

Working...