Git Product home page Git Product logo

Comments (10)

laverdet avatar laverdet commented on August 18, 2024

A gdb stack trace would be helpful here. Did you have any luck running fibers in Snow Leopard?

As Lion is still beta I'm not surprised there are compatibility issues but without more information or a copy of Lion myself I'll be of little help. I plan on upgrading as soon as Lion is available commercially, but until then I won't be able to resolve this.

from node-fibers.

dmorilha avatar dmorilha commented on August 18, 2024

getting a Seg Fault on Leopard (10.5) too, running with node.js 0.4.9 from macports and installed the same way, npm install -g fibers

So I just figured out coroutines.dylib is not loading libpthreads.dylib. So dlsym loops forever when it tries to find pthread_create.

from node-fibers.

laverdet avatar laverdet commented on August 18, 2024

Update now that I have Lion installed on my system:
0b23613 gets us most of the way there. There's still some crazy weird bug that I haven't quite tracked down yet though. If you comment out lines 216 and 217 (two asserts), fibers will work just fine. Anyway, more updates soon.

from node-fibers.

laverdet avatar laverdet commented on August 18, 2024

Hello all, could you please try to compile the latest version from github and confirm whether or not it works for you? I'd appreciate it. Thanks.

from node-fibers.

bsgbryan avatar bsgbryan commented on August 18, 2024

I'm getting a Segmentation fault: 11 on node v0.6.7 (installed via n) after refactoring a library I'm working on. Before the refactor everything worked correctly. Now, I also run some tests, but some (larger chunks of code) generate segfaults. I'm running Lion (10.7.2).

Sorry for the silly question, but what would be the easiest way to get a gdb stack trace for you - I've never had to do that before.

Thanks!

from node-fibers.

laverdet avatar laverdet commented on August 18, 2024

Hey there, there is a threading bug in v8 that caused segmentation faults while using fibers under high load. The bug was fixed in v8 branches 3.7.x and above, but Node is still using v8 3.6.x. Could you compile Node with a later version of v8 and try your tests again? I am 90% this will fix your issue. Node compiles and runs cleanly on newer versions of v8. You can do this by getting Node source, and replacing "deps/v8" with the latest tagged version of v8 (svn co http://v8.googlecode.com/svn/tags/3.8.5/ v8).

from node-fibers.

bsgbryan avatar bsgbryan commented on August 18, 2024

Thanks for responding so quickly, sorry it's taken me a while to get back
to you.

After reading your response, I think I'm going to say that this segfault
has more to do with bad design on my part then anything. The tests I was
running should not put node under enough stress that it would cause an
issue.

I've refactored my library, but am now running into an issue that seems to
be related to a difference between versions of node.

The code I have funs perfectly on node 0.4.12, but fails on 0.6.x. I'm
trying it on 0.5.10 now. I'll work on isolating the issue into something I
can put in a gist and possibly post about it. Hopefully it's just something
I'm doing wrong :-)

I do think I'll update to the newest version of v8, though. Thanks for the
head's up!

We're using node for a project at work. Would building node with the newest
version of v8 be stable enough to use for my work project, or would you
recommend sticking with the v8 that ships with node?

On Fri, Jan 13, 2012 at 4:56 PM, Marcel Laverdet <
[email protected]

wrote:

Hey there, there is a threading bug in v8 that caused segmentation faults
while using fibers under high load. The bug was fixed in v8 branches 3.7.x
and above, but Node is still using v8 3.6.x. Could you compile Node with a
later version of v8 and try your tests again? I am 90% this will fix your
issue. Node compiles and runs cleanly on newer versions of v8. You can do
this by getting Node source, and replacing "deps/v8" with the latest tagged
version of v8 (svn co http://v8.googlecode.com/svn/tags/3.8.5/ v8).


Reply to this email directly or view it on GitHub:
#28 (comment)

For science

from node-fibers.

laverdet avatar laverdet commented on August 18, 2024

No I wouldn't say it's bad design. Heavy load will bring issues up to the surface that are more rare under normal load. Maybe under heavy load you can segfault once every 5 minutes, but under normal load you will segfault once every week.

If your issue on 0.6.x is still a segfault I'll ask you to upgrade to at least v8 3.7.3 before I look into it :). I haven't run into any stability issues with newer v8 builds.

from node-fibers.

laverdet avatar laverdet commented on August 18, 2024

And if you are using fibers in production I'd say a newer version of v8 is almost required.

from node-fibers.

bsgbryan avatar bsgbryan commented on August 18, 2024

Hey again, happy MLK Day (Monday, if you're outside the States) :-)

I followed your advice regarding v8 and will definitely share that with the rest of my team, thank you!

Thanks, also for your input regarding load and segfaults, and thanks for giving me the benefit of the doubt! The other issue I mentioned isn't related to a segfault, so I'll work on tracking that down. I do very much appreciate your help, thanks again!

In case you're interested in taking a look at the library I'm working on, you can find it here. As the disclaimer a the top of the README says, it's still under heavy development, butI'd love feedback if you have any :-)

Thanks again, and happy coding!

from node-fibers.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.