<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/node-new.git/benchmark/http/client-request-body.js, branch Remove-Python-3-tests</title>
<subtitle>github.com: nodejs/node.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/'/>
<entry>
<title>benchmark: refactor for consistent style</title>
<updated>2019-02-07T06:18:31+00:00</updated>
<author>
<name>Rich Trott</name>
<email>rtrott@gmail.com</email>
</author>
<published>2019-02-05T06:06:08+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=29e74d4952b772f7f1bf51e1a8f1665bbbde39d1'/>
<id>29e74d4952b772f7f1bf51e1a8f1665bbbde39d1</id>
<content type='text'>
Code in benchmark directory sometimes uses `function () {}` for
anonymous callbacks and sometimes uses `() =&gt; {}`. Multi-line arrays
sometimes have a trailing comma and sometimes do not. Update to always
use arrow functions for anonymous callbacks and trailing commas for
multiline arrays.

PR-URL: https://github.com/nodejs/node/pull/25944
Reviewed-By: Anto Aravinth &lt;anto.aravinth.cse@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Code in benchmark directory sometimes uses `function () {}` for
anonymous callbacks and sometimes uses `() =&gt; {}`. Multi-line arrays
sometimes have a trailing comma and sometimes do not. Update to always
use arrow functions for anonymous callbacks and trailing commas for
multiline arrays.

PR-URL: https://github.com/nodejs/node/pull/25944
Reviewed-By: Anto Aravinth &lt;anto.aravinth.cse@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>benchmark: (http) use destructuring</title>
<updated>2018-01-23T00:29:28+00:00</updated>
<author>
<name>Ruben Bridgewater</name>
<email>ruben@bridgewater.de</email>
</author>
<published>2017-12-30T02:57:46+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=a52878c23911df269cd86dbca35d1d75a6468efe'/>
<id>a52878c23911df269cd86dbca35d1d75a6468efe</id>
<content type='text'>
PR-URL: https://github.com/nodejs/node/pull/18250
Reviewed-By: Matteo Collina &lt;matteo.collina@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
PR-URL: https://github.com/nodejs/node/pull/18250
Reviewed-By: Matteo Collina &lt;matteo.collina@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>benchmark: var to const</title>
<updated>2017-09-20T00:14:38+00:00</updated>
<author>
<name>Ruben Bridgewater</name>
<email>ruben@bridgewater.de</email>
</author>
<published>2017-09-14T01:48:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=e167ab71fb113fa38866dd11aa99af7079fb463c'/>
<id>e167ab71fb113fa38866dd11aa99af7079fb463c</id>
<content type='text'>
PR-URL: https://github.com/nodejs/node/pull/13757
Reviewed-By: Matteo Collina &lt;matteo.collina@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
Reviewed-By: Luigi Pinca &lt;luigipinca@gmail.com&gt;
Reviewed-By: Gibson Fahnestock &lt;gibfahn@gmail.com&gt;
Reviewed-By: Tobias Nießen &lt;tniessen@tnie.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
PR-URL: https://github.com/nodejs/node/pull/13757
Reviewed-By: Matteo Collina &lt;matteo.collina@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
Reviewed-By: Luigi Pinca &lt;luigipinca@gmail.com&gt;
Reviewed-By: Gibson Fahnestock &lt;gibfahn@gmail.com&gt;
Reviewed-By: Tobias Nießen &lt;tniessen@tnie.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>benchmark: control HTTP benchmarks run time</title>
<updated>2017-04-09T10:16:08+00:00</updated>
<author>
<name>Joyee Cheung</name>
<email>joyeec9h3@gmail.com</email>
</author>
<published>2017-03-29T15:31:31+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=3e3414f45fb872fd4378132f6aa893806b2fad98'/>
<id>3e3414f45fb872fd4378132f6aa893806b2fad98</id>
<content type='text'>
PR-URL: https://github.com/nodejs/node/pull/12121
Refs: https://github.com/nodejs/node/issues/12068
Reviewed-By: Rich Trott &lt;rtrott@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
PR-URL: https://github.com/nodejs/node/pull/12121
Refs: https://github.com/nodejs/node/issues/12068
Reviewed-By: Rich Trott &lt;rtrott@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>benchmark: replace [].join() with ''.repeat()</title>
<updated>2017-04-04T16:19:18+00:00</updated>
<author>
<name>Vse Mozhet Byt</name>
<email>vsemozhetbyt@gmail.com</email>
</author>
<published>2017-04-02T21:32:50+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=74dc3bfe08b8f0a47759206d3d9d4d6f5a0528c1'/>
<id>74dc3bfe08b8f0a47759206d3d9d4d6f5a0528c1</id>
<content type='text'>
Also add a benchmark to compare both ways to create strings.

