Skip to content

Instantly share code, notes, and snippets.

@bnoordhuis
Created March 7, 2012 21:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bnoordhuis/2c62b4e8d151a64a918b to your computer and use it in GitHub Desktop.
Save bnoordhuis/2c62b4e8d151a64a918b to your computer and use it in GitHub Desktop.
diff --git a/benchmark/http_simple_auto.js b/benchmark/http_simple_auto.js
index 4e136a6..06cf9fa 100644
--- a/benchmark/http_simple_auto.js
+++ b/benchmark/http_simple_auto.js
@@ -34,10 +34,8 @@ var server = http.createServer(function (req, res) {
if (n <= 0)
throw "bytes called with n <= 0"
if (stored[n] === undefined) {
- stored[n] = "";
- for (var i = 0; i < n; i++) {
- stored[n] += "C"
- }
+ stored[n] = "C";
+ while (stored[n].length < n) stored[n] += stored[n];
}
body = stored[n];
diff --git a/common.gypi b/common.gypi
index 6e13b60..41f9f29 100644
--- a/common.gypi
+++ b/common.gypi
@@ -35,6 +35,7 @@
},
},
'Release': {
+ 'defines': [ 'NDEBUG', '_NDEBUG' ],
'cflags': [ '-O3', '-fdata-sections', '-ffunction-sections' ],
'conditions': [
['target_arch=="x64"', {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment