[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [rtl] segmentation fault because of sin()



On Thu, Dec 07, 2000 at 02:51:44PM -0500, Mohsen Mahvash Mohammadi wrote:
> I have found that using sin() and cos() in real time task has caused 
> segmentation fault for user program.here is part of my program which 
> causes the problem:

Couple of things to check:

1) Make sure floating point support is turned on when you configure RTLinux.
2) Make sure you enable floating point support for the thread you will be
doing floating point in by calling pthread_setfp_np(pthread_self(), 1) before
you do anything else in that thread (even initialization of floating point
variables).