WvTask is a cooperative threading system, which uses getcontext and
setcontext to save and restore the state of each thread when switching
tasks. getcontext is a standard library function - "man getcontext"
should explain how it works.
Try running wvstreams through "strace" so you can see the actual error
code returned by getcontext.
Joe
> Hi all, is there any workaround for getcontext on ARM platform?
I didn't think we would *need* to workaround it on the ARM. There's
no reason (that I know of) that getcontext wouldn't "just work."
If we send you a patch, can you try applying it and see what happens?
Can you try using the 'revert-wvtask' branch of wvstreams from
git://github.com/apenwarr/wvstreams.git and see if that works any
better?
> And do you think the problem line is the following line? I am making
> such a guess because makedev might be needed to create a new thread?
>
> fstat64(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 0), ...}) = 0
The "= 0" at the end means the fstat was successful. And makedev() in
this case just means "the device object make from major=136, minor=0".
Unfortunately getcontext is not a kernel system call so the advice to
run strace won't actually help much. But please try my above-linked
git version of wvstreams and let me know if that helps.
Thanks,
Avery
Hi Philip,
Thanks for confirming back. That's a really long thread, and I
*think* the important changes discussed there were included in the
revert-wvtask branch in git. Did you try out that branch to see if it
works without any changes?
Even if you don't use git, you can download a tarball of that version
by clicking the 'download' button at this link:
http://github.com/apenwarr/wvstreams/commits/revert-wvtask
Please let me know if that branch works for you.
Have fun,
Avery