0
0
mirror of https://github.com/nodejs/node.git synced 2024-12-01 16:10:02 +01:00
Commit Graph

7602 Commits

Author SHA1 Message Date
Nathan Rajlich
b916774255 configure: define "arm_fpu" and "arm_neon" for ARM
v8's common.gypi file expects them to be defined now.

Closes #4534.
2013-01-10 17:13:59 -08:00
yangguo@chromium.org
438e0c6d75 v8: Hardfloat does not imply VFPv3, only VFPv2.
Raspberry Pi is an example.

BUG=v8:2393

Review URL: https://chromiumcodereview.appspot.com/11570061
Patch from Chi-Thanh Christopher Nguyen <nguyenchithanh@gmail.com>.

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@13232 ce2b1a6d-e550-0410-aec6-3dcde31c8c00

This is a backport of v8/v8@44419ad089.
2013-01-10 17:02:59 -08:00
isaacs
9ece63b1d7 http: Don't switch the socket into old-mode 2013-01-10 13:50:06 -08:00
isaacs
bc8feb151c http: Use stream.push() instead of touching _readableState 2013-01-10 13:50:06 -08:00
isaacs
840401c024 net: Use readable.push() instead of private methods 2013-01-10 13:50:05 -08:00
isaacs
b43e544140 stream: Use push() for Transform._output()
This also slightly changes the semantics, in that a 'readable'
event may be triggered by the first write() call, even if a
user has not yet called read().

This happens because the Transform _write() handler is calling
read(0) to start the flow of data.  Technically, the new behavior
is more 'correct', since it is more in line with the semantics
of the 'readable' event in other streams.
2013-01-10 13:49:54 -08:00
isaacs
530585b2d1 stream: Use push() for readable.wrap() 2013-01-10 13:49:53 -08:00
isaacs
a993f740f0 stream: Add readable.push(chunk) method 2013-01-10 13:49:53 -08:00
Ben Noordhuis
a6756a2c06 test: run tests in alphabetical order 2013-01-10 01:58:30 +01:00
Dean McNamee
c207d400f1 typed arrays: implement load and store swizzling
Implement load and store swizzling operations. This reduces an unneeded
back and forth between types and additionally keeps the value in the
swappable type until it is swapped. This is important for correctness
when dealing with floating point, to avoid the possibility of loading
the bits of a signaling NaN (because it isn't yet swapped) into the FPU.

This additionally produces better code (comments are mine):

gcc version 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00)

setValue<double>:
  movd  %xmm0, %rax         ; fp reg -> gen reg
  bswapq  %rax              ; 64-bit byte swap
  movq  %rax, (%r15,%r12)   ; store
2013-01-09 17:44:25 +01:00
Dean McNamee
46a489be73 typed arrays: swizzle with compiler intrinsics
Implement swizzling with compiler intrinsics and be aware of the native
endianness to correctly swap on big endian machines.

This introduces a template function to swap the bytes of a value,
and macros for the low level swap (taking advantage of gcc and msvc
intrinsics). This produces code like the following (comments are mine):

gcc version 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00)

setValue<double>:
  movd  %xmm0, %rax         ; fp reg -> gen reg
  bswapq  %rax              ; 64-bit byte swap
  movd  %rax, %xmm0         ; gen reg -> fp reg
  movq  %xmm0, (%r15,%r12)  ; store
2013-01-09 17:44:25 +01:00
Ben Noordhuis
7d66a9d060 typed arrays: undo local changes
Partially revert 5664dd2, 6573fc3 and 7788a6b to ease landing changes
from upstream.
2013-01-09 17:43:19 +01:00
Shigeki Ohtsu
1211946a8c stream: fix typo
Also: Revert "stream: Override addListener as well as on"