PR-URL: https://github.com/nodejs/node/pull/12170
Reviewed-By: Luigi Pinca &lt;luigipinca@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Also add a benchmark to compare both ways to create strings.

PR-URL: https://github.com/nodejs/node/pull/12170
Reviewed-By: Luigi Pinca &lt;luigipinca@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>benchmark: missing process.exit after bench.end</title>
<updated>2016-07-26T11:21:50+00:00</updated>
<author>
<name>Andreas Madsen</name>
<email>amwebdk@gmail.com</email>
</author>
<published>2016-05-31T19:49:16+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=8bb59fdb127b060d38430c0428d7783931ebec6e'/>
<id>8bb59fdb127b060d38430c0428d7783931ebec6e</id>
<content type='text'>
Previously bench.end would call process.exit(0) however this is rather
confusing and indeed a few benchmarks had code that assumed otherwise.

This adds process.exit(0) to the benchmarks that needs it.

PR-URL: https://github.com/nodejs/node/pull/7094
Reviewed-By: Trevor Norris &lt;trev.norris@gmail.com&gt;
Reviewed-By: Jeremiah Senkpiel &lt;fishrock123@rocketmail.com&gt;
Reviewed-By: Brian White &lt;mscdex@mscdex.net&gt;
Reviewed-By: Anna Henningsen &lt;anna@addaleax.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Previously bench.end would call process.exit(0) however this is rather
confusing and indeed a few benchmarks had code that assumed otherwise.

This adds process.exit(0) to the benchmarks that needs it.

PR-URL: https://github.com/nodejs/node/pull/7094
Reviewed-By: Trevor Norris &lt;trev.norris@gmail.com&gt;
Reviewed-By: Jeremiah Senkpiel &lt;fishrock123@rocketmail.com&gt;
Reviewed-By: Brian White &lt;mscdex@mscdex.net&gt;
Reviewed-By: Anna Henningsen &lt;anna@addaleax.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>buffer: add .from(), .alloc() and .allocUnsafe()</title>
<updated>2016-03-16T15:34:02+00:00</updated>
<author>
<name>James M Snell</name>
<email>jasnell@gmail.com</email>
</author>
<published>2016-01-25T23:00:06+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=85ab4a5f1281c4e1dd06450ac7bd3250326267fa'/>
<id>85ab4a5f1281c4e1dd06450ac7bd3250326267fa</id>
<content type='text'>
Several changes:

* Soft-Deprecate Buffer() constructors
* Add `Buffer.from()`, `Buffer.alloc()`, and `Buffer.allocUnsafe()`
* Add `--zero-fill-buffers` command line option
* Add byteOffset and length to `new Buffer(arrayBuffer)` constructor
* buffer.fill('') previously had no effect, now zero-fills
* Update the docs

PR-URL: https://github.com/nodejs/node/pull/4682
Reviewed-By: Сковорода Никита Андреевич &lt;chalkerx@gmail.com&gt;
Reviewed-By: Stephen Belanger &lt;admin@stephenbelanger.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Several changes:

* Soft-Deprecate Buffer() constructors
* Add `Buffer.from()`, `Buffer.alloc()`, and `Buffer.allocUnsafe()`
* Add `--zero-fill-buffers` command line option
* Add byteOffset and length to `new Buffer(arrayBuffer)` constructor
* buffer.fill('') previously had no effect, now zero-fills
* Update the docs

PR-URL: https://github.com/nodejs/node/pull/4682
Reviewed-By: Сковорода Никита Андреевич &lt;chalkerx@gmail.com&gt;
Reviewed-By: Stephen Belanger &lt;admin@stephenbelanger.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>benchmark: use strict mode</title>
<updated>2016-02-22T19:09:26+00:00</updated>
<author>
<name>Rich Trott</name>
<email>rtrott@gmail.com</email>
</author>
<published>2016-02-20T01:03:16+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=4bb529d972afaa02d57a2ca29db33ac92f69b81d'/>
<id>4bb529d972afaa02d57a2ca29db33ac92f69b81d</id>
<content type='text'>
Apply strict mode to benchmark code.

