Changeset 468 for trunk/platforms/tsar_generic_iob/top.cpp
- Timestamp:
- Jul 24, 2013, 8:47:40 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/platforms/tsar_generic_iob/top.cpp
r450 r468 802 802 // Horizontal inter-clusters INT network DSPIN 803 803 DspinSignals<dspin_int_cmd_width>*** signal_dspin_int_cmd_h_inc = 804 alloc_elems<DspinSignals<dspin_int_cmd_width> >("signal_dspin_int_cmd_h_inc", XMAX-1, YMAX, 2);804 alloc_elems<DspinSignals<dspin_int_cmd_width> >("signal_dspin_int_cmd_h_inc", XMAX-1, YMAX, 3); 805 805 DspinSignals<dspin_int_cmd_width>*** signal_dspin_int_cmd_h_dec = 806 alloc_elems<DspinSignals<dspin_int_cmd_width> >("signal_dspin_int_cmd_h_dec", XMAX-1, YMAX, 2);806 alloc_elems<DspinSignals<dspin_int_cmd_width> >("signal_dspin_int_cmd_h_dec", XMAX-1, YMAX, 3); 807 807 DspinSignals<dspin_int_rsp_width>*** signal_dspin_int_rsp_h_inc = 808 808 alloc_elems<DspinSignals<dspin_int_rsp_width> >("signal_dspin_int_rsp_h_inc", XMAX-1, YMAX, 2); … … 812 812 // Vertical inter-clusters INT network DSPIN 813 813 DspinSignals<dspin_int_cmd_width>*** signal_dspin_int_cmd_v_inc = 814 alloc_elems<DspinSignals<dspin_int_cmd_width> >("signal_dspin_int_cmd_v_inc", XMAX, YMAX-1, 2);814 alloc_elems<DspinSignals<dspin_int_cmd_width> >("signal_dspin_int_cmd_v_inc", XMAX, YMAX-1, 3); 815 815 DspinSignals<dspin_int_cmd_width>*** signal_dspin_int_cmd_v_dec = 816 alloc_elems<DspinSignals<dspin_int_cmd_width> >("signal_dspin_int_cmd_v_dec", XMAX, YMAX-1, 2);816 alloc_elems<DspinSignals<dspin_int_cmd_width> >("signal_dspin_int_cmd_v_dec", XMAX, YMAX-1, 3); 817 817 DspinSignals<dspin_int_rsp_width>*** signal_dspin_int_rsp_v_inc = 818 818 alloc_elems<DspinSignals<dspin_int_rsp_width> >("signal_dspin_int_rsp_v_inc", XMAX, YMAX-1, 2); … … 822 822 // Mesh boundaries INT network DSPIN 823 823 DspinSignals<dspin_int_cmd_width>**** signal_dspin_false_int_cmd_in = 824 alloc_elems<DspinSignals<dspin_int_cmd_width> >("signal_dspin_false_int_cmd_in", XMAX, YMAX, 2, 4);824 alloc_elems<DspinSignals<dspin_int_cmd_width> >("signal_dspin_false_int_cmd_in", XMAX, YMAX, 4, 3); 825 825 DspinSignals<dspin_int_cmd_width>**** signal_dspin_false_int_cmd_out = 826 alloc_elems<DspinSignals<dspin_int_cmd_width> >("signal_dspin_false_int_cmd_out", XMAX, YMAX, 2, 4);826 alloc_elems<DspinSignals<dspin_int_cmd_width> >("signal_dspin_false_int_cmd_out", XMAX, YMAX, 4, 3); 827 827 DspinSignals<dspin_int_rsp_width>**** signal_dspin_false_int_rsp_in = 828 alloc_elems<DspinSignals<dspin_int_rsp_width> >("signal_dspin_false_int_rsp_in", XMAX, YMAX, 2, 4);828 alloc_elems<DspinSignals<dspin_int_rsp_width> >("signal_dspin_false_int_rsp_in", XMAX, YMAX, 4, 2); 829 829 DspinSignals<dspin_int_rsp_width>**** signal_dspin_false_int_rsp_out = 830 alloc_elems<DspinSignals<dspin_int_rsp_width> >("signal_dspin_false_int_rsp_out", XMAX, YMAX, 2, 4);830 alloc_elems<DspinSignals<dspin_int_rsp_width> >("signal_dspin_false_int_rsp_out", XMAX, YMAX, 4, 2); 831 831 832 832 … … 1152 1152 for (size_t y = 0; y < YMAX; y++) 1153 1153 { 1154 for (size_t k = 0; k < 3; k++) 1155 { 1156 clusters[x][y]->p_dspin_int_cmd_out[EAST][k] (signal_dspin_int_cmd_h_inc[x][y][k]); 1157 clusters[x+1][y]->p_dspin_int_cmd_in[WEST][k] (signal_dspin_int_cmd_h_inc[x][y][k]); 1158 clusters[x][y]->p_dspin_int_cmd_in[EAST][k] (signal_dspin_int_cmd_h_dec[x][y][k]); 1159 clusters[x+1][y]->p_dspin_int_cmd_out[WEST][k] (signal_dspin_int_cmd_h_dec[x][y][k]); 1160 } 1161 1154 1162 for (size_t k = 0; k < 2; k++) 1155 1163 { 1156 clusters[x][y]->p_dspin_int_cmd_out[k][EAST] (signal_dspin_int_cmd_h_inc[x][y][k]); 1157 clusters[x+1][y]->p_dspin_int_cmd_in[k][WEST] (signal_dspin_int_cmd_h_inc[x][y][k]); 1158 clusters[x][y]->p_dspin_int_cmd_in[k][EAST] (signal_dspin_int_cmd_h_dec[x][y][k]); 1159 clusters[x+1][y]->p_dspin_int_cmd_out[k][WEST] (signal_dspin_int_cmd_h_dec[x][y][k]); 1160 clusters[x][y]->p_dspin_int_rsp_out[k][EAST] (signal_dspin_int_rsp_h_inc[x][y][k]); 1161 clusters[x+1][y]->p_dspin_int_rsp_in[k][WEST] (signal_dspin_int_rsp_h_inc[x][y][k]); 1162 clusters[x][y]->p_dspin_int_rsp_in[k][EAST] (signal_dspin_int_rsp_h_dec[x][y][k]); 1163 clusters[x+1][y]->p_dspin_int_rsp_out[k][WEST] (signal_dspin_int_rsp_h_dec[x][y][k]); 1164 clusters[x][y]->p_dspin_int_rsp_out[EAST][k] (signal_dspin_int_rsp_h_inc[x][y][k]); 1165 clusters[x+1][y]->p_dspin_int_rsp_in[WEST][k] (signal_dspin_int_rsp_h_inc[x][y][k]); 1166 clusters[x][y]->p_dspin_int_rsp_in[EAST][k] (signal_dspin_int_rsp_h_dec[x][y][k]); 1167 clusters[x+1][y]->p_dspin_int_rsp_out[WEST][k] (signal_dspin_int_rsp_h_dec[x][y][k]); 1164 1168 } 1165 1169 … … 1185 1189 for (size_t x = 0; x < XMAX; x++) 1186 1190 { 1191 for (size_t k = 0; k < 3; k++) 1192 { 1193 clusters[x][y]->p_dspin_int_cmd_out[NORTH][k] (signal_dspin_int_cmd_v_inc[x][y][k]); 1194 clusters[x][y+1]->p_dspin_int_cmd_in[SOUTH][k] (signal_dspin_int_cmd_v_inc[x][y][k]); 1195 clusters[x][y]->p_dspin_int_cmd_in[NORTH][k] (signal_dspin_int_cmd_v_dec[x][y][k]); 1196 clusters[x][y+1]->p_dspin_int_cmd_out[SOUTH][k] (signal_dspin_int_cmd_v_dec[x][y][k]); 1197 } 1198 1187 1199 for (size_t k = 0; k < 2; k++) 1188 1200 { 1189 clusters[x][y]->p_dspin_int_cmd_out[k][NORTH] (signal_dspin_int_cmd_v_inc[x][y][k]); 1190 clusters[x][y+1]->p_dspin_int_cmd_in[k][SOUTH] (signal_dspin_int_cmd_v_inc[x][y][k]); 1191 clusters[x][y]->p_dspin_int_cmd_in[k][NORTH] (signal_dspin_int_cmd_v_dec[x][y][k]); 1192 clusters[x][y+1]->p_dspin_int_cmd_out[k][SOUTH] (signal_dspin_int_cmd_v_dec[x][y][k]); 1193 clusters[x][y]->p_dspin_int_rsp_out[k][NORTH] (signal_dspin_int_rsp_v_inc[x][y][k]); 1194 clusters[x][y+1]->p_dspin_int_rsp_in[k][SOUTH] (signal_dspin_int_rsp_v_inc[x][y][k]); 1195 clusters[x][y]->p_dspin_int_rsp_in[k][NORTH] (signal_dspin_int_rsp_v_dec[x][y][k]); 1196 clusters[x][y+1]->p_dspin_int_rsp_out[k][SOUTH] (signal_dspin_int_rsp_v_dec[x][y][k]); 1201 clusters[x][y]->p_dspin_int_rsp_out[NORTH][k] (signal_dspin_int_rsp_v_inc[x][y][k]); 1202 clusters[x][y+1]->p_dspin_int_rsp_in[SOUTH][k] (signal_dspin_int_rsp_v_inc[x][y][k]); 1203 clusters[x][y]->p_dspin_int_rsp_in[NORTH][k] (signal_dspin_int_rsp_v_dec[x][y][k]); 1204 clusters[x][y+1]->p_dspin_int_rsp_out[SOUTH][k] (signal_dspin_int_rsp_v_dec[x][y][k]); 1197 1205 } 1198 1206 … … 1214 1222 for (size_t y = 0; y < YMAX; y++) 1215 1223 { 1224 for (size_t k = 0; k < 3; k++) 1225 { 1226 clusters[0][y]->p_dspin_int_cmd_in[WEST][k] (signal_dspin_false_int_cmd_in[0][y][WEST][k]); 1227 clusters[0][y]->p_dspin_int_cmd_out[WEST][k] (signal_dspin_false_int_cmd_out[0][y][WEST][k]); 1228 clusters[XMAX-1][y]->p_dspin_int_cmd_in[EAST][k] (signal_dspin_false_int_cmd_in[XMAX-1][y][EAST][k]); 1229 clusters[XMAX-1][y]->p_dspin_int_cmd_out[EAST][k] (signal_dspin_false_int_cmd_out[XMAX-1][y][EAST][k]); 1230 } 1231 1216 1232 for (size_t k = 0; k < 2; k++) 1217 1233 { 1218 clusters[0][y]->p_dspin_int_cmd_in[k][WEST] (signal_dspin_false_int_cmd_in[0][y][k][WEST]); 1219 clusters[0][y]->p_dspin_int_cmd_out[k][WEST] (signal_dspin_false_int_cmd_out[0][y][k][WEST]); 1220 clusters[0][y]->p_dspin_int_rsp_in[k][WEST] (signal_dspin_false_int_rsp_in[0][y][k][WEST]); 1221 clusters[0][y]->p_dspin_int_rsp_out[k][WEST] (signal_dspin_false_int_rsp_out[0][y][k][WEST]); 1222 1223 clusters[XMAX-1][y]->p_dspin_int_cmd_in[k][EAST] (signal_dspin_false_int_cmd_in[XMAX-1][y][k][EAST]); 1224 clusters[XMAX-1][y]->p_dspin_int_cmd_out[k][EAST] (signal_dspin_false_int_cmd_out[XMAX-1][y][k][EAST]); 1225 clusters[XMAX-1][y]->p_dspin_int_rsp_in[k][EAST] (signal_dspin_false_int_rsp_in[XMAX-1][y][k][EAST]); 1226 clusters[XMAX-1][y]->p_dspin_int_rsp_out[k][EAST] (signal_dspin_false_int_rsp_out[XMAX-1][y][k][EAST]); 1234 clusters[0][y]->p_dspin_int_rsp_in[WEST][k] (signal_dspin_false_int_rsp_in[0][y][WEST][k]); 1235 clusters[0][y]->p_dspin_int_rsp_out[WEST][k] (signal_dspin_false_int_rsp_out[0][y][WEST][k]); 1236 clusters[XMAX-1][y]->p_dspin_int_rsp_in[EAST][k] (signal_dspin_false_int_rsp_in[XMAX-1][y][EAST][k]); 1237 clusters[XMAX-1][y]->p_dspin_int_rsp_out[EAST][k] (signal_dspin_false_int_rsp_out[XMAX-1][y][EAST][k]); 1227 1238 } 1228 1239 … … 1243 1254 for (size_t x = 0; x < XMAX; x++) 1244 1255 { 1256 for (size_t k = 0; k < 3; k++) 1257 { 1258 clusters[x][0]->p_dspin_int_cmd_in[SOUTH][k] (signal_dspin_false_int_cmd_in[x][0][SOUTH][k]); 1259 clusters[x][0]->p_dspin_int_cmd_out[SOUTH][k] (signal_dspin_false_int_cmd_out[x][0][SOUTH][k]); 1260 clusters[x][YMAX-1]->p_dspin_int_cmd_in[NORTH][k] (signal_dspin_false_int_cmd_in[x][YMAX-1][NORTH][k]); 1261 clusters[x][YMAX-1]->p_dspin_int_cmd_out[NORTH][k] (signal_dspin_false_int_cmd_out[x][YMAX-1][NORTH][k]); 1262 } 1263 1245 1264 for (size_t k = 0; k < 2; k++) 1246 1265 { 1247 clusters[x][0]->p_dspin_int_cmd_in[k][SOUTH] (signal_dspin_false_int_cmd_in[x][0][k][SOUTH]); 1248 clusters[x][0]->p_dspin_int_cmd_out[k][SOUTH] (signal_dspin_false_int_cmd_out[x][0][k][SOUTH]); 1249 clusters[x][0]->p_dspin_int_rsp_in[k][SOUTH] (signal_dspin_false_int_rsp_in[x][0][k][SOUTH]); 1250 clusters[x][0]->p_dspin_int_rsp_out[k][SOUTH] (signal_dspin_false_int_rsp_out[x][0][k][SOUTH]); 1251 1252 clusters[x][YMAX-1]->p_dspin_int_cmd_in[k][NORTH] (signal_dspin_false_int_cmd_in[x][YMAX-1][k][NORTH]); 1253 clusters[x][YMAX-1]->p_dspin_int_cmd_out[k][NORTH] (signal_dspin_false_int_cmd_out[x][YMAX-1][k][NORTH]); 1254 clusters[x][YMAX-1]->p_dspin_int_rsp_in[k][NORTH] (signal_dspin_false_int_rsp_in[x][YMAX-1][k][NORTH]); 1255 clusters[x][YMAX-1]->p_dspin_int_rsp_out[k][NORTH] (signal_dspin_false_int_rsp_out[x][YMAX-1][k][NORTH]); 1266 clusters[x][0]->p_dspin_int_rsp_in[SOUTH][k] (signal_dspin_false_int_rsp_in[x][0][SOUTH][k]); 1267 clusters[x][0]->p_dspin_int_rsp_out[SOUTH][k] (signal_dspin_false_int_rsp_out[x][0][SOUTH][k]); 1268 clusters[x][YMAX-1]->p_dspin_int_rsp_in[NORTH][k] (signal_dspin_false_int_rsp_in[x][YMAX-1][NORTH][k]); 1269 clusters[x][YMAX-1]->p_dspin_int_rsp_out[NORTH][k] (signal_dspin_false_int_rsp_out[x][YMAX-1][NORTH][k]); 1256 1270 } 1257 1271 … … 1283 1297 for (size_t a = 0; a < 4; a++) 1284 1298 { 1299 for (size_t k = 0; k < 3; k++) 1300 { 1301 signal_dspin_false_int_cmd_in[x][y][a][k].write = false; 1302 signal_dspin_false_int_cmd_in[x][y][a][k].read = true; 1303 signal_dspin_false_int_cmd_out[x][y][a][k].write = false; 1304 signal_dspin_false_int_cmd_out[x][y][a][k].read = true; 1305 } 1306 1285 1307 for (size_t k = 0; k < 2; k++) 1286 1308 { 1287 signal_dspin_false_int_cmd_in[x][y][k][a].write = false; 1288 signal_dspin_false_int_cmd_in[x][y][k][a].read = true; 1289 signal_dspin_false_int_cmd_out[x][y][k][a].write = false; 1290 signal_dspin_false_int_cmd_out[x][y][k][a].read = true; 1291 1292 signal_dspin_false_int_rsp_in[x][y][k][a].write = false; 1293 signal_dspin_false_int_rsp_in[x][y][k][a].read = true; 1294 signal_dspin_false_int_rsp_out[x][y][k][a].write = false; 1295 signal_dspin_false_int_rsp_out[x][y][k][a].read = true; 1309 signal_dspin_false_int_rsp_in[x][y][a][k].write = false; 1310 signal_dspin_false_int_rsp_in[x][y][a][k].read = true; 1311 signal_dspin_false_int_rsp_out[x][y][a][k].write = false; 1312 signal_dspin_false_int_rsp_out[x][y][a][k].read = true; 1296 1313 } 1297 1314
Note: See TracChangeset
for help on using the changeset viewer.