author: kx <kx@radix-linux.su> 2024-12-20 16:11:07 +0300
committer: kx <kx@radix-linux.su> 2024-12-20 16:11:07 +0300
commit: 868b2b66b564b5c00e3a74d10be45db7151627ac
parent: cce2ae8d3312493b7653358bb4af201d3271377b
Commit Summary:
Diffstat:
1 file changed, 840 insertions, 0 deletions
diff --git a/mpu/st-service.c b/mpu/st-service.c
new file mode 100644
index 0000000..c537b3d
--- /dev/null
+++ b/mpu/st-service.c
@@ -0,0 +1,961 @@
+
+/***************************************************************
+ __ST_SERVICE.C
+
+ This file contains source code of functions for
+ SERVICE constants operations.
+
+ PART OF : MPU - library .
+
+ USAGE : Internal only .
+
+ NOTE : NONE .
+
+ Copyright (C) 2000 - 2024 by Andrew V.Kosteltsev.
+ All Rights Reserved.
+ ***************************************************************/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <errno.h> /* errno(3) */
+#include <string.h> /* strcpy(3) */
+#include <strings.h> /* bzero(3) */
+#include <stdlib.h>
+
+#include <libmpu.h>
+#include <mpu-context.h>
+
+#include <mpu-emutype.h>
+#include <mpu-integer.h>
+#include <mpu-real.h>
+#include <mpu-floatp.h>
+
+#include <mpu-char.h>
+#include <mpu-symbols.h>
+
+#include <mpu-math-errno.h>
+#include <mpu-mtherr.h>
+
+
+/***************************************************************
+ Кодировка имен файлов:
+
+ Трехзначное десятичное число, представляющее количество
+ 128-и битных слов, из которых состоят вещественные числа
+ размещенные в массивах:
+
+ размер чисел в битах кодировка
+ -------------------- ---------
+ 128 001
+ 256 002
+ 512 004
+ 1024 008
+ 2048 016
+ 4096 032
+ 8192 064
+ 16384 128
+ 32768 256
+ 65536 512 (это предел);
+
+ ПРИМЕРЫ:
+ -------
+ ei_service_001_emu32lsb.dfn - 128-бит,
+ ei_service_512_emu32lsb.dfn - 65536-бит.
+
+ ***************************************************************/
+
+#if MPU_MATH_FN_LIMIT >= 128
+#if MPU_WORD_ORDER_BIG_ENDIAN == 0
+#include <math/service/emu00128/ei_service_001_emu32lsb.dfn>
+#else
+#include <math/service/emu00128/ei_service_001_emu32msb.dfn>
+#endif
+#endif /* MPU_MATH_FN_LIMIT >= 128 */
+
+#if MPU_MATH_FN_LIMIT >= 256
+#if MPU_WORD_ORDER_BIG_ENDIAN == 0
+#include <math/service/emu00256/ei_service_002_emu32lsb.dfn>
+#else
+#include <math/service/emu00256/ei_service_002_emu32msb.dfn>
+#endif
+#endif /* MPU_MATH_FN_LIMIT >= 256 */
+
+#if MPU_MATH_FN_LIMIT >= 512
+#if MPU_WORD_ORDER_BIG_ENDIAN == 0
+#include <math/service/emu00512/ei_service_004_emu32lsb.dfn>
+#else
+#include <math/service/emu00512/ei_service_004_emu32msb.dfn>
+#endif
+#endif /* MPU_MATH_FN_LIMIT >= 512 */
+
+#if MPU_MATH_FN_LIMIT >= 1024
+#if MPU_WORD_ORDER_BIG_ENDIAN == 0
+#include <math/service/emu01024/ei_service_008_emu32lsb.dfn>
+#else
+#include <math/service/emu01024/ei_service_008_emu32msb.dfn>
+#endif
+#endif /* MPU_MATH_FN_LIMIT >= 1024 */
+
+#if MPU_MATH_FN_LIMIT >= 2048
+#if MPU_WORD_ORDER_BIG_ENDIAN == 0
+#include <math/service/emu02048/ei_service_016_emu32lsb.dfn>
+#else
+#include <math/service/emu02048/ei_service_016_emu32msb.dfn>
+#endif
+#endif /* MPU_MATH_FN_LIMIT >= 2048 */
+
+#if MPU_MATH_FN_LIMIT >= 4096
+#if MPU_WORD_ORDER_BIG_ENDIAN == 0
+#include <math/service/emu04096/ei_service_032_emu32lsb.dfn>
+#else
+#include <math/service/emu04096/ei_service_032_emu32msb.dfn>
+#endif
+#endif /* MPU_MATH_FN_LIMIT >= 4096 */
+
+#if MPU_MATH_FN_LIMIT >= 8192
+#if MPU_WORD_ORDER_BIG_ENDIAN == 0
+#include <math/service/emu08192/ei_service_064_emu32lsb.dfn>
+#else
+#include <math/service/emu08192/ei_service_064_emu32msb.dfn>
+#endif
+#endif /* MPU_MATH_FN_LIMIT >= 8192 */
+
+#if MPU_MATH_FN_LIMIT >= 16384
+#if MPU_WORD_ORDER_BIG_ENDIAN == 0
+#include <math/service/emu16384/ei_service_128_emu32lsb.dfn>
+#else
+#include <math/service/emu16384/ei_service_128_emu32msb.dfn>
+#endif
+#endif /* MPU_MATH_FN_LIMIT >= 16384 */
+
+#if MPU_MATH_FN_LIMIT >= 32768
+#if MPU_WORD_ORDER_BIG_ENDIAN == 0
+#include <math/service/emu32768/ei_service_256_emu32lsb.dfn>
+#else
+#include <math/service/emu32768/ei_service_256_emu32msb.dfn>
+#endif
+#endif /* MPU_MATH_FN_LIMIT >= 32768 */
+
+#if MPU_MATH_FN_LIMIT >= 65536
+#if MPU_WORD_ORDER_BIG_ENDIAN == 0
+#include <math/service/emu65536/ei_service_512_emu32lsb.dfn>
+#else
+#include <math/service/emu65536/ei_service_512_emu32msb.dfn>
+#endif
+#endif /* MPU_MATH_FN_LIMIT >= 65536 */
+
+
+EMUSHORT *_get_m_ln2hi_ptr( int nb )
+{
+ EMUSHORT *rc = (EMUSHORT *)NULL;
+
+ if( nb < NBR_32 || nb > MPU_MATH_FN_LIMIT )
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ return( rc );
+ }
+
+ switch( nb )
+ {
+#if MPU_MATH_FN_LIMIT >= 128
+ case NBR_32 :
+ case NBR_64 :
+ case NBR_128 :
+ rc = (EMUSHORT *)&_ei_m_ln2hi_128_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 128 */
+#if MPU_MATH_FN_LIMIT >= 256
+ case NBR_256 :
+ rc = (EMUSHORT *)&_ei_m_ln2hi_256_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 256 */
+#if MPU_MATH_FN_LIMIT >= 512
+ case NBR_512 :
+ rc = (EMUSHORT *)&_ei_m_ln2hi_512_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 512 */
+#if MPU_MATH_FN_LIMIT >= 1024
+ case NBR_1024 :
+ rc = (EMUSHORT *)&_ei_m_ln2hi_1024_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 1024 */
+#if MPU_MATH_FN_LIMIT >= 2048
+ case NBR_2048 :
+ rc = (EMUSHORT *)&_ei_m_ln2hi_2048_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 2048 */
+#if MPU_MATH_FN_LIMIT >= 4096
+ case NBR_4096 :
+ rc = (EMUSHORT *)&_ei_m_ln2hi_4096_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 4096 */
+#if MPU_MATH_FN_LIMIT >= 8192
+ case NBR_8192 :
+ rc = (EMUSHORT *)&_ei_m_ln2hi_8192_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 8192 */
+#if MPU_MATH_FN_LIMIT >= 16384
+ case NBR_16384:
+ rc = (EMUSHORT *)&_ei_m_ln2hi_16384_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 16384 */
+
+ default:
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ break;
+ }
+
+ } /* End of switch( nb ) */
+
+ return( rc );
+
+} /* End of _get_m_ln2hi_ptr() */
+
+
+EMUSHORT *_get_m_ln2lo_ptr( int nb )
+{
+ EMUSHORT *rc = (EMUSHORT *)NULL;
+
+ if( nb < NBR_32 || nb > MPU_MATH_FN_LIMIT )
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ return( rc );
+ }
+
+ switch( nb )
+ {
+#if MPU_MATH_FN_LIMIT >= 128
+ case NBR_32 :
+ case NBR_64 :
+ case NBR_128 :
+ rc = (EMUSHORT *)&_ei_m_ln2lo_128_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 128 */
+#if MPU_MATH_FN_LIMIT >= 256
+ case NBR_256 :
+ rc = (EMUSHORT *)&_ei_m_ln2lo_256_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 256 */
+#if MPU_MATH_FN_LIMIT >= 512
+ case NBR_512 :
+ rc = (EMUSHORT *)&_ei_m_ln2lo_512_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 512 */
+#if MPU_MATH_FN_LIMIT >= 1024
+ case NBR_1024 :
+ rc = (EMUSHORT *)&_ei_m_ln2lo_1024_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 1024 */
+#if MPU_MATH_FN_LIMIT >= 2048
+ case NBR_2048 :
+ rc = (EMUSHORT *)&_ei_m_ln2lo_2048_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 2048 */
+#if MPU_MATH_FN_LIMIT >= 4096
+ case NBR_4096 :
+ rc = (EMUSHORT *)&_ei_m_ln2lo_4096_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 4096 */
+#if MPU_MATH_FN_LIMIT >= 8192
+ case NBR_8192 :
+ rc = (EMUSHORT *)&_ei_m_ln2lo_8192_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 8192 */
+#if MPU_MATH_FN_LIMIT >= 16384
+ case NBR_16384:
+ rc = (EMUSHORT *)&_ei_m_ln2lo_16384_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 16384 */
+
+ default:
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ break;
+ }
+
+ } /* End of switch( nb ) */
+
+ return( rc );
+
+} /* End of _get_m_ln2lo_ptr() */
+
+
+EMUSHORT *_get_m_ln_huge_ptr( int nb )
+{
+ EMUSHORT *rc = (EMUSHORT *)NULL;
+
+ if( nb < NBR_32 || nb > MPU_MATH_FN_LIMIT )
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ return( rc );
+ }
+
+ switch( nb )
+ {
+#if MPU_MATH_FN_LIMIT >= 128
+ case NBR_32 :
+ case NBR_64 :
+ case NBR_128 :
+ rc = (EMUSHORT *)&_ei_m_ln_huge_128_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 128 */
+#if MPU_MATH_FN_LIMIT >= 256
+ case NBR_256 :
+ rc = (EMUSHORT *)&_ei_m_ln_huge_256_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 256 */
+#if MPU_MATH_FN_LIMIT >= 512
+ case NBR_512 :
+ rc = (EMUSHORT *)&_ei_m_ln_huge_512_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 512 */
+#if MPU_MATH_FN_LIMIT >= 1024
+ case NBR_1024 :
+ rc = (EMUSHORT *)&_ei_m_ln_huge_1024_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 1024 */
+#if MPU_MATH_FN_LIMIT >= 2048
+ case NBR_2048 :
+ rc = (EMUSHORT *)&_ei_m_ln_huge_2048_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 2048 */
+#if MPU_MATH_FN_LIMIT >= 4096
+ case NBR_4096 :
+ rc = (EMUSHORT *)&_ei_m_ln_huge_4096_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 4096 */
+#if MPU_MATH_FN_LIMIT >= 8192
+ case NBR_8192 :
+ rc = (EMUSHORT *)&_ei_m_ln_huge_8192_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 8192 */
+#if MPU_MATH_FN_LIMIT >= 16384
+ case NBR_16384:
+ rc = (EMUSHORT *)&_ei_m_ln_huge_16384_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 16384 */
+
+ default:
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ break;
+ }
+
+ } /* End of switch( nb ) */
+
+ return( rc );
+
+} /* End of _get_m_ln_huge_ptr() */
+
+
+EMUSHORT *_get_m_ln_tiny_ptr( int nb )
+{
+ EMUSHORT *rc = (EMUSHORT *)NULL;
+
+ if( nb < NBR_32 || nb > MPU_MATH_FN_LIMIT )
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ return( rc );
+ }
+
+ switch( nb )
+ {
+#if MPU_MATH_FN_LIMIT >= 128
+ case NBR_32 :
+ case NBR_64 :
+ case NBR_128 :
+ rc = (EMUSHORT *)&_ei_m_ln_tiny_128_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 128 */
+#if MPU_MATH_FN_LIMIT >= 256
+ case NBR_256 :
+ rc = (EMUSHORT *)&_ei_m_ln_tiny_256_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 256 */
+#if MPU_MATH_FN_LIMIT >= 512
+ case NBR_512 :
+ rc = (EMUSHORT *)&_ei_m_ln_tiny_512_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 512 */
+#if MPU_MATH_FN_LIMIT >= 1024
+ case NBR_1024 :
+ rc = (EMUSHORT *)&_ei_m_ln_tiny_1024_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 1024 */
+#if MPU_MATH_FN_LIMIT >= 2048
+ case NBR_2048 :
+ rc = (EMUSHORT *)&_ei_m_ln_tiny_2048_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 2048 */
+#if MPU_MATH_FN_LIMIT >= 4096
+ case NBR_4096 :
+ rc = (EMUSHORT *)&_ei_m_ln_tiny_4096_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 4096 */
+#if MPU_MATH_FN_LIMIT >= 8192
+ case NBR_8192 :
+ rc = (EMUSHORT *)&_ei_m_ln_tiny_8192_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 8192 */
+#if MPU_MATH_FN_LIMIT >= 16384
+ case NBR_16384:
+ rc = (EMUSHORT *)&_ei_m_ln_tiny_16384_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 16384 */
+
+ default:
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ break;
+ }
+
+ } /* End of switch( nb ) */
+
+ return( rc );
+
+} /* End of _get_m_ln_tiny_ptr() */
+
+
+EMUSHORT *_get_m_athfhi_ptr( int nb )
+{
+ EMUSHORT *rc = (EMUSHORT *)NULL;
+
+ if( nb < NBR_32 || nb > MPU_MATH_FN_LIMIT )
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ return( rc );
+ }
+
+ switch( nb )
+ {
+#if MPU_MATH_FN_LIMIT >= 128
+ case NBR_32 :
+ case NBR_64 :
+ case NBR_128 :
+ rc = (EMUSHORT *)&_ei_m_athfhi_128_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 128 */
+#if MPU_MATH_FN_LIMIT >= 256
+ case NBR_256 :
+ rc = (EMUSHORT *)&_ei_m_athfhi_256_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 256 */
+#if MPU_MATH_FN_LIMIT >= 512
+ case NBR_512 :
+ rc = (EMUSHORT *)&_ei_m_athfhi_512_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 512 */
+#if MPU_MATH_FN_LIMIT >= 1024
+ case NBR_1024 :
+ rc = (EMUSHORT *)&_ei_m_athfhi_1024_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 1024 */
+#if MPU_MATH_FN_LIMIT >= 2048
+ case NBR_2048 :
+ rc = (EMUSHORT *)&_ei_m_athfhi_2048_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 2048 */
+#if MPU_MATH_FN_LIMIT >= 4096
+ case NBR_4096 :
+ rc = (EMUSHORT *)&_ei_m_athfhi_4096_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 4096 */
+#if MPU_MATH_FN_LIMIT >= 8192
+ case NBR_8192 :
+ rc = (EMUSHORT *)&_ei_m_athfhi_8192_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 8192 */
+#if MPU_MATH_FN_LIMIT >= 16384
+ case NBR_16384:
+ rc = (EMUSHORT *)&_ei_m_athfhi_16384_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 16384 */
+
+ default:
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ break;
+ }
+
+ } /* End of switch( nb ) */
+
+ return( rc );
+
+} /* End of _get_m_athfhi_ptr() */
+
+
+EMUSHORT *_get_m_athflo_ptr( int nb )
+{
+ EMUSHORT *rc = (EMUSHORT *)NULL;
+
+ if( nb < NBR_32 || nb > MPU_MATH_FN_LIMIT )
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ return( rc );
+ }
+
+ switch( nb )
+ {
+#if MPU_MATH_FN_LIMIT >= 128
+ case NBR_32 :
+ case NBR_64 :
+ case NBR_128 :
+ rc = (EMUSHORT *)&_ei_m_athflo_128_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 128 */
+#if MPU_MATH_FN_LIMIT >= 256
+ case NBR_256 :
+ rc = (EMUSHORT *)&_ei_m_athflo_256_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 256 */
+#if MPU_MATH_FN_LIMIT >= 512
+ case NBR_512 :
+ rc = (EMUSHORT *)&_ei_m_athflo_512_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 512 */
+#if MPU_MATH_FN_LIMIT >= 1024
+ case NBR_1024 :
+ rc = (EMUSHORT *)&_ei_m_athflo_1024_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 1024 */
+#if MPU_MATH_FN_LIMIT >= 2048
+ case NBR_2048 :
+ rc = (EMUSHORT *)&_ei_m_athflo_2048_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 2048 */
+#if MPU_MATH_FN_LIMIT >= 4096
+ case NBR_4096 :
+ rc = (EMUSHORT *)&_ei_m_athflo_4096_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 4096 */
+#if MPU_MATH_FN_LIMIT >= 8192
+ case NBR_8192 :
+ rc = (EMUSHORT *)&_ei_m_athflo_8192_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 8192 */
+#if MPU_MATH_FN_LIMIT >= 16384
+ case NBR_16384:
+ rc = (EMUSHORT *)&_ei_m_athflo_16384_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 16384 */
+
+ default:
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ break;
+ }
+
+ } /* End of switch( nb ) */
+
+ return( rc );
+
+} /* End of _get_m_athflo_ptr() */
+
+
+EMUSHORT *_get_m_at1fhi_ptr( int nb )
+{
+ EMUSHORT *rc = (EMUSHORT *)NULL;
+
+ if( nb < NBR_32 || nb > MPU_MATH_FN_LIMIT )
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ return( rc );
+ }
+
+ switch( nb )
+ {
+#if MPU_MATH_FN_LIMIT >= 128
+ case NBR_32 :
+ case NBR_64 :
+ case NBR_128 :
+ rc = (EMUSHORT *)&_ei_m_at1fhi_128_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 128 */
+#if MPU_MATH_FN_LIMIT >= 256
+ case NBR_256 :
+ rc = (EMUSHORT *)&_ei_m_at1fhi_256_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 256 */
+#if MPU_MATH_FN_LIMIT >= 512
+ case NBR_512 :
+ rc = (EMUSHORT *)&_ei_m_at1fhi_512_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 512 */
+#if MPU_MATH_FN_LIMIT >= 1024
+ case NBR_1024 :
+ rc = (EMUSHORT *)&_ei_m_at1fhi_1024_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 1024 */
+#if MPU_MATH_FN_LIMIT >= 2048
+ case NBR_2048 :
+ rc = (EMUSHORT *)&_ei_m_at1fhi_2048_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 2048 */
+#if MPU_MATH_FN_LIMIT >= 4096
+ case NBR_4096 :
+ rc = (EMUSHORT *)&_ei_m_at1fhi_4096_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 4096 */
+#if MPU_MATH_FN_LIMIT >= 8192
+ case NBR_8192 :
+ rc = (EMUSHORT *)&_ei_m_at1fhi_8192_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 8192 */
+#if MPU_MATH_FN_LIMIT >= 16384
+ case NBR_16384:
+ rc = (EMUSHORT *)&_ei_m_at1fhi_16384_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 16384 */
+
+ default:
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ break;
+ }
+
+ } /* End of switch( nb ) */
+
+ return( rc );
+
+} /* End of _get_m_at1fhi_ptr() */
+
+
+EMUSHORT *_get_m_at1flo_ptr( int nb )
+{
+ EMUSHORT *rc = (EMUSHORT *)NULL;
+
+ if( nb < NBR_32 || nb > MPU_MATH_FN_LIMIT )
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ return( rc );
+ }
+
+ switch( nb )
+ {
+#if MPU_MATH_FN_LIMIT >= 128
+ case NBR_32 :
+ case NBR_64 :
+ case NBR_128 :
+ rc = (EMUSHORT *)&_ei_m_at1flo_128_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 128 */
+#if MPU_MATH_FN_LIMIT >= 256
+ case NBR_256 :
+ rc = (EMUSHORT *)&_ei_m_at1flo_256_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 256 */
+#if MPU_MATH_FN_LIMIT >= 512
+ case NBR_512 :
+ rc = (EMUSHORT *)&_ei_m_at1flo_512_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 512 */
+#if MPU_MATH_FN_LIMIT >= 1024
+ case NBR_1024 :
+ rc = (EMUSHORT *)&_ei_m_at1flo_1024_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 1024 */
+#if MPU_MATH_FN_LIMIT >= 2048
+ case NBR_2048 :
+ rc = (EMUSHORT *)&_ei_m_at1flo_2048_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 2048 */
+#if MPU_MATH_FN_LIMIT >= 4096
+ case NBR_4096 :
+ rc = (EMUSHORT *)&_ei_m_at1flo_4096_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 4096 */
+#if MPU_MATH_FN_LIMIT >= 8192
+ case NBR_8192 :
+ rc = (EMUSHORT *)&_ei_m_at1flo_8192_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 8192 */
+#if MPU_MATH_FN_LIMIT >= 16384
+ case NBR_16384:
+ rc = (EMUSHORT *)&_ei_m_at1flo_16384_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 16384 */
+
+ default:
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ break;
+ }
+
+ } /* End of switch( nb ) */
+
+ return( rc );
+
+} /* End of _get_m_at1flo_ptr() */
+
+
+EMUSHORT *_get_m_39_16_ptr( int nb )
+{
+ EMUSHORT *rc = (EMUSHORT *)NULL;
+
+ if( nb < NBR_32 || nb > MPU_MATH_FN_LIMIT )
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ return( rc );
+ }
+
+ switch( nb )
+ {
+#if MPU_MATH_FN_LIMIT >= 128
+ case NBR_32 :
+ case NBR_64 :
+ case NBR_128 :
+ rc = (EMUSHORT *)&_ei_m_39_16__128_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 128 */
+#if MPU_MATH_FN_LIMIT >= 256
+ case NBR_256 :
+ rc = (EMUSHORT *)&_ei_m_39_16__256_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 256 */
+#if MPU_MATH_FN_LIMIT >= 512
+ case NBR_512 :
+ rc = (EMUSHORT *)&_ei_m_39_16__512_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 512 */
+#if MPU_MATH_FN_LIMIT >= 1024
+ case NBR_1024 :
+ rc = (EMUSHORT *)&_ei_m_39_16__1024_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 1024 */
+#if MPU_MATH_FN_LIMIT >= 2048
+ case NBR_2048 :
+ rc = (EMUSHORT *)&_ei_m_39_16__2048_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 2048 */
+#if MPU_MATH_FN_LIMIT >= 4096
+ case NBR_4096 :
+ rc = (EMUSHORT *)&_ei_m_39_16__4096_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 4096 */
+#if MPU_MATH_FN_LIMIT >= 8192
+ case NBR_8192 :
+ rc = (EMUSHORT *)&_ei_m_39_16__8192_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 8192 */
+#if MPU_MATH_FN_LIMIT >= 16384
+ case NBR_16384:
+ rc = (EMUSHORT *)&_ei_m_39_16__16384_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 16384 */
+
+ default:
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ break;
+ }
+
+ } /* End of switch( nb ) */
+
+ return( rc );
+
+} /* End of _get_m_39_16_ptr() */
+
+
+EMUSHORT *_get_m_1_16_ptr( int nb )
+{
+ EMUSHORT *rc = (EMUSHORT *)NULL;
+
+ if( nb < NBR_32 || nb > MPU_MATH_FN_LIMIT )
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ return( rc );
+ }
+
+ switch( nb )
+ {
+#if MPU_MATH_FN_LIMIT >= 128
+ case NBR_32 :
+ case NBR_64 :
+ case NBR_128 :
+ rc = (EMUSHORT *)&_ei_m_1_16__128_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 128 */
+#if MPU_MATH_FN_LIMIT >= 256
+ case NBR_256 :
+ rc = (EMUSHORT *)&_ei_m_1_16__256_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 256 */
+#if MPU_MATH_FN_LIMIT >= 512
+ case NBR_512 :
+ rc = (EMUSHORT *)&_ei_m_1_16__512_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 512 */
+#if MPU_MATH_FN_LIMIT >= 1024
+ case NBR_1024 :
+ rc = (EMUSHORT *)&_ei_m_1_16__1024_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 1024 */
+#if MPU_MATH_FN_LIMIT >= 2048
+ case NBR_2048 :
+ rc = (EMUSHORT *)&_ei_m_1_16__2048_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 2048 */
+#if MPU_MATH_FN_LIMIT >= 4096
+ case NBR_4096 :
+ rc = (EMUSHORT *)&_ei_m_1_16__4096_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 4096 */
+#if MPU_MATH_FN_LIMIT >= 8192
+ case NBR_8192 :
+ rc = (EMUSHORT *)&_ei_m_1_16__8192_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 8192 */
+#if MPU_MATH_FN_LIMIT >= 16384
+ case NBR_16384:
+ rc = (EMUSHORT *)&_ei_m_1_16__16384_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 16384 */
+
+ default:
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ break;
+ }
+
+ } /* End of switch( nb ) */
+
+ return( rc );
+
+} /* End of _get_m_1_16_ptr() */
+
+
+EMUSHORT *_get_m_thovfl_ptr( int nb )
+{
+ EMUSHORT *rc = (EMUSHORT *)NULL;
+
+ if( nb < NBR_32 || nb > MPU_MATH_FN_LIMIT )
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ return( rc );
+ }
+
+ switch( nb )
+ {
+#if MPU_MATH_FN_LIMIT >= 128
+ case NBR_32 :
+ case NBR_64 :
+ case NBR_128 :
+ rc = (EMUSHORT *)&_ei_m_thovfl_128_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 128 */
+#if MPU_MATH_FN_LIMIT >= 256
+ case NBR_256 :
+ rc = (EMUSHORT *)&_ei_m_thovfl_256_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 256 */
+#if MPU_MATH_FN_LIMIT >= 512
+ case NBR_512 :
+ rc = (EMUSHORT *)&_ei_m_thovfl_512_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 512 */
+#if MPU_MATH_FN_LIMIT >= 1024
+ case NBR_1024 :
+ rc = (EMUSHORT *)&_ei_m_thovfl_1024_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 1024 */
+#if MPU_MATH_FN_LIMIT >= 2048
+ case NBR_2048 :
+ rc = (EMUSHORT *)&_ei_m_thovfl_2048_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 2048 */
+#if MPU_MATH_FN_LIMIT >= 4096
+ case NBR_4096 :
+ rc = (EMUSHORT *)&_ei_m_thovfl_4096_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 4096 */
+#if MPU_MATH_FN_LIMIT >= 8192
+ case NBR_8192 :
+ rc = (EMUSHORT *)&_ei_m_thovfl_8192_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 8192 */
+#if MPU_MATH_FN_LIMIT >= 16384
+ case NBR_16384:
+ rc = (EMUSHORT *)&_ei_m_thovfl_16384_[0];
+ break;
+#endif /* MPU_MATH_FN_LIMIT >= 16384 */
+
+ default:
+ {
+ /* error: Invalid size of operand(s) */
+ __real_error_no = __R_ESIZE__;
+ __STIND; /* Set REAL ind-produsing operation Flag */
+ break;
+ }
+
+ } /* End of switch( nb ) */
+
+ return( rc );
+
+} /* End of _get_m_thovfl_ptr() */
+
+
+/***************************************************************
+ Hide internal symbols:
+ ***************************************************************/
+
+__mpu_hidden_decl(_get_m_ln2hi_ptr);
+__mpu_hidden_decl(_get_m_ln2lo_ptr);
+__mpu_hidden_decl(_get_m_ln_huge_ptr);
+__mpu_hidden_decl(_get_m_ln_tiny_ptr);
+__mpu_hidden_decl(_get_m_athfhi_ptr);
+__mpu_hidden_decl(_get_m_athflo_ptr);
+__mpu_hidden_decl(_get_m_at1fhi_ptr);
+__mpu_hidden_decl(_get_m_at1flo_ptr);
+__mpu_hidden_decl(_get_m_39_16_ptr);
+__mpu_hidden_decl(_get_m_1_16_ptr);
+__mpu_hidden_decl(_get_m_thovfl_ptr);
+
+
+/*
+ End of hide internal symbols.
+ ***************************************************************/