pthread_attr_setfp_np

Name

pthread_attr_setfp_np, pthread_attr_getfp_np -- set and get floating point enable attribute

Synopsis

       #include <rtl_sched.h>
      
       int pthread_attr_setfp_np(pthread_attr_t *attr, int use_fp);
       int pthread_attr_getfp_np(pthread_attr_t *attr, int *use_fp);

DESCRIPTION

These functions are non-portable RTLinux extensions.

pthread_attr_setfp_np modifies the thread attribute object attribute to allow or disallow use of the floating point unit (FPU) in the created thread. use_fp is zero to disallow floating-point operations, or non-zero to allow them. The thread attribute object attr first has to be initialized with pthread_attr_init(3).

pthread_attr_getfp_np fills the location pointed to by cpu with the use_fp flag from the attribute structure.

RETURN VALUE

All functions return 0 on success and a non-zero error code on error.

ERRORS

No errors are defined.

NOTES

By default, floating point operations are disallowed in RT-threads.

AUTHOR

Michael Barabanov (baraban@fsmlabs.com)

SEE ALSO

pthread_setfp_np(3), UNIX spec pthread_attr_getstacksize(3), UNIX spec pthread_attr_setstacksize(3), UNIX spec pthread_attr_setschedparam(3), UNIX spec pthread_attr_init(3), UNIX spec pthread_attr_getschedparam(3), UNIX spec pthread_create(3)

2001 FSMLabs Inc.

All rights reserved.