Slashdot Mirror


Firefox Javascript Engine Becomes Single Threaded

An anonymous reader writes with news about work on Mozilla's Javascript engine. Quoting Mozilla engineer Luke Wagner's blog: "With web workers in separate runtimes, there were no significant multi-threaded runtime uses remaining. Furthermore, to achieve single-threaded compartments, the platform features that allowed JS to easily ship a closure off to another thread had been removed since closures fundamentally carry with them a reference to their original enclosing scope. Even non-Mozilla SpiderMonkey embeddings had reportedly experienced problems that pushed them toward a similar shared-nothing design. Thus, there was little reason to maintain the non-trivial complexity caused by multi-threading support. There are a lot of things that 'would be nice' but what pushed us over the edge is that a single-threaded runtime allows us to hoist a lot data currently stored per-compartment into the runtime. This provides immediate memory savings."

8 of 346 comments (clear)

  1. You had me at.. by Sez+Zero · · Score: 5, Funny

    "memory savings".

    1. Re:You had me at.. by Anonymous Coward · · Score: 5, Funny

      There's a reason they're the most efficient browser when it comes down to memory usage. They actively work at it.

    2. Re:You had me at.. by Lisandro · · Score: 1, Funny

      There's a reason they're the most efficient browser when it comes down to memory usage. They actively work at it.

      Yeah, it's not like it leaks memory like a BP pipeline.

    3. Re:You had me at.. by Anonymous Coward · · Score: 2, Funny

      And we're on what now, Firefox 82?

    4. Re:You had me at.. by hazah · · Score: 3, Funny

      It parses the HTML as a bonus!

    5. Re:You had me at.. by bursch-X · · Score: 5, Funny

      You've got an 8GB system and complaining about FF 3.6 memory leakage?

      I'm not sure whether you are aware of it, but there's this cool way of replacing your application with a newer version (new: less than two years old). For free! It's called updating. I'm aware it's a radical concept, but try it out, it's pretty cool.

      --
      There are two rules for success:
      1. Never tell everything you know.
  2. Re:God saves his son 1st, Jesuchrist. by K.+S.+Kyosuke · · Score: 2, Funny

    It's an evil sentence for saving the tiranny originated by the supposed saved Queen

    I'm puzzled. Since when does the UK have such a strong pro-Albanian foreign policy?

    --
    Ezekiel 23:20
  3. *More* outsourcing?! Bloody "globalization"! by zooblethorpe · · Score: 3, Funny

    Multi-threading in JS is handled by web workers.

    Oh, great! So now we're outsourcing even more textile jobs to anyone willing to work online, is that it? Sheesh!

    (On a more serious note, thank you for that informative link.)

    --
    "What in the name of Fats Waller is that?"
    "A four-foot prune."