Index: lys/monomials/p_MemAdd.h
===================================================================
--- polys/monomials/p_MemAdd.h	(revision 0087338a44e796a7d0c0ffe1127d1e9f428a0c7b)
+++ 	(revision )
@@ -1,389 +1,0 @@
-/****************************************
-*  Computer Algebra System SINGULAR     *
-****************************************/
-/***************************************************************
- *  File:    p_MemAdd.h
- *  Purpose: macros for memory addition
- *  Author:  obachman (Olaf Bachmann)
- *  Created: 8/00
- *  Version: $Id$
- *******************************************************************/
-#ifndef P_MEM_ADD_H
-#define P_MEM_ADD_H
-
-/***************************************************************
- *
- * MemSum
- *
- ***************************************************************/
-
-#define _p_MemSum(i, r, s1, s2) r[i] = s1[i] + s2[i]
-
-#define _p_MemSum_LengthOne(r, s1, s2) _p_MemSum(0, r, s1, s2)
-#define _p_MemSum_LengthTwo(r, s1, s2) do{_p_MemSum_LengthOne(r, s1, s2); _p_MemSum(1, r, s1, s2);} while(0)
-#define _p_MemSum_LengthThree(r, s1, s2) do{_p_MemSum_LengthTwo(r, s1, s2); _p_MemSum(2, r, s1, s2);} while(0)
-#define _p_MemSum_LengthFour(r, s1, s2) do{_p_MemSum_LengthThree(r, s1, s2); _p_MemSum(3, r, s1, s2);} while(0)
-#define _p_MemSum_LengthFive(r, s1, s2) do{_p_MemSum_LengthFour(r, s1, s2); _p_MemSum(4, r, s1, s2);} while(0)
-#define _p_MemSum_LengthSix(r, s1, s2) do{_p_MemSum_LengthFive(r, s1, s2); _p_MemSum(5, r, s1, s2);} while(0)
-#define _p_MemSum_LengthSeven(r, s1, s2) do{_p_MemSum_LengthSix(r, s1, s2); _p_MemSum(6, r, s1, s2);} while(0)
-#define _p_MemSum_LengthEight(r, s1, s2) do{_p_MemSum_LengthSeven(r, s1, s2); _p_MemSum(7, r, s1, s2);} while(0)
-
-#define _p_MemSum_Declare(r, s1, s2)                \
-  const unsigned long* _s1 = ((unsigned long*) s1); \
-  const unsigned long* _s2 = ((unsigned long*) s2); \
-  unsigned long* _r = ((unsigned long*) r)
-
-#define p_MemSum_LengthOne(r, s1, s2, length) _p_MemSum_LengthOne(r, s1, s2)
-#define p_MemSum_LengthTwo(r, s1, s2, length)   \
-do                                              \
-{                                               \
-  _p_MemSum_Declare(r,s1,s2);                    \
-  _p_MemSum_LengthTwo(_r, _s1, _s2);            \
-}                                               \
-while (0)
-#define p_MemSum_LengthThree(r, s1, s2, length) \
-do                                              \
-{                                               \
-  _p_MemSum_Declare(r,s1,s2);                    \
-  _p_MemSum_LengthThree(_r, _s1, _s2);          \
-}                                               \
-while (0)
-#define p_MemSum_LengthFour(r, s1, s2, length)  \
-do                                              \
-{                                               \
-  _p_MemSum_Declare(r,s1,s2);                    \
-  _p_MemSum_LengthFour(_r, _s1, _s2);           \
-}                                               \
-while (0)
-#define p_MemSum_LengthFive(r, s1, s2, length)  \
-do                                              \
-{                                               \
-  _p_MemSum_Declare(r,s1,s2);                    \
-  _p_MemSum_LengthFive(_r, _s1, _s2);           \
-}                                               \
-while (0)
-#define p_MemSum_LengthSix(r, s1, s2, length)   \
-do                                              \
-{                                               \
-  _p_MemSum_Declare(r,s1,s2);                    \
-  _p_MemSum_LengthSix(_r, _s1, _s2);            \
-}                                               \
-while (0)
-#define p_MemSum_LengthSeven(r, s1, s2, length) \
-do                                              \
-{                                               \
-  _p_MemSum_Declare(r,s1,s2);                    \
-  _p_MemSum_LengthSeven(_r, _s1, _s2);          \
-}                                               \
-while (0)
-#define p_MemSum_LengthEight(r, s1, s2, length) \
-do                                              \
-{                                               \
-  _p_MemSum_Declare(r,s1,s2);                    \
-  _p_MemSum_LengthEight(_r, _s1, _s2);          \
-}                                               \
-while (0)
-
-#define p_MemSum_LengthGeneral(r, s1, s2, length)   \
-do                                                  \
-{                                                   \
-  _p_MemSum_Declare(r,s1,s2);                       \
-  const unsigned long _l = (unsigned long) length;       \
-  unsigned long _i = 0;                             \
-                                                    \
-  do                                                \
-  {                                                 \
-    _r[_i] = _s1[_i] + _s2[_i];                     \
-    _i++;                                           \
-  }                                                 \
-  while (_i != _l);                                 \
-}                                                   \
-while (0)
-
-/***************************************************************
- *
- * MemAdd
- *
- ***************************************************************/
-#define _p_MemAdd(i, r, s) r[i] += s[i]
-
-#define _p_MemAdd_LengthOne(r, s) _p_MemAdd(0, r, s)
-#define _p_MemAdd_LengthTwo(r, s) do{_p_MemAdd_LengthOne(r, s); _p_MemAdd(1, r, s);} while(0)
-#define _p_MemAdd_LengthThree(r, s) do{_p_MemAdd_LengthTwo(r, s); _p_MemAdd(2, r, s);} while(0)
-#define _p_MemAdd_LengthFour(r, s) do{_p_MemAdd_LengthThree(r, s); _p_MemAdd(3, r, s);} while(0)
-#define _p_MemAdd_LengthFive(r, s) do{_p_MemAdd_LengthFour(r, s); _p_MemAdd(4, r, s);} while(0)
-#define _p_MemAdd_LengthSix(r, s) do{_p_MemAdd_LengthFive(r, s); _p_MemAdd(5, r, s);} while(0)
-#define _p_MemAdd_LengthSeven(r, s) do{_p_MemAdd_LengthSix(r, s); _p_MemAdd(6, r, s);} while(0)
-#define _p_MemAdd_LengthEight(r, s) do{_p_MemAdd_LengthSeven(r, s); _p_MemAdd(7, r, s);} while(0)
-
-#define _p_MemAdd_Declare(r, s)                \
-  const unsigned long* _s = ((unsigned long*) s); \
-  unsigned long* _r = ((unsigned long*) r)
-
-#define p_MemAdd_LengthOne(r, s, length) _p_MemAdd_LengthOne(r, s)
-#define p_MemAdd_LengthTwo(r, s, length)   \
-do                                              \
-{                                               \
-  _p_MemAdd_Declare(r,s);                    \
-  _p_MemAdd_LengthTwo(_r, _s);            \
-}                                               \
-while (0)
-#define p_MemAdd_LengthThree(r, s, length) \
-do                                              \
-{                                               \
-  _p_MemAdd_Declare(r,s);                    \
-  _p_MemAdd_LengthThree(_r, _s);          \
-}                                               \
-while (0)
-#define p_MemAdd_LengthFour(r, s, length)  \
-do                                              \
-{                                               \
-  _p_MemAdd_Declare(r,s);                    \
-  _p_MemAdd_LengthFour(_r, _s);           \
-}                                               \
-while (0)
-#define p_MemAdd_LengthFive(r, s, length)  \
-do                                              \
-{                                               \
-  _p_MemAdd_Declare(r,s);                    \
-  _p_MemAdd_LengthFive(_r, _s);           \
-}                                               \
-while (0)
-#define p_MemAdd_LengthSix(r, s, length)   \
-do                                              \
-{                                               \
-  _p_MemAdd_Declare(r,s);                    \
-  _p_MemAdd_LengthSix(_r, _s);            \
-}                                               \
-while (0)
-#define p_MemAdd_LengthSeven(r, s, length) \
-do                                              \
-{                                               \
-  _p_MemAdd_Declare(r,s);                    \
-  _p_MemAdd_LengthSeven(_r, _s);          \
-}                                               \
-while (0)
-#define p_MemAdd_LengthEight(r, s, length) \
-do                                              \
-{                                               \
-  _p_MemAdd_Declare(r,s);                    \
-  _p_MemAdd_LengthEight(_r, _s);          \
-}                                               \
-while (0)
-
-#define p_MemAdd_LengthGeneral(r, s, length)       \
-do                                                  \
-{                                                   \
-  _p_MemAdd_Declare(r,s);                          \
-  const unsigned long _l = (unsigned long) length;  \
-  unsigned long _i = 0;                             \
-                                                    \
-  do                                                \
-  {                                                 \
-    _r[_i] += _s[_i];                               \
-    _i++;                                           \
-  }                                                 \
-  while (_i != _l);                                 \
-}                                                   \
-while (0)
-
-
-/***************************************************************
- *
- * MemDiff
- *
- ***************************************************************/
-#define _p_MemDiff(i, r, s1, s2) r[i] = s1[i] - s2[i]
-
-#define _p_MemDiff_LengthOne(r, s1, s2) _p_MemDiff(0, r, s1, s2)
-#define _p_MemDiff_LengthTwo(r, s1, s2) do{_p_MemDiff_LengthOne(r, s1, s2); _p_MemDiff(1, r, s1, s2);} while(0)
-#define _p_MemDiff_LengthThree(r, s1, s2) do{_p_MemDiff_LengthTwo(r, s1, s2); _p_MemDiff(2, r, s1, s2);} while(0)
-#define _p_MemDiff_LengthFour(r, s1, s2) do{_p_MemDiff_LengthThree(r, s1, s2); _p_MemDiff(3, r, s1, s2);} while(0)
-#define _p_MemDiff_LengthFive(r, s1, s2) do{_p_MemDiff_LengthFour(r, s1, s2); _p_MemDiff(4, r, s1, s2);} while(0)
-#define _p_MemDiff_LengthSix(r, s1, s2) do{_p_MemDiff_LengthFive(r, s1, s2); _p_MemDiff(5, r, s1, s2);} while(0)
-#define _p_MemDiff_LengthSeven(r, s1, s2) do{_p_MemDiff_LengthSix(r, s1, s2); _p_MemDiff(6, r, s1, s2);} while(0)
-#define _p_MemDiff_LengthEight(r, s1, s2) do{_p_MemDiff_LengthSeven(r, s1, s2); _p_MemDiff(7, r, s1, s2);} while(0)
-
-#define _p_MemDiff_Declare(r, s1, s2)                \
-  const unsigned long* _s1 = ((unsigned long*) s1); \
-  const unsigned long* _s2 = ((unsigned long*) s2); \
-  unsigned long* _r = ((unsigned long*) r)
-
-#define p_MemDiff_LengthOne(r, s1, s2, length) _p_MemDiff_LengthOne(r, s1, s2)
-#define p_MemDiff_LengthTwo(r, s1, s2, length)   \
-do                                              \
-{                                               \
-  _p_MemDiff_Declare(r,s1,s2);                    \
-  _p_MemDiff_LengthTwo(_r, _s1, _s2);            \
-}                                               \
-while (0)
-#define p_MemDiff_LengthThree(r, s1, s2, length) \
-do                                              \
-{                                               \
-  _p_MemDiff_Declare(r,s1,s2);                    \
-  _p_MemDiff_LengthThree(_r, _s1, _s2);          \
-}                                               \
-while (0)
-#define p_MemDiff_LengthFour(r, s1, s2, length)  \
-do                                              \
-{                                               \
-  _p_MemDiff_Declare(r,s1,s2);                    \
-  _p_MemDiff_LengthFour(_r, _s1, _s2);           \
-}                                               \
-while (0)
-#define p_MemDiff_LengthFive(r, s1, s2, length)  \
-do                                              \
-{                                               \
-  _p_MemDiff_Declare(r,s1,s2);                    \
-  _p_MemDiff_LengthFive(_r, _s1, _s2);           \
-}                                               \
-while (0)
-#define p_MemDiff_LengthSix(r, s1, s2, length)   \
-do                                              \
-{                                               \
-  _p_MemDiff_Declare(r,s1,s2);                    \
-  _p_MemDiff_LengthSix(_r, _s1, _s2);            \
-}                                               \
-while (0)
-#define p_MemDiff_LengthSeven(r, s1, s2, length) \
-do                                              \
-{                                               \
-  _p_MemDiff_Declare(r,s1,s2);                    \
-  _p_MemDiff_LengthSeven(_r, _s1, _s2);          \
-}                                               \
-while (0)
-#define p_MemDiff_LengthEight(r, s1, s2, length) \
-do                                              \
-{                                               \
-  _p_MemDiff_Declare(r,s1,s2);                    \
-  _p_MemDiff_LengthEight(_r, _s1, _s2);          \
-}                                               \
-while (0)
-
-#define p_MemDiff_LengthGeneral(r, s1, s2, length)   \
-do                                                  \
-{                                                   \
-  _p_MemDiff_Declare(r,s1,s2);                       \
-  const unsigned long _l = (unsigned long) length;       \
-  unsigned long _i = 0;                             \
-                                                    \
-  do                                                \
-  {                                                 \
-    _r[_i] = _s1[_i] - _s2[_i];                     \
-    _i++;                                           \
-  }                                                 \
-  while (_i != _l);                                 \
-}                                                   \
-while (0)
-
-
-/***************************************************************
- *
- * MemSub
- *
- ***************************************************************/
-
-#define _p_MemSub(i, r, s) r[i] -= s[i]
-
-#define _p_MemSub_LengthOne(r, s) _p_MemSub(0, r, s)
-#define _p_MemSub_LengthTwo(r, s) do{_p_MemSub_LengthOne(r, s); _p_MemSub(1, r, s);} while(0)
-#define _p_MemSub_LengthThree(r, s) do{_p_MemSub_LengthTwo(r, s); _p_MemSub(2, r, s);} while(0)
-#define _p_MemSub_LengthFour(r, s) do{_p_MemSub_LengthThree(r, s); _p_MemSub(3, r, s);} while(0)
-#define _p_MemSub_LengthFive(r, s) do{_p_MemSub_LengthFour(r, s); _p_MemSub(4, r, s);} while(0)
-#define _p_MemSub_LengthSix(r, s) do{_p_MemSub_LengthFive(r, s); _p_MemSub(5, r, s);} while(0)
-#define _p_MemSub_LengthSeven(r, s) do{_p_MemSub_LengthSix(r, s); _p_MemSub(6, r, s);} while(0)
-#define _p_MemSub_LengthEight(r, s) do{_p_MemSub_LengthSeven(r, s); _p_MemSub(7, r, s);} while(0)
-
-#define _p_MemSub_Declare(r, s)                \
-  const unsigned long* _s = ((unsigned long*) s); \
-  unsigned long* _r = ((unsigned long*) r)
-
-#define p_MemSub_LengthOne(r, s, length) _p_MemSub_LengthOne(r, s)
-#define p_MemSub_LengthTwo(r, s, length)   \
-do                                              \
-{                                               \
-  _p_MemSub_Declare(r,s);                    \
-  _p_MemSub_LengthTwo(_r, _s);            \
-}                                               \
-while (0)
-#define p_MemSub_LengthThree(r, s, length) \
-do                                              \
-{                                               \
-  _p_MemSub_Declare(r,s);                    \
-  _p_MemSub_LengthThree(_r, _s);          \
-}                                               \
-while (0)
-#define p_MemSub_LengthFour(r, s, length)  \
-do                                              \
-{                                               \
-  _p_MemSub_Declare(r,s);                    \
-  _p_MemSub_LengthFour(_r, _s);           \
-}                                               \
-while (0)
-#define p_MemSub_LengthFive(r, s, length)  \
-do                                              \
-{                                               \
-  _p_MemSub_Declare(r,s);                    \
-  _p_MemSub_LengthFive(_r, _s);           \
-}                                               \
-while (0)
-#define p_MemSub_LengthSix(r, s, length)   \
-do                                              \
-{                                               \
-  _p_MemSub_Declare(r,s);                    \
-  _p_MemSub_LengthSix(_r, _s);            \
-}                                               \
-while (0)
-#define p_MemSub_LengthSeven(r, s, length) \
-do                                              \
-{                                               \
-  _p_MemSub_Declare(r,s);                    \
-  _p_MemSub_LengthSeven(_r, _s);          \
-}                                               \
-while (0)
-#define p_MemSub_LengthEight(r, s, length) \
-do                                              \
-{                                               \
-  _p_MemSub_Declare(r,s);                    \
-  _p_MemSub_LengthEight(_r, _s);          \
-}                                               \
-while (0)
-
-#define p_MemSub_LengthGeneral(r, s, length)       \
-do                                                  \
-{                                                   \
-  _p_MemSub_Declare(r,s);                          \
-  const unsigned long _l = (unsigned long) length;  \
-  unsigned long _i = 0;                             \
-                                                    \
-  do                                                \
-  {                                                 \
-    _r[_i] -= _s[_i];                               \
-    _i++;                                           \
-  }                                                 \
-  while (_i != _l);                                 \
-}                                                   \
-while (0)
-
-#define _p_MemAddSub_Declare(r, s, t)                \
-  const unsigned long* _s = ((unsigned long*) s); \
-  const unsigned long* _t = ((unsigned long*) t); \
-  unsigned long* _r = ((unsigned long*) r)
-
-#define p_MemAddSub_LengthGeneral(r, s, t, length)  \
-do                                                  \
-{                                                   \
-  _p_MemAddSub_Declare(r,s, t);                     \
-  const unsigned long _l = (unsigned long) length;  \
-  unsigned long _i = 0;                             \
-                                                    \
-  do                                                \
-  {                                                 \
-    _r[_i] += _s[_i] - _t[_i];                      \
-    _i++;                                           \
-  }                                                 \
-  while (_i != _l);                                 \
-}                                                   \
-while (0)
-
-#endif /* P_MEM_ADD_H */
Index: lys/monomials/p_MemCmp.h
===================================================================
--- polys/monomials/p_MemCmp.h	(revision 0087338a44e796a7d0c0ffe1127d1e9f428a0c7b)
+++ 	(revision )
@@ -1,949 +1,0 @@
-/****************************************
-*  Computer Algebra System SINGULAR     *
-****************************************/
-/***************************************************************
- *  File:    p_MemCmp.h
- *  Purpose: macros for memory comparisons
- *  Author:  obachman (Olaf Bachmann)
- *  Created: 8/00
- *  Version: $Id$
- *******************************************************************/
-#ifndef P_MEM_CMP_H
-#define P_MEM_CMP_H
-
-/***************************************************************
- *
- *  auxiallary macros
- *
- *******************************************************************/
-#define _p_MemCmp_Declare(s1, s2)                   \
-  const unsigned long* _s1 = ((unsigned long*) s1); \
-  const unsigned long* _s2 = ((unsigned long*) s2); \
-  register unsigned long _v1;                       \
-  register unsigned long _v2
-
-#define _p_MemCmp_Equal(i, s1, s2, actionE) \
-  do {  _v1=((unsigned long*)s1)[i]; _v2=((unsigned long*)s2)[i]; if (_v1==_v2) actionE; }while (0)
-#define _p_MemCmp_NotEqual(actionG, actionS)   \
-  do {if (_v1 > _v2) actionG; actionS;} while (0)
-
-#define _p_MemCmp_LengthOne_Equal(i, s1, s2, actionE) \
-  _p_MemCmp_Equal(i, s1, s2, actionE)
-#define _p_MemCmp_LengthTwo_Equal(i, s1, s2, actionE) \
-  _p_MemCmp_Equal(i, s1, s2, _p_MemCmp_Equal(i+1, s1, s2, actionE))
-#define _p_MemCmp_LengthThree_Equal(i, s1, s2, actionE) \
-  _p_MemCmp_LengthTwo_Equal(i, s1, s2, _p_MemCmp_Equal(i+2, s1, s2, actionE))
-#define _p_MemCmp_LengthFour_Equal(i, s1, s2, actionE) \
-  _p_MemCmp_LengthThree_Equal(i, s1, s2, _p_MemCmp_Equal(i+3, s1, s2, actionE))
-#define _p_MemCmp_LengthFive_Equal(i, s1, s2, actionE) \
-  _p_MemCmp_LengthFour_Equal(i, s1, s2, _p_MemCmp_Equal(i+4, s1, s2, actionE))
-#define _p_MemCmp_LengthSix_Equal(i, s1, s2, actionE) \
-  _p_MemCmp_LengthFive_Equal(i, s1, s2, _p_MemCmp_Equal(i+5, s1, s2, actionE))
-#define _p_MemCmp_LengthSeven_Equal(i, s1, s2, actionE) \
-  _p_MemCmp_LengthSix_Equal(i, s1, s2, _p_MemCmp_Equal(i+6, s1, s2, actionE))
-#define _p_MemCmp_LengthEight_Equal(i, s1, s2, actionE) \
-  _p_MemCmp_LengthSeven_Equal(i, s1, s2, _p_MemCmp_Equal(i+7, s1, s2, actionE))
-#define _p_MemCmp_LengthGeneral_Equal(i, s1, s2, length, actionE)   \
-do                                                                  \
-{                                                                   \
-                                                                    \
-  register unsigned long _i = (unsigned long) i;                    \
-  const unsigned long _l =                                          \
-         (unsigned long) length + (unsigned long)i ;                \
-                                                                    \
-  LengthGeneral_LoopTop:                                            \
-    _v1 = s1[_i];                                                   \
-    _v2 = s2[_i];                                                   \
-    if (_v1 == _v2)                                                 \
-    {                                                               \
-      _i++;                                                         \
-      if (_i == _l) actionE;                                        \
-      else  goto LengthGeneral_LoopTop;                             \
-    }                                                               \
-}                                                                   \
-while (0)
-
-/***************************************************************
- *
- *  Pomog
- *
- *******************************************************************/
-#define p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-do                                                                          \
-{                                                                           \
-  _p_MemCmp_Declare(s1,s2);                                                 \
-  _p_MemCmp_LengthOne_Equal(0, _s1, _s2, actionE);                          \
-  _p_MemCmp_NotEqual(actionG, actionS);                                     \
-}                                                                           \
-while (0)
-#define p_MemCmp_LengthTwo_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-do                                                                          \
-{                                                                           \
-  _p_MemCmp_Declare(s1,s2);                                                 \
-  _p_MemCmp_LengthTwo_Equal(0, _s1, _s2, actionE);                 \
-  _p_MemCmp_NotEqual(actionG, actionS);                                      \
-}                                                                           \
-while (0)
-#define p_MemCmp_LengthThree_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Declare(s1,s2);                                                     \
-  _p_MemCmp_LengthThree_Equal(0, _s1, _s2, actionE);                   \
-  _p_MemCmp_NotEqual(actionG, actionS);                                      \
-}                                                                               \
-while (0)
-#define p_MemCmp_LengthFour_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Declare(s1,s2);                                                     \
-  _p_MemCmp_LengthFour_Equal(0, _s1, _s2, actionE);                    \
-  _p_MemCmp_NotEqual(actionG, actionS);                                      \
-}                                                                               \
-while (0)
-#define p_MemCmp_LengthFive_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Declare(s1,s2);                                                     \
-  _p_MemCmp_LengthFive_Equal(0, _s1, _s2, actionE);                    \
-  _p_MemCmp_NotEqual(actionG, actionS);                                      \
-}                                                                               \
-while (0)
-#define p_MemCmp_LengthSix_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-do                                                                          \
-{                                                                           \
-  _p_MemCmp_Declare(s1,s2);                                                 \
-  _p_MemCmp_LengthSix_Equal(0, _s1, _s2, actionE);                 \
-  _p_MemCmp_NotEqual(actionG, actionS);                                      \
-}                                                                           \
-while (0)
-#define p_MemCmp_LengthSeven_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Declare(s1,s2);                                                     \
-  _p_MemCmp_LengthSeven_Equal(0, _s1, _s2, actionE);                   \
-  _p_MemCmp_NotEqual(actionG, actionS);;                                      \
-}                                                                               \
-while (0)
-
-#define p_MemCmp_LengthEight_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Declare(s1,s2);                                                     \
-  _p_MemCmp_LengthEight_Equal(0, _s1, _s2, actionE);                   \
-  _p_MemCmp_NotEqual(actionG, actionS);                                      \
-}                                                                               \
-while (0)
-#define p_MemCmp_LengthGeneral_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Declare(s1,s2);                                                     \
-  _p_MemCmp_LengthGeneral_Equal(0, _s1, _s2, length, actionE);      \
-  _p_MemCmp_NotEqual(actionG, actionS);                                          \
-}                                                                               \
-while (0)
-
-/***************************************************************
- *
- *  Nomog
- *
- *******************************************************************/
-#define p_MemCmp_LengthOne_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthTwo_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthTwo_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthThree_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthThree_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthFour_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthFour_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthFive_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthFive_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthSix_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthSix_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthSeven_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSeven_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthEight_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthEight_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthGeneral_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthGeneral_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-
-/***************************************************************
- *
- *  PomogZero
- *
- *******************************************************************/
-#define p_MemCmp_LengthTwo_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthThree_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthTwo_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFour_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthThree_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFive_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthFour_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSix_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthFive_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSeven_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSix_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthEight_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSeven_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthGeneral_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthGeneral_OrdPomog(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
-
-/***************************************************************
- *
- *  NomogZero
- *
- *******************************************************************/
-#define p_MemCmp_LengthTwo_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthOne_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthThree_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthTwo_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFour_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthThree_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFive_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthFour_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSix_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthFive_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSeven_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSix_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthEight_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSeven_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthGeneral_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthGeneral_OrdNomog(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
-
-/***************************************************************
- *
- *  NegPomog
- *
- *******************************************************************/
-#define p_MemCmp_LengthTwo_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                      \
-                           _p_MemCmp_LengthOne_Equal(1, _s2, _s1,actionE),      \
-                           actionS, actionG)
-#define p_MemCmp_LengthThree_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
-                           _p_MemCmp_LengthTwo_Equal(1, _s2, _s1, actionE),              \
-                           actionS, actionG)
-#define p_MemCmp_LengthFour_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                      \
-                           _p_MemCmp_LengthThree_Equal(1, _s2, _s1, actionE),        \
-                           actionS, actionG)
-#define p_MemCmp_LengthFive_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                      \
-                           _p_MemCmp_LengthFour_Equal(1, _s2, _s1, actionE),         \
-                           actionS, actionG)
-#define p_MemCmp_LengthSix_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                      \
-                           _p_MemCmp_LengthFive_Equal(1, _s2, _s1, actionE),         \
-                           actionS, actionG)
-#define p_MemCmp_LengthSeven_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
-                           _p_MemCmp_LengthSix_Equal(1, _s2, _s1, actionE),              \
-                           actionS, actionG)
-#define p_MemCmp_LengthEight_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
-                           _p_MemCmp_LengthSeven_Equal(1, _s2, _s1, actionE),            \
-                           actionS, actionG)
-#define p_MemCmp_LengthGeneral_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)      \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                              \
-                           _p_MemCmp_LengthGeneral_Equal(1, _s2, _s1, (length) -1, actionE), \
-                           actionS, actionG)
-
-/***************************************************************
- *
- *  PomogNeg
- *
- *******************************************************************/
-#define p_MemCmp_LengthTwo_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                      \
-                           _p_MemCmp_Equal(1, _s2, _s1, actionE),               \
-                           actionG, actionS)
-#define p_MemCmp_LengthThree_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthTwo_OrdPomog(s1, s2, length, ordsgn,                                          \
-                           _p_MemCmp_Equal(2, _s2, _s1, actionE),                   \
-                           actionG, actionS)
-#define p_MemCmp_LengthFour_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthThree_OrdPomog(s1, s2, length, ordsgn,                                    \
-                           _p_MemCmp_Equal(3, _s2, _s1, actionE),              \
-                           actionG, actionS)
-#define p_MemCmp_LengthFive_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthFour_OrdPomog(s1, s2, length, ordsgn,                                     \
-                           _p_MemCmp_Equal(4, _s2, _s1, actionE),               \
-                           actionG, actionS)
-#define p_MemCmp_LengthSix_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-  p_MemCmp_LengthFive_OrdPomog(s1, s2, length, ordsgn,                                     \
-                           _p_MemCmp_Equal(5, _s2, _s1, actionE),               \
-                           actionG, actionS)
-#define p_MemCmp_LengthSeven_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthSix_OrdPomog(s1, s2, length, ordsgn,                                          \
-                           _p_MemCmp_Equal(6, _s2, _s1, actionE),                   \
-                           actionG, actionS)
-#define p_MemCmp_LengthEight_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthSeven_OrdPomog(s1, s2, length, ordsgn,                                        \
-                           _p_MemCmp_Equal(7, _s2, _s1, actionE),                   \
-                           actionG, actionS)
-#define p_MemCmp_LengthGeneral_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-  p_MemCmp_LengthGeneral_OrdPomog(s1, s2, (length-1), ordsgn,                                  \
-                           _p_MemCmp_Equal(_i, _s2, _s1, actionE),                  \
-                           actionG, actionS)
-
-/***************************************************************
- *
- *  PosNomog
- *
- *******************************************************************/
-#define p_MemCmp_LengthThree_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthThree_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthFour_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthFour_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthFive_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthFive_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthSix_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-  p_MemCmp_LengthSix_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthSeven_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthSeven_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthEight_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthEight_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthGeneral_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-  p_MemCmp_LengthGeneral_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
-
-/***************************************************************
- *
- *  NomogPos
- *
- *******************************************************************/
-#define p_MemCmp_LengthThree_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthThree_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthFour_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthFour_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthFive_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthFive_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthSix_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-  p_MemCmp_LengthSix_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthSeven_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthSeven_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthEight_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthEight_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
-#define p_MemCmp_LengthGeneral_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-  p_MemCmp_LengthGeneral_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
-
-
-/***************************************************************
- *
- *  PomogNegZero
- *
- *******************************************************************/
-#define p_MemCmp_LengthThree_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthTwo_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFour_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthThree_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFive_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthFour_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSix_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthFive_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSeven_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSix_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthEight_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSeven_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthGeneral_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthGeneral_OrdPomogNeg(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
-
-/***************************************************************
- *
- *  NegPomogZero
- *
- *******************************************************************/
-#define p_MemCmp_LengthThree_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthTwo_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFour_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthThree_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFive_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthFour_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSix_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthFive_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSeven_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSix_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthEight_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSeven_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthGeneral_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthGeneral_OrdNegPomog(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
-
-/***************************************************************
- *
- *  NomogPosZero
- *
- *******************************************************************/
-#define p_MemCmp_LengthFour_OrdNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthThree_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFive_OrdNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthFour_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSix_OrdNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthFive_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSeven_OrdNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSix_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthEight_OrdNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSeven_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthGeneral_OrdNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthGeneral_OrdNomogPos(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
-
-/***************************************************************
- *
- *  PosNomogZero
- *
- *******************************************************************/
-#define p_MemCmp_LengthFour_OrdPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthThree_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFive_OrdPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthFour_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSix_OrdPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthFive_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSeven_OrdPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSix_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthEight_OrdPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSeven_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthGeneral_OrdPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthGeneral_OrdPosNomog(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
-
-/***************************************************************
- *
- * PosPosNomog
- *
- *******************************************************************/
-#define p_MemCmp_LengthThree_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)             \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_Equal(1, _s1, _s2,                                         \
-                                           _p_MemCmp_LengthOne_Equal(2, _s2, _s1, actionE)),    \
-                           actionG, actionS)
-#define p_MemCmp_LengthFour_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_Equal(1, _s1, _s2,                                         \
-                                           _p_MemCmp_LengthTwo_Equal(2, _s2, _s1, actionE)),    \
-                           actionG, actionS)
-#define p_MemCmp_LengthFive_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_Equal(1, _s1, _s2,                                         \
-                                           _p_MemCmp_LengthThree_Equal(2, _s2, _s1, actionE)),    \
-                           actionG, actionS)
-#define p_MemCmp_LengthSix_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_Equal(1, _s1, _s2,                                         \
-                                           _p_MemCmp_LengthFour_Equal(2, _s2, _s1, actionE)),    \
-                           actionG, actionS)
-#define p_MemCmp_LengthSeven_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_Equal(1, _s1, _s2,                                         \
-                                           _p_MemCmp_LengthFive_Equal(2, _s2, _s1, actionE)),    \
-                           actionG, actionS)
-#define p_MemCmp_LengthEight_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_Equal(1, _s1, _s2,                                         \
-                                           _p_MemCmp_LengthSix_Equal(2, _s2, _s1, actionE)),    \
-                           actionG, actionS)
-#define p_MemCmp_LengthGeneral_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)          \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                     \
-                           _p_MemCmp_Equal(1, _s1, _s2,                                                   \
-                                           _p_MemCmp_LengthGeneral_Equal(2,_s2,_s1,(length-2), actionE)), \
-                           actionG, actionS)
-
-/***************************************************************
- *
- * NegPosNomog
- *
- *******************************************************************/
-#define p_MemCmp_LengthThree_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)             \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_Equal(1, _s2, _s1,                                         \
-                                           _p_MemCmp_LengthOne_Equal(2, _s1, _s2, actionE)),    \
-                           actionS, actionG)
-#define p_MemCmp_LengthFour_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)              \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_Equal(1, _s2, _s1,                                         \
-                                           _p_MemCmp_LengthTwo_Equal(2, _s1, _s2, actionE)),    \
-                           actionS, actionG)
-#define p_MemCmp_LengthFive_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)              \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_Equal(1, _s2, _s1,                                         \
-                                           _p_MemCmp_LengthThree_Equal(2, _s1, _s2, actionE)),  \
-                           actionS, actionG)
-#define p_MemCmp_LengthSix_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)               \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_Equal(1, _s2, _s1,                                         \
-                                           _p_MemCmp_LengthFour_Equal(2, _s1, _s2, actionE)),   \
-                           actionS, actionG)
-#define p_MemCmp_LengthSeven_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)             \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_Equal(1, _s2, _s1,                                         \
-                                           _p_MemCmp_LengthFive_Equal(2, _s1, _s2, actionE)),   \
-                           actionS, actionG)
-#define p_MemCmp_LengthEight_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)             \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_Equal(1, _s2, _s1,                                         \
-                                           _p_MemCmp_LengthSix_Equal(2, _s1, _s2, actionE)),    \
-                           actionS, actionG)
-#define p_MemCmp_LengthGeneral_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)               \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                          \
-                           _p_MemCmp_Equal(1, _s2, _s1,                                             \
-                                           _p_MemCmp_LengthGeneral_Equal(2, _s1,_s2,                \
-                                                                         (length-2) , actionE)),    \
-                           actionS, actionG)
-
-/***************************************************************
- *
- * PosNomogPos
- *
- *******************************************************************/
-#define p_MemCmp_LengthThree_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)             \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
-                           _p_MemCmp_LengthOne_Equal(1, _s2, _s1,                               \
-                                           _p_MemCmp_LengthOne_Equal(2, _s1, _s2, actionE)),    \
-                           actionG, actionS)
-#define p_MemCmp_LengthFour_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
-                           _p_MemCmp_LengthTwo_Equal(1, _s2, _s1,                  \
-                                           _p_MemCmp_Equal(3, _s1, _s2, actionE)),  \
-                           actionG, actionS)
-#define p_MemCmp_LengthFive_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
-                           _p_MemCmp_LengthThree_Equal(1, _s2, _s1,                 \
-                                           _p_MemCmp_Equal(4, _s1, _s2, actionE)),  \
-                           actionG, actionS)
-#define p_MemCmp_LengthSix_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
-                           _p_MemCmp_LengthFour_Equal(1, _s2, _s1,                  \
-                                           _p_MemCmp_Equal(5, _s1, _s2, actionE)),  \
-                           actionG, actionS)
-#define p_MemCmp_LengthSeven_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
-                           _p_MemCmp_LengthFive_Equal(1, _s2, _s1,                  \
-                                           _p_MemCmp_Equal(6, _s1, _s2, actionE)),  \
-                           actionG, actionS)
-#define p_MemCmp_LengthEight_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
-                           _p_MemCmp_LengthSix_Equal(1, _s2, _s1,                   \
-                                           _p_MemCmp_Equal(7, _s1, _s2, actionE)),  \
-                           actionG, actionS)
-#define p_MemCmp_LengthGeneral_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)       \
-  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                  \
-                           _p_MemCmp_LengthGeneral_Equal(1, _s2, _s1, (length - 2),         \
-                                                   _p_MemCmp_Equal(_i, _s1, _s2, actionE)), \
-                           actionG, actionS)
-
-
-/***************************************************************
- *
- *  PosPosNomogZero
- *
- *******************************************************************/
-#define p_MemCmp_LengthFour_OrdPosPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthThree_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFive_OrdPosPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthFour_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSix_OrdPosPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthFive_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSeven_OrdPosPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSix_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthEight_OrdPosPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSeven_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthGeneral_OrdPosPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthGeneral_OrdPosPosNomog(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
-
-/***************************************************************
- *
- *  PosNomogPosZero
- *
- *******************************************************************/
-#define p_MemCmp_LengthFour_OrdPosNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthThree_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFive_OrdPosNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthFour_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSix_OrdPosNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthFive_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSeven_OrdPosNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSix_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthEight_OrdPosNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSeven_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthGeneral_OrdPosNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthGeneral_OrdPosNomogPos(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
-
-/***************************************************************
- *
- *  NegPosNomogZero
- *
- *******************************************************************/
-#define p_MemCmp_LengthFour_OrdNegPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthThree_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthFive_OrdNegPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-  p_MemCmp_LengthFour_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSix_OrdNegPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
-  p_MemCmp_LengthFive_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthSeven_OrdNegPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSix_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthEight_OrdNegPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-  p_MemCmp_LengthSeven_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
-#define p_MemCmp_LengthGeneral_OrdNegPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
-  p_MemCmp_LengthGeneral_OrdNegPosNomog(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
-
-
-/***************************************************************
- *
- *  OrdGeneral
- *
- *******************************************************************/
-#define _p_MemCmp_OrdGeneral_Declare(s1, s2)    \
-  const unsigned long* _s1 = ((unsigned long*) s1);     \
-  const unsigned long* _s2 = ((unsigned long*) s2);     \
-  register unsigned long _v1;                           \
-  register unsigned long _v2;                           \
-  register unsigned long _i
-
-#define _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS) \
-do                                                              \
-{                                                               \
-  const long* _ordsgn = (long*) ordsgn;                        \
-  if (_v1 > _v2)                                                \
-  {                                                             \
-    if (_ordsgn[_i] == 1) actionG;                              \
-    actionS;                                                    \
-  }                                                             \
-  if (_ordsgn[_i] == 1) actionS;                                \
-  actionG;                                                      \
-}                                                               \
-while (0)
-
-#define _p_MemCmp_OrdGeneral(i, actionE)         \
-do                                              \
-{                                               \
-  _i = i;                                       \
-  _v1 = _s1[i];                                 \
-  _v2 = _s2[i];                                 \
-  if (_v1 == _v2) actionE;                      \
-}                                               \
-while(0)
-
-#define _p_MemCmp_LengthTwo_OrdGeneral(actionE)          \
-  _p_MemCmp_OrdGeneral(0, _p_MemCmp_OrdGeneral(1, actionE))
-
-#define _p_MemCmp_LengthThree_OrdGeneral(actionE)          \
-  _p_MemCmp_LengthTwo_OrdGeneral(_p_MemCmp_OrdGeneral(2, actionE))
-
-#define _p_MemCmp_LengthFour_OrdGeneral(actionE)          \
-  _p_MemCmp_LengthThree_OrdGeneral(_p_MemCmp_OrdGeneral(3, actionE))
-
-#define _p_MemCmp_LengthFive_OrdGeneral(actionE)          \
-  _p_MemCmp_LengthFour_OrdGeneral(_p_MemCmp_OrdGeneral(4, actionE))
-
-#define _p_MemCmp_LengthSix_OrdGeneral(actionE)          \
-  _p_MemCmp_LengthFive_OrdGeneral(_p_MemCmp_OrdGeneral(5, actionE))
-
-#define _p_MemCmp_LengthSeven_OrdGeneral(actionE)          \
-  _p_MemCmp_LengthSix_OrdGeneral(_p_MemCmp_OrdGeneral(6, actionE))
-
-#define _p_MemCmp_LengthEight_OrdGeneral(actionE)          \
-  _p_MemCmp_LengthSeven_OrdGeneral(_p_MemCmp_OrdGeneral(7, actionE))
-
-#define p_MemCmp_LengthOne_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-do                                                                                          \
-{                                                                                           \
-  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
-  _p_MemCmp_OrdGeneral(0, actionE);                                                         \
-  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
-}                                                                                           \
-while (0)
-
-#define p_MemCmp_LengthTwo_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-do                                                                                          \
-{                                                                                           \
-  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
-  _p_MemCmp_LengthTwo_OrdGeneral(actionE);                                               \
-  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
-}                                                                                           \
-while (0)
-
-#define p_MemCmp_LengthThree_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-do                                                                                          \
-{                                                                                           \
-  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
-  _p_MemCmp_LengthThree_OrdGeneral(actionE);                                             \
-  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
-}                                                                                           \
-while (0)
-
-#define p_MemCmp_LengthFour_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-do                                                                                          \
-{                                                                                           \
-  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
-  _p_MemCmp_LengthFour_OrdGeneral(actionE);                                              \
-  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
-}                                                                                           \
-while (0)
-
-#define p_MemCmp_LengthFive_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-do                                                                                          \
-{                                                                                           \
-  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
-  _p_MemCmp_LengthFive_OrdGeneral(actionE);                                              \
-  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
-}                                                                                           \
-while (0)
-
-#define p_MemCmp_LengthSix_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-do                                                                                          \
-{                                                                                           \
-  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
-  _p_MemCmp_LengthSix_OrdGeneral(actionE);                                               \
-  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
-}                                                                                           \
-while (0)
-
-#define p_MemCmp_LengthSeven_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-do                                                                                          \
-{                                                                                           \
-  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
-  _p_MemCmp_LengthSeven_OrdGeneral(actionE);                                             \
-  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
-}                                                                                           \
-while (0)
-
-#define p_MemCmp_LengthEight_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
-do                                                                                          \
-{                                                                                           \
-  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
-  _p_MemCmp_LengthEight_OrdGeneral(actionE);                                                \
-  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
-}                                                                                           \
-while (0)
-
-/***************************************************************
- *
- *  Last but not least LengthGeneral_OrdGeneral
- *
- *******************************************************************/
-#define p_MemCmp_LengthGeneral_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
-do                                                                                              \
-{                                                                                               \
-  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                         \
-  const unsigned long _l = (unsigned long) length;                                              \
-                                                                                                \
-  _i=0;                                                                                         \
-                                                                                                \
-  LengthGeneral_OrdGeneral_LoopTop:                                                             \
-  _v1 = _s1[_i];                                                                                \
-  _v2 = _s2[_i];                                                                                \
-  if (_v1 == _v2)                                                                               \
-  {                                                                                             \
-    _i++;                                                                                       \
-    if (_i == _l) actionE;                                                                      \
-    goto LengthGeneral_OrdGeneral_LoopTop;                                                      \
-  }                                                                                             \
-                                                                                                \
-  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                      \
-}                                                                                               \
-while (0)
-
-// or, in other (less efficient) words
-#define p_MemCmp_LengthGeneral_OrdGeneral2(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
-do                                                                                              \
-{                                                                                               \
-  int _i;                                                                                       \
-                                                                                                \
-  for (_i=0; _i<length;_i++)                                                                    \
-  {                                                                                             \
-    if (s1[_i] != s2[_i])                                                                       \
-    {                                                                                           \
-      if (s1[_i] > s2[_i])                                                                      \
-      {                                                                                         \
-        if (ordsgn[_i] == 1)                                                                    \
-          actionG;                                                                              \
-        actionS;                                                                                \
-      }                                                                                         \
-      if (ordsgn[_i] == 1)                                                                      \
-        actionS;                                                                                \
-      actionG;                                                                                  \
-    }                                                                                           \
-  }                                                                                             \
-  actionE;                                                                                      \
-}                                                                                               \
-while (0)
-
-/***************************************************************
- *
- *  Bitmask
- *
- *******************************************************************/
-#define _p_MemCmp_Bitmask_Declare(s1, s2, bitmask)  \
-  const unsigned long* _s1 = ((unsigned long*) s1); \
-  const unsigned long* _s2 = ((unsigned long*) s2); \
-  register const unsigned long _bitmask = bitmask;  \
-  register unsigned long _v1;                       \
-  register unsigned long _v2;                       \
-  register unsigned long _i                         \
-
-
-#define p_MemCmp_Bitmask_LengthGeneral(s1, s2, bitmask, length, actionG, actionS)   \
-do                                                                                  \
-{                                                                                   \
-  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                             \
-  const unsigned long _l = (unsigned long) length;                                  \
-                                                                                    \
-  _i=0;                                                                             \
-                                                                                    \
-  while (_i < _l)                                                                   \
-  {                                                                                 \
-    _v1 = _s1[_i];                                                                  \
-    _v2 = _s2[_i];                                                                  \
-                                                                                    \
-    if ((_v1 > _v2) ||                                                              \
-        (((_v1 & _bitmask) ^ (_v2 & _bitmask)) != ((_v2 - _v1) & _bitmask)))           \
-      actionS;                                                                      \
-    _i++;                                                                           \
-  }                                                                                 \
-  actionG;                                                                          \
-}                                                                                   \
-while (0)
-
-
-#define _p_MemCmp_Bitmask(i, actionS)                                       \
-do                                                                          \
-{                                                                           \
-  _i = i;                                                                   \
-  _v1 = _s1[i];                                                             \
-  _v2 = _s2[i];                                                             \
-  if ((_v1 > _v2) ||                                                        \
-      (((_v1 & _bitmask) ^ (_v2 & _bitmask)) != ((_v2 - _v1) & _bitmask)))     \
-    actionS;                                                               \
-}                                                                           \
-while (0)
-
-#define _p_MemCmp_Bitmask_LengthTwo(actionS)    \
-  do                                            \
-{                                               \
-  _p_MemCmp_Bitmask(0, actionS);                \
-  _p_MemCmp_Bitmask(1, actionS);                \
-}                                               \
-while (0)
-
-#define _p_MemCmp_Bitmask_LengthThree(actionS)  \
-  do                                            \
-{                                               \
-  _p_MemCmp_Bitmask_LengthTwo(actionS);         \
-  _p_MemCmp_Bitmask(2, actionS);                \
-}                                               \
-while (0)
-
-#define _p_MemCmp_Bitmask_LengthFour(actionS)   \
-  do                                            \
-{                                               \
-  _p_MemCmp_Bitmask_LengthThree(actionS);    \
-  _p_MemCmp_Bitmask(3, actionS);                \
-}                                               \
-while (0)
-
-
-#define _p_MemCmp_Bitmask_LengthFive(actionS)   \
-  do                                            \
-{                                               \
-  _p_MemCmp_Bitmask_LengthFour(actionS);     \
-  _p_MemCmp_Bitmask(4, actionS);                \
-}                                               \
-while (0)
-
-
-#define _p_MemCmp_Bitmask_LengthSix(actionS)    \
-  do                                            \
-{                                               \
-  _p_MemCmp_Bitmask_LengthFive(actionS);     \
-  _p_MemCmp_Bitmask(5, actionS);                \
-}                                               \
-while (0)
-
-#define _p_MemCmp_Bitmask_LengthSeven(actionS)  \
-  do                                            \
-{                                               \
-  _p_MemCmp_Bitmask_LengthSix(actionS);      \
-  _p_MemCmp_Bitmask(6, actionS);                \
-}                                               \
-while (0)
-
-#define _p_MemCmp_Bitmask_LengthEight(actionS)  \
-do                                              \
-{                                               \
-  _p_MemCmp_Bitmask_LengthSeven(actionS);    \
-  _p_MemCmp_Bitmask(7, actionS);                \
-}                                               \
-while (0)
-
-#define p_MemCmp_Bitmask_LengthZero(s1, s2, bitmask, length, actionG, actionS) actionG
-
-#define p_MemCmp_Bitmask_LengthOne(s1, s2, bitmask, length, actionG, actionS)   \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
-  _p_MemCmp_Bitmask(0, actionS);                                                \
-  actionG;                                                                      \
-}                                                                               \
-while (0)
-
-#define p_MemCmp_Bitmask_LengthTwo(s1, s2, bitmask, length, actionG, actionS)   \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
-  _p_MemCmp_Bitmask_LengthTwo(actionS);                                         \
-  actionG;                                                                      \
-}                                                                               \
-while (0)
-
-#define p_MemCmp_Bitmask_LengthThree(s1, s2, bitmask, length, actionG, actionS)   \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
-  _p_MemCmp_Bitmask_LengthThree(actionS);                                         \
-  actionG;                                                                      \
-}                                                                               \
-while (0)
-
-#define p_MemCmp_Bitmask_LengthFour(s1, s2, bitmask, length, actionG, actionS)   \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
-  _p_MemCmp_Bitmask_LengthFour(actionS);                                         \
-  actionG;                                                                      \
-}                                                                               \
-while (0)
-
-#define p_MemCmp_Bitmask_LengthFive(s1, s2, bitmask, length, actionG, actionS)   \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
-  _p_MemCmp_Bitmask_LengthFive(actionS);                                         \
-  actionG;                                                                      \
-}                                                                               \
-while (0)
-
-#define p_MemCmp_Bitmask_LengthSix(s1, s2, bitmask, length, actionG, actionS)   \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
-  _p_MemCmp_Bitmask_LengthSix(actionS);                                         \
-  actionG;                                                                      \
-}                                                                               \
-while (0)
-
-#define p_MemCmp_Bitmask_LengthSeven(s1, s2, bitmask, length, actionG, actionS) \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
-  _p_MemCmp_Bitmask_LengthSeven(actionS);                                       \
-  actionG;                                                                      \
-}                                                                               \
-while (0)
-
-#define p_MemCmp_Bitmask_LengthEigth(s1, s2, bitmask, length, actionG, actionS) \
-do                                                                              \
-{                                                                               \
-  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
-  _p_MemCmp_Bitmask_LengthEigth(actionS);                                       \
-  actionG;                                                                      \
-}                                                                               \
-while (0)
-
-
-#endif // P_MEM_CMP
Index: lys/monomials/p_MemCopy.h
===================================================================
--- polys/monomials/p_MemCopy.h	(revision 0087338a44e796a7d0c0ffe1127d1e9f428a0c7b)
+++ 	(revision )
@@ -1,96 +1,0 @@
-/****************************************
-*  Computer Algebra System SINGULAR     *
-****************************************/
-/***************************************************************
- *  File:    p_MemCopy.h
- *  Purpose: macros for memory addition
- *  Author:  obachman (Olaf Bachmann)
- *  Created: 8/00
- *  Version: $Id$
- *******************************************************************/
-#ifndef P_MEM_COPY_H
-#define P_MEM_COPY_H
-
-#define _p_MemCopy(i, d, s) d[i] = s[i]
-
-#define _p_MemCopy_LengthOne(d, s) _p_MemCopy(0, d, s)
-#define _p_MemCopy_LengthTwo(d, s) do{_p_MemCopy_LengthOne(d, s); _p_MemCopy(1, d, s);} while(0)
-#define _p_MemCopy_LengthThree(d, s) do{_p_MemCopy_LengthTwo(d, s); _p_MemCopy(2, d, s);} while(0)
-#define _p_MemCopy_LengthFour(d, s) do{_p_MemCopy_LengthThree(d, s); _p_MemCopy(3, d, s);} while(0)
-#define _p_MemCopy_LengthFive(d, s) do{_p_MemCopy_LengthFour(d, s); _p_MemCopy(4, d, s);} while(0)
-#define _p_MemCopy_LengthSix(d, s) do{_p_MemCopy_LengthFive(d, s); _p_MemCopy(5, d, s);} while(0)
-#define _p_MemCopy_LengthSeven(d, s) do{_p_MemCopy_LengthSix(d, s); _p_MemCopy(6, d, s);} while(0)
-#define _p_MemCopy_LengthEight(d, s) do{_p_MemCopy_LengthSeven(d, s); _p_MemCopy(7, d, s);} while(0)
-
-#define _p_MemCopy_Declare(d, s)                \
-  unsigned long* _d = ((unsigned long*) d); \
-  const unsigned long* _s = ((unsigned long*) s)
-
-#define p_MemCopy_LengthOne(d, s, length) _p_MemCopy_LengthOne(d, s)
-#define p_MemCopy_LengthTwo(d, s, length)   \
-do                                              \
-{                                               \
-  _p_MemCopy_Declare(d,s);                    \
-  _p_MemCopy_LengthTwo(_d, _s);            \
-}                                               \
-while (0)
-#define p_MemCopy_LengthThree(d, s, length) \
-do                                              \
-{                                               \
-  _p_MemCopy_Declare(d,s);                    \
-  _p_MemCopy_LengthThree(_d, _s);          \
-}                                               \
-while (0)
-#define p_MemCopy_LengthFour(d, s, length)  \
-do                                              \
-{                                               \
-  _p_MemCopy_Declare(d,s);                    \
-  _p_MemCopy_LengthFour(_d, _s);           \
-}                                               \
-while (0)
-#define p_MemCopy_LengthFive(d, s, length)  \
-do                                              \
-{                                               \
-  _p_MemCopy_Declare(d,s);                    \
-  _p_MemCopy_LengthFive(_d, _s);           \
-}                                               \
-while (0)
-#define p_MemCopy_LengthSix(d, s, length)   \
-do                                              \
-{                                               \
-  _p_MemCopy_Declare(d,s);                    \
-  _p_MemCopy_LengthSix(_d, _s);            \
-}                                               \
-while (0)
-#define p_MemCopy_LengthSeven(d, s, length) \
-do                                              \
-{                                               \
-  _p_MemCopy_Declare(d,s);                    \
-  _p_MemCopy_LengthSeven(_d, _s);          \
-}                                               \
-while (0)
-#define p_MemCopy_LengthEight(d, s, length) \
-do                                              \
-{                                               \
-  _p_MemCopy_Declare(d,s);                    \
-  _p_MemCopy_LengthEight(_d, _s);          \
-}                                               \
-while (0)
-
-#define p_MemCopy_LengthGeneral(d, s, length)   \
-do                                              \
-{                                               \
-  _p_MemCopy_Declare(d,s);                      \
-  const unsigned long _l = (unsigned long) length;   \
-  unsigned long _i = 0;                         \
-                                                \
-  do                                            \
-  {                                             \
-    _d[_i] = _s[_i];                            \
-    _i++;                                       \
-  }                                             \
-  while (_i != _l);                             \
-}                                               \
-while (0)
-
-#endif // P_MEM_COPY_H
Index: polys/templates/p_MemAdd.h
===================================================================
--- polys/templates/p_MemAdd.h	(revision 4cfe968e9f2c139f34f69fccb257823023c3890e)
+++ polys/templates/p_MemAdd.h	(revision 4cfe968e9f2c139f34f69fccb257823023c3890e)
@@ -0,0 +1,389 @@
+/****************************************
+*  Computer Algebra System SINGULAR     *
+****************************************/
+/***************************************************************
+ *  File:    p_MemAdd.h
+ *  Purpose: macros for memory addition
+ *  Author:  obachman (Olaf Bachmann)
+ *  Created: 8/00
+ *  Version: $Id$
+ *******************************************************************/
+#ifndef P_MEM_ADD_H
+#define P_MEM_ADD_H
+
+/***************************************************************
+ *
+ * MemSum
+ *
+ ***************************************************************/
+
+#define _p_MemSum(i, r, s1, s2) r[i] = s1[i] + s2[i]
+
+#define _p_MemSum_LengthOne(r, s1, s2) _p_MemSum(0, r, s1, s2)
+#define _p_MemSum_LengthTwo(r, s1, s2) do{_p_MemSum_LengthOne(r, s1, s2); _p_MemSum(1, r, s1, s2);} while(0)
+#define _p_MemSum_LengthThree(r, s1, s2) do{_p_MemSum_LengthTwo(r, s1, s2); _p_MemSum(2, r, s1, s2);} while(0)
+#define _p_MemSum_LengthFour(r, s1, s2) do{_p_MemSum_LengthThree(r, s1, s2); _p_MemSum(3, r, s1, s2);} while(0)
+#define _p_MemSum_LengthFive(r, s1, s2) do{_p_MemSum_LengthFour(r, s1, s2); _p_MemSum(4, r, s1, s2);} while(0)
+#define _p_MemSum_LengthSix(r, s1, s2) do{_p_MemSum_LengthFive(r, s1, s2); _p_MemSum(5, r, s1, s2);} while(0)
+#define _p_MemSum_LengthSeven(r, s1, s2) do{_p_MemSum_LengthSix(r, s1, s2); _p_MemSum(6, r, s1, s2);} while(0)
+#define _p_MemSum_LengthEight(r, s1, s2) do{_p_MemSum_LengthSeven(r, s1, s2); _p_MemSum(7, r, s1, s2);} while(0)
+
+#define _p_MemSum_Declare(r, s1, s2)                \
+  const unsigned long* _s1 = ((unsigned long*) s1); \
+  const unsigned long* _s2 = ((unsigned long*) s2); \
+  unsigned long* _r = ((unsigned long*) r)
+
+#define p_MemSum_LengthOne(r, s1, s2, length) _p_MemSum_LengthOne(r, s1, s2)
+#define p_MemSum_LengthTwo(r, s1, s2, length)   \
+do                                              \
+{                                               \
+  _p_MemSum_Declare(r,s1,s2);                    \
+  _p_MemSum_LengthTwo(_r, _s1, _s2);            \
+}                                               \
+while (0)
+#define p_MemSum_LengthThree(r, s1, s2, length) \
+do                                              \
+{                                               \
+  _p_MemSum_Declare(r,s1,s2);                    \
+  _p_MemSum_LengthThree(_r, _s1, _s2);          \
+}                                               \
+while (0)
+#define p_MemSum_LengthFour(r, s1, s2, length)  \
+do                                              \
+{                                               \
+  _p_MemSum_Declare(r,s1,s2);                    \
+  _p_MemSum_LengthFour(_r, _s1, _s2);           \
+}                                               \
+while (0)
+#define p_MemSum_LengthFive(r, s1, s2, length)  \
+do                                              \
+{                                               \
+  _p_MemSum_Declare(r,s1,s2);                    \
+  _p_MemSum_LengthFive(_r, _s1, _s2);           \
+}                                               \
+while (0)
+#define p_MemSum_LengthSix(r, s1, s2, length)   \
+do                                              \
+{                                               \
+  _p_MemSum_Declare(r,s1,s2);                    \
+  _p_MemSum_LengthSix(_r, _s1, _s2);            \
+}                                               \
+while (0)
+#define p_MemSum_LengthSeven(r, s1, s2, length) \
+do                                              \
+{                                               \
+  _p_MemSum_Declare(r,s1,s2);                    \
+  _p_MemSum_LengthSeven(_r, _s1, _s2);          \
+}                                               \
+while (0)
+#define p_MemSum_LengthEight(r, s1, s2, length) \
+do                                              \
+{                                               \
+  _p_MemSum_Declare(r,s1,s2);                    \
+  _p_MemSum_LengthEight(_r, _s1, _s2);          \
+}                                               \
+while (0)
+
+#define p_MemSum_LengthGeneral(r, s1, s2, length)   \
+do                                                  \
+{                                                   \
+  _p_MemSum_Declare(r,s1,s2);                       \
+  const unsigned long _l = (unsigned long) length;       \
+  unsigned long _i = 0;                             \
+                                                    \
+  do                                                \
+  {                                                 \
+    _r[_i] = _s1[_i] + _s2[_i];                     \
+    _i++;                                           \
+  }                                                 \
+  while (_i != _l);                                 \
+}                                                   \
+while (0)
+
+/***************************************************************
+ *
+ * MemAdd
+ *
+ ***************************************************************/
+#define _p_MemAdd(i, r, s) r[i] += s[i]
+
+#define _p_MemAdd_LengthOne(r, s) _p_MemAdd(0, r, s)
+#define _p_MemAdd_LengthTwo(r, s) do{_p_MemAdd_LengthOne(r, s); _p_MemAdd(1, r, s);} while(0)
+#define _p_MemAdd_LengthThree(r, s) do{_p_MemAdd_LengthTwo(r, s); _p_MemAdd(2, r, s);} while(0)
+#define _p_MemAdd_LengthFour(r, s) do{_p_MemAdd_LengthThree(r, s); _p_MemAdd(3, r, s);} while(0)
+#define _p_MemAdd_LengthFive(r, s) do{_p_MemAdd_LengthFour(r, s); _p_MemAdd(4, r, s);} while(0)
+#define _p_MemAdd_LengthSix(r, s) do{_p_MemAdd_LengthFive(r, s); _p_MemAdd(5, r, s);} while(0)
+#define _p_MemAdd_LengthSeven(r, s) do{_p_MemAdd_LengthSix(r, s); _p_MemAdd(6, r, s);} while(0)
+#define _p_MemAdd_LengthEight(r, s) do{_p_MemAdd_LengthSeven(r, s); _p_MemAdd(7, r, s);} while(0)
+
+#define _p_MemAdd_Declare(r, s)                \
+  const unsigned long* _s = ((unsigned long*) s); \
+  unsigned long* _r = ((unsigned long*) r)
+
+#define p_MemAdd_LengthOne(r, s, length) _p_MemAdd_LengthOne(r, s)
+#define p_MemAdd_LengthTwo(r, s, length)   \
+do                                              \
+{                                               \
+  _p_MemAdd_Declare(r,s);                    \
+  _p_MemAdd_LengthTwo(_r, _s);            \
+}                                               \
+while (0)
+#define p_MemAdd_LengthThree(r, s, length) \
+do                                              \
+{                                               \
+  _p_MemAdd_Declare(r,s);                    \
+  _p_MemAdd_LengthThree(_r, _s);          \
+}                                               \
+while (0)
+#define p_MemAdd_LengthFour(r, s, length)  \
+do                                              \
+{                                               \
+  _p_MemAdd_Declare(r,s);                    \
+  _p_MemAdd_LengthFour(_r, _s);           \
+}                                               \
+while (0)
+#define p_MemAdd_LengthFive(r, s, length)  \
+do                                              \
+{                                               \
+  _p_MemAdd_Declare(r,s);                    \
+  _p_MemAdd_LengthFive(_r, _s);           \
+}                                               \
+while (0)
+#define p_MemAdd_LengthSix(r, s, length)   \
+do                                              \
+{                                               \
+  _p_MemAdd_Declare(r,s);                    \
+  _p_MemAdd_LengthSix(_r, _s);            \
+}                                               \
+while (0)
+#define p_MemAdd_LengthSeven(r, s, length) \
+do                                              \
+{                                               \
+  _p_MemAdd_Declare(r,s);                    \
+  _p_MemAdd_LengthSeven(_r, _s);          \
+}                                               \
+while (0)
+#define p_MemAdd_LengthEight(r, s, length) \
+do                                              \
+{                                               \
+  _p_MemAdd_Declare(r,s);                    \
+  _p_MemAdd_LengthEight(_r, _s);          \
+}                                               \
+while (0)
+
+#define p_MemAdd_LengthGeneral(r, s, length)       \
+do                                                  \
+{                                                   \
+  _p_MemAdd_Declare(r,s);                          \
+  const unsigned long _l = (unsigned long) length;  \
+  unsigned long _i = 0;                             \
+                                                    \
+  do                                                \
+  {                                                 \
+    _r[_i] += _s[_i];                               \
+    _i++;                                           \
+  }                                                 \
+  while (_i != _l);                                 \
+}                                                   \
+while (0)
+
+
+/***************************************************************
+ *
+ * MemDiff
+ *
+ ***************************************************************/
+#define _p_MemDiff(i, r, s1, s2) r[i] = s1[i] - s2[i]
+
+#define _p_MemDiff_LengthOne(r, s1, s2) _p_MemDiff(0, r, s1, s2)
+#define _p_MemDiff_LengthTwo(r, s1, s2) do{_p_MemDiff_LengthOne(r, s1, s2); _p_MemDiff(1, r, s1, s2);} while(0)
+#define _p_MemDiff_LengthThree(r, s1, s2) do{_p_MemDiff_LengthTwo(r, s1, s2); _p_MemDiff(2, r, s1, s2);} while(0)
+#define _p_MemDiff_LengthFour(r, s1, s2) do{_p_MemDiff_LengthThree(r, s1, s2); _p_MemDiff(3, r, s1, s2);} while(0)
+#define _p_MemDiff_LengthFive(r, s1, s2) do{_p_MemDiff_LengthFour(r, s1, s2); _p_MemDiff(4, r, s1, s2);} while(0)
+#define _p_MemDiff_LengthSix(r, s1, s2) do{_p_MemDiff_LengthFive(r, s1, s2); _p_MemDiff(5, r, s1, s2);} while(0)
+#define _p_MemDiff_LengthSeven(r, s1, s2) do{_p_MemDiff_LengthSix(r, s1, s2); _p_MemDiff(6, r, s1, s2);} while(0)
+#define _p_MemDiff_LengthEight(r, s1, s2) do{_p_MemDiff_LengthSeven(r, s1, s2); _p_MemDiff(7, r, s1, s2);} while(0)
+
+#define _p_MemDiff_Declare(r, s1, s2)                \
+  const unsigned long* _s1 = ((unsigned long*) s1); \
+  const unsigned long* _s2 = ((unsigned long*) s2); \
+  unsigned long* _r = ((unsigned long*) r)
+
+#define p_MemDiff_LengthOne(r, s1, s2, length) _p_MemDiff_LengthOne(r, s1, s2)
+#define p_MemDiff_LengthTwo(r, s1, s2, length)   \
+do                                              \
+{                                               \
+  _p_MemDiff_Declare(r,s1,s2);                    \
+  _p_MemDiff_LengthTwo(_r, _s1, _s2);            \
+}                                               \
+while (0)
+#define p_MemDiff_LengthThree(r, s1, s2, length) \
+do                                              \
+{                                               \
+  _p_MemDiff_Declare(r,s1,s2);                    \
+  _p_MemDiff_LengthThree(_r, _s1, _s2);          \
+}                                               \
+while (0)
+#define p_MemDiff_LengthFour(r, s1, s2, length)  \
+do                                              \
+{                                               \
+  _p_MemDiff_Declare(r,s1,s2);                    \
+  _p_MemDiff_LengthFour(_r, _s1, _s2);           \
+}                                               \
+while (0)
+#define p_MemDiff_LengthFive(r, s1, s2, length)  \
+do                                              \
+{                                               \
+  _p_MemDiff_Declare(r,s1,s2);                    \
+  _p_MemDiff_LengthFive(_r, _s1, _s2);           \
+}                                               \
+while (0)
+#define p_MemDiff_LengthSix(r, s1, s2, length)   \
+do                                              \
+{                                               \
+  _p_MemDiff_Declare(r,s1,s2);                    \
+  _p_MemDiff_LengthSix(_r, _s1, _s2);            \
+}                                               \
+while (0)
+#define p_MemDiff_LengthSeven(r, s1, s2, length) \
+do                                              \
+{                                               \
+  _p_MemDiff_Declare(r,s1,s2);                    \
+  _p_MemDiff_LengthSeven(_r, _s1, _s2);          \
+}                                               \
+while (0)
+#define p_MemDiff_LengthEight(r, s1, s2, length) \
+do                                              \
+{                                               \
+  _p_MemDiff_Declare(r,s1,s2);                    \
+  _p_MemDiff_LengthEight(_r, _s1, _s2);          \
+}                                               \
+while (0)
+
+#define p_MemDiff_LengthGeneral(r, s1, s2, length)   \
+do                                                  \
+{                                                   \
+  _p_MemDiff_Declare(r,s1,s2);                       \
+  const unsigned long _l = (unsigned long) length;       \
+  unsigned long _i = 0;                             \
+                                                    \
+  do                                                \
+  {                                                 \
+    _r[_i] = _s1[_i] - _s2[_i];                     \
+    _i++;                                           \
+  }                                                 \
+  while (_i != _l);                                 \
+}                                                   \
+while (0)
+
+
+/***************************************************************
+ *
+ * MemSub
+ *
+ ***************************************************************/
+
+#define _p_MemSub(i, r, s) r[i] -= s[i]
+
+#define _p_MemSub_LengthOne(r, s) _p_MemSub(0, r, s)
+#define _p_MemSub_LengthTwo(r, s) do{_p_MemSub_LengthOne(r, s); _p_MemSub(1, r, s);} while(0)
+#define _p_MemSub_LengthThree(r, s) do{_p_MemSub_LengthTwo(r, s); _p_MemSub(2, r, s);} while(0)
+#define _p_MemSub_LengthFour(r, s) do{_p_MemSub_LengthThree(r, s); _p_MemSub(3, r, s);} while(0)
+#define _p_MemSub_LengthFive(r, s) do{_p_MemSub_LengthFour(r, s); _p_MemSub(4, r, s);} while(0)
+#define _p_MemSub_LengthSix(r, s) do{_p_MemSub_LengthFive(r, s); _p_MemSub(5, r, s);} while(0)
+#define _p_MemSub_LengthSeven(r, s) do{_p_MemSub_LengthSix(r, s); _p_MemSub(6, r, s);} while(0)
+#define _p_MemSub_LengthEight(r, s) do{_p_MemSub_LengthSeven(r, s); _p_MemSub(7, r, s);} while(0)
+
+#define _p_MemSub_Declare(r, s)                \
+  const unsigned long* _s = ((unsigned long*) s); \
+  unsigned long* _r = ((unsigned long*) r)
+
+#define p_MemSub_LengthOne(r, s, length) _p_MemSub_LengthOne(r, s)
+#define p_MemSub_LengthTwo(r, s, length)   \
+do                                              \
+{                                               \
+  _p_MemSub_Declare(r,s);                    \
+  _p_MemSub_LengthTwo(_r, _s);            \
+}                                               \
+while (0)
+#define p_MemSub_LengthThree(r, s, length) \
+do                                              \
+{                                               \
+  _p_MemSub_Declare(r,s);                    \
+  _p_MemSub_LengthThree(_r, _s);          \
+}                                               \
+while (0)
+#define p_MemSub_LengthFour(r, s, length)  \
+do                                              \
+{                                               \
+  _p_MemSub_Declare(r,s);                    \
+  _p_MemSub_LengthFour(_r, _s);           \
+}                                               \
+while (0)
+#define p_MemSub_LengthFive(r, s, length)  \
+do                                              \
+{                                               \
+  _p_MemSub_Declare(r,s);                    \
+  _p_MemSub_LengthFive(_r, _s);           \
+}                                               \
+while (0)
+#define p_MemSub_LengthSix(r, s, length)   \
+do                                              \
+{                                               \
+  _p_MemSub_Declare(r,s);                    \
+  _p_MemSub_LengthSix(_r, _s);            \
+}                                               \
+while (0)
+#define p_MemSub_LengthSeven(r, s, length) \
+do                                              \
+{                                               \
+  _p_MemSub_Declare(r,s);                    \
+  _p_MemSub_LengthSeven(_r, _s);          \
+}                                               \
+while (0)
+#define p_MemSub_LengthEight(r, s, length) \
+do                                              \
+{                                               \
+  _p_MemSub_Declare(r,s);                    \
+  _p_MemSub_LengthEight(_r, _s);          \
+}                                               \
+while (0)
+
+#define p_MemSub_LengthGeneral(r, s, length)       \
+do                                                  \
+{                                                   \
+  _p_MemSub_Declare(r,s);                          \
+  const unsigned long _l = (unsigned long) length;  \
+  unsigned long _i = 0;                             \
+                                                    \
+  do                                                \
+  {                                                 \
+    _r[_i] -= _s[_i];                               \
+    _i++;                                           \
+  }                                                 \
+  while (_i != _l);                                 \
+}                                                   \
+while (0)
+
+#define _p_MemAddSub_Declare(r, s, t)                \
+  const unsigned long* _s = ((unsigned long*) s); \
+  const unsigned long* _t = ((unsigned long*) t); \
+  unsigned long* _r = ((unsigned long*) r)
+
+#define p_MemAddSub_LengthGeneral(r, s, t, length)  \
+do                                                  \
+{                                                   \
+  _p_MemAddSub_Declare(r,s, t);                     \
+  const unsigned long _l = (unsigned long) length;  \
+  unsigned long _i = 0;                             \
+                                                    \
+  do                                                \
+  {                                                 \
+    _r[_i] += _s[_i] - _t[_i];                      \
+    _i++;                                           \
+  }                                                 \
+  while (_i != _l);                                 \
+}                                                   \
+while (0)
+
+#endif /* P_MEM_ADD_H */
Index: polys/templates/p_MemCmp.h
===================================================================
--- polys/templates/p_MemCmp.h	(revision 4cfe968e9f2c139f34f69fccb257823023c3890e)
+++ polys/templates/p_MemCmp.h	(revision 4cfe968e9f2c139f34f69fccb257823023c3890e)
@@ -0,0 +1,949 @@
+/****************************************
+*  Computer Algebra System SINGULAR     *
+****************************************/
+/***************************************************************
+ *  File:    p_MemCmp.h
+ *  Purpose: macros for memory comparisons
+ *  Author:  obachman (Olaf Bachmann)
+ *  Created: 8/00
+ *  Version: $Id$
+ *******************************************************************/
+#ifndef P_MEM_CMP_H
+#define P_MEM_CMP_H
+
+/***************************************************************
+ *
+ *  auxiallary macros
+ *
+ *******************************************************************/
+#define _p_MemCmp_Declare(s1, s2)                   \
+  const unsigned long* _s1 = ((unsigned long*) s1); \
+  const unsigned long* _s2 = ((unsigned long*) s2); \
+  register unsigned long _v1;                       \
+  register unsigned long _v2
+
+#define _p_MemCmp_Equal(i, s1, s2, actionE) \
+  do {  _v1=((unsigned long*)s1)[i]; _v2=((unsigned long*)s2)[i]; if (_v1==_v2) actionE; }while (0)
+#define _p_MemCmp_NotEqual(actionG, actionS)   \
+  do {if (_v1 > _v2) actionG; actionS;} while (0)
+
+#define _p_MemCmp_LengthOne_Equal(i, s1, s2, actionE) \
+  _p_MemCmp_Equal(i, s1, s2, actionE)
+#define _p_MemCmp_LengthTwo_Equal(i, s1, s2, actionE) \
+  _p_MemCmp_Equal(i, s1, s2, _p_MemCmp_Equal(i+1, s1, s2, actionE))
+#define _p_MemCmp_LengthThree_Equal(i, s1, s2, actionE) \
+  _p_MemCmp_LengthTwo_Equal(i, s1, s2, _p_MemCmp_Equal(i+2, s1, s2, actionE))
+#define _p_MemCmp_LengthFour_Equal(i, s1, s2, actionE) \
+  _p_MemCmp_LengthThree_Equal(i, s1, s2, _p_MemCmp_Equal(i+3, s1, s2, actionE))
+#define _p_MemCmp_LengthFive_Equal(i, s1, s2, actionE) \
+  _p_MemCmp_LengthFour_Equal(i, s1, s2, _p_MemCmp_Equal(i+4, s1, s2, actionE))
+#define _p_MemCmp_LengthSix_Equal(i, s1, s2, actionE) \
+  _p_MemCmp_LengthFive_Equal(i, s1, s2, _p_MemCmp_Equal(i+5, s1, s2, actionE))
+#define _p_MemCmp_LengthSeven_Equal(i, s1, s2, actionE) \
+  _p_MemCmp_LengthSix_Equal(i, s1, s2, _p_MemCmp_Equal(i+6, s1, s2, actionE))
+#define _p_MemCmp_LengthEight_Equal(i, s1, s2, actionE) \
+  _p_MemCmp_LengthSeven_Equal(i, s1, s2, _p_MemCmp_Equal(i+7, s1, s2, actionE))
+#define _p_MemCmp_LengthGeneral_Equal(i, s1, s2, length, actionE)   \
+do                                                                  \
+{                                                                   \
+                                                                    \
+  register unsigned long _i = (unsigned long) i;                    \
+  const unsigned long _l =                                          \
+         (unsigned long) length + (unsigned long)i ;                \
+                                                                    \
+  LengthGeneral_LoopTop:                                            \
+    _v1 = s1[_i];                                                   \
+    _v2 = s2[_i];                                                   \
+    if (_v1 == _v2)                                                 \
+    {                                                               \
+      _i++;                                                         \
+      if (_i == _l) actionE;                                        \
+      else  goto LengthGeneral_LoopTop;                             \
+    }                                                               \
+}                                                                   \
+while (0)
+
+/***************************************************************
+ *
+ *  Pomog
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+do                                                                          \
+{                                                                           \
+  _p_MemCmp_Declare(s1,s2);                                                 \
+  _p_MemCmp_LengthOne_Equal(0, _s1, _s2, actionE);                          \
+  _p_MemCmp_NotEqual(actionG, actionS);                                     \
+}                                                                           \
+while (0)
+#define p_MemCmp_LengthTwo_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+do                                                                          \
+{                                                                           \
+  _p_MemCmp_Declare(s1,s2);                                                 \
+  _p_MemCmp_LengthTwo_Equal(0, _s1, _s2, actionE);                 \
+  _p_MemCmp_NotEqual(actionG, actionS);                                      \
+}                                                                           \
+while (0)
+#define p_MemCmp_LengthThree_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Declare(s1,s2);                                                     \
+  _p_MemCmp_LengthThree_Equal(0, _s1, _s2, actionE);                   \
+  _p_MemCmp_NotEqual(actionG, actionS);                                      \
+}                                                                               \
+while (0)
+#define p_MemCmp_LengthFour_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Declare(s1,s2);                                                     \
+  _p_MemCmp_LengthFour_Equal(0, _s1, _s2, actionE);                    \
+  _p_MemCmp_NotEqual(actionG, actionS);                                      \
+}                                                                               \
+while (0)
+#define p_MemCmp_LengthFive_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Declare(s1,s2);                                                     \
+  _p_MemCmp_LengthFive_Equal(0, _s1, _s2, actionE);                    \
+  _p_MemCmp_NotEqual(actionG, actionS);                                      \
+}                                                                               \
+while (0)
+#define p_MemCmp_LengthSix_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+do                                                                          \
+{                                                                           \
+  _p_MemCmp_Declare(s1,s2);                                                 \
+  _p_MemCmp_LengthSix_Equal(0, _s1, _s2, actionE);                 \
+  _p_MemCmp_NotEqual(actionG, actionS);                                      \
+}                                                                           \
+while (0)
+#define p_MemCmp_LengthSeven_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Declare(s1,s2);                                                     \
+  _p_MemCmp_LengthSeven_Equal(0, _s1, _s2, actionE);                   \
+  _p_MemCmp_NotEqual(actionG, actionS);;                                      \
+}                                                                               \
+while (0)
+
+#define p_MemCmp_LengthEight_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Declare(s1,s2);                                                     \
+  _p_MemCmp_LengthEight_Equal(0, _s1, _s2, actionE);                   \
+  _p_MemCmp_NotEqual(actionG, actionS);                                      \
+}                                                                               \
+while (0)
+#define p_MemCmp_LengthGeneral_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Declare(s1,s2);                                                     \
+  _p_MemCmp_LengthGeneral_Equal(0, _s1, _s2, length, actionE);      \
+  _p_MemCmp_NotEqual(actionG, actionS);                                          \
+}                                                                               \
+while (0)
+
+/***************************************************************
+ *
+ *  Nomog
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthOne_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthTwo_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthTwo_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthThree_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthThree_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthFour_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthFour_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthFive_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthFive_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthSix_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthSix_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthSeven_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSeven_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthEight_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthEight_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthGeneral_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthGeneral_OrdPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+
+/***************************************************************
+ *
+ *  PomogZero
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthTwo_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthThree_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthTwo_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFour_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthThree_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFive_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthFour_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSix_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthFive_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSeven_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSix_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthEight_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSeven_OrdPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthGeneral_OrdPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthGeneral_OrdPomog(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
+
+/***************************************************************
+ *
+ *  NomogZero
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthTwo_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthOne_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthThree_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthTwo_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFour_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthThree_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFive_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthFour_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSix_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthFive_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSeven_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSix_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthEight_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSeven_OrdNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthGeneral_OrdNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthGeneral_OrdNomog(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
+
+/***************************************************************
+ *
+ *  NegPomog
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthTwo_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                      \
+                           _p_MemCmp_LengthOne_Equal(1, _s2, _s1,actionE),      \
+                           actionS, actionG)
+#define p_MemCmp_LengthThree_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
+                           _p_MemCmp_LengthTwo_Equal(1, _s2, _s1, actionE),              \
+                           actionS, actionG)
+#define p_MemCmp_LengthFour_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                      \
+                           _p_MemCmp_LengthThree_Equal(1, _s2, _s1, actionE),        \
+                           actionS, actionG)
+#define p_MemCmp_LengthFive_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                      \
+                           _p_MemCmp_LengthFour_Equal(1, _s2, _s1, actionE),         \
+                           actionS, actionG)
+#define p_MemCmp_LengthSix_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                      \
+                           _p_MemCmp_LengthFive_Equal(1, _s2, _s1, actionE),         \
+                           actionS, actionG)
+#define p_MemCmp_LengthSeven_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
+                           _p_MemCmp_LengthSix_Equal(1, _s2, _s1, actionE),              \
+                           actionS, actionG)
+#define p_MemCmp_LengthEight_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
+                           _p_MemCmp_LengthSeven_Equal(1, _s2, _s1, actionE),            \
+                           actionS, actionG)
+#define p_MemCmp_LengthGeneral_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)      \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                              \
+                           _p_MemCmp_LengthGeneral_Equal(1, _s2, _s1, (length) -1, actionE), \
+                           actionS, actionG)
+
+/***************************************************************
+ *
+ *  PomogNeg
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthTwo_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                      \
+                           _p_MemCmp_Equal(1, _s2, _s1, actionE),               \
+                           actionG, actionS)
+#define p_MemCmp_LengthThree_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthTwo_OrdPomog(s1, s2, length, ordsgn,                                          \
+                           _p_MemCmp_Equal(2, _s2, _s1, actionE),                   \
+                           actionG, actionS)
+#define p_MemCmp_LengthFour_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthThree_OrdPomog(s1, s2, length, ordsgn,                                    \
+                           _p_MemCmp_Equal(3, _s2, _s1, actionE),              \
+                           actionG, actionS)
+#define p_MemCmp_LengthFive_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthFour_OrdPomog(s1, s2, length, ordsgn,                                     \
+                           _p_MemCmp_Equal(4, _s2, _s1, actionE),               \
+                           actionG, actionS)
+#define p_MemCmp_LengthSix_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+  p_MemCmp_LengthFive_OrdPomog(s1, s2, length, ordsgn,                                     \
+                           _p_MemCmp_Equal(5, _s2, _s1, actionE),               \
+                           actionG, actionS)
+#define p_MemCmp_LengthSeven_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthSix_OrdPomog(s1, s2, length, ordsgn,                                          \
+                           _p_MemCmp_Equal(6, _s2, _s1, actionE),                   \
+                           actionG, actionS)
+#define p_MemCmp_LengthEight_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthSeven_OrdPomog(s1, s2, length, ordsgn,                                        \
+                           _p_MemCmp_Equal(7, _s2, _s1, actionE),                   \
+                           actionG, actionS)
+#define p_MemCmp_LengthGeneral_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+  p_MemCmp_LengthGeneral_OrdPomog(s1, s2, (length-1), ordsgn,                                  \
+                           _p_MemCmp_Equal(_i, _s2, _s1, actionE),                  \
+                           actionG, actionS)
+
+/***************************************************************
+ *
+ *  PosNomog
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthThree_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthThree_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthFour_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthFour_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthFive_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthFive_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthSix_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+  p_MemCmp_LengthSix_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthSeven_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthSeven_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthEight_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthEight_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthGeneral_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+  p_MemCmp_LengthGeneral_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionS, actionG)
+
+/***************************************************************
+ *
+ *  NomogPos
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthThree_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthThree_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthFour_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthFour_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthFive_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthFive_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthSix_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+  p_MemCmp_LengthSix_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthSeven_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthSeven_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthEight_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthEight_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
+#define p_MemCmp_LengthGeneral_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+  p_MemCmp_LengthGeneral_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionS, actionG)
+
+
+/***************************************************************
+ *
+ *  PomogNegZero
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthThree_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthTwo_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFour_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthThree_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFive_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthFour_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSix_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthFive_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSeven_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSix_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthEight_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSeven_OrdPomogNeg(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthGeneral_OrdPomogNegZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthGeneral_OrdPomogNeg(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
+
+/***************************************************************
+ *
+ *  NegPomogZero
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthThree_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthTwo_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFour_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthThree_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFive_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthFour_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSix_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthFive_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSeven_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSix_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthEight_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSeven_OrdNegPomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthGeneral_OrdNegPomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthGeneral_OrdNegPomog(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
+
+/***************************************************************
+ *
+ *  NomogPosZero
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthFour_OrdNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthThree_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFive_OrdNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthFour_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSix_OrdNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthFive_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSeven_OrdNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSix_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthEight_OrdNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSeven_OrdNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthGeneral_OrdNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthGeneral_OrdNomogPos(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
+
+/***************************************************************
+ *
+ *  PosNomogZero
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthFour_OrdPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthThree_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFive_OrdPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthFour_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSix_OrdPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthFive_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSeven_OrdPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSix_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthEight_OrdPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSeven_OrdPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthGeneral_OrdPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthGeneral_OrdPosNomog(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
+
+/***************************************************************
+ *
+ * PosPosNomog
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthThree_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)             \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_Equal(1, _s1, _s2,                                         \
+                                           _p_MemCmp_LengthOne_Equal(2, _s2, _s1, actionE)),    \
+                           actionG, actionS)
+#define p_MemCmp_LengthFour_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_Equal(1, _s1, _s2,                                         \
+                                           _p_MemCmp_LengthTwo_Equal(2, _s2, _s1, actionE)),    \
+                           actionG, actionS)
+#define p_MemCmp_LengthFive_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_Equal(1, _s1, _s2,                                         \
+                                           _p_MemCmp_LengthThree_Equal(2, _s2, _s1, actionE)),    \
+                           actionG, actionS)
+#define p_MemCmp_LengthSix_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_Equal(1, _s1, _s2,                                         \
+                                           _p_MemCmp_LengthFour_Equal(2, _s2, _s1, actionE)),    \
+                           actionG, actionS)
+#define p_MemCmp_LengthSeven_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_Equal(1, _s1, _s2,                                         \
+                                           _p_MemCmp_LengthFive_Equal(2, _s2, _s1, actionE)),    \
+                           actionG, actionS)
+#define p_MemCmp_LengthEight_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_Equal(1, _s1, _s2,                                         \
+                                           _p_MemCmp_LengthSix_Equal(2, _s2, _s1, actionE)),    \
+                           actionG, actionS)
+#define p_MemCmp_LengthGeneral_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)          \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                     \
+                           _p_MemCmp_Equal(1, _s1, _s2,                                                   \
+                                           _p_MemCmp_LengthGeneral_Equal(2,_s2,_s1,(length-2), actionE)), \
+                           actionG, actionS)
+
+/***************************************************************
+ *
+ * NegPosNomog
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthThree_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)             \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_Equal(1, _s2, _s1,                                         \
+                                           _p_MemCmp_LengthOne_Equal(2, _s1, _s2, actionE)),    \
+                           actionS, actionG)
+#define p_MemCmp_LengthFour_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)              \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_Equal(1, _s2, _s1,                                         \
+                                           _p_MemCmp_LengthTwo_Equal(2, _s1, _s2, actionE)),    \
+                           actionS, actionG)
+#define p_MemCmp_LengthFive_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)              \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_Equal(1, _s2, _s1,                                         \
+                                           _p_MemCmp_LengthThree_Equal(2, _s1, _s2, actionE)),  \
+                           actionS, actionG)
+#define p_MemCmp_LengthSix_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)               \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_Equal(1, _s2, _s1,                                         \
+                                           _p_MemCmp_LengthFour_Equal(2, _s1, _s2, actionE)),   \
+                           actionS, actionG)
+#define p_MemCmp_LengthSeven_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)             \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_Equal(1, _s2, _s1,                                         \
+                                           _p_MemCmp_LengthFive_Equal(2, _s1, _s2, actionE)),   \
+                           actionS, actionG)
+#define p_MemCmp_LengthEight_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)             \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_Equal(1, _s2, _s1,                                         \
+                                           _p_MemCmp_LengthSix_Equal(2, _s1, _s2, actionE)),    \
+                           actionS, actionG)
+#define p_MemCmp_LengthGeneral_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)               \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                          \
+                           _p_MemCmp_Equal(1, _s2, _s1,                                             \
+                                           _p_MemCmp_LengthGeneral_Equal(2, _s1,_s2,                \
+                                                                         (length-2) , actionE)),    \
+                           actionS, actionG)
+
+/***************************************************************
+ *
+ * PosNomogPos
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthThree_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)             \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                      \
+                           _p_MemCmp_LengthOne_Equal(1, _s2, _s1,                               \
+                                           _p_MemCmp_LengthOne_Equal(2, _s1, _s2, actionE)),    \
+                           actionG, actionS)
+#define p_MemCmp_LengthFour_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
+                           _p_MemCmp_LengthTwo_Equal(1, _s2, _s1,                  \
+                                           _p_MemCmp_Equal(3, _s1, _s2, actionE)),  \
+                           actionG, actionS)
+#define p_MemCmp_LengthFive_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
+                           _p_MemCmp_LengthThree_Equal(1, _s2, _s1,                 \
+                                           _p_MemCmp_Equal(4, _s1, _s2, actionE)),  \
+                           actionG, actionS)
+#define p_MemCmp_LengthSix_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
+                           _p_MemCmp_LengthFour_Equal(1, _s2, _s1,                  \
+                                           _p_MemCmp_Equal(5, _s1, _s2, actionE)),  \
+                           actionG, actionS)
+#define p_MemCmp_LengthSeven_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
+                           _p_MemCmp_LengthFive_Equal(1, _s2, _s1,                  \
+                                           _p_MemCmp_Equal(6, _s1, _s2, actionE)),  \
+                           actionG, actionS)
+#define p_MemCmp_LengthEight_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                          \
+                           _p_MemCmp_LengthSix_Equal(1, _s2, _s1,                   \
+                                           _p_MemCmp_Equal(7, _s1, _s2, actionE)),  \
+                           actionG, actionS)
+#define p_MemCmp_LengthGeneral_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)       \
+  p_MemCmp_LengthOne_OrdPomog(s1, s2, length, ordsgn,                                                  \
+                           _p_MemCmp_LengthGeneral_Equal(1, _s2, _s1, (length - 2),         \
+                                                   _p_MemCmp_Equal(_i, _s1, _s2, actionE)), \
+                           actionG, actionS)
+
+
+/***************************************************************
+ *
+ *  PosPosNomogZero
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthFour_OrdPosPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthThree_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFive_OrdPosPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthFour_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSix_OrdPosPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthFive_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSeven_OrdPosPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSix_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthEight_OrdPosPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSeven_OrdPosPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthGeneral_OrdPosPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthGeneral_OrdPosPosNomog(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
+
+/***************************************************************
+ *
+ *  PosNomogPosZero
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthFour_OrdPosNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthThree_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFive_OrdPosNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthFour_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSix_OrdPosNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthFive_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSeven_OrdPosNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSix_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthEight_OrdPosNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSeven_OrdPosNomogPos(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthGeneral_OrdPosNomogPosZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthGeneral_OrdPosNomogPos(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
+
+/***************************************************************
+ *
+ *  NegPosNomogZero
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthFour_OrdNegPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthThree_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthFive_OrdNegPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+  p_MemCmp_LengthFour_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSix_OrdNegPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)     \
+  p_MemCmp_LengthFive_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthSeven_OrdNegPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSix_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthEight_OrdNegPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+  p_MemCmp_LengthSeven_OrdNegPosNomog(s1, s2, length, ordsgn, actionE, actionG, actionS)
+#define p_MemCmp_LengthGeneral_OrdNegPosNomogZero(s1, s2, length, ordsgn, actionE, actionG, actionS) \
+  p_MemCmp_LengthGeneral_OrdNegPosNomog(s1, s2, (length) -1, ordsgn, actionE, actionG, actionS)
+
+
+/***************************************************************
+ *
+ *  OrdGeneral
+ *
+ *******************************************************************/
+#define _p_MemCmp_OrdGeneral_Declare(s1, s2)    \
+  const unsigned long* _s1 = ((unsigned long*) s1);     \
+  const unsigned long* _s2 = ((unsigned long*) s2);     \
+  register unsigned long _v1;                           \
+  register unsigned long _v2;                           \
+  register unsigned long _i
+
+#define _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS) \
+do                                                              \
+{                                                               \
+  const long* _ordsgn = (long*) ordsgn;                        \
+  if (_v1 > _v2)                                                \
+  {                                                             \
+    if (_ordsgn[_i] == 1) actionG;                              \
+    actionS;                                                    \
+  }                                                             \
+  if (_ordsgn[_i] == 1) actionS;                                \
+  actionG;                                                      \
+}                                                               \
+while (0)
+
+#define _p_MemCmp_OrdGeneral(i, actionE)         \
+do                                              \
+{                                               \
+  _i = i;                                       \
+  _v1 = _s1[i];                                 \
+  _v2 = _s2[i];                                 \
+  if (_v1 == _v2) actionE;                      \
+}                                               \
+while(0)
+
+#define _p_MemCmp_LengthTwo_OrdGeneral(actionE)          \
+  _p_MemCmp_OrdGeneral(0, _p_MemCmp_OrdGeneral(1, actionE))
+
+#define _p_MemCmp_LengthThree_OrdGeneral(actionE)          \
+  _p_MemCmp_LengthTwo_OrdGeneral(_p_MemCmp_OrdGeneral(2, actionE))
+
+#define _p_MemCmp_LengthFour_OrdGeneral(actionE)          \
+  _p_MemCmp_LengthThree_OrdGeneral(_p_MemCmp_OrdGeneral(3, actionE))
+
+#define _p_MemCmp_LengthFive_OrdGeneral(actionE)          \
+  _p_MemCmp_LengthFour_OrdGeneral(_p_MemCmp_OrdGeneral(4, actionE))
+
+#define _p_MemCmp_LengthSix_OrdGeneral(actionE)          \
+  _p_MemCmp_LengthFive_OrdGeneral(_p_MemCmp_OrdGeneral(5, actionE))
+
+#define _p_MemCmp_LengthSeven_OrdGeneral(actionE)          \
+  _p_MemCmp_LengthSix_OrdGeneral(_p_MemCmp_OrdGeneral(6, actionE))
+
+#define _p_MemCmp_LengthEight_OrdGeneral(actionE)          \
+  _p_MemCmp_LengthSeven_OrdGeneral(_p_MemCmp_OrdGeneral(7, actionE))
+
+#define p_MemCmp_LengthOne_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+do                                                                                          \
+{                                                                                           \
+  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
+  _p_MemCmp_OrdGeneral(0, actionE);                                                         \
+  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
+}                                                                                           \
+while (0)
+
+#define p_MemCmp_LengthTwo_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+do                                                                                          \
+{                                                                                           \
+  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
+  _p_MemCmp_LengthTwo_OrdGeneral(actionE);                                               \
+  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
+}                                                                                           \
+while (0)
+
+#define p_MemCmp_LengthThree_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+do                                                                                          \
+{                                                                                           \
+  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
+  _p_MemCmp_LengthThree_OrdGeneral(actionE);                                             \
+  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
+}                                                                                           \
+while (0)
+
+#define p_MemCmp_LengthFour_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+do                                                                                          \
+{                                                                                           \
+  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
+  _p_MemCmp_LengthFour_OrdGeneral(actionE);                                              \
+  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
+}                                                                                           \
+while (0)
+
+#define p_MemCmp_LengthFive_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+do                                                                                          \
+{                                                                                           \
+  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
+  _p_MemCmp_LengthFive_OrdGeneral(actionE);                                              \
+  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
+}                                                                                           \
+while (0)
+
+#define p_MemCmp_LengthSix_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+do                                                                                          \
+{                                                                                           \
+  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
+  _p_MemCmp_LengthSix_OrdGeneral(actionE);                                               \
+  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
+}                                                                                           \
+while (0)
+
+#define p_MemCmp_LengthSeven_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+do                                                                                          \
+{                                                                                           \
+  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
+  _p_MemCmp_LengthSeven_OrdGeneral(actionE);                                             \
+  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
+}                                                                                           \
+while (0)
+
+#define p_MemCmp_LengthEight_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)  \
+do                                                                                          \
+{                                                                                           \
+  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                     \
+  _p_MemCmp_LengthEight_OrdGeneral(actionE);                                                \
+  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                  \
+}                                                                                           \
+while (0)
+
+/***************************************************************
+ *
+ *  Last but not least LengthGeneral_OrdGeneral
+ *
+ *******************************************************************/
+#define p_MemCmp_LengthGeneral_OrdGeneral(s1, s2, length, ordsgn, actionE, actionG, actionS)    \
+do                                                                                              \
+{                                                                                               \
+  _p_MemCmp_OrdGeneral_Declare(s1, s2);                                                         \
+  const unsigned long _l = (unsigned long) length;                                              \
+                                                                                                \
+  _i=0;                                                                                         \
+                                                                                                \
+  LengthGeneral_OrdGeneral_LoopTop:                                                             \
+  _v1 = _s1[_i];                                                                                \
+  _v2 = _s2[_i];                                                                                \
+  if (_v1 == _v2)                                                                               \
+  {                                                                                             \
+    _i++;                                                                                       \
+    if (_i == _l) actionE;                                                                      \
+    goto LengthGeneral_OrdGeneral_LoopTop;                                                      \
+  }                                                                                             \
+                                                                                                \
+  _p_MemCmp_OrdGeneral_NotEqual(ordsgn, actionG, actionS);                                      \
+}                                                                                               \
+while (0)
+
+// or, in other (less efficient) words
+#define p_MemCmp_LengthGeneral_OrdGeneral2(s1, s2, length, ordsgn, actionE, actionG, actionS)   \
+do                                                                                              \
+{                                                                                               \
+  int _i;                                                                                       \
+                                                                                                \
+  for (_i=0; _i<length;_i++)                                                                    \
+  {                                                                                             \
+    if (s1[_i] != s2[_i])                                                                       \
+    {                                                                                           \
+      if (s1[_i] > s2[_i])                                                                      \
+      {                                                                                         \
+        if (ordsgn[_i] == 1)                                                                    \
+          actionG;                                                                              \
+        actionS;                                                                                \
+      }                                                                                         \
+      if (ordsgn[_i] == 1)                                                                      \
+        actionS;                                                                                \
+      actionG;                                                                                  \
+    }                                                                                           \
+  }                                                                                             \
+  actionE;                                                                                      \
+}                                                                                               \
+while (0)
+
+/***************************************************************
+ *
+ *  Bitmask
+ *
+ *******************************************************************/
+#define _p_MemCmp_Bitmask_Declare(s1, s2, bitmask)  \
+  const unsigned long* _s1 = ((unsigned long*) s1); \
+  const unsigned long* _s2 = ((unsigned long*) s2); \
+  register const unsigned long _bitmask = bitmask;  \
+  register unsigned long _v1;                       \
+  register unsigned long _v2;                       \
+  register unsigned long _i                         \
+
+
+#define p_MemCmp_Bitmask_LengthGeneral(s1, s2, bitmask, length, actionG, actionS)   \
+do                                                                                  \
+{                                                                                   \
+  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                             \
+  const unsigned long _l = (unsigned long) length;                                  \
+                                                                                    \
+  _i=0;                                                                             \
+                                                                                    \
+  while (_i < _l)                                                                   \
+  {                                                                                 \
+    _v1 = _s1[_i];                                                                  \
+    _v2 = _s2[_i];                                                                  \
+                                                                                    \
+    if ((_v1 > _v2) ||                                                              \
+        (((_v1 & _bitmask) ^ (_v2 & _bitmask)) != ((_v2 - _v1) & _bitmask)))           \
+      actionS;                                                                      \
+    _i++;                                                                           \
+  }                                                                                 \
+  actionG;                                                                          \
+}                                                                                   \
+while (0)
+
+
+#define _p_MemCmp_Bitmask(i, actionS)                                       \
+do                                                                          \
+{                                                                           \
+  _i = i;                                                                   \
+  _v1 = _s1[i];                                                             \
+  _v2 = _s2[i];                                                             \
+  if ((_v1 > _v2) ||                                                        \
+      (((_v1 & _bitmask) ^ (_v2 & _bitmask)) != ((_v2 - _v1) & _bitmask)))     \
+    actionS;                                                               \
+}                                                                           \
+while (0)
+
+#define _p_MemCmp_Bitmask_LengthTwo(actionS)    \
+  do                                            \
+{                                               \
+  _p_MemCmp_Bitmask(0, actionS);                \
+  _p_MemCmp_Bitmask(1, actionS);                \
+}                                               \
+while (0)
+
+#define _p_MemCmp_Bitmask_LengthThree(actionS)  \
+  do                                            \
+{                                               \
+  _p_MemCmp_Bitmask_LengthTwo(actionS);         \
+  _p_MemCmp_Bitmask(2, actionS);                \
+}                                               \
+while (0)
+
+#define _p_MemCmp_Bitmask_LengthFour(actionS)   \
+  do                                            \
+{                                               \
+  _p_MemCmp_Bitmask_LengthThree(actionS);    \
+  _p_MemCmp_Bitmask(3, actionS);                \
+}                                               \
+while (0)
+
+
+#define _p_MemCmp_Bitmask_LengthFive(actionS)   \
+  do                                            \
+{                                               \
+  _p_MemCmp_Bitmask_LengthFour(actionS);     \
+  _p_MemCmp_Bitmask(4, actionS);                \
+}                                               \
+while (0)
+
+
+#define _p_MemCmp_Bitmask_LengthSix(actionS)    \
+  do                                            \
+{                                               \
+  _p_MemCmp_Bitmask_LengthFive(actionS);     \
+  _p_MemCmp_Bitmask(5, actionS);                \
+}                                               \
+while (0)
+
+#define _p_MemCmp_Bitmask_LengthSeven(actionS)  \
+  do                                            \
+{                                               \
+  _p_MemCmp_Bitmask_LengthSix(actionS);      \
+  _p_MemCmp_Bitmask(6, actionS);                \
+}                                               \
+while (0)
+
+#define _p_MemCmp_Bitmask_LengthEight(actionS)  \
+do                                              \
+{                                               \
+  _p_MemCmp_Bitmask_LengthSeven(actionS);    \
+  _p_MemCmp_Bitmask(7, actionS);                \
+}                                               \
+while (0)
+
+#define p_MemCmp_Bitmask_LengthZero(s1, s2, bitmask, length, actionG, actionS) actionG
+
+#define p_MemCmp_Bitmask_LengthOne(s1, s2, bitmask, length, actionG, actionS)   \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
+  _p_MemCmp_Bitmask(0, actionS);                                                \
+  actionG;                                                                      \
+}                                                                               \
+while (0)
+
+#define p_MemCmp_Bitmask_LengthTwo(s1, s2, bitmask, length, actionG, actionS)   \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
+  _p_MemCmp_Bitmask_LengthTwo(actionS);                                         \
+  actionG;                                                                      \
+}                                                                               \
+while (0)
+
+#define p_MemCmp_Bitmask_LengthThree(s1, s2, bitmask, length, actionG, actionS)   \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
+  _p_MemCmp_Bitmask_LengthThree(actionS);                                         \
+  actionG;                                                                      \
+}                                                                               \
+while (0)
+
+#define p_MemCmp_Bitmask_LengthFour(s1, s2, bitmask, length, actionG, actionS)   \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
+  _p_MemCmp_Bitmask_LengthFour(actionS);                                         \
+  actionG;                                                                      \
+}                                                                               \
+while (0)
+
+#define p_MemCmp_Bitmask_LengthFive(s1, s2, bitmask, length, actionG, actionS)   \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
+  _p_MemCmp_Bitmask_LengthFive(actionS);                                         \
+  actionG;                                                                      \
+}                                                                               \
+while (0)
+
+#define p_MemCmp_Bitmask_LengthSix(s1, s2, bitmask, length, actionG, actionS)   \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
+  _p_MemCmp_Bitmask_LengthSix(actionS);                                         \
+  actionG;                                                                      \
+}                                                                               \
+while (0)
+
+#define p_MemCmp_Bitmask_LengthSeven(s1, s2, bitmask, length, actionG, actionS) \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
+  _p_MemCmp_Bitmask_LengthSeven(actionS);                                       \
+  actionG;                                                                      \
+}                                                                               \
+while (0)
+
+#define p_MemCmp_Bitmask_LengthEigth(s1, s2, bitmask, length, actionG, actionS) \
+do                                                                              \
+{                                                                               \
+  _p_MemCmp_Bitmask_Declare(s1, s2, bitmask);                                         \
+  _p_MemCmp_Bitmask_LengthEigth(actionS);                                       \
+  actionG;                                                                      \
+}                                                                               \
+while (0)
+
+
+#endif // P_MEM_CMP
Index: polys/templates/p_MemCopy.h
===================================================================
--- polys/templates/p_MemCopy.h	(revision 4cfe968e9f2c139f34f69fccb257823023c3890e)
+++ polys/templates/p_MemCopy.h	(revision 4cfe968e9f2c139f34f69fccb257823023c3890e)
@@ -0,0 +1,96 @@
+/****************************************
+*  Computer Algebra System SINGULAR     *
+****************************************/
+/***************************************************************
+ *  File:    p_MemCopy.h
+ *  Purpose: macros for memory addition
+ *  Author:  obachman (Olaf Bachmann)
+ *  Created: 8/00
+ *  Version: $Id$
+ *******************************************************************/
+#ifndef P_MEM_COPY_H
+#define P_MEM_COPY_H
+
+#define _p_MemCopy(i, d, s) d[i] = s[i]
+
+#define _p_MemCopy_LengthOne(d, s) _p_MemCopy(0, d, s)
+#define _p_MemCopy_LengthTwo(d, s) do{_p_MemCopy_LengthOne(d, s); _p_MemCopy(1, d, s);} while(0)
+#define _p_MemCopy_LengthThree(d, s) do{_p_MemCopy_LengthTwo(d, s); _p_MemCopy(2, d, s);} while(0)
+#define _p_MemCopy_LengthFour(d, s) do{_p_MemCopy_LengthThree(d, s); _p_MemCopy(3, d, s);} while(0)
+#define _p_MemCopy_LengthFive(d, s) do{_p_MemCopy_LengthFour(d, s); _p_MemCopy(4, d, s);} while(0)
+#define _p_MemCopy_LengthSix(d, s) do{_p_MemCopy_LengthFive(d, s); _p_MemCopy(5, d, s);} while(0)
+#define _p_MemCopy_LengthSeven(d, s) do{_p_MemCopy_LengthSix(d, s); _p_MemCopy(6, d, s);} while(0)
+#define _p_MemCopy_LengthEight(d, s) do{_p_MemCopy_LengthSeven(d, s); _p_MemCopy(7, d, s);} while(0)
+
+#define _p_MemCopy_Declare(d, s)                \
+  unsigned long* _d = ((unsigned long*) d); \
+  const unsigned long* _s = ((unsigned long*) s)
+
+#define p_MemCopy_LengthOne(d, s, length) _p_MemCopy_LengthOne(d, s)
+#define p_MemCopy_LengthTwo(d, s, length)   \
+do                                              \
+{                                               \
+  _p_MemCopy_Declare(d,s);                    \
+  _p_MemCopy_LengthTwo(_d, _s);            \
+}                                               \
+while (0)
+#define p_MemCopy_LengthThree(d, s, length) \
+do                                              \
+{                                               \
+  _p_MemCopy_Declare(d,s);                    \
+  _p_MemCopy_LengthThree(_d, _s);          \
+}                                               \
+while (0)
+#define p_MemCopy_LengthFour(d, s, length)  \
+do                                              \
+{                                               \
+  _p_MemCopy_Declare(d,s);                    \
+  _p_MemCopy_LengthFour(_d, _s);           \
+}                                               \
+while (0)
+#define p_MemCopy_LengthFive(d, s, length)  \
+do                                              \
+{                                               \
+  _p_MemCopy_Declare(d,s);                    \
+  _p_MemCopy_LengthFive(_d, _s);           \
+}                                               \
+while (0)
+#define p_MemCopy_LengthSix(d, s, length)   \
+do                                              \
+{                                               \
+  _p_MemCopy_Declare(d,s);                    \
+  _p_MemCopy_LengthSix(_d, _s);            \
+}                                               \
+while (0)
+#define p_MemCopy_LengthSeven(d, s, length) \
+do                                              \
+{                                               \
+  _p_MemCopy_Declare(d,s);                    \
+  _p_MemCopy_LengthSeven(_d, _s);          \
+}                                               \
+while (0)
+#define p_MemCopy_LengthEight(d, s, length) \
+do                                              \
+{                                               \
+  _p_MemCopy_Declare(d,s);                    \
+  _p_MemCopy_LengthEight(_d, _s);          \
+}                                               \
+while (0)
+
+#define p_MemCopy_LengthGeneral(d, s, length)   \
+do                                              \
+{                                               \
+  _p_MemCopy_Declare(d,s);                      \
+  const unsigned long _l = (unsigned long) length;   \
+  unsigned long _i = 0;                         \
+                                                \
+  do                                            \
+  {                                             \
+    _d[_i] = _s[_i];                            \
+    _i++;                                       \
+  }                                             \
+  while (_i != _l);                             \
+}                                               \
+while (0)
+
+#endif // P_MEM_COPY_H
