Changeset 252 for trunk/softs
- Timestamp:
- Aug 16, 2012, 2:28:51 PM (12 years ago)
- Location:
- trunk/softs/soft_filter_giet
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/softs/soft_filter_giet/ldscript
r248 r252 10 10 peripherals are not present in the architecture */ 11 11 12 NB_CLUSTERS 13 NB_PROCS 14 NB_TASKS 15 NB_TIMERS 16 NB_LOCKS 12 NB_CLUSTERS = 4; /* number of clusters */ 13 NB_PROCS = 4; /* number of processors per cluster */ 14 NB_TASKS = 1; /* number of tasks per processor */ 15 NB_TIMERS = 1; /* max number of timers per processor */ 16 NB_LOCKS = 8; /* number of spin_locks */ 17 17 18 18 /* definition of the base address for all segments -
trunk/softs/soft_filter_giet/main.c
r248 r252 16 16 #define FRAME_SIZE ((NB_PIXELS) * (PIXEL_SIZE)) 17 17 18 #define PRINTF(...) ({ if (proc_id == 1) { tty_printf(__VA_ARGS__); } })18 #define PRINTF(...) ({ if (proc_id == 0) { tty_printf(__VA_ARGS__); } }) 19 19 20 20 #define TA(c,l,p) (A[c][((NP) * (l)) + (p)]) … … 116 116 PRINTF("\n*** Processor %d entering main at cycle %d ***\n\n", proc_id, proctime()); 117 117 118 //*(unsigned int *) 0x60000000 = *(unsigned int *) 0x70000000;119 //PRINTF("apres acces illegal\n");120 118 121 119 ///////////////////////// … … 129 127 } 130 128 129 //////////////////////////////////////////////////////////////////////// 130 // Warning: NB_CLUSTERS must be at least 4 because of the heap size; // 131 // if there are less clusters, the heap mixes with the stack // 132 // (the total heap size must be at least 0x01000000) // 133 //////////////////////////////////////////////////////////////////////// 131 134 if ((nclusters != 4) && (nclusters != 8) && (nclusters != 16) && 132 135 (nclusters != 32) && (nclusters != 64) && (nclusters !=128) && (nclusters != 256)){ … … 178 181 for (c = 0; c < nclusters; c++){ 179 182 unsigned int offset = base + increment * c; 180 A[c] = (unsigned short *) (offset 183 A[c] = (unsigned short *) (offset); 181 184 B[c] = (int *) (offset + frame_size * 1 / nclusters); // We increment by 2 * frame_size 182 185 C[c] = (int *) (offset + frame_size * 3 / nclusters); // because sizeof(int) = 2*sizeof(short) … … 426 429 TZ(cluster_id,l,p) = (unsigned char) (((TD(cluster_id,l,p) + TC(cluster_id,l,p)) >> 8) & 0xFF); 427 430 } 428 fb_sync_write(NP * (cluster_id * lines_per_cluster + l), &TZ(cluster_id,l,0), NP); 429 } 430 431 #if 0 432 for (l = first; l < last; l++){ 433 for (p = 0; p < NP; p++){ 434 TA(cluster_id, l, p) = (unsigned char) ((TA(cluster_id, l, p) >> 8) & 0xFF); 435 } 436 fb_write(NP * (cluster_id * lines_per_cluster + l), &TA(cluster_id,l,0), NP); 437 } 438 #endif 431 fb_write(NP * (cluster_id * lines_per_cluster + l), &TZ(cluster_id,l,0), NP); 432 } 439 433 440 434 date = proctime();
Note: See TracChangeset
for help on using the changeset viewer.