6 ms·
Memories of Mozilla at 15 and Thoughts on Mozilla Research
- pnt 14y agoRewriting the browser stack in an evolving language feels like trying to shoot the moon. However, I hesitate to bet against Mozilla when it comes to impossible rewrites.
- haberman 14y agoI love the idea. It will give Rust lots of feedback about real-world, practical problems that arise on large-scale software. I think it will make it all that much more likely that Rust will be an industrial strength systems language.
- nnethercote 14y agoYep. It's a high-risk project, but the pay-off could be huge (both for programming languages and browsers) if they pull it off.
- surrealize 14y agoOne of the slides shows a benchmark where Rust beats GCC; it would be really nice to see the code.
- Ygg2 14y agoIn what? Compilation speed? Atm Rust is no way the light nimble language they need it to be.
- deleted 14y ago[deleted]
- pcwalton 14y agoRuntime performance. This is mostly an LLVM versus GCC thing. Runtime performance is far more important to us than compiler speed—a fast-to-compile Web browser is useless if it loses to existing engines in UX or benchmarks (every cycle counts!)—but we continue to spend time on compiler speed, because it's important for developers.
- surrealize 14y ago> This is mostly an LLVM versus GCC thing. So how does clang do on nbody.c?
- kibwen 14y agoI don't know which code Brendan was using, but using the http://shootout.alioth.debian.org/ http://shootout.alioth.debian.org/ implementations I ran some tests of my own: Performance counter stats for './nbody.gcc_run 50000000' (5 runs): 6232.525219 task-clock # 0.999 CPUs utilized ( +- 0.09% ) 533 context-switches # 0.086 K/sec ( +- 0.43% ) 1 CPU-migrations # 0.000 K/sec ( +- 66.67% ) 166 page-faults # 0.027 K/sec ( +- 0.15% ) 27,385,819,080 cycles # 4.394 GHz ( +- 0.05% ) [83.31%] 19,494,722,200 stalled-cycles-frontend # 71.19% frontend cycles idle ( +- 0.07% ) [83.30%] 6,403,657,640 stalled-cycles-backend # 23.38% backend cycles idle ( +- 0.21% ) [66.70%] 31,905,910,193 instructions # 1.17 insns per cycle # 0.61 stalled cycles per insn ( +- 0.01% ) [83.37%] 1,902,954,908 branches # 305.326 M/sec ( +- 0.05% ) [83.36%] 39,925 branch-misses # 0.00% of all branches ( +- 31.16% ) [83.34%] 6.239027874 seconds time elapsed ( +- 0.08% ) Performance counter stats for './nbody_rustc 50000000' (5 runs): 6970.131625 task-clock # 0.999 CPUs utilized ( +- 0.07% ) 601 context-switches # 0.086 K/sec ( +- 0.33% ) 5 CPU-migrations # 0.001 K/sec ( +- 7.41% ) 1,024 page-faults # 0.147 K/sec ( +- 0.02% ) 30,587,917,853 cycles # 4.388 GHz ( +- 0.04% ) [83.31%] 19,368,464,950 stalled-cycles-frontend # 63.32% frontend cycles idle ( +- 0.06% ) [83.34%] 7,348,766,082 stalled-cycles-backend # 24.03% backend cycles idle ( +- 0.84% ) [66.69%] 36,479,184,126 instructions # 1.19 insns per cycle # 0.53 stalled cycles per insn ( +- 0.01% ) [83.35%] 2,404,008,283 branches # 344.901 M/sec ( +- 0.04% ) [83.35%] 65,846 branch-misses # 0.00% of all branches ( +- 11.89% ) [83.33%] 6.977211938 seconds time elapsed The C version is here: http://benchmarksgame.alioth.debian.org/u32/program.php?test=nbody&lang=gcc&id=1 http://benchmarksgame.alioth.debian.org/u32/program.php?test... . It appears to be the fastest C verson on the site. The Rust version looks pretty gross (it's likely very old code), I'd like to try porting the C version to Rust (it's only 140 lines) and compare the results. Note also that I'm using a version of the compiler that's so new that it's not even in the official repo yet, containing optimizations for floating-point math.
- wslh 14y agoI never liked Mozilla for a number of experiences: Their transition from an open source project to an organization receiving millions from the Google search box. The restrictions (based on security reasons) to install an extension from a site different than mozilla addons. For me this was a prequel of app stores. Mozilla Thunderbird team had no respect for people who reported bugs: they closed important bug reports. Lack of respect for extension developers breaking compatibility between versions and not clearly isolating extensions. I remember looking into the TabMix Plus extension and seeing ~40 IFs handling special cases with other extensions. Lack of a good community (circa 2007) where complex questions were never answered. I can think about more disgusting experiences...
- wslh 14y agoIt would be interesting to receive replies instead of downvotes.
- simonw 14y ago"Their transition from an open source project to an organization receiving millions from the Google search box." You can be both things. Generally it's nice to be paid for your work. "The restrictions (based on security reasons) to install an extension from a site different than mozilla addons" If someone convinces you to install a malicious browser extension (easily done in a world where people will click OK on basically anything) they can spy on and control everything you do online.
- wslh 14y ago> If someone convinces you to install a malicious browser extension (easily done in a world where people will click OK on basically anything) they can spy on and control everything you do online. Do you think then that for example desktop software must be installed from a central company like Microsoft because someone can convince you to install it from every website? And also: do you think that Mozilla was really doing security inspections in the early days? No, it wasn't, the extensions had all kind of security bugs. I think it was more about control.
- noelwelsh 14y agoMozilla Research is awesome. They punch way way way above their weight. Google is chock full of programming language people, but Mozilla's work on Rust and Javascript (ES6, asm.js, sweet.js) is producing far better languages than Google has done with Go and Dart in my humble opinion.
- wslh 14y agoYou can't compare Google Research against Mozilla Research. Google is really moving computer science forward, just look at their papers and real implementations (disclaimer: I am not a Google fan). If you compare the Google Chrome source code vs Firefox you will quickly understand how miles ahead Google is.
- noelwelsh 14y agoMy opinion is that what Mozilla produces in the domain of programming languages is superior to what Google produces in the same domain. I make no claims comparing the two outside this domain. Google has far more resources than Mozilla, and produces loads of great stuff in many domains. I use both browsers daily (Aurora specifically, for Firefox) and have no preference between them. I have no opinion on their source code.
- seanmcdirmid 14y agoGoogle has been pretty influential in PL, especially in the PL/systems domain (MapReduce); just because they aren't designing so many mainstream languages doesn't mean people like Jeff Dean aren't putting their PL skillz to work. In fact, many of the heavy hitters at Google have PL backgrounds and do a lot of PL work, they are just pragmatic and realize that not all PL work involves overtly new languages. And then there is what Holzle, Bak, Bracha, etc...are doing with Dart; and of course Pike with Go.
- OrsenPike 14y agoTo be fair though Chrome was started from scratch in 2007/2008 whereas Firefox has a lot of legacy stuff still hanging around from the early 2000s.
- pohl 14y agoAs Peter Norvig argued, design patterns are bug reports against your programming language. Does anybody know what the actual quote is? I love this.
- OrsenPike 14y agoCheck out the following http://en.wikipedia.org/wiki/Software_design_pattern#Criticism http://en.wikipedia.org/wiki/Software_design_pattern#Critici... Also http://c2.com/cgi/wiki?AreDesignPatternsMissingLanguageFeatures http://c2.com/cgi/wiki?AreDesignPatternsMissingLanguageFeatu... and http://c2.com/cgi/wiki?DesignPatternsInDynamicProgramming http://c2.com/cgi/wiki?DesignPatternsInDynamicProgramming
- gabriel 14y agoThere was a link: http://www.norvig.com/design-patterns/ http://www.norvig.com/design-patterns/ I think you are looking for an exact quote but the link is to slides of a talk :( I also agree with the sentiment, but you Architecture Astronaut will no doubt disagree. You really can't just take a design pattern and apply it blindly across languages. I spend far too much of my time on a C# application where I have to deconstruct anti-patterns and make them more amenable to change.
- pohl 14y agoYeah, I've shared that sentiment for a while now, but it was the turn of phrase that pulled me in, and I wanted to know whether to attribute it to Peter or Brendan.
- BrendanEich 14y agoI turned that particular phrase based on Peter Norvig's old Harlequin-era talk. I've also heard people say that "design patterns are feature requests", or "the kindest form of feature request", but bug or feature -- what's the difference? /be
- fuzzix 14y agoAn aside, but I like this series of articles on design patterns in Perl, first here: http://www.perl.com/pub/2003/06/13/design1.html http://www.perl.com/pub/2003/06/13/design1.html "If a pattern is really valuable, then it should be part of the core language"