This reverts commit 18c985919d.
2013-01-08 23:13:02 -08:00
isaacs
18c985919d stream: Override addListener as well as on
For the compatibility switch.
2013-01-08 14:27:01 -08:00
Fedor Indutny
45941811dc streams: set listener first, emit 'data' later
When switching into compatibility mode by setting `data` event listener,
`_read()` method will be called immediately. If method implementation
invokes callback in the same tick - all emitted `data` events will be
discarded, because `data` listener wasn't set yet.
2013-01-08 22:13:09 +04:00
Tim Bradshaw
e6acfed9cc doc: os.cpus() returns times in milliseconds 2013-01-08 05:38:36 +01:00
Dean McNamee
3f75454426 typed arrays: don't declare as module
TypedArrays is not a module, it is attached to the global object.
Don't register it with Node's module system.
2013-01-08 05:08:00 +01:00
Dean McNamee
b50d51ef5b typed arrays: replace switch with templates
Convert TypedArray's TypeName implementation to template specialization
instead of a switch() statement.
2013-01-08 05:08:00 +01:00
Shigeki Ohtsu
9b363b022f net: fix bufferSize include writableStream length
socket.bufferSize missed to include the length of internal buffers in
writableStream.
2013-01-08 04:59:50 +01:00
Mike Harsch
aeb030bead build: fail w/err msg when missing binutils
Building --with-dtrace requires objdump from GNU binutils.
This change inserts a helpful error message if there is a
problem executing objdump.
2013-01-08 03:41:26 +01:00
isaacs
321b8eec08 dtrace: More style
Continuation lines should be indented with 4 spaces, not a tab.
2013-01-07 12:31:44 -08:00
isaacs
38df9d51a2 dtrace: Make D style more D-ish 2013-01-07 12:23:41 -08:00
Fedor Indutny
f9afb3f010 dtrace: x64 ustack helper 2013-01-07 23:04:11 +04:00
Fedor Indutny
13296e4b13 dtrace: fix style in ustack helper 2013-01-07 23:01:54 +04:00
isaacs
3b715edda9 dtrace: SeqAsciiString was renamed to SeqOneByteString in v8 2013-01-07 10:30:15 -08:00
Ben Noordhuis
7788a6bf85 src: pass node_isolate to Undefined() 2013-01-07 17:39:58 +01:00
Ben Noordhuis
c7d7ae1fe2 src: pass node_isolate to Null() 2013-01-07 17:39:57 +01:00
Ben Noordhuis
109f73b2c0 src: pass node_isolate to True() and False() 2013-01-07 17:39:57 +01:00
Ben Noordhuis
01c3d0aa88 src: pass node_isolate to Local<>::New 2013-01-07 17:39:57 +01:00
Ben Noordhuis
6573fc3502 src: pass node_isolate to Integer::New 2013-01-07 17:39:57 +01:00
Ben Noordhuis
412b3cee05 src: pass node_isolate to String::Empty 2013-01-07 17:39:57 +01:00
Ben Noordhuis
5d0816bf3e src: make node_isolate global
V8 3.15 has new API functions that let you specify the Isolate. V8 and
node.js generally spend 0.5-3.5% of the time in pthread_getspecific(),
looking up the current Isolate. Avoid that overhead by making "our"
isolate global so we can pass it around. The change to the new API is
introduced in follow-up commits.
2013-01-07 17:39:57 +01:00
isaacs
df3563aa65 child_process: Pull through untouched stdio streams
Otherwise child procs will never emit a 'close' event if you don't
ever consume their streams, because they will never hit the EOF.
2013-01-07 08:36:49 -08:00
isaacs
3e6f737eaf stream: Clean up more effectively in pipe() 2013-01-07 08:36:49 -08:00
Maciej Małecki
a5d4e74891 child_process: don't resume() created socket
Calling `resume()` on a stream switches it to the old mode which causes
piping stdio from a child process to fail.

Fixes joyent/node#4510.
2013-01-07 08:36:49 -08:00
Dean McNamee
8adebb92bc node: move symbol caching to Load() 2013-01-07 17:19:09 +01:00
Ben Noordhuis
879efb3338 test: fix simple/test-http-client-timeout-with-data
The test was failing in debug mode because the timeouts were set too
low. Fix that by increasing the timeouts. Admittedly not a great fix.
If this test keeps playing up, it's probably best to remove it.

Fixes #4528.
2013-01-07 16:04:33 +01:00
Ben Noordhuis
fa3bfc3a66 test: put tty in blocking mode after test
Tests can leave the tty in non-blocking mode. If the test runner tries
to print to stdout/stderr after that and the tty buffer is full, it'll
die with a EAGAIN OSError. Ergo, put the tty back in blocking mode
before proceeding.
2013-01-07 03:59:10 +01:00
Ben Noordhuis
4e1a2f9a89 test: disable simple/test-debug-brk-file
This test is timing sensitive and hence quite unreliable with debug
builds. What's worse is that it leaves a stray child process behind
that listens on the default test port and that makes all the tests
that come after it fail with EADDRINUSE errors.
2013-01-07 03:40:12 +01:00
Bradley Meck
70ad9bbcbd child_process: make fork() execPath configurable
Allows for arbitrary path to executable spawned using `fork`. This
fixes some issues around running multiple versions of node with workers
and allows arbitrary IPC with compatible executables.

Fixes #3248.
2013-01-06 22:55:30 +01:00
James Hight
3f76419a04 net: add localAddress and localPort to Socket 2013-01-05 17:05:13 +01:00
Ben Noordhuis
5664dd2fc1 src: use static_cast where appropriate
Use static_cast instead of reinterpret_cast when casting from void*
to another type.

This is mostly an aesthetic change but may help catch bugs when the
affected code is modified.
2013-01-05 00:16:23 +01:00
Shigeki Ohtsu
2b6c561040 fs: remove unused default option in WriteStream
No bufferSize option is used in stream.Writable and fs.WriteStream.
2013-01-04 19:02:05 +01:00
Shigeki Ohtsu
829f96bada fs: pool size coincide with ReadStream bufferSize
pool size of file reading in ReadableStream can be adjustable
with a bufferSize option.
2013-01-04 19:00:16 +01:00
Ben Noordhuis
93591a2a88 v8: remove optimization switches
Remove compiler switches from $(TOPLEVEL)/deps/v8/build/common.gypi,
we set them globally in $(TOPLEVEL)/common.gypi.

Commit 7b4d95a introduced the switches again, resulting in V8 getting
built without any optimizations.

This commit is essentially a rehash of commit 4b8629d.
2013-01-04 20:06:03 +04:00
Fedor Indutny
97056c064f object_wrap: add missing HandleScope
by Sven Panne's suggestion, see [0] for details.

[0]: https://code.google.com/p/v8/issues/detail?id=2468
2013-01-04 16:39:24 +04:00
Fedor Indutny
0054264d88 v8: update to 3.15.11.5 2013-01-04 15:44:47 +04:00
Nirk Niggler
0459a23063 REPL: fix floating point number parsing
In JS, the expression ".1" is a floating point number.  Issue 4268 concerns the
REPL interpreting floating point numbers that lead with a "." as keywords.  The
original bugfix worked for this specific case but not for the general case:

    var x = [
        .1,
        .2,
        .3
    ];

The attached change and test (`.1+.1` should be `.2`) fix the bug.

Closes #4513.
2013-01-03 17:11:54 -08:00
Scott Blomquist
a616774281 windows: improve Visual Studio Express build support
* Moved generated files to a clearer directory.
* Improved detection logic for ctrpp.exe tool.

Closes #4482
2013-01-03 23:38:25 +01:00
Scott Blomquist
5a39df4959 windows: fix perfctr crash on XP and 2003
Some performance counter related functions are not available on Windows
XP and Windows Server 2003, which caused node to call a NULL pointer.

Closes #4462
Closes #4511
2013-01-03 23:31:26 +01:00