PR-URL: https://github.com/nodejs/node/pull/5336
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
Reviewed-By: Jeremiah Senkpiel &lt;fishrock123@rocketmail.com&gt;
Reviewed-By: Roman Reiss &lt;me@silverwind.io&gt;
Reviewed-By: Ben Noordhuis &lt;info@bnoordhuis.nl&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Apply strict mode to benchmark code.

PR-URL: https://github.com/nodejs/node/pull/5336
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
Reviewed-By: Jeremiah Senkpiel &lt;fishrock123@rocketmail.com&gt;
Reviewed-By: Roman Reiss &lt;me@silverwind.io&gt;
Reviewed-By: Ben Noordhuis &lt;info@bnoordhuis.nl&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>benchmark: remove extra spacing in http options</title>
<updated>2015-01-30T21:09:10+00:00</updated>
<author>
<name>Brendan Ashworth</name>
<email>brendan.ashworth@me.com</email>
</author>
<published>2015-01-29T06:14:57+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=083c421b5ca08576897b5da396085a462010780e'/>
<id>083c421b5ca08576897b5da396085a462010780e</id>
<content type='text'>
This commit removes the benchmark spacing modification in
`client-request-body.js` and `end-vs-write-end.js` which adds two spaces
to the end of some variables to make sure the lines line up.

The reason behind this is that its totally pointless (the lines don't
actually line up with it) and it disallows you to parse the output with
a tool like awk, or at least makes it a lot harder.

PR-URL: https://github.com/iojs/io.js/pull/650
Reviewed-By: Colin Ihrig &lt;cjihrig@gmail.com&gt;
Reviewed-By: Ben Noordhuis &lt;info@bnoordhuis.nl&gt;
Reviewed-By: Jeremiah Senkpiel &lt;fishrock123@rocketmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commit removes the benchmark spacing modification in
`client-request-body.js` and `end-vs-write-end.js` which adds two spaces
to the end of some variables to make sure the lines line up.

The reason behind this is that its totally pointless (the lines don't
actually line up with it) and it disallows you to parse the output with
a tool like awk, or at least makes it a lot harder.

PR-URL: https://github.com/iojs/io.js/pull/650
Reviewed-By: Colin Ihrig &lt;cjihrig@gmail.com&gt;
Reviewed-By: Ben Noordhuis &lt;info@bnoordhuis.nl&gt;
Reviewed-By: Jeremiah Senkpiel &lt;fishrock123@rocketmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>http: save roundtrips, convert buffers to strings</title>
<updated>2013-05-23T00:13:26+00:00</updated>
<author>
<name>Ben Noordhuis</name>
<email>info@bnoordhuis.nl</email>
</author>
<published>2013-05-22T19:43:35+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=fda2b319dc8a5dae528f8b12096911b71a0282db'/>
<id>fda2b319dc8a5dae528f8b12096911b71a0282db</id>
<content type='text'>
This commit adds an optimization to the HTTP client that makes it
possible to:

* Pack the headers and the first chunk of the request body into a
  single write().

* Pack the chunk header and the chunk itself into a single write().

Because only one write() system call is issued instead of several,
the chances of data ending up in a single TCP packet are phenomenally
higher: the benchmark with `type=buf size=32` jumps from 50 req/s to
7,500 req/s, a 150-fold increase.

This commit removes the check from e4b716ef that pushes binary encoded
strings into the slow path. The commit log mentions that:

    We were assuming that any string can be concatenated safely to
    CRLF.  However, for hex, base64, or binary encoded writes, this
    is not the case, and results in sending the incorrect response.

For hex and base64 strings that's certainly true but binary strings
are 'das Ding an sich': string.length is the same before and after
decoding.

Fixes #5528.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commit adds an optimization to the HTTP client that makes it
possible to:

* Pack the headers and the first chunk of the request body into a
  single write().

* Pack the chunk header and the chunk itself into a single write().

Because only one write() system call is issued instead of several,
the chances of data ending up in a single TCP packet are phenomenally
higher: the benchmark with `type=buf size=32` jumps from 50 req/s to
7,500 req/s, a 150-fold increase.

This commit removes the check from e4b716ef that pushes binary encoded
strings into the slow path. The commit log mentions that:

    We were assuming that any string can be concatenated safely to
    CRLF.  However, for hex, base64, or binary encoded writes, this
    is not the case, and results in sending the incorrect response.

For hex and base64 strings that's certainly true but binary strings
are 'das Ding an sich': string.length is the same before and after
decoding.

Fixes #5528.
</pre>
</div>
</content>
</entry>
</feed>
