version 1.23, 2001/09/07 08:54:58 |
version 1.28, 2001/09/17 10:32:41 |
|
|
* DEVELOPER SHALL HAVE NO LIABILITY IN CONNECTION WITH THE USE, |
* DEVELOPER SHALL HAVE NO LIABILITY IN CONNECTION WITH THE USE, |
* PERFORMANCE OR NON-PERFORMANCE OF THE SOFTWARE. |
* PERFORMANCE OR NON-PERFORMANCE OF THE SOFTWARE. |
* |
* |
* $OpenXM: OpenXM_contrib2/asir2000/include/ca.h,v 1.22 2001/09/04 08:48:20 noro Exp $ |
* $OpenXM: OpenXM_contrib2/asir2000/include/ca.h,v 1.27 2001/09/17 08:37:31 noro Exp $ |
*/ |
*/ |
#include <stdio.h> |
#include <stdio.h> |
|
|
|
|
#include <stdlib.h> |
#include <stdlib.h> |
#endif |
#endif |
|
|
|
#if !defined(VISUAL) |
|
#include <sys/param.h> |
|
#endif |
|
|
#if defined(linux) || (defined(sun) && !defined(SYSV)) || defined(news5000) || (defined(mips) && defined(ultrix)) |
#if defined(linux) || (defined(sun) && !defined(SYSV)) || defined(news5000) || (defined(mips) && defined(ultrix)) |
#include <alloca.h> |
#include <alloca.h> |
#endif |
#endif |
Line 373 typedef struct oDL { |
|
Line 377 typedef struct oDL { |
|
|
|
typedef struct oCDP { |
typedef struct oCDP { |
int len; |
int len; |
struct oCMP *body; |
int psindex; |
|
unsigned int *body; |
} *CDP; |
} *CDP; |
|
|
typedef struct oCMP { |
typedef struct oCM { |
int index; |
int index; |
int c; |
int c; |
} *CMP; |
} *CM; |
|
|
|
/* bucket list for DL */ |
|
|
|
typedef struct oDLBUCKET { |
|
int td; |
|
struct oNODE *body; |
|
struct oDLBUCKET *next; |
|
} *DLBUCKET; |
|
|
typedef struct oVL { |
typedef struct oVL { |
V v; |
V v; |
struct oVL *next; |
struct oVL *next; |
Line 488 typedef unsigned int ModNum; |
|
Line 501 typedef unsigned int ModNum; |
|
#endif |
#endif |
|
|
/* general macros */ |
/* general macros */ |
|
#if defined(MAX) |
|
#undef MAX |
|
#endif |
|
#if defined(MIN) |
|
#undef MIN |
|
#endif |
#define MAX(a,b) ((a) > (b) ? (a) : (b) ) |
#define MAX(a,b) ((a) > (b) ? (a) : (b) ) |
#define MIN(a,b) ((a) > (b) ? (b) : (a) ) |
#define MIN(a,b) ((a) > (b) ? (b) : (a) ) |
#ifdef ABS |
#ifdef ABS |
Line 607 bzero((char *)(q)->b,(w)*sizeof(unsigned int))) |
|
Line 626 bzero((char *)(q)->b,(w)*sizeof(unsigned int))) |
|
#define NEWV(v) ((v)=(V)MALLOC(sizeof(struct oV))) |
#define NEWV(v) ((v)=(V)MALLOC(sizeof(struct oV))) |
#define NEWVL(vl) ((vl)=(VL)MALLOC(sizeof(struct oVL))) |
#define NEWVL(vl) ((vl)=(VL)MALLOC(sizeof(struct oVL))) |
#define NEWMP(m) ((m)=(MP)MALLOC(sizeof(struct oMP))) |
#define NEWMP(m) ((m)=(MP)MALLOC(sizeof(struct oMP))) |
|
#define NEWDLBUCKET(a) ((a)=(DLBUCKET)MALLOC(sizeof(struct oDLBUCKET))) |
|
|
#define NEWMAT(l) ((l)=(MAT)MALLOC(sizeof(struct oMAT)),OID(l)=O_MAT) |
#define NEWMAT(l) ((l)=(MAT)MALLOC(sizeof(struct oMAT)),OID(l)=O_MAT) |
#define NEWGF2MAT(l) ((l)=(GF2MAT)MALLOC(sizeof(struct oGF2MAT)),OID(l)=O_GF2MAT) |
#define NEWGF2MAT(l) ((l)=(GF2MAT)MALLOC(sizeof(struct oGF2MAT)),OID(l)=O_GF2MAT) |
Line 662 if(!(r)){NEWNODE(r);(c)=(r);}else{NEWNODE(NEXT(c));(c) |
|
Line 682 if(!(r)){NEWNODE(r);(c)=(r);}else{NEWNODE(NEXT(c));(c) |
|
if(!(r)){NEWMP(r);(c)=(r);}else{NEWMP(NEXT(c));(c)=NEXT(c);} |
if(!(r)){NEWMP(r);(c)=(r);}else{NEWMP(NEXT(c));(c)=NEXT(c);} |
#define NEXTMP2(r,c,s) \ |
#define NEXTMP2(r,c,s) \ |
if(!(r)){(c)=(r)=(s);}else{NEXT(c)=(s);(c)=(s);} |
if(!(r)){(c)=(r)=(s);}else{NEXT(c)=(s);(c)=(s);} |
|
#define NEXTDLBUCKET(r,c) \ |
|
if(!(r)){NEWDLBUCKET(r);(c)=(r);}else{NEWDLBUCKET(NEXT(c));(c)=NEXT(c);} |
|
|
/* convertors */ |
/* convertors */ |
#define NTOQ(n,s,q) \ |
#define NTOQ(n,s,q) \ |
Line 723 PL(NM(q))=1,BD(NM(q))[0]=(unsigned int)(n),DN(q)=0,(q) |
|
Line 745 PL(NM(q))=1,BD(NM(q))[0]=(unsigned int)(n),DN(q)=0,(q) |
|
|
|
#define NV(p) ((p)->nv) |
#define NV(p) ((p)->nv) |
#define C(p) ((p)->c) |
#define C(p) ((p)->c) |
|
#if 0 |
#define ITOS(p) (((unsigned int)(p))&0x7fffffff) |
#define ITOS(p) (((unsigned int)(p))&0x7fffffff) |
#define STOI(i) ((P)((unsigned int)(i)|0x80000000)) |
#define STOI(i) ((P)((unsigned int)(i)|0x80000000)) |
|
#else |
|
#define ITOS(p) (((unsigned int)(p))) |
|
#define STOI(i) ((P)((unsigned int)(i))) |
|
#endif |
|
|
/* immediate GFS representation */ |
/* immediate GFS representation */ |
|
|