Good point.


On Thu, Jan 2, 2014 at 1:08 PM, Jeff Pinner <notifications@github.com>wrote:

> In src/test/java/com/twitter/hpack/PerfTest.java:
>
> > +    for (int i = 0; i < args.length; i++) {
> > +      FileInputStream fis = new FileInputStream(args[i]);
> > +      testCases[i] = TestCase.load(fis);
> > +      fis.close();
> > +    }
> > +    return testCases;
> > +  }
> > +
> > +  public static void main(String[] args) throws Exception {
> > +    TestCase[] testCases = loadTestCases(args);
> > +
> > +    Encoder encoder = new Encoder(true, TABLE_SIZE, true, false, false);
> > +
> > +    long start = System.currentTimeMillis();
> > +
> > +    for (int i = 0; i < ITERATIONS; i++) {
>
> you need to time both a "warm-up" period and an "execution" period --
> otherwise you include time of things like jitting in the output -- see
> something like caliper
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/jpinner/hpack/pull/5/files#r8618354>
> .
>