Isn't that gc doing its work ? As a workaround, you can turn it off and run it manually node --nouse_idle_notification --expose_gc > global.gc();
Regards, Jérémy. On 11/05/2012 09:51, Joran Greef wrote: > I have posted this in v8-users but perhaps someone else here will also be > familiar with this: > > I am using V8 as part of Node and have written a Javascript implementation of > Bitcask, using a Javascript object as a hash to keep file offsets in memory. > > This object has 7 million entries and I'm noticing that while the JS code is > resting, doing nothing, V8 is hitting 100% CPU every few seconds and doing > this continually. > > Attached is the full result of running V8 with --prof. > > And of particular interest: > > [C++]: > ticks total nonlib name > 73615 43.1% 43.1% > v8::internal::StaticMarkingVisitor::VisitUnmarkedObjects > 68436 40.1% 40.1% _accept$NOCANCEL > 4796 2.8% 2.8% > v8::internal::FlexibleBodyVisitor<v8::internal::StaticMarkingVisitor, > v8::internal::JSObject::BodyDescriptor, void>::VisitSpecialized<40> > > Should I be using many smaller hashes to keep this overhead down? i.e. some > sort of sparse hash implementation? Or using key mod 1000 to determine the > hash it should be in? > > Does V8 have limits on hash table sizes? > > Thanks. > > -- > Job Board: http://jobs.nodejs.org/ > Posting guidelines: > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > You received this message because you are subscribed to the Google > Groups "nodejs" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/nodejs?hl=en?hl=en -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
