Details | 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 |
||
59 | * |
||
60 | * Revision 1.21 2000/10/04 10:37:14 10:37:14 mjames (Mike James) |
||
61 | * Part of Release PSAVAT01 |
||
62 | * |
||
63 | * Revision 1.20 2000/10/02 11:04:21 11:04:21 mjames (Mike James) |
||
64 | * new_vhdl |
||
65 | * |
||
66 | * Revision 1.19 2000/09/27 14:42:29 14:42:29 mjames (Mike James) |
||
67 | * Part of Release Sep_27_ST_2000 |
||
68 | * |
||
69 | * Revision 1.18 2000/09/21 10:15:58 10:15:58 mjames (Mike James) |
||
70 | * Part of Release Sep21Alpha |
||
71 | * |
||
72 | * Revision 1.17 2000/08/25 09:57:23 09:57:23 mjames (Mike James) |
||
73 | * Part of Release Aug25_alpha |
||
74 | * |
||
75 | * Revision 1.16 2000/08/16 08:57:39 08:57:39 mjames (Mike James) |
||
76 | * Part of Release CD01_Aug2000 |
||
77 | * |
||
78 | * Revision 1.15 2000/08/14 14:45:18 14:45:18 mjames (Mike James) |
||
79 | * Part of Release Aug_14_2000 |
||
80 | * |
||
81 | * Revision 1.14 2000/08/11 08:30:39 08:30:39 mjames (Mike James) |
||
82 | * Part of Release Aug_11_2000 |
||
83 | * |
||
84 | * Revision 1.13 2000/08/09 10:31:56 10:31:56 mjames (Mike James) |
||
85 | * Part of Release Aug__9_2000 |
||
86 | * |
||
87 | * Revision 1.12 2000/05/31 11:43:09 11:43:09 mjames (Mike James) |
||
88 | * Part of Release May_31_2000 |
||
89 | * |
||
90 | * Revision 1.11 2000/05/08 17:01:45 17:01:45 mjames (Mike James) |
||
91 | * Part of Release May__8_2000 |
||
92 | * |
||
93 | * Revision 1.10 2000/05/08 16:59:39 16:59:39 mjames (Mike James) |
||
94 | * Part of Release May__8_2000 |
||
95 | * |
||
96 | * Revision 1.9 2000/05/08 16:57:15 16:57:15 mjames (Mike James) |
||
97 | * Part of Release May__8_2000 |
||
98 | * |
||
99 | * Revision 1.8 2000/03/08 16:19:32 16:19:32 mjames (Mike James) |
||
100 | * New version including PC |
||
101 | * |
||
102 | * Revision 1.5 2000/01/20 15:58:57 15:58:57 mjames (Mike James) |
||
103 | * Part of Release R22 |
||
104 | * |
||
105 | * Revision 1.4 99/12/22 11:15:37 11:15:37 mjames (Mike James) |
||
106 | * Part of Release Dec_22_1999 |
||
107 | * |
||
108 | * Revision 1.3 98/02/11 11:27:21 11:27:21 mjames (Mike James) |
||
109 | * Checked in for version 6.2a |
||
110 | * |
||
111 | * Revision 1.2 97/04/23 08:44:46 08:44:46 mjames (Mike James) |
||
112 | * CHecked in for release rel23041997 |
||
113 | * |
||
114 | * Revision 1.1 96/12/23 10:24:34 10:24:34 mjames (Mike James) |
||
115 | * Initial revision |
||
116 | * */ |
||
117 | |||
118 | #pragma once |
||
119 | |||
120 | #include <regex.h> |
||
121 | /* pin identifying letters that are permitted in IC pin identifiers */ |
||
122 | #define PIN_MAP_LEGAL_CHARS "ABCDEFGHJKLMNPQRSTUVWXYZ" |
||
123 | /* the number of characters in the legal character set */ |
||
124 | #define PIN_MAP_LEGAL_CHAR_COUNT 24 |
||
125 | |||
126 | /* pin identifying letters that are not permitted in IC pin identifiers */ |
||
127 | #define PIN_MAP_ILLEGAL_CHARS "IO"; |
||
128 | /* the number of characters in the illegal character set */ |
||
129 | #define PIN_MAP_ILLEGAL_CHAR_COUNT 2 |
||
130 | |||
131 | /* maximum alphabetic characters before we decide pin identifier should not be |
||
132 | assigned a column number in sort_nodes */ |
||
133 | #define MAX_ID_ALPHA_SORT 5 |
||
134 | |||
135 | /* this function also determines the 'row' and 'columns' of each chip sorted, |
||
136 | as well as the minimum and maximum row and column numbers */ |
||
137 | |||
138 | /* this now made conditional on mode being EXTRACT_XY */ |
||
139 | typedef enum |
||
140 | { |
||
141 | NO_EXTRACT_XY, |
||
142 | EXTRACT_XY |
||
143 | } extract_xy_t; |
||
144 | |||
145 | extern void sort_nodes (socket_t *chip, extract_xy_t mode); |
||
146 | extern socket_t *sort_sockets (socket_t **s); |
||
147 | /* regular expression compiler according to Vertical rules */ |
||
148 | |||
149 | #define MAX_REGEXP_SUBEXPR 10 |
||
150 | |||
151 | typedef struct vrt |
||
152 | { |
||
153 | regex_t preg[1]; |
||
154 | regmatch_t regpatt[MAX_REGEXP_SUBEXPR]; |
||
155 | char *buff; |
||
156 | } vert_regex_t; |
||
157 | |||
158 | extern int vert_regcomp (vert_regex_t **preg, char *expr); |
||
159 | |||
160 | extern int vert_regfree (vert_regex_t **preg); |