Slashdot Mirror


Facebook Develops HTML5 Gaming Benchmark

An anonymous reader writes "A couple of Facebook engineers are developing an HTML5 gaming benchmark. They write, 'Two weeks ago Bruce and I released JSGameBench version 0.1. Today marks the release of version 0.2, a much faster and cleaner version. We continue to learn both from tightening the code and from the strong HTML5 community. Version 0.2 reinforces our belief in HTML5 as a strong, horizontal platform for games and highly interactive applications across the web.'"

49 of 84 comments (clear)

  1. Why is this tagged Chrome by Anonymous Coward · · Score: 2, Informative
    1. Re:Why is this tagged Chrome by Anonymous Coward · · Score: 2, Funny

      When firefox kicks the shit out of it in the benchmark

      Because Chrome fanboys* are a lot like Apple fanboys* -- unconcerned with objective evidence of any kind. They are unable to appreciate Mozilla's accomplishments and strengths because they weren't done by "their team" and anyone not on "their team" is TEH ENEMY. Course, "their team" is sort of like the fat couch potatoes who see their favorite football team win a game and say "fuck yeah, we won" and the only correct response is "really? I didn't see you out there on that field". So they won, you shallow dipshits who'd have no identity whatsoever if you couldn't borrow some organization's.

      * There's a big, BIG difference between someone who uses a thing because it meets his/her needs and gives a satisfying experience but has no special loyalty to any corporation or brand name, versus someone who must fanatically defend their favorite corporate logo and make it look good whether or not it deserves to like some religious crusade because it's become an unhealthy extension of their ego. I know the Slashdot crowd doesn't do such a good job making these distinctions so I am spelling it out for you. Oh you'll knee-jerk anyway but now you'll do it with no excuse.

    2. Re:Why is this tagged Chrome by Thing+1 · · Score: 1

      My new favorite response to office football discussions.

      --
      I feel fantastic, and I'm still alive.
    3. Re:Why is this tagged Chrome by adamofgreyskull · · Score: 2

      tl;dr watch this.

    4. Re:Why is this tagged Chrome by bunratty · · Score: 1

      I never realized that religious wars over differing programs were like sports until now. I've never understand how people can argue over vi vs. emacs or Firefox vs. Chrome vs. Opera. I've never been into sports, either. Is it some sort of territorial thing?

      --
      What a fool believes, he sees, no wise man has the power to reason away.
    5. Re:Why is this tagged Chrome by BZ · · Score: 1

      Not quite territorial. Tribal. There's your tribe, and the Others. And you have to protect your tribe from those Others....

    6. Re:Why is this tagged Chrome by perryizgr8 · · Score: 1

      hell even ie9 scores better. chrome outhta be ashamed.

      --
      Wealth is the gift that keeps on giving.
    7. Re:Why is this tagged Chrome by Zelgadiss · · Score: 1

      Well, Chrome 11 is still in alpha though.

      And from what I noticed, while Chrome seems to "lag" other browsers when you compare versions, but due to it's ridiculously fast development cycle it almost always catches up if not surpass it's competition.

      People have been saying, IE9 has this, FF4 has that, since ... Chrome 7, and they both still aren't out yet.

    8. Re:Why is this tagged Chrome by nyctopterus · · Score: 1

      No, Webkit is slow at compositing images, which I'm sure is what this benchmark reflecting. Firefox is really fast. Interestingly, this seems to be the case whether you use a bunch of HTML elements or canvas. The image rendering in Webkit needs an overhaul.

      I found this out when I was making this. Check it out in Firefox or Opera compared to Safari or Chrome.

    9. Re:Why is this tagged Chrome by Zelgadiss · · Score: 1

      Interesting.

      It's quite a lot more jerky in Safari and Chrome.

      Looks like this is something the Webkit guys need to work on.

    10. Re:Why is this tagged Chrome by kyrio · · Score: 1

      Nope, I dislike "professional" sports because it's a waste of money.

  2. Chrome 11? by quantumphaze · · Score: 1

    Didn't they just release Chrome 10 beta? It's still on the front page of Slashdot (at this time).

    1. Re:Chrome 11? by teh31337one · · Score: 1

      I'm on 11.0.672.2 dev. They have a stable release (9.x), a beta release (10.x), and a dev release(11.x).

    2. Re:Chrome 11? by rtaylor · · Score: 1

      You can assume they're using a version currently under development.

      --
      Rod Taylor
  3. All OSX browsers are really slow here by dotwhynot · · Score: 2

    Kind of ironic when Apple is the company that is most vocal about HTML5 replacing Flash. http://developers.facebook.com/attachment/scores.png

    1. Re:All OSX browsers are really slow here by inpher · · Score: 2

      They tested Chrome 11 and Firefox 4 and IE9 (all development versions) but not the development version of Safari: WebKit.

    2. Re:All OSX browsers are really slow here by dakameleon · · Score: 1

      The fastest non-BETA browser is Safari 5 on OSX. Your point?

      --
      Man who leaps off cliff jumps to conclusion.
    3. Re:All OSX browsers are really slow here by inpher · · Score: 1

      Oh, I forgot, the latest stable Chrome on OS X is 9.0.597.102 which makes Chrome 10 a development version also. So unless Chrome 10 on Windows is a shipping stable version, then Safari is doing pretty well.

    4. Re:All OSX browsers are really slow here by Anonymous Coward · · Score: 1

      I have first hand experience that browsing is sub-par on OS X using any mainstream browser - Safari, Chrome, FF. I recently bought a top end Macbook Pro (Core i7 Nvidia 330M) and was very unimpressed with browsing performance - scrolling and page rendering mainly. I installed Win 7 and both Chrome and FF4 beta really shine in performance department - so much so that I am very reluctant to go back to OS X. FF4 it is explainable that the hardware acceleration may be making a difference but Chrome by default doesn't enable it and still feels great.

    5. Re:All OSX browsers are really slow here by dakameleon · · Score: 1

      Chrome 10 is BETA; Chrome 11 is more like nightly/alpha.

      --
      Man who leaps off cliff jumps to conclusion.
    6. Re:All OSX browsers are really slow here by inpher · · Score: 2

      Still a development versions. Makes no sense to exclude development versions of Opera and Safari when they both are readily available.

    7. Re:All OSX browsers are really slow here by DavidR1991 · · Score: 1

      Isn't this also because FF4 and IE9 both use hardware acceleration on Windows? (+ The points made already about comparing dev builds vs. stable)

    8. Re:All OSX browsers are really slow here by DavidR1991 · · Score: 1

      So? Pretty bloody obvious why it's worth noting: the task is wholly graphical in nature, so obviously hardware acceleration will give IE9 and FF4 an advantage on Windows (and FF4 is not HW accelerated on OS X). So it's kind of a no-brainer why there's a huge discrepancy

    9. Re:All OSX browsers are really slow here by Anonymous Coward · · Score: 1

      They didn't bother testing non-beta versions of Firefox or Chrome or *anything* on Linux or WinXP. This article is useless.

      WinXP is like IE6 - people still staying with a decade old system are clearly not interested in being up to date, so out of scope for this comparison.

    10. Re:All OSX browsers are really slow here by dakameleon · · Score: 1

      My point was that Chrome 10 is still Beta on Windows. Absolutely agree with your main point that the other browsers deserved to have their dev versions tested too.

      --
      Man who leaps off cliff jumps to conclusion.
    11. Re:All OSX browsers are really slow here by dakameleon · · Score: 1

      TFA is not the one you've linked there. TFA:

      Benchmarking

      In order to talk about browser performance, we needed to standardize. We now have two machines that will be our testing machines:

      For OS X: a MacBook Pro laptop, currently OS X 10.6.6, 4GB of RAM, 2.66 GHz Intel Core i7, and NVIDIA GT 330M with 512MB of RAM.
      For Windows: a Lenovo T410s laptop, currently Windows 7 Enterprise, 4GB of RAM, 2.53 GHz Intel Core i5, and NVIDIA NVS 3100M with 512MB of RAM.
      Both of these laptops are significantly less powerful than the Mac Pro the original tests were run on. In addition, the 3100M offers approximately half the performance of the 330M.

      Additionally, even in the article you linked to, Safari was the fastest non-beta browser.

      --
      Man who leaps off cliff jumps to conclusion.
    12. Re:All OSX browsers are really slow here by BZ · · Score: 1

      Yes, which is precisely the point. On Mac there is no way to easily do 2d hardware acceleration at the moment.

    13. Re:All OSX browsers are really slow here by TorKlingberg · · Score: 1

      They used different hardware for Windows and OS X. It looks like the Mac is actually more powerful though, so the OSX browsers should score higher if they were equally efficient.

      * For OS X: a MacBook Pro laptop, currently OS X 10.6.6, 4GB of RAM, 2.66 GHz Intel Core i7, and NVIDIA GT 330M with 512MB of RAM.
      * For Windows: a Lenovo T410s laptop, currently Windows 7 Enterprise, 4GB of RAM, 2.53 GHz Intel Core i5, and NVIDIA NVS 3100M with 512MB of RAM.

    14. Re:All OSX browsers are really slow here by inpher · · Score: 2

      Core Animation is the way to animate 2D on Mac OS X (and iOS). It is what is used to animate CSS (which the article touches upon). From what I can tell reading various developer blogs Core Animation seems pretty well liked.

    15. Re:All OSX browsers are really slow here by BZ · · Score: 1

      The problem is that Core Animation is too high-level. It wants to handle the entire animation itself, which makes it suitable for implementing CSS Transitions and CSS Animations (heck, the initial specs for those were basically "do what Core Animation does, because that's how we implemented it"), but not great for handling painting of web pages where you don't know what the web page will do next

      To put it in web terms, Core Animation is closer to being like SVG while Direct2D is closer to being like canvas. They both have their use cases, but do quite different things.

    16. Re:All OSX browsers are really slow here by tlhIngan · · Score: 1

      They used different hardware for Windows and OS X. It looks like the Mac is actually more powerful though, so the OSX browsers should score higher if they were equally efficient.

      * For OS X: a MacBook Pro laptop, currently OS X 10.6.6, 4GB of RAM, 2.66 GHz Intel Core i7, and NVIDIA GT 330M with 512MB of RAM.
      * For Windows: a Lenovo T410s laptop, currently Windows 7 Enterprise, 4GB of RAM, 2.53 GHz Intel Core i5, and NVIDIA NVS 3100M with 512MB of RAM.

      That makes no sense, really. Why use two different machines? Last I checked Boot Camp was perfectly well supported, and running them on the same machine would give far better results (and nice cross-OS comparisons, too).

      Hell, you can run Windows 7 on a Macbook Air these days (slightly tricky, but doable).

  4. Re:Facebook engineers? by maxume · · Score: 1

    They serve a massive number of complicated pages. They have been hiring people away from Google and such.

    --
    Nerd rage is the funniest rage.
  5. Re:Facebook engineers? by dakameleon · · Score: 2

    Think in terms of "software engineers" - 500 million users is a hefty workload for any single site.

    --
    Man who leaps off cliff jumps to conclusion.
  6. HTML5? by BenoitRen · · Score: 2

    Except for the canvas element, there's not much HTML5 to be found here. It's mostly about DOM manipulation using JavaScript and about fancy new CSS styles.

    1. Re:HTML5? by tepples · · Score: 2

      Except for the canvas element, there's not much HTML5 to be found here.

      It's precisely the 2D canvas that makes HTML5 game graphics practical.

    2. Re:HTML5? by am+2k · · Score: 1

      It's precisely the 2D canvas that makes HTML5 game graphics practical.

      Wrong, canvas isn't suited for games in current browsers. Moving around divs is much faster and much easier (no need to do image loading manually, no need to handle redraws, etc). The only issue is alpha-aware hit testing, that's actually impossible with divs.

      See this presentation by Paul Backaus (the guy behind jQuery UI and a javascript game engine that was bought by Zynga) starting on slide 31.

      WebGL will change a lot there, when it's finally working in all major browsers (except IE of course).

  7. Re:Facebook engineers? by Anonymous Coward · · Score: 1

    If you're really so good at making sites that serve billions of page views per month, has fairly low latency across the globe despite the huge volume and variety of requests being processed, has marketed itself successfully to half a billion active users worldwide, interface with hundreds of thousands of third party apps, work on a range of mobile devices... and no matter how crude and low-tech the front-end UI may feel to the end user, IT WORKS. If all these are just "routine IT skills" for you - ok, great, just show me where you're on the Forbes list and I'll definitely pay my respects.

    If not, you're just a sore loser.

  8. Rationalizing Bad Code by fatp · · Score: 1

    Is Facebook releasing this to rationalize their creation of ineffective code?

    1. Re:Rationalizing Bad Code by souravzzz · · Score: 1

      It is a comparison of HTML5 canvas drawing speed, fb uses no html5 for their webpages till now.

  9. Re:Facebook engineers? by FuckingNickName · · Score: 2

    If you're really so good at making sites that serve billions of page views per month

    Creating a routine site which "serves billions of page views per month" is a routine IT skill. Hell, creating a routine site which serves millions of page views requires no expertise at all, and is something I'm sure lots of enthusiasts posting here have done before the days of point-and-click blogs and social networking sites. So, is Facebook routine?

    has fairly low latency across the globe despite the huge volume

    Fifteen years ago called. They want your cutting edge content delivery network research.

    has marketed itself successfully to half a billion active users worldwide

    No disagreement here. Facebook knows how to sell itself.

    interface with hundreds of thousands of third party apps

    Have you actually used the Facebook API? While this is the only "engineered" component of Facebook, it's (i.e. the Graph API is) basically a frontend to tables of personal information and junction/link tables between them. Again, the skill here is the routine deployment of an SQL database.

    work on a range of mobile devices.

    Well, not on mine, but I think what you meant was: at least vaguely tested on the devices commonly used by their employees with remaining complaints perhaps fixed eventually, and with a translation API suiting the native language of a few of the more common mobile platforms.

    nd no matter how crude and low-tech the front-end UI may feel to the end user, IT WORKS.

    Nonsense. It's in a perpetual state of beta, and if you haven't seen it not working it's because you haven't used it often enough to be targeted for testing - at which point something on the site will break for a while and will get fixed only because enough people whine.

    If all these are just "routine IT skills" for you - ok, great, just show me where you're on the Forbes list and I'll definitely pay my respects.

    Ah, the nerd of 2011, whose skill is measured by "where you're on the Forbes list".

    Facebook is successful because it successfully preys on the social weaknesses of the average human. As an engineering feat, it is almost completely uninteresting.

  10. Flipping by tepples · · Score: 1

    Moving around divs is much faster

    One needs to horizontally flip an image when a character in a side-scrolling platformer faces the other way. Which browser can horizontally flip an image in a div? Otherwise, download size for sprite sheets doubles, as the server has to send both the unflipped and flipped versions of every cel.

    1. Re:Flipping by BZ · · Score: 1

      > Which browser can horizontally flip an image in a div?

      Any browser implementing CSS 2D Transforms (Firefox 3.5 or newer, Safari 3.2 or newer, Chrome at 7 and maybe even older, Opera 10.5 or newer, IE 9).

      So pretty much anything on the market that supports canvas supports transforms too.

    2. Re:Flipping by tepples · · Score: 1

      But good luck getting users of IE 8 on Windows XP, which isn't getting IE 9, to convince their local administrators to install the Google Chrome Frame plug-in. Flash Player gets a free pass because far more web sites require it than require the HTML features that Chrome Frame has and IE 8 lacks.

    3. Re:Flipping by Anonymous Coward · · Score: 1

      You asked which browser supported horizontally flipping and image, and when shown that virtually every modern browser supports it, you responded with the one that doesn't. It would have been more gentlemanly to admit you were wrong.

    4. Re:Flipping by BZ · · Score: 2

      Yes, but the original claim was that you have to do HTML5 games in canvas because you can't flip images otherwise. IE8 doesn't support canvas either, so if you're writing an HTML5 game with canvas you aren't targeting IE8 to start with.

  11. Re:Facebook engineers? by icebraining · · Score: 1

    Have you actually used the Facebook API? While this is the only "engineered" component of Facebook, it's (i.e. the Graph API is) basically a frontend to tables of personal information and junction/link tables between them. Again, the skill here is the routine deployment of an SQL database.

    They've actually develop their own non-relational database (Cassandra, now an Apache project).

  12. Re:Facebook engineers? by brantondaveperson · · Score: 1

    This is kind of a good point - no-one really cares that much if FBs pages break a little bit (as they often to, friends lists changing at random, comments not showing up, etc etc). You just refresh and (mostly) everything comes right.

    I'm not saying that FB isn't impressive, just that they don't have to hit especially high standards of data consistency in order to be a success.

  13. Please clear this up by pokyo · · Score: 1

    I'm ignorant when it comes to web programming. When creating games using HTML5 do developers need to be more concerned with code stealing than with Flash? There are already many duplicate games on the web, will this further compound the issue?

  14. I apologize for being unclear by tepples · · Score: 1

    when shown that virtually every modern browser supports it, you responded with the one that doesn't.

    I apologize for being unclear. I should have written the following: "Half of users don't use a modern browser. Good luck convincing them to."