Subversion Repositories Vertical

Rev

Rev 2 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 mjames 1
/*
2
 * $Id: sorting.h,v 1.1.1.1 2003/11/04 23:34:57 mjames Exp $
3
 *
4
 * $Log: sorting.h,v $
5
 * Revision 1.1.1.1  2003/11/04 23:34:57  mjames
6
 * Imported into local repositrory
7
 *
8
 * Revision 1.12  2002/09/16 14:41:43  mjames
9
 * Merge back pin indexing bug that meant
10
 * pin AZ12 was indistinguishable from pin Z12 in
11
 * rename ident/name commands
12
 *
13
 * Revision 1.11  2002/09/09 10:10:21  mjames
14
 * Moved pin remapping function to pin ident editing function from
15
 * sorting pin name routine.
16
 *
17
 * Revision 1.10  2002/08/23 14:13:55  mjames
18
 * Added legal/illegal pin identifying letters to the header file.
19
 * Upgraded sort to determine row/column locations of pins identified like
20
 * 'a1' and '1a' etc or '1' , '2'
21
 *
22
 * Revision 1.9  2002/08/23 14:04:12  mjames
23
 * Added legal/illegal pin identifying letters to the header file.
24
 *
25
 * Revision 1.8  2002/01/21 09:35:57  mjames
26
 * Increased number of regular expression sub expressions that can be
27
 * matched from 4 to 10
28
 *
29
 * Revision 1.7  2001/12/11 21:27:12  mjames
30
 * Allowed for a variable number of sub-expressions to be matched by
31
 * regexp expressions.
32
 *
33
 * Revision 1.6  2001/10/31 22:20:17  mjames
34
 * Tidying up problematical comments caused by CVS
35
 * 'intelligent' comment guessing
36
 *
37
 * Revision 1.5  2001/10/31 16:15:36  mjames
38
 * Added a datastructure to hide regular expression information from programs.
39
 *
40
 * Revision 1.4  2001/10/22 10:53:40  mjames
41
 * Added a declaration of the Vertical regular expression compiler
42
 * which validates and complains about older 'regular expressions'
43
 * used by Vertical prior to using regexp in the C library
44
 *
45
 * Revision 1.3  2001/10/10 20:17:59  mjames
46
 * Added a vert_regcomp function to compile regular expressions
47
 * with '^' (match start string) and  '$' (match end string) bracketing
48
 * this => wildcard must match entire string not just a part of it.
49
 *
50
 * Revision 1.2  2001/06/06 12:10:17  mjames
51
 * Move from HPUX
52
 *
53
 * Revision 1.1.1.1  2000/10/19 21:58:40  mjames
54
 * Mike put it here
55
 *
56
 *
57
 * Revision 1.21  2000/10/04  10:37:14  10:37:14  mjames (Mike James)
58
 * Modified for Vertical2 : support COMPONENTS and SIGNALS
11 mjames 59
 *
2 mjames 60
 * Revision 1.21  2000/10/04  10:37:14  10:37:14  mjames (Mike James)
61
 * Part of Release PSAVAT01
11 mjames 62
 *
2 mjames 63
 * Revision 1.20  2000/10/02  11:04:21  11:04:21  mjames (Mike James)
64
 * new_vhdl
11 mjames 65
 *
2 mjames 66
 * Revision 1.19  2000/09/27  14:42:29  14:42:29  mjames (Mike James)
67
 * Part of Release Sep_27_ST_2000
11 mjames 68
 *
2 mjames 69
 * Revision 1.18  2000/09/21  10:15:58  10:15:58  mjames (Mike James)
70
 * Part of Release Sep21Alpha
11 mjames 71
 *
2 mjames 72
 * Revision 1.17  2000/08/25  09:57:23  09:57:23  mjames (Mike James)
73
 * Part of Release Aug25_alpha
11 mjames 74
 *
2 mjames 75
 * Revision 1.16  2000/08/16  08:57:39  08:57:39  mjames (Mike James)
76
 * Part of Release CD01_Aug2000
11 mjames 77
 *
2 mjames 78
 * Revision 1.15  2000/08/14  14:45:18  14:45:18  mjames (Mike James)
79
 * Part of Release Aug_14_2000
11 mjames 80
 *
2 mjames 81
 * Revision 1.14  2000/08/11  08:30:39  08:30:39  mjames (Mike James)
82
 * Part of Release Aug_11_2000
11 mjames 83
 *
2 mjames 84
 * Revision 1.13  2000/08/09  10:31:56  10:31:56  mjames (Mike James)
85
 * Part of Release Aug__9_2000
11 mjames 86
 *
2 mjames 87
 * Revision 1.12  2000/05/31  11:43:09  11:43:09  mjames (Mike James)
88
 * Part of Release May_31_2000
11 mjames 89
 *
2 mjames 90
 * Revision 1.11  2000/05/08  17:01:45  17:01:45  mjames (Mike James)
91
 * Part of Release May__8_2000
11 mjames 92
 *
2 mjames 93
 * Revision 1.10  2000/05/08  16:59:39  16:59:39  mjames (Mike James)
94
 * Part of Release May__8_2000
11 mjames 95
 *
2 mjames 96
 * Revision 1.9  2000/05/08  16:57:15  16:57:15  mjames (Mike James)
97
 * Part of Release May__8_2000
11 mjames 98
 *
2 mjames 99
 * Revision 1.8  2000/03/08  16:19:32  16:19:32  mjames (Mike James)
100
 * New version including PC
11 mjames 101
 *
2 mjames 102
 * Revision 1.5  2000/01/20  15:58:57  15:58:57  mjames (Mike James)
103
 * Part of Release R22
11 mjames 104
 *
2 mjames 105
 * Revision 1.4  99/12/22  11:15:37  11:15:37  mjames (Mike James)
106
 * Part of Release Dec_22_1999
11 mjames 107
 *
2 mjames 108
 * Revision 1.3  98/02/11  11:27:21  11:27:21  mjames (Mike James)
109
 * Checked in for version 6.2a
11 mjames 110
 *
2 mjames 111
 * Revision 1.2  97/04/23  08:44:46  08:44:46  mjames (Mike James)
112
 * CHecked in for release rel23041997
11 mjames 113
 *
2 mjames 114
 * Revision 1.1  96/12/23  10:24:34  10:24:34  mjames (Mike James)
115
 * Initial revision
116
 *  */
