source: trunk/symtab/id_group_strms.hpp @ 2152

Last change on this file since 2152 was 1929, checked in by ksherdy, 8 years ago

Updated identity symbol table.

File size: 6.6 KB
Line 
1#ifndef ID_GROUP_STRMS_TEMPLATE_HPP
2#define ID_GROUP_STRMS_TEMPLATE_HPP
3
4#include "../lib/bitblock.hpp"
5#include "../lib/carryQ.hpp"
6
7// GENERATED
8  struct Groups {
9  BitBlock starts;
10  BitBlock ends;
11  BitBlock ends_1;
12  BitBlock ends_2;
13  BitBlock ends_3;
14  BitBlock ends_4;
15  BitBlock ends_5;
16  BitBlock ends_6;
17  BitBlock ends_7;
18  BitBlock ends_8;
19  BitBlock ends_9;
20  BitBlock ends_10;
21  BitBlock ends_11;
22  BitBlock ends_12;
23  BitBlock ends_13;
24  BitBlock ends_14;
25  BitBlock ends_15;
26  BitBlock ends_16;
27  BitBlock ends_gte_17;
28};
29
30  struct Gen_lgth_groups {
31  Gen_lgth_groups() { 
32 }
33  void do_block(Markers & markers, Groups & groups) {
34                BitBlock cursor, temp;
35
36
37        groups.starts = markers.starts;
38        groups.ends = markers.ends;
39        cursor = groups.starts;
40        temp = groups.ends;
41        cursor = carryQ.BitBlock_advance_ci_co(cursor, 0);
42        groups.ends_1 = simd_and(cursor, temp);
43        temp = simd_andc(temp, groups.ends_1);
44        cursor = carryQ.BitBlock_advance_ci_co(cursor, 1);
45        groups.ends_2 = simd_and(cursor, temp);
46        temp = simd_andc(temp, groups.ends_2);
47        cursor = carryQ.BitBlock_advance_ci_co(cursor, 2);
48        groups.ends_3 = simd_and(cursor, temp);
49        temp = simd_andc(temp, groups.ends_3);
50        cursor = carryQ.BitBlock_advance_ci_co(cursor, 3);
51        groups.ends_4 = simd_and(cursor, temp);
52        temp = simd_andc(temp, groups.ends_4);
53        cursor = carryQ.BitBlock_advance_ci_co(cursor, 4);
54        groups.ends_5 = simd_and(cursor, temp);
55        temp = simd_andc(temp, groups.ends_5);
56        cursor = carryQ.BitBlock_advance_ci_co(cursor, 5);
57        groups.ends_6 = simd_and(cursor, temp);
58        temp = simd_andc(temp, groups.ends_6);
59        cursor = carryQ.BitBlock_advance_ci_co(cursor, 6);
60        groups.ends_7 = simd_and(cursor, temp);
61        temp = simd_andc(temp, groups.ends_7);
62        cursor = carryQ.BitBlock_advance_ci_co(cursor, 7);
63        groups.ends_8 = simd_and(cursor, temp);
64        temp = simd_andc(temp, groups.ends_8);
65        cursor = carryQ.BitBlock_advance_ci_co(cursor, 8);
66        groups.ends_9 = simd_and(cursor, temp);
67        temp = simd_andc(temp, groups.ends_9);
68        cursor = carryQ.BitBlock_advance_ci_co(cursor, 9);
69        groups.ends_10 = simd_and(cursor, temp);
70        temp = simd_andc(temp, groups.ends_10);
71        cursor = carryQ.BitBlock_advance_ci_co(cursor, 10);
72        groups.ends_11 = simd_and(cursor, temp);
73        temp = simd_andc(temp, groups.ends_11);
74        cursor = carryQ.BitBlock_advance_ci_co(cursor, 11);
75        groups.ends_12 = simd_and(cursor, temp);
76        temp = simd_andc(temp, groups.ends_12);
77        cursor = carryQ.BitBlock_advance_ci_co(cursor, 12);
78        groups.ends_13 = simd_and(cursor, temp);
79        temp = simd_andc(temp, groups.ends_13);
80        cursor = carryQ.BitBlock_advance_ci_co(cursor, 13);
81        groups.ends_14 = simd_and(cursor, temp);
82        temp = simd_andc(temp, groups.ends_14);
83        cursor = carryQ.BitBlock_advance_ci_co(cursor, 14);
84        groups.ends_15 = simd_and(cursor, temp);
85        temp = simd_andc(temp, groups.ends_15);
86        cursor = carryQ.BitBlock_advance_ci_co(cursor, 15);
87        groups.ends_16 = simd_and(cursor, temp);
88        temp = simd_andc(temp, groups.ends_16);
89        groups.ends_gte_17 = temp;
90        carryQ.CarryQ_Adjust(16);
91  }
92  void do_final_block(Markers & markers, Groups & groups, BitBlock EOF_mask) {
93                BitBlock cursor, temp;
94
95
96        groups.starts = markers.starts;
97        groups.ends = markers.ends;
98        cursor = groups.starts;
99        temp = groups.ends;
100        cursor = carryQ.BitBlock_advance_ci_co(cursor, 0);
101        groups.ends_1 = simd_and(cursor, temp);
102        temp = simd_andc(temp, groups.ends_1);
103        cursor = carryQ.BitBlock_advance_ci_co(cursor, 1);
104        groups.ends_2 = simd_and(cursor, temp);
105        temp = simd_andc(temp, groups.ends_2);
106        cursor = carryQ.BitBlock_advance_ci_co(cursor, 2);
107        groups.ends_3 = simd_and(cursor, temp);
108        temp = simd_andc(temp, groups.ends_3);
109        cursor = carryQ.BitBlock_advance_ci_co(cursor, 3);
110        groups.ends_4 = simd_and(cursor, temp);
111        temp = simd_andc(temp, groups.ends_4);
112        cursor = carryQ.BitBlock_advance_ci_co(cursor, 4);
113        groups.ends_5 = simd_and(cursor, temp);
114        temp = simd_andc(temp, groups.ends_5);
115        cursor = carryQ.BitBlock_advance_ci_co(cursor, 5);
116        groups.ends_6 = simd_and(cursor, temp);
117        temp = simd_andc(temp, groups.ends_6);
118        cursor = carryQ.BitBlock_advance_ci_co(cursor, 6);
119        groups.ends_7 = simd_and(cursor, temp);
120        temp = simd_andc(temp, groups.ends_7);
121        cursor = carryQ.BitBlock_advance_ci_co(cursor, 7);
122        groups.ends_8 = simd_and(cursor, temp);
123        temp = simd_andc(temp, groups.ends_8);
124        cursor = carryQ.BitBlock_advance_ci_co(cursor, 8);
125        groups.ends_9 = simd_and(cursor, temp);
126        temp = simd_andc(temp, groups.ends_9);
127        cursor = carryQ.BitBlock_advance_ci_co(cursor, 9);
128        groups.ends_10 = simd_and(cursor, temp);
129        temp = simd_andc(temp, groups.ends_10);
130        cursor = carryQ.BitBlock_advance_ci_co(cursor, 10);
131        groups.ends_11 = simd_and(cursor, temp);
132        temp = simd_andc(temp, groups.ends_11);
133        cursor = carryQ.BitBlock_advance_ci_co(cursor, 11);
134        groups.ends_12 = simd_and(cursor, temp);
135        temp = simd_andc(temp, groups.ends_12);
136        cursor = carryQ.BitBlock_advance_ci_co(cursor, 12);
137        groups.ends_13 = simd_and(cursor, temp);
138        temp = simd_andc(temp, groups.ends_13);
139        cursor = carryQ.BitBlock_advance_ci_co(cursor, 13);
140        groups.ends_14 = simd_and(cursor, temp);
141        temp = simd_andc(temp, groups.ends_14);
142        cursor = carryQ.BitBlock_advance_ci_co(cursor, 14);
143        groups.ends_15 = simd_and(cursor, temp);
144        temp = simd_andc(temp, groups.ends_15);
145        cursor = carryQ.BitBlock_advance_ci_co(cursor, 15);
146        groups.ends_16 = simd_and(cursor, temp);
147        temp = simd_andc(temp, groups.ends_16);
148        groups.ends_gte_17 = temp;
149  }
150  void do_segment(Markers markers[], Groups groups[], int segment_blocks) {
151  int i;
152  for (i = 0; i < segment_blocks; i++)
153    do_block(markers[i], groups[i]);
154  }
155  CarryArray<16> carryQ;
156  };
157
158
159// GENERATED
160  Gen_lgth_groups gen_lgth_groups;
161
162
163static IDISA_ALWAYS_INLINE void identity_group_do_block(Markers & markers, Groups & groups) {
164        // GENERATED
165       
166  gen_lgth_groups.do_block(markers, groups);
167}
168
169static IDISA_ALWAYS_INLINE void identity_group_do_final_block(Markers & markers, Groups & groups, BitBlock & EOF_mask) {
170        // GENERATED
171       
172  gen_lgth_groups.do_final_block(markers, groups, EOF_mask);
173}
174
175#endif // ID_GROUP_STRMS_TEMPLATE_HPP
Note: See TracBrowser for help on using the repository browser.