1 /****************************************************************************/
3 /* Chaine de CAO & VLSI AVERTEC */
5 /* Produit : BEG_GEN Version 1.00 */
6 /* Fichier : beg_lib.h */
8 /* (c) copyright 2002 AVERTEC */
9 /* Tous droits reserves */
11 /* Auteur(s) : Antony PINTO */
13 /****************************************************************************/
22 #define BEG_PRE (long) 0x00000002
23 #define BEG_REG (long) 0x00000004
24 #define BEG_BUS (long) 0x00000008
25 #define BEG_CMPLX (long) 0x00000010
26 #define BEG_LAST (long) 0x00000020
28 #define BEG_MASK_OUT (long) 0x00000010
29 #define BEG_MASK_AUX (long) 0x00000020
30 #define BEG_MASK_BUS (long) 0x00000030
31 #define BEG_MASK_BUX (long) 0x00000040
32 #define BEG_MASK_REG (long) 0x00000050
33 #define BEG_MASK_POR (long) 0x00000060
34 #define BEG_MASK_RIN (long) 0x00000070
36 #define BEG_MASK_VECT (long) 0x00000001
37 #define BEG_MASK_SING (long) 0x00000002
38 #define BEG_MASK_TYPE (long) 0x0000000F
40 #define BEG_TYPE_VECTOUT (long) 0x00000011
41 #define BEG_TYPE_SINGOUT (long) 0x00000012
42 #define BEG_TYPE_VECTAUX (long) 0x00000021
43 #define BEG_TYPE_SINGAUX (long) 0x00000022
44 #define BEG_TYPE_VECTBUS (long) 0x00000031
45 #define BEG_TYPE_SINGBUS (long) 0x00000032
46 #define BEG_TYPE_VECTBUX (long) 0x00000041
47 #define BEG_TYPE_SINGBUX (long) 0x00000042
48 #define BEG_TYPE_VECTREG (long) 0x00000051
49 #define BEG_TYPE_SINGREG (long) 0x00000052
50 #define BEG_TYPE_VECTPOR (long) 0x00000061
51 #define BEG_TYPE_SINGPOR (long) 0x00000062
52 #define BEG_TYPE_CONFLIT (long) 0x00000071
54 // mode de recherche pour beg_get_vectname
55 #define BEG_SEARCH_NAME '('
56 #define BEG_SEARCH_ABL ' '
57 #define BEG_SEARCH_LOOP 'L'
58 #define BEG_SEARCH_ALOOP 'a'
61 #define BEG_NOVERIF (int) 0xFF00
62 // verify coherence with bvl
64 #define BEG_OBJ ptype_list*
65 #define BEG_CORRESP_PTYPE (long) 0xc1c01263
66 #define BEG_RENAME_LIST (long) 0xc1c03093
68 void beg_init ( void );
69 void beg_def_por ( char *name
,
71 void beg_def_sig ( char *name
,
73 unsigned int time
,int,int, long);
74 biabl_list
* beg_def_mux ( char *name
,
79 long flags
, long biflags
);
80 biabl_list
* beg_def_process ( char *name
,
87 long flags
, long biflags
);
88 biabl_list
* beg_def_loop ( char *name
,
94 long flags
, long biflags
);
95 biabl_list
* beg_def_biloop ( char *name
,
102 long flags
, long biflags
);
103 void beg_assertion ( char *expr
,
108 befig_list
*beg_get_befig ( int verif
);
109 void beg_freeBefig ( void );
110 void beg_delBefig ( befig_list
*fig
);
111 void beg_def_befig ( char *name
);
113 void beg_get_vectname ( char *signame
,
118 void beg_eat_por ( befig_list
*eaten
);
119 void beg_eat_figure ( befig_list
*eaten
);
120 befig_list
*beg_get_befigByName ( char *name
);
122 void beg_sort ( void);
123 // !!! WARNING beg_compact need beg_sort to be performed before use
124 void beg_compact ( void);
126 int beg_isVect ( BEG_OBJ obj
);
127 BEG_OBJ
beg_getObjByName ( befig_list
*fig
,
130 berin_list
*beg_getBerinByName ( befig_list
*fig
,
132 int beg_getLeft ( BEG_OBJ obj
);
133 int beg_getRight ( BEG_OBJ obj
);
134 void beg_newRight ( BEG_OBJ obj
,
136 void beg_newLeft ( BEG_OBJ obj
,
138 vectbiabl_list
*beg_getVectBiabl ( BEG_OBJ obj
);
140 chain_list
*beg_str2Abl ( char *str
);
141 char *beg_boolDelNot ( chain_list
*expr
,
143 chain_list
*beg_compactAbl ( chain_list
*expr
);
144 int beg_isDeletedBiabl ( biabl_list
*biabl
);
146 void beg_add_pors ( befig_list
*fig
);
148 void beg_terminate ( befig_list
*fig
);
150 void beg_topLevel ( befig_list
**befig
,
151 chain_list
*insbefigs
,
153 loins_list
*loins
, ht
**renamed
, ht
**morealiases
);
154 void beg_addAllInstances ( char *curbefig
, befig_list
*befig
,
164 char *beg_get_currentName ( void );
165 befig_list
*beg_duplicate ( befig_list
*model
,
168 #define BEGAPI_HT_BASE 13
169 #define DISABLE_CREATE_BEH 2
170 #define DISABLE_CREATE_COR 4
171 #define DISABLE_COMPACT 8
173 ht
*begGetCorrespHT(char *name
);
174 void begFreeCorrespHT(befig_list
*bf
, char *name
);
175 ht
*begGetCorrespHTCreate(char *name
);
176 void begGetCorrespHTUnlink(char *name
);
177 void begGetCorrespHTRelink(char *name
, ht
*newc
);
178 void beg_forceZSort(void);