summaryrefslogtreecommitdiff
path: root/benchmark/net
diff options
context:
space:
mode:
authorAndreas Madsen <amwebdk@gmail.com>2016-05-31 21:49:16 +0200
committerAndreas Madsen <amwebdk@gmail.com>2016-07-26 13:21:50 +0200
commit8bb59fdb127b060d38430c0428d7783931ebec6e (patch)
treefb0ba5c611c27b19480c11349283030cf463d986 /benchmark/net
parentf99471b2ae147fbb072223be62e9100862379dc8 (diff)
downloadandroid-node-v8-8bb59fdb127b060d38430c0428d7783931ebec6e.tar.gz
android-node-v8-8bb59fdb127b060d38430c0428d7783931ebec6e.tar.bz2
android-node-v8-8bb59fdb127b060d38430c0428d7783931ebec6e.zip
benchmark: missing process.exit after bench.end
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 <trev.norris@gmail.com> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Anna Henningsen <anna@addaleax.net>
Diffstat (limited to 'benchmark/net')
-rw-r--r--benchmark/net/net-c2s-cork.js1
-rw-r--r--benchmark/net/net-c2s.js1
-rw-r--r--benchmark/net/net-pipe.js1
-rw-r--r--benchmark/net/net-s2c.js1
-rw-r--r--benchmark/net/tcp-raw-c2s.js1
-rw-r--r--benchmark/net/tcp-raw-pipe.js1
-rw-r--r--benchmark/net/tcp-raw-s2c.js1
7 files changed, 7 insertions, 0 deletions
diff --git a/benchmark/net/net-c2s-cork.js b/benchmark/net/net-c2s-cork.js
index 5e8dd349d6..6af9162025 100644
--- a/benchmark/net/net-c2s-cork.js
+++ b/benchmark/net/net-c2s-cork.js
@@ -84,6 +84,7 @@ function server() {
var bytes = writer.received;
var gbits = (bytes * 8) / (1024 * 1024 * 1024);
bench.end(gbits);
+ process.exit(0);
}, dur * 1000);
function send() {
diff --git a/benchmark/net/net-c2s.js b/benchmark/net/net-c2s.js
index 2c3bbe3c6a..9b4df2f5a7 100644
--- a/benchmark/net/net-c2s.js
+++ b/benchmark/net/net-c2s.js
@@ -106,6 +106,7 @@ function server() {
var bytes = writer.received;
var gbits = (bytes * 8) / (1024 * 1024 * 1024);
bench.end(gbits);
+ process.exit(0);
}, dur * 1000);
});
});
diff --git a/benchmark/net/net-pipe.js b/benchmark/net/net-pipe.js
index fd3a6d4f43..03db348878 100644
--- a/benchmark/net/net-pipe.js
+++ b/benchmark/net/net-pipe.js
@@ -109,6 +109,7 @@ function server() {
var bytes = writer.received * 2;
var gbits = (bytes * 8) / (1024 * 1024 * 1024);
bench.end(gbits);
+ process.exit(0);
}, dur * 1000);
});
});
diff --git a/benchmark/net/net-s2c.js b/benchmark/net/net-s2c.js
index fc3f3e1389..469b66a25a 100644
--- a/benchmark/net/net-s2c.js
+++ b/benchmark/net/net-s2c.js
@@ -106,6 +106,7 @@ function server() {
var bytes = writer.received;
var gbits = (bytes * 8) / (1024 * 1024 * 1024);
bench.end(gbits);
+ process.exit(0);
}, dur * 1000);
});
});
diff --git a/benchmark/net/tcp-raw-c2s.js b/benchmark/net/tcp-raw-c2s.js
index e9dd7ca662..c33c6d0f2a 100644
--- a/benchmark/net/tcp-raw-c2s.js
+++ b/benchmark/net/tcp-raw-c2s.js
@@ -56,6 +56,7 @@ function server() {
setTimeout(function() {
// report in Gb/sec
bench.end((bytes * 8) / (1024 * 1024 * 1024));
+ process.exit(0);
}, dur * 1000);
clientHandle.onread = function(nread, buffer) {
diff --git a/benchmark/net/tcp-raw-pipe.js b/benchmark/net/tcp-raw-pipe.js
index fb8da5ea41..b7c6776c95 100644
--- a/benchmark/net/tcp-raw-pipe.js
+++ b/benchmark/net/tcp-raw-pipe.js
@@ -116,6 +116,7 @@ function client() {
// multiply by 2 since we're sending it first one way
// then then back again.
bench.end(2 * (bytes * 8) / (1024 * 1024 * 1024));
+ process.exit(0);
}, dur * 1000);
while (clientHandle.writeQueueSize === 0)
diff --git a/benchmark/net/tcp-raw-s2c.js b/benchmark/net/tcp-raw-s2c.js
index a7ef40db83..a7eeed1921 100644
--- a/benchmark/net/tcp-raw-s2c.js
+++ b/benchmark/net/tcp-raw-s2c.js
@@ -135,6 +135,7 @@ function client() {
setTimeout(function() {
// report in Gb/sec
bench.end((bytes * 8) / (1024 * 1024 * 1024));
+ process.exit(0);
}, dur * 1000);
};
}