Commit Graph

165 Commits

Author SHA1 Message Date
Ryan Dahl
fdbc9a82e4 Use EVBACKEND_SELECT on Solaris
Using EVBACKEND_PORT DTraceToolkit-0.99/Proc/syscallbypid.d reports after 5
seconds

   PID CMD                      SYSCALL                     COUNT
     . .                        .                               .
     . .                        .                               .
     . .                        .                               .
 28551 mysqld                   fcntl                         485
 24793 httpd                    gtime                         528
 28551 mysqld                   read                          707
 28551 mysqld                   gtime                         956
 21050 rsync                    pollsys                       965
 21050 rsync                    read                          965
 24793 httpd                    read                          982
 28551 mysqld                   lwp_sigmask                  1422
  4675 dtrace                   ioctl                        1579
 15136 node                     portfs                      15681
 15136 node                     clock_gettime               31358

On a very simple node process.
2010-03-02 10:39:07 -08:00
Zoran Tomicic
b2995829e1 Edit PrintHelp() text 2010-02-26 00:30:43 -08:00
Jonas Pfenniger
8f59cccb75 Removed deprecation errors in src/node.cc
Removed constness on string litterals. This should cause no problem
since we're not modifying them.
2010-02-24 13:16:52 -08:00
James Duncan
df1c1e593f Add setgid,getgid 2010-02-23 14:45:02 -08:00
Jérémy Lal
ffb4b47367 Fix for when EV_MULTIPLICITY=1 2010-02-22 13:25:57 -08:00
Ryan Dahl
46ebaa00ce Encoding 0 length data, returns '' instead of null 2010-02-22 12:07:07 -08:00
Zoran Tomicic
d98ea70168 Configurable debug ports, and --debug-brk 2010-02-21 21:17:25 -08:00
Jeremy Ashkenas
2916a2acd4 Remove '--' from command line parsing 2010-02-20 22:47:49 -08:00
Ryan Dahl
ea4956f046 Simplify call to V8::IdleNotification
Run a max priority ev_timer every 2 seconds. If there aren't any pending
watchers then call V8::IdleNotification() once. This is slower at freeing
memory, but I think simpler and less aggressive.
2010-02-20 20:36:33 -08:00
Ryan Dahl
daacb81d3a Experimental idle garbage compact 2010-02-20 18:23:21 -08:00
Ryan Dahl
5468173ce9 [debug] Give debug_watcher maximum priority 2010-02-16 19:45:12 -08:00
Ryan Dahl
4322523fcf [debug] Use ProcessDebugMessage() instead of executing empty script
And don't use --debugger_auto_break v8 flag, it seems unnecessary.
2010-02-16 19:45:01 -08:00
Jérémy Lal
5a08a5653c Calculate page size with getpagesize for armel 2010-02-16 16:16:01 -08:00
Ryan Dahl
95fd370096 Remove unused variable 2010-02-15 17:15:40 -08:00
Ryan Dahl
7d428a7741 s/tinyclouds.org/nodejs.org/ 2010-02-12 00:08:26 -08:00
Ryan Dahl
b20c343a7a Fix whitespace and warnings in node.cc 2010-02-11 21:55:08 -08:00
Michael Carter
a38607605c Add process.setuid(), getuid() 2010-02-07 22:13:10 -08:00
Ryan Dahl
6f92d8f3b0 Add handlescope and flush to process.reallyExit() 2010-02-07 21:59:56 -08:00
Ryan Dahl
ae1fc497bb Fix stdout flush issue
http://github.com/ry/node/issues#issue/53
2010-02-07 21:56:36 -08:00
Ryan Dahl
f3ad635576 Downcase process.ARGV/ENV to process.argv/env 2010-02-03 12:19:21 -08:00
Ryan Dahl
9f5643f427 Reorganize the start-up process
- assign 'GLOBAL' (and now 'global') inside src/node.js

- position for eventually allowing replacements to src/node.js for people
  like Kris Kowal who want the nice libev and libeio bindings but not
  necessarily node's choices of modules or promises.
2010-01-30 23:22:34 -08:00
Ryan Dahl
f88d39de74 getmem() for solaris 2010-01-20 11:19:17 -08:00
Ryan Dahl
aeb7d6d168 Add process.IdleWatcher
With priorities. Will be used for process.nextLoop().
2010-01-18 10:12:04 -08:00
Ryan Dahl
8e6dd52683 Hack to display more useful SyntaxError exceptions.
For some reason v8 doesn't include the frame with the syntax error in the
stack trace - so have to special case it.
2010-01-15 10:45:04 -08:00
Ryan Dahl
53413598b6 Fix another problem with the EIO interface
Should call eio_poll() when given a done_poll signal as well.