117
/* pin identifying letters that are permitted in IC pin identifiers */
118
#define PIN_MAP_LEGAL_CHARS "ABCDEFGHJKLMNPQRSTUVWXYZ"
119
/* the number of characters in the legal character set */
11 mjames 120
#define PIN_MAP_LEGAL_CHAR_COUNT 24 
2 mjames 121
 
122
/* pin identifying letters that are not permitted in IC pin identifiers */
11 mjames 123
#define PIN_MAP_ILLEGAL_CHARS   "IO";
2 mjames 124
/* the number of characters in the illegal character set */
11 mjames 125
#define PIN_MAP_ILLEGAL_CHAR_COUNT 2 
2 mjames 126
 
11 mjames 127
/* maximum alphabetic characters before we decide pin identifier should not be
2 mjames 128
   assigned a column number in sort_nodes */
129
#define MAX_ID_ALPHA_SORT 5
130
 
131
/* this function also determines the 'row' and 'columns' of each chip sorted,
132
   as well as the minimum and maximum row and column numbers */
133
 
134
/* this now made conditional on mode being EXTRACT_XY */
11 mjames 135
typedef enum { NO_EXTRACT_XY,EXTRACT_XY} extract_xy_t;
2 mjames 136
 
11 mjames 137
 
138
extern void sort_nodes(socket_t * chip,extract_xy_t mode) ;
139
extern  socket_t * sort_sockets(socket_t ** s);
2 mjames 140
/* regular expression compiler according to Vertical rules */
141
 
142
#define MAX_REGEXP_SUBEXPR 10
143
 
11 mjames 144
 
2 mjames 145
typedef struct vrt
11 mjames 146
  {
147
  regex_t     preg[1];
148
  regmatch_t  regpatt[MAX_REGEXP_SUBEXPR];
149
  char*       buff;
150
  } vert_regex_t;
2 mjames 151
 
11 mjames 152
extern int vert_regcomp(vert_regex_t ** preg,char * expr);
2 mjames 153
 
11 mjames 154
 
155
extern int vert_regfree(vert_regex_t ** preg);