Changes between Version 11 and Version 12 of user_applications
- Timestamp:
- Oct 16, 2015, 1:57:52 PM (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
user_applications
v11 v12 156 156 157 157 This multi-threaded application emulates a network processing application such as an 158 ethernet router. All communications between threads use the MWMR ( Multi-Writer/Multi-Reader) channelsmiddleware.158 ethernet router. All communications between threads use the MWMR (multi-writer/multi-reader) middleware. 159 159 The application is described as a TCG (Task and communication Graph) : 160 * The number of thread Nis (x_size*y_size*nprocs): nprocs threads per clusters.160 * The number N of thread is (x_size*y_size*nprocs): nprocs threads per clusters. 161 161 * There is one producer() thread, one consumer() thread, and N-2 compute() threads. 162 162 * The number M of MWMR channels is (2 * x_size * y_size) : one input and one output channel per cluster. 163 163 164 164 It that can run on a multi-processors, multi-clusters architecture, with one thread per processor. 165 In this implementation, only integer token are transfered between threads, but they can be interpreted as job descriptors:166 * The main() thread, running on P[0,0,0], makes the initializations, and laughthe N other threads, and exit.165 In this implementation, only integer token are transfered between threads, but each token can be interpreted as a job descriptor: 166 * The main() thread, running on P[0,0,0], makes the initializations, launches the N other threads, and exit. 167 167 * The producer() thread, running on P[0,0,0] try to write continuously tokens into the M distributed input channels using non-blocking write function. 168 168 * The consumer() thread, running on P[0,0,1] try to read continuously tokens from the M distributed output channels, using a non-blocking read function. 169 * The N-2 compute() threads running on all other processors are reading token from the local input channel, and writing token to the local output channel, after a random delay emulating a variable processing time.169 * The N-2 compute() threads running on all other processors are continuously reading token from the local input channel, and writing the same token to the local output channel, after a random delay emulating a variable processing time. They use blocking access functions. 170 170 171 171 It require one TTY terminal shared by all threads.