Bug report and test case by Kris Zyp <kriszyp@gmail.com>
2010-01-08 22:20:23 -08:00
Vanilla Hsu
d22952bfe0 getmem for freebsd 2010-01-06 23:37:27 -08:00
Ryan Dahl
b1e126f415 libeio bugfix part 4
Oops. Last commit broke a few tests. Should work now!
2010-01-06 01:53:34 -08:00
Ryan Dahl
f80cc69c23 libeio bugfix part 3
Finally (hopefully) fix the issue that Felix reported. It's only appearing
on macintosh (test/mjsunit/test-eio-race3.js)

The trick/hack is to call eio_poll() again before reentering the event loop.

Additionally this commit implements a more complex method of calling
eio_poll(), occasionally dropping to an ev_idle watcher.

See also:
3f39772834
http://lists.schmorp.de/pipermail/libev/2010q1/000855.html
http://groups.google.com/group/nodejs/browse_thread/thread/9f8db11c792a68bb/a89705f68971f53c
2010-01-06 01:27:31 -08:00
Ryan Dahl
3f39772834 libeio bugfix part 2
Reverts the change to deps/libeio/eio.c added in
04dd2d51be
It wasn't a bug, I was just using eio incorrectly.

See http://lists.schmorp.de/pipermail/libev/2010q1/000855.html
2010-01-05 21:09:02 -08:00
Ryan Dahl
53a841d96a Simplify exception reporting 2009-12-29 20:20:51 +01:00
Ryan Dahl
0d7e88a429 Bugfix: libeio race condition
Process at most 10 pending responses from the thread pool in one go.
10 was chosen arbitrarily.
Test and report by Felix Geisendörfer <felix@debuggable.com>
2009-12-29 19:11:04 +01:00
Ryan Dahl
45a806a066 Statically define symbols
~7% improvement in hello world HTTP response bench.
2009-12-09 09:12:01 +01:00
Ryan Dahl
4d818f1fd3 Implement promises entirely in JS 2009-12-06 11:36:22 +01:00
Ryan Dahl
48452838b3 Clean up context creation 2009-12-05 18:27:28 +01:00
Ryan Dahl
38e425d9bf Add V8 heap info to process.memoryUsage() 2009-11-28 16:31:29 +01:00
choonkeat
44d5f212fe Stat::Callback has 2 arguments for callback: current stat info and previous stat info
http://groups.google.com/group/nodejs/msg/f8e51a8e0c74bd85
2009-11-28 15:13:12 +01:00
Ryan Dahl
dc093ef833 Add process.loop() process.unloop()!!!
Move the event loop calls into javascript.
Makes life so much easier.
2009-11-23 00:59:39 +01:00
Friedemann Altrock
0433d828cf add process.umask() 2009-11-22 19:52:52 +01:00
Ryan Dahl
8d2f9e83a4 Add process.watchFile() process.unwatchFile()
This is an interface to libev's ev_stat watcher.
2009-11-17 14:07:48 +01:00
Felix Geisendörfer
2b252acea4 Implement process "uncaughtException" event
This event can be used to overwrite the default exception mechanism which
reports the exception and kills the node process.

See google group post:
http://groups.google.com/group/nodejs/browse_thread/thread/9721dc3a2638446f
2009-11-14 23:46:37 +01:00
Ryan Dahl
06d493e7e3 Remove debug message 2009-11-12 12:47:02 +01:00
Felix Geisendörfer
7371fcb312 Temporary function to determine str byte length
Will need a better place later on
2009-11-11 18:42:46 +01:00
Ryan Dahl
d737a060c8 Combine all compiled javascript files into src/node.js 2009-11-07 14:37:22 +01:00
Brandon Beacher
47fcf785ac Added process.chdir() 2009-11-03 19:22:37 +01:00
Ryan Dahl
b3b3cfe007 Move memoryUsage() into C on Linux 2009-11-03 13:00:42 +01:00
Ryan Dahl
3a70129a9c Add sys.memoryUsage() 2009-11-03 01:30:01 +01:00
Ryan Dahl
f481183140 Add process.platform 2009-11-03 00:21:00 +01:00
Ryan Dahl
ad0a4cefb8 Namespace EVERYTHING under process; introduce GLOBAL
http://groups.google.com/group/nodejs/browse_thread/thread/1034fd2ad2cd93e8
2009-10-29 23:36:41 +01:00
Ryan Dahl
a5df0f6a65 Prefix all source files with node_ 2009-10-27 11:46:58 +01:00
Ryan Dahl
3456a16f71 Accept string representations of signals in node.kill and child.kill 2009-10-15 15:45:04 +02:00