Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Optimization of string.c
- X-seq: zsh-workers 36787
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: Sebastian Gniazdowski <sgniazdowski@xxxxxxxxx>, zsh-workers@xxxxxxx
- Subject: Re: Optimization of string.c
- Date: Mon, 5 Oct 2015 14:18:56 -0700
- In-reply-to: <CAKc7PVAZeK-gUtkQF0ZJhFh0z1DW=z-u5B4aTu668Vn3rSX6Ow@mail.gmail.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <CAKc7PVAZeK-gUtkQF0ZJhFh0z1DW=z-u5B4aTu668Vn3rSX6Ow@mail.gmail.com>
On Oct 5, 7:23pm, Sebastian Gniazdowski wrote:
}
} It might be that the faster the CPU is, the lower the gain is. If
} someone could repeat the tests on machine with 1.5 GHz or more it
} would be of value.
I ran the tests twice each, once built without the patch (and with
--enable-zsh-debug) and the other using the patch (but not debug,
accidentally), on a VirtualBox VM inside a 3.2GHz host. cpuinfo in
the VM guest reports the same values as the host, whether that's an
accurate measure or not. I may try again later with more care to
be sure the compiler flags are the same.
Note in the testopt2 and testopt4 cases performance was worse with
the patch, which is why I decided to send this even though I messed
up the configure flags. Best viewed in fixed-width.
No patch w/ debug | Patch w/o debug
-----------------------------------|----------------------------------
|
testopt1 | testopt1
|
num calls time | num calls time
-----------------------------------|----------------------------------
1) 5 2214.75 442.95 | 1) 5 1690.37 338.07
1) 5 2191.67 438.33 | 1) 5 1697.04 339.41
|
-----------------------------------|----------------------------------
|
testopt2 | testopt2
|
num calls time | num calls time
-----------------------------------|----------------------------------
1) 5 271.99 54.40 | 1) 5 311.95 62.39
1) 5 274.84 54.97 | 1) 5 312.72 62.54
|
-----------------------------------|----------------------------------
|
testopt3 | testopt3
|
num calls time | num calls time
-----------------------------------|----------------------------------
1) 1 13331.32 13331.32 | 1) 1 10533.46 10533.46
1) 1 13468.76 13468.76 | 1) 1 10538.59 10538.59
|
-----------------------------------|----------------------------------
|
testopt4 | testopt4
|
num calls time | num calls time
-----------------------------------|----------------------------------
1) 1 2085.65 2085.65 | 1) 1 2442.47 2442.47
1) 1 2010.71 2010.71 | 1) 1 2523.01 2523.01
|
-----------------------------------|----------------------------------
Messages sorted by:
Reverse Date,
Date,
Thread,
Author