📄 libm.h
字号:
this will best help code size and speed, as well as omitting the code for other compatibility modes. If not defined, the math library can be set at run-time to any of the supported compatibility modes." type radio parent CYGPKG_LIBM_COMPATIBILITY } cdl_component CYGPKG_LIBM_COMPATIBILITY_DEFAULT { display "Default mode" description "If you want to have support for more than one compatibility mode settable at run-time, rather than hard-coded IEEE mode, this component lets you choose which mode should be the default." type radio parent CYGPKG_LIBM_COMPATIBILITY requires CYGPKG_LIBC } cdl_option CYGNUM_LIBM_COMPATIBILITY_POSIX { display "POSIX" description "This sets the default compatibility mode to POSIX" type radio parent CYGPKG_LIBM_COMPATIBILITY_DEFAULT } cdl_option CYGNUM_LIBM_COMPATIBILITY_IEEE { display "IEEE" description "This sets the default compatibility mode to IEEE" type radio parent CYGPKG_LIBM_COMPATIBILITY_DEFAULT } cdl_option CYGNUM_LIBM_COMPATIBILITY_XOPEN { display "X/OPEN" description "This sets the default compatibility mode to X/OPEN" type radio parent CYGPKG_LIBM_COMPATIBILITY_DEFAULT } cdl_option CYGNUM_LIBM_COMPATIBILITY_SVID { display "SVID" description "This sets the default compatibility mode to SVID" type radio parent CYGPKG_LIBM_COMPATIBILITY_DEFAULT } cdl_option CYGFUN_LIBM_SVID3_scalb { display "SVID3-style scalb()" description "SVID3 defined the scalb() function as double scalb(double, double) rather than double scalb(double, int) which is used by IBM, DEC, and probably others. Enabling this option chooses the (double, double) version. Note there is a function double scalbn(double, int) which is unaffected by this choice." type boolean parent CYGPKG_LIBM_COMPATIBILITY } cdl_option CYGSYM_LIBM_NO_XOPEN_SVID_NAMESPACE_POLLUTION { display "Reduce namespace pollution" description "If you do not want to use either the X/Open or SVID3 compatibility modes, you may want to define this option to reduce the chance of namespace pollution. This is particularly likely to occur here as these standards define symbols with names that often appear in applications, such as exception, DOMAIN, OVERFLOW, etc. If your application also used these names, it may cause problems." type boolean parent CYGPKG_LIBM_COMPATIBILITY } cdl_option CYGSEM_LIBM_USE_STDERR { display "Output to stderr for math errors" description "The SVID3 standard says that error messages should be output on the stderr console output stream. This option allows this ability to be explicitly controlled. However, this still only has an effect in SVID3 compatibility mode." type boolean requires !CYGSEM_LIBM_COMPAT_IEEE_ONLY requires CYGPKG_LIBC_STDIO parent CYGPKG_LIBM_COMPATIBILITY } }}CFG_DATA*/#undef CYGSEM_LIBM_COMPAT_IEEE_ONLY#define CYGPKG_LIBM_COMPATIBILITY_DEFAULT#ifdef CYGPKG_LIBM_COMPATIBILITY_DEFAULT# ifndef CYGPKG_LIBC# error You must include the libc package if enabling \ CYGPKG_LIBM_COMPATIBILITY_DEFAULT# endif#endif#define CYGNUM_LIBM_COMPATIBILITY_POSIX#undef CYGNUM_LIBM_COMPATIBILITY_IEEE#undef CYGNUM_LIBM_COMPATIBILITY_XOPEN#undef CYGNUM_LIBM_COMPATIBILITY_SVID#if defined(CYGPKG_LIBM_COMPATIBILITY_DEFAULT)# if defined(CYGNUM_LIBM_COMPATIBILITY_POSIX)# define CYGNUM_LIBM_COMPAT_DEFAULT CYGNUM_LIBM_COMPAT_POSIX# elif defined(CYGNUM_LIBM_COMPATIBILITY_IEEE)# define CYGNUM_LIBM_COMPAT_DEFAULT CYGNUM_LIBM_COMPAT_IEEE# elif defined(CYGNUM_LIBM_COMPATIBILITY_XOPEN)# define CYGNUM_LIBM_COMPAT_DEFAULT CYGNUM_LIBM_COMPAT_XOPEN# elif defined(CYGNUM_LIBM_COMPATIBILITY_SVID)# define CYGNUM_LIBM_COMPAT_DEFAULT CYGNUM_LIBM_COMPAT_SVID# else# error Configuration broken - no default mode set# endif#endif#define CYGFUN_LIBM_SVID3_scalb#undef CYGSYM_LIBM_NO_XOPEN_SVID_NAMESPACE_POLLUTION#undef CYGSEM_LIBM_USE_STDERR//========================================================================//// THREAD-SAFETY CONFIGURATION OPTIONS/* {{CFG_DATA cdl_component CYGPKG_LIBM_THREAD_SAFETY { display "Thread safety" description "This option controls whether the C library has support for thread safe operation in general. This requires eCos kernel support for per-thread data, and adjustment of the stack limit." type dummy parent CYGPKG_LIBM doc ref/ecos-ref/c-and-math-library-overview-thread-safety.html } cdl_option CYGSEM_LIBM_THREAD_SAFE_COMPAT_MODE { display "Compatibility mode setting" description "This option makes the setting of the compatiblity mode be a per-thread property. This directly implies that it also becomes thread-safe." requires !CYGSEM_LIBM_COMPAT_IEEE_ONLY requires CYGVAR_KERNEL_THREADS_DATA parent CYGPKG_LIBM_THREAD_SAFETY } }}CFG_DATA*/#ifndef CYGSEM_LIBM_COMPAT_IEEE_ONLY // irrelevant if mode is constant#undef CYGSEM_LIBM_THREAD_SAFE_COMPAT_MODE#endif#if ( defined(CYGSEM_LIBM_THREAD_SAFE_COMPAT_MODE) && \ !defined(CYGVAR_KERNEL_THREADS_DATA) )# error The kernel must have thread-specific data \ (CYGVAR_KERNEL_THREADS_DATA) turned on for a thread-safe math library#endif//========================================================================//// TRACING OPTIONS/* {{CFG_DATA cdl_component CYGPKG_LIBM_TRACE { display "Tracing output levels in Math library" description "Tracing support is useful for debugging. Some Math library modules can be configured with different levels of tracing verbosity. These levels can be configured here." type boolean requires CYGDBG_USE_TRACING parent CYGPKG_LIBM } cdl_option CYGNUM_LIBM_COMPATMODE_TRACE_LEVEL { display "Compatibility mode get/set" description "Trace level for debugging the getting and setting of the compatibility mode when it is configured to be thread-safe." type count legal_values 0 to 1 requires CYGSEM_LIBM_THREAD_SAFE_COMPAT_MODE parent CYGPKG_LIBM_TRACE } }}CFG_DATA*/#undef CYGPKG_LIBM_TRACE#ifdef CYGPKG_LIBM_TRACE#define CYGNUM_LIBM_COMPATMODE_TRACE_LEVEL 0#endif#endif // CYGONCE_PKGCONF_LIBM_H multiple inclusion protection// EOF libm.h
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -