Loading ...
Sorry, an error occurred while loading the content.

Re: [jslint] Re: Actual JavaScript Engine Performance

Expand Messages
  • Jean-Charles Meyrignac
    I m sorry, but this is not an answer to my question. How did you compute the benchmark ? Did you run JSLint 10 times on every browser, removed the slowest and
    Message 1 of 18 , Apr 21 4:56 PM
    • 0 Attachment
      I'm sorry, but this is not an answer to my question.

      How did you compute the benchmark ?

      Did you run JSLint 10 times on every browser, removed the slowest and faster
      runs, and computed the average of the remaining runs ? (I think that this is
      the standard method to compute benchmarks).

      Or did you run the program once, and just displayed the time it took to run
      the program ?

      Browsers tend to be slow when you start them, and Chrome is very slow when
      you open a window (see how much memory it consumes !).
      I guess also that their JS engine may be slower to generate assembly code,
      but probably does a better job at optimizing it.
      On the other hand, and I hope I'm not wrong, JSLint doesn't heavily execute
      loops, so converting it to assembly code should not be very efficient.

      Another thing is that, in order to appear fast, the browsers tend to redraw
      the loaded page frequently, and this slows down the Javascript engine.

      In the case of Chrome, the 2.801 seconds may be an artefact.

      JC
      (Not trying to defend Chrome, since I prefer Firefox !)


      On Fri, Apr 22, 2011 at 1:31 AM, Douglas Crockford <douglas@...>wrote:

      >
      >
      > The JSLint benchmark is a measure of JavaScript performance. It does not
      > attempt to measure overall browser performance. It does not look at
      > network efficiency, marshalling, rendering, layout, or any factor other
      > than the execution of JavaScript. Most web applications are DOM limited.
      > Such applications benefit little if at all from improved JavaScript
      > performance. The benefit of the new faster JavaScript engines is the
      > enabling of new kinds of applications.
      >
      > The JSLint benchmark is 6.6KLOC. Ordinary benchmarks tend to be much
      > smaller. It does a good mix or regular expressions, string building
      > with + and join, and prototypal and functional patterns.
      >
      > I was very surprised to see Chrome score at the bottom. My expectation
      > was that it would score at the top. I don't know why that was the case.
      >
      >


      [Non-text portions of this message have been removed]
    • Douglas Crockford
      ... Try the experiment yourself.
      Message 2 of 18 , Apr 21 5:17 PM
      • 0 Attachment
        --- In jslint_com@yahoogroups.com, Jean-Charles Meyrignac <jcmeyrignac@...> wrote:
        >
        > I'm sorry, but this is not an answer to my question.
        >
        > How did you compute the benchmark ?
        >
        > Did you run JSLint 10 times on every browser, removed the slowest and faster
        > runs, and computed the average of the remaining runs ? (I think that this is
        > the standard method to compute benchmarks).
        >
        > Or did you run the program once, and just displayed the time it took to run
        > the program ?
        >
        > Browsers tend to be slow when you start them, and Chrome is very slow when
        > you open a window (see how much memory it consumes !).
        > I guess also that their JS engine may be slower to generate assembly code,
        > but probably does a better job at optimizing it.
        > On the other hand, and I hope I'm not wrong, JSLint doesn't heavily execute
        > loops, so converting it to assembly code should not be very efficient.
        >
        > Another thing is that, in order to appear fast, the browsers tend to redraw
        > the loaded page frequently, and this slows down the Javascript engine.
        >
        > In the case of Chrome, the 2.801 seconds may be an artefact.

        Try the experiment yourself.
      • Jean-Charles Meyrignac
        Here are my timings, I have an old laptop with Windows 7 64-bits: Firefox 4.0: 0.807 seconds IE 9: 1.113 seconds Chrome: 1.867 seconds I guess that the
        Message 3 of 18 , Apr 21 5:24 PM
        • 0 Attachment
          Here are my timings, I have an old laptop with Windows 7 64-bits:

          Firefox 4.0: 0.807 seconds
          IE 9: 1.113 seconds
          Chrome: 1.867 seconds

          I guess that the rendering is slow, because the result page is large.

          JC

          On Fri, Apr 22, 2011 at 2:17 AM, Douglas Crockford <douglas@...>wrote:

          >
          >
          > --- In jslint_com@yahoogroups.com, Jean-Charles Meyrignac <jcmeyrignac@...>
          > wrote:
          > >
          >
          > Try the experiment yourself.
          >
          >


          [Non-text portions of this message have been removed]
        • Douglas Crockford
          ... That is in line with my results. ... Rendering is not a factor. It only measures JavaScript execution. Chrome executes slower.
          Message 4 of 18 , Apr 21 5:30 PM
          • 0 Attachment
            --- In jslint_com@yahoogroups.com, Jean-Charles Meyrignac <jcmeyrignac@...> wrote:

            > Here are my timings, I have an old laptop with Windows 7 64-bits:
            >
            > Firefox 4.0: 0.807 seconds
            > IE 9: 1.113 seconds
            > Chrome: 1.867 seconds

            That is in line with my results.

            > I guess that the rendering is slow, because the result page is large.

            Rendering is not a factor. It only measures JavaScript execution.
            Chrome executes slower.
          Your message has been successfully submitted and would be delivered to recipients shortly.