2 \documentclass[10pt,conference,compsocconf]{IEEEtran}
5 %\documentclass[conference,compsoc,a4paper,onecolumn]{IEEEtran}
6 %\documentclass[compsoc,a4paper,oneside]{IEEEtran}
8 \usepackage[T1]{fontenc}
10 \usepackage[utf8x]{inputenc}
14 %\usepackage[Glenn]{fncychap}
18 %\usepackage{graphicx}
20 % Definition des marges
22 %\setpapersize[portrait]{A4}
24 \usepackage[english]{babel}
25 % Extension pour les graphiques EPS
26 %\usepackage[dvips]{graphicx}
27 \usepackage[pdftex,final]{graphicx}
28 % Extension pour les liens intra-documents (tagged PDF)
29 % et l'affichage correct des URL (commande \url{http://example.com})
31 % Extension pour que plus de titres apparaissent dans la table des matieres
32 % (table des matieres, bibliographie, index).
33 %\usepackage{tocbibind}
34 %\newcommand{\tabledesmatieres}{
35 % \setlength{\parskip}{0ex} % suppression de l'espace entre les paragraphes
39 %\NoAutoSpaceBeforeFDP
40 %\author{Sébastien Miquée}
42 \usepackage[ruled,vlined]{algorithm2e}
45 \newcommand{\myitemize}[1]
53 \usepackage[pdftex]{graphicx}
54 \DeclareGraphicsExtensions{.pdf,.jpeg,.png}
58 % *** PDF, URL AND HYPERLINK PACKAGES ***
63 \title{Mapping Asynchronous Iterative Applications on Heterogeneous
64 Distributed Architectures}
67 \IEEEauthorblockN{Raphaël Couturier \hspace{10pt} David Laiymani
68 \hspace{10pt} Sébastien Miquée}
70 \IEEEauthorblockA{Laboratoire d'Informatique de Franche-Comté
72 %University of Franche-Comté\\
73 IUT de Belfort-Montbéliard,2 Rue Engel Gros, BP 27, 90016 Belfort,
75 % Tel.: +33-3-84587782 \hspace{20pt} Fax: +33-3-84587781\\
77 \{raphael.couturier,david.laiymani,sebastien.miquee\}@univ-fcomte.fr}
79 \thanks{This work was supported by the European Interreg IV From-P2P project
80 and the region of Franche-Comté}
83 %% Permet de réactiver le \thanks
84 \IEEEoverridecommandlockouts
89 %% left, top, right, bottom
90 %\setmargrb{20mm}{15mm}{20mm}{15mm}
92 \IEEEcompsoctitleabstractindextext
98 To design parallel numerical algorithms on large scale distributed
99 and heterogeneous platforms, the asynchronous iteration model (AIAC)
100 may be an efficient solution. This class of algorithm is very
101 suitable since it enables communication/computation overlapping and
102 it suppresses all synchronizations between computation nodes. Since
103 target architectures are composed of more than one thousand
104 heterogeneous nodes connected through heterogeneous networks, the
105 need for mapping algorithms is crucial. In this paper, we propose a
106 new mapping algorithm dedicated to the AIAC model. To evaluate our
107 mapping algorithm we implemented it in the JaceP2P programming and
108 executing environment dedicated to AIAC applications and we
109 conducted a set of experiments on the Grid'5000 testbed. Results
110 are very encouraging and show that the use of our algorithm brings
111 an important gain in term of execution time (about $40\%$).
114 % than 700 computing cores and with a real and typical AIAC
115 % application based on the NAS parallel benchmarks.
117 % To design parallel and distributed applications on heterogeneous
118 % distributed architectures, the asynchronous iteration model may be
119 % an efficient solution. Such architectures contain various computing
120 % nodes connected by heterogeneous links. Nowadays, these
121 % architectures offer users too many computing nodes as they need, so
122 % a choice should be done, which is called ``tasks mapping''. In this
123 % paper we propose a comparison between different mapping algorithms,
124 % in order to evaluate mapping needs of the asynchronous iteration
125 % model on this kind of architectures. To do our experiments we used a
126 % middleware, JaceP2P-V2, which allows users to design asynchronous
127 % iterative applications and execute them on distributed
128 % architectures, in which we added a mapping library.\\
132 Mapping algorithms; Distributed clusters; Parallel iterative
133 asynchronous algorithms; Heterogeneous distributed architectures.
139 \IEEEpeerreviewmaketitle
142 % Mapping algorithms, Distributed clusters, Parallel iterative
143 % asynchronous algorithms, Heterogeneous architectures.
146 \section{Introduction}
149 Nowadays scientists of many domains, like climatic simulation or
150 biological research, need large and powerful architectures to compute
151 their large applications. Distributed clusters architectures, which
152 are part of the grid architecture, are one of the best architectures
153 used to solve such applications with an acceptable execution
154 time. These architectures provide a lot of heterogeneous computing
155 nodes interconnected by a high performance network, but even with the
156 greatest efforts of their maintainers, there are latency and
157 computation capacity differences between clusters of each site.
159 In order to efficiently use this massive distributed computation
160 power, numerous numerical algorithms have been modified. These
161 algorithms can be broadly classified into two categories. First,
162 \textit{direct methods}, which give the exact solution of the problem
163 using a finite number of operations (e.g. Cholesky,
164 LU\dots). These methods cannot be applied to all kinds of
165 numerical problems. Generally, they are not well adapted to very
166 large problems. Then \textit{iterative methods}, that repeat the same
167 instructions until a desired approximation of the solution is reached
168 -- we say that the algorithm has converged. Iterative algorithms
169 constitute the only known approach to solving some kinds of problems
170 and are easier to parallelize than direct methods. The Jacobi or
171 Conjugate Gradient algorithms are examples of such iterative
178 % \includegraphics[width=7.4cm]{images/ISCA}
179 % \caption{Two processors computing in the Synchronous Iteration - Asynchronous Communication (SIAC) model}
183 In the rest of this paper we only focus on iterative methods. Now to
184 parallelize this kind of algorithm, two classes of parallel iterative
185 models can be described. In the \textit{synchronous iteration model}
186 after each iteration a node sends its results to its neighbors and
187 waits for the reception of all dependency messages from them
188 to start the next iteration. This results in large idle times and is
189 equivalent to a global synchronization of nodes after each
190 iteration. These synchronizations can strongly penalize the overall
191 performance of the application particularly in case of large scale
192 platforms with high latency network. Furthermore, if a message is
193 lost, its receiver will wait forever for this message and the
194 application will be blocked. In the same way, if a machine fails, all
195 the computation will be blocked.
199 \includegraphics[width=7.4cm]{images/IACA}
200 \caption{Two processors computing in the Asynchronous Iteration - Asynchronous Communication (AIAC) model}
205 In the \textit{asynchronous iteration model} a node sends its
206 results to its neighbors and starts immediately the next iteration
207 with the last received data. These data could be data from previous
208 iterations, because the most recent data has not arrived in time or
209 neighbors have not finish their current iteration. The receiving and
210 sending mechanisms are asynchronous and nodes do not have to wait for
211 the reception of dependency messages from their
212 neighbors. Consequently, there is no more idle time between two
213 iterations. Furthermore, this model is tolerant to messages loss and
214 even if a node dies, the remaining nodes continue the computation,
215 with the last data the failed node sent. Unfortunately, the
216 asynchronous iteration model generally requires more iterations than
217 the synchronous one to converge to the solution.
219 This class of algorithms is very suitable in a distributed clusters
220 computing context because it suppresses all synchronizations between
221 computation nodes, tolerates messages loss and enables the overlapping
222 of communications by computations. Interested readers might consult
223 \cite{book_raph} for a precise classification and comparison of
224 parallel iterative algorithms. In this way, several experiments
225 \cite{book_raph} show the relevance of the AIAC algorithms in the
226 context of distributed clusters with high latency between
227 clusters. These works underline the good adaptability of AIAC
228 algorithms to network and processor heterogeneity.
230 As we aim to solve very large problems on heterogeneous distributed
231 architectures, in the rest of this study we only focus on the
232 asynchronous iteration model. In order to efficiently use such
233 algorithms on distributed clusters architectures, it is essential to
234 map the application's tasks to the best sub-sets of nodes of the
235 target architecture. This mapping procedure must take into account
236 parameters such as network heterogeneity, computing nodes
237 heterogeneity and tasks heterogeneity in order to minimize the overall
238 execution time of the application.
240 %sets of computing nodes, which can improve applications execution
241 %time. Indeed, as there are more available nodes as we need on such
242 %architectures, it is important to select appropriate computing nodes,
243 %due to their heterogeneity at computation power as well as relying
245 To the best of our knowledge, there exits no algorithm which
246 specifically addresses the mapping of AIAC applications on distributed
247 architectures. The aim of this paper is to propose a new mapping
248 algorithm dedicated to AIAC applications and to implement it into a
249 real large scale computing platform, JaceP2P-V2. Experiments conducted
250 on the Grid'5000 testbed with more than 400 computing cores show that
251 this new algorithm enhances the performance of JaceP2P-V2 by
252 about $40\%$ for a real and typical AIAC application.
254 %this mapping problem. Our aim is to evaluate the
255 %more common approaches to solve this problem, by using several mapping
256 %algorithms implemented in a real large scale computing platform,
257 %JaceP2P-V2, on a true distributed clusters architecture.\\
259 The rest of this paper is organized as follows. Section
260 \ref{sec:jacep2p} presents the JaceP2P-V2 middleware. We focus here on
261 one of the main drawbacks of this platform: its lack of an efficient
262 mapping strategy. Section \ref{sec:pb} presents our mapping problem
263 and quotes existing issues to address it. Section
264 \ref{sec:aiacmapping} describes the specificities of the AIAC model
265 and details the main solution we propose to address the AIAC mapping
266 problem. In section \ref{sec:expe} we describe the experiments we have
267 conducted, with their different components and results. These results
268 were conducted on the Grid'5000 testbed with more than 400 computing
269 cores and show an important gain (about $40\%$) of the overall
270 execution time for a typical AIAC application, i.e. based on the NAS
271 Parallel Benchmark. Finally, we give some concluding remarks and plan
272 our future work in section \ref{sec:conclu}.
278 JaceP2P-V2\cite{jaceP2P-v2} is a distributed platform implemented
279 using the Java programming language and dedicated to developing and
280 executing parallel iterative asynchronous applications. JaceP2P-V2
281 executes parallel iterative asynchronous applications with
282 dependencies between computing nodes. In addition, JaceP2P is fault
283 tolerant which allows it to execute parallel applications over
284 volatile environments and even for stable environments like local
285 clusters, it offers a safer and crash free platform. To our knowledge
286 this is the only platform dedicated to designing and executing AIAC
289 %\subsection{Architecture}
290 %\label{sec:archijaceP2P}
292 %In this section we describe the JaceP2P-V2 environment.
294 %on Figure \ref{fig:jaceP2P-v2}, which shows
296 The JaceP2P-V2 architecture, is composed of three main entities:
301 % \includegraphics[width=7.4cm]{images/JACEP2P-V2}
302 % \caption{The JaceP2P-V2 architecture}
303 % \label{fig:jaceP2P-v2}
308 \item The first entity is the ``super-node''. %(represented by a big
309 %circle in Figure \ref{fig:jaceP2P-v2}).
310 Super-nodes form a circular network and store, in registers, the
311 identifiers of all the computing nodes that are connected to the
312 platform and that are not executing any application.
313 % Each super-node has a status table containing the
314 % number of connected computing nodes to each super-node and all the
315 % super-nodes share a ``token'' that is passed successively from a
316 % super-node to the next one. Once a super-node has the token, it
317 % computes the average number of computing nodes connected to a
318 % super-node ($avg$) using the status table. If $avg$ is lower than
319 % the number of computing nodes connected to it, then it sends the
320 % identifiers of the extra computing nodes to the super-nodes that
321 % have the number of computing nodes connected to them less than
322 % $avg$. If the number of computing nodes connected to it has changed,
323 % it broadcasts the information to all the super-nodes in the
324 % platform. Finally, it passes the token to the next super node. This
325 % distribution reduces the load of the super-nodes.
326 A super-node regularly receives heartbeat messages
328 % doted lines in Figure \ref{fig:jaceP2P-v2})
329 from the computing nodes connected to it. If a super-node does not
330 receive a heartbeat message from a computing node for a given period
331 of time, it declares that this computing node is dead and deletes
332 its identifier from the register.
334 \item The second entity is the ``spawner''.
335 %(represented by a square in
336 % Figure \ref{fig:jaceP2P-v2}).
337 When a user wants to execute a parallel application that requires
338 $N$ computing nodes, he or she launches a spawner. This one contacts
339 a super-node to reserve the $N$ computing nodes plus some extra
340 nodes. When it receives the list of nodes from the super-node, it
341 transforms the extra nodes into spawners (for fault tolerance and
342 scalability reasons) and stores the identifiers of the rest of the
343 nodes in its own register.
344 % Once the extra nodes are transformed into spawners, they
345 % form a circular network and they receive the register containing the
346 % identifiers of the computing nodes.
347 Then each spawner becomes
348 responsible for a subgroup of computing nodes, starts the tasks on
349 the computing nodes under its command and sends a specific register
352 % computing node receives a specific register that only contains the
353 % identifiers of the daemons it interacts with and that depends on the
354 % application being executed. These specific registers reduce the
355 % number of messages sent by the spawners to update the register of
356 % the daemons after a daemon crashes because usually a small number of
357 % daemons is affected by this crash.
358 % If the spawner receives a message from a computing node informing
359 % that one of its neighbors has failed, it fetches a new one from the
360 % super-node in order to replace the dead one. The spawner initializes
361 % the new daemon, which retrieves the last backup (see next paragraph)
362 % of the dead node and continues the computing task from that
365 \item The third entity is the ``daemon'', or the computing node.
366 % (represented in Figure \ref{fig:jaceP2P-v2} by a hashed small circle
367 % if it is idle and by a white small circle if it is executing an
369 Once launched, it connects to a super-node and waits for a task to
370 execute. Once they begin executing an application daemons form a
371 circular network which is only used in the failure detection
372 mechanism. Each daemon can communicate directly with the daemons
373 whose identifiers are in its register. At the end of a task, the
374 daemons reconnect to a super-node.
377 To be able to execute asynchronous iterative applications, JaceP2P-V2
378 has an asynchronous messaging mechanism and to resist daemons'
379 failures, it implements a distributed backup mechanism called the
380 uncoordinated distributed checkpointing. For more details on the
381 JaceP2P-V2 platform, interested readers can refer to \cite{jaceP2P-v2}.
383 % This method allows daemons to
384 % save their data on neighboring daemons without any user
385 % intervention. The asynchronous nature of the application allows two
386 % daemons to execute two different iterations, thus each daemon saves
387 % its status without synchronizing with other daemons. This
388 % decentralized procedure allows the platform to be very scalable, with
389 % no weak points and does not require a secure and stable station for
390 % backups. Moreover, since the AIAC model is tolerant to messages loss,
391 % if a daemon dies, the other computing nodes continue their tasks and
392 % are not affected by this failure.
393 % The application convergence detection is done by daemons, using the
394 % decentralized global convergence detection algorithm presented in
395 % \cite{conv_dec}. It consists of two phases: the detection phase and
396 % the verification phase. This algorithm aims to detect efficiently
397 % the global convergence of asynchronous iterative parallel algorithms
398 % on distributed architectures.
403 \subsubsection*{Benefits of mapping}
406 In the previously described JaceP2P-V2 environment there is no
407 effective mapping solution. Indeed, when a user wants to launch an
408 application, the spawner emits a request to the super-node, which is
409 in charge of available daemons. Basically, the super-node returns the
410 amount of requested computing nodes by choosing in its own list.
412 %if there are sufficient daemons connected on it, or in other
413 %super-nodes lists, in addition of its one.
414 In this method, the super-node only cares about the amount of
415 requested nodes and it returns in general nodes in the order of their
416 connection to the platform -- there is no specific selection.
417 Distributed architectures such as distributed clusters,
419 %on Figure \ref{fig:pbdistclust},
420 are often composed of heterogeneous
421 clusters linked via heterogeneous networks with high latencies and
422 bandwidths. As an example the Grid'5000\cite{g5k} testbed is composed
423 of 23 clusters spread over 9 sites. Those clusters are heterogeneous,
424 with computing powers starting from bi-cores at 2GHz to
425 bi-quad-cores at 2.83GHz with 2Gb of memory for the first one to 8Gb
426 for the second. Links relying clusters are 10Gb/s capable, but as many
427 researchers use this platform, high latencies appear in links between
429 %In the targeted architectures, which are distributed clusters, each
430 %cluster provides a fixed number of homogeneous computing nodes --
431 %computing nodes are heterogeneous from a cluster to another. Figure
432 %\ref{fig:pbdistclust} represents such an architecture, in which we can
433 %see different sites containing several heterogeneous clusters. Each
434 %cluster is relied by high speed network with clusters in the same site
435 %and in others. We note that the architecture may not be represented by
436 %a full connected graph, as some sites are not directly connected to
437 %some others. The Grid'5000 testbed, described in section
438 %\ref{sec:g5k}, is an example of such a distributed clusters
439 %architecture. Though there are efficient links relying each site, a
440 %residual latency continues to exist, at local clusters (in the same
441 %site) as well as distant clusters (from two distinct sites), and can
442 %penalize performance.
444 % \begin{figure}[ht!]
446 % \includegraphics[width=7.8cm]{images/dist_clust}
447 % \caption{A distributed clusters architecture}
448 % \label{fig:pbdistclust}
452 With such an architecture, it could be
453 efficient to assign tasks communicating with each other on the same
454 cluster, in order to improve communications. But, as we use very large
455 problems, it is quite impossible to find clusters containing as many
456 computing nodes as requested. So we have to dispatch tasks over
457 several clusters. That implies a need to deal with heterogeneity in clusters
458 computing power and heterogeneity in network. We should make a
459 trade-off between both components in order to take the best part
460 of each one to improve the overall performance.
462 %literature in high performance computing has broadly demonstrated the
463 %benefits of mapping solutions on the applications execution time.
465 In order to check if a tasks mapping algorithm would provide
466 performance improvement in the JaceP2P-V2 environment, we have evaluated
467 the contributions of a simple mapping algorithm, which is described in
468 section \ref{sec:sma}. These experiments used the NPB Kernel CG
469 application described in section \ref{sec:cg}, with two problem sizes
470 (the given problem sizes are the sides sizes of square matrices used)
471 and using a distributed clusters architecture composed of 102
472 computing nodes, representing 320 computing cores, spread over 5
473 clusters in 5 sites. The results of these experiments are given in
474 Table \ref{tab:benef}.
476 \renewcommand{\arraystretch}{1.5}
480 \begin{tabular}{|c|c|c|}
482 Problem size&$550,000$&$5,000,000$\\
484 Execution Time (without mapping)&141s&129s\\
485 Execution Time (with mapping)&97s&81s\\
487 Gains&$31\%$&$37\%$\\
490 \caption{Effects of a simple tasks
491 mapping algorithm on application's execution time}
496 As can be seen in Table \ref{tab:benef}, the effects of a
497 simple tasks mapping algorithm are significant.
498 %Moreover, we can see
499 %that are scalable with the application's size, which demonstrates the
500 %real needs of the platform for a such algorithm.
501 This encouraged us to look further for better task mapping
502 algorithms. In the next section, we describe the specificities of our
503 model and issues which can be exploited.
505 \section{Problem description}
508 % In this section we describe the AIAC mapping problem. We first
509 % formalize the different elements we should take into consideration:
510 % the application, the targeted architecture and the objectives
511 % functions of the mapping. We also give a state of the art about
512 % considered kinds of mapping algorithms.
514 \subsection{Model formalization}
517 % In this section the models of the applications and architectures we
518 % used are given, with the objectives functions of the mapping
521 \subsubsection{Application modeling}
522 \label{sec:pbmodelapp}
524 In high performance computing, when we want to improve the global
525 execution time of parallel applications we have to make an efficient
526 assignation of tasks to computing nodes. Usually, to assign tasks of
527 parallel applications to computing nodes, scheduling algorithms are
528 used. These algorithms often represent the application by a graph,
529 called DAG \cite{dag1,dag2,dag3,dag4} (Directed Acyclic Graph). In
530 this graph, each task is represented by a vertex which is relayed to
531 others by edges, which represent dependencies and communications
532 between tasks. This means that some tasks could not start before other
533 ones finish their computation and send their results. As discussed in
534 the introduction, in the AIAC model, there is no precedence between
537 Indeed, with the AIAC model, all tasks compute in parallel at the same
538 time. As communications are asynchronous, there is no synchronization
539 and no precedence. During an iteration, each task does its job and
540 sends results to its neighbors and continues with the next
541 iteration. If a task receives new data from its dependencies, it
542 includes them and the computation continues with these new data. If
543 not all dependencies data, or none, are received before starting the
544 computation of the next iteration, old data are used instead. Tasks
545 are not blocked on dependencies. Nevertheless regularly receiving new
546 data allows tasks to converge more quickly. So, it appears that DAG
547 are not appropriate to modeling AIAC applications. TIG\cite{tig1,
548 tig2} (Task Interaction Graph) are more appropriate.
549 %That is why we use the
550 %TIG\cite{tig1, tig2} (Task Interaction Graph) model instead of DAG,
551 %which allows to modeling application using tasks and their
552 %communication dependencies. Figure \ref{fig:tig} gives an example of a
557 \includegraphics[width=4cm]{images/tig}
558 \caption{An example of a TIG of a nine tasks application}
562 In the TIG model, a parallel program is represented by a graph , as
563 can be seen in Figure \ref{fig:tig}. This graph $GT(V,E)$, where $V =
564 \{V_1,V_2,\dots V_v\}$ is the set of $|V|$ vertices and $E \subset V
565 \times V$ is the set of undirectional edges. The vertices represent
566 tasks and the edges represent the mutual communication among tasks. A
567 function $ET : V \rightarrow R^+$ gives the computation cost of tasks
568 and $CT : E \rightarrow R^+$ gives the communication cost for message
569 passing on edges. We define $v = |V|$, $ET(V_i) = e_i$ and
570 $CT(V_i,V_j) = c_{ij}$. For example, in Figure \ref{fig:tig},
571 \mbox{$e_0$ = 10} and $c_{01} = 2$, $c_{03} = 2$ and $c_{04} = 2$.
572 Tasks in TIG exchange information during their execution and there is
573 no precedence relationship among tasks; each task cooperates with its
574 neighbors. This model is used to represent applications, where tasks
575 are considered to be executed simultaneously. Temporal dependencies in
576 the execution of tasks are not explicitly addressed: all the tasks are
577 considered simultaneously executable and communications can take place
578 at any time during the computation. That is why vertices and edges are
580 describing computational and communication costs.
584 \subsubsection{Architecture modeling}
585 \label{sec:pbmodelarchi}
587 As TIG models the application, we have to model the targeted
588 architecture. A distributed clusters architecture can be modeled by a
589 three-level-graph. The levels are \textit{architecture} (a), in our
590 study it is the Grid'5000 grid, \textit{cluster} (c) and computing
592 %Figure \ref{fig:pbdistclust} in section
593 %\ref{sec:benef} shows such a model.
594 Let $GG(N,L)$ be a graph
595 representing a distributed clusters architecture, where $N =
596 \{N_1,N_2,\dots N_n\}$ is the set of $|N|$ vertices and $L$ is the set
597 of undirectional edges. The vertices represent the computing nodes and
598 the edges represent the links between them. An edge $L_i \in L$ is an
599 unordered pair $(N_x,N_y) \in N$, representing a communication link
600 between nodes $N_x$ and $N_y$. Let be $|C|$ the number of clusters in the
601 architecture containing computing nodes. A function $WN : N
602 \rightarrow R^+$ gives the computational power of nodes and $WL : L
603 \rightarrow R^+$ gives the communication latency of links. We define
604 $WN(N_i) = wn_i$ and $WL(L_i,L_j) = wl_{ij}$.
606 An architecture with a three-level-graph is specified according as
607 follows. All computing nodes are in the same node level. When
608 computing nodes can communicate to one another with the same
609 communication latency, they can be grouped into the same cluster. In
610 addition, like in the Grid'5000 testbed, if computing nodes seemly
611 have the same computational power with a low communication latency, a
612 cluster of these nodes can be defined. All participating clusters,
613 including computing nodes, are in the same architecture level and
614 communicate through the architecture network.
618 \subsubsection{Mapping functions}
619 \label{sec:pbmodelmapping}
621 After having described the two graphs used to model the application
622 and the architecture, this section defines our objectives.
624 When a parallel application $App$, represented by a graph $GT$, is
625 mapped on a distributed clusters architecture, represented by a graph
626 $GG$, the execution time of the application, $ET(App)$, can be defined
627 as the execution time of the slowest task.
628 %In the AIAC model, tasks
629 %have, in general, seemly the same work and communication loads; so the
630 %difference on execution time depends on the executing machines.
631 Indeed an application ends when all the tasks have detected
632 convergence and have reached the desired approximation of the
633 solution, that is why the execution time of the application depends on
635 %, this converges last.
636 We define $ ET(App) = \max_{i=1 \dots v} ( ET(V_i) )$
639 % ET(App) = \max_{i=1 \dots v} ( ET(V_i) )
642 %$ET(V_s)$ is the execution time of the slowest task $V_s$. The
643 execution time of each task $i$ \mbox{($i=1 \dots v$)}, $ET(V_i)$ is
644 given by $ET(V_i) = \frac{e_i}{wn_i} + \sum_{j \in J} c_{ij} \cdot wl_{ij}$
648 % ET(V_i) = \frac{e_i}{wn_i} + \sum_{j \in J} c_{ij} \cdot wl_{ij}
651 where $e_i$ is the computational cost of $V_i$, $wn_i$ is the
652 computational power of the node $N_i$ on which $V_i$ is mapped, $J$
653 represents the neighbors set of $V_i$, $c_{ij}$ is the amount of
654 communications between $V_i$ and $V_j$, and $wl_{ij}$ is the link
655 latency between the computing nodes on which are mapped $V_i$ and
657 %Note that in the AIAC model, we only consider for $e_i$ the
658 %cost of an only one iteration, as we cannot determine in advance the
659 %amount of iterations a task should complete to converge.
660 We underline here that in the AIAC model, it is impossible to predict
661 the number of iterations of a task. So it is difficult to evaluate a
662 priori the cost $e_i$ of a task. In the remainder, we approximate
663 $e_i$ by the cost of one iteration.
665 The mapping problem is similar to the classical graph partitioning and
666 task assignment problem \cite{npcomp}, and is thus NP-complete.
668 %generalization of this problem by considering both heterogeneous tasks
669 %graph and architecture graph makes the problem more complex.
670 %The JaceP2P-V2 platform is design to execute parallel asynchronous
671 %iterative application on heterogeneous distributed architectures, so
672 %it has to launch applications on a variety of computing nodes relying
673 %by non-uniform links. As demonstrates in the previous section, it does
674 %not map efficiently tasks on nodes and the overall performance can be
675 %strongly penalize by this lack of mapping. Indeed, if the
676 %heterogeneity degree of the architecture used is high, it can be
677 %possible to have two neighbors tasks executing on two foreign
678 %computing nodes, that penalizes communications between these tasks,
679 %that increase the execution time. With the same mining, it is
680 %interesting to have similar computing nodes, in order to have seemly
681 %the same iteration execution time that allows to converge more
682 %quickly. We can conclude that JaceP2P-V2 needs an algorithm to
683 %efficiently map tasks on computing nodes.
685 %%As we use parallel distributed algorithms on distributed
686 %%architectures, we have to efficiently map tasks on computing nodes, in
687 %%order to obtain best performance and the slowest execution time of
689 %There exist many scheduling and mapping algorithms in the literature,
690 %and the research is active in this domain. A first approach is to use
691 %one the numerous scheduling algorithms, but our model does not fit
692 %with them. Indeed, a scheduling implies that we have tasks which are
693 %depending on others, more precisely that some tasks cannot start
694 %computation before having received data from other tasks, which are
695 %called precedences, or ``strong dependencies''. This class of
696 %algorithms uses a well known application's representation: the DAG
697 %(Direct Acyclic Graph). This model cannot be used with our
698 %problematic. Indeed, in asynchronous iterative applications, all the
699 %tasks are executed in the same time, in parallel; there is no
700 %precedence. So we have to look at another way, which is the ``tasks
703 %The second approach is to use a tasks mapping algorithm, which only
704 %aims to map tasks on nodes, following a metric, to minimize the
705 %application's execution time. To determine which class of tasks
706 %mapping algorithms we should consider, it is important to draw up a
707 %list of which information we have in hands. When an application using
708 %the asynchronous iteration model is run, the number of iterations to
709 %converge to the solution is unpredictable and change from a run to
710 %another. So, we cannot give a good approximation of the execution time
711 %of a task, but we can retrieve an estimation of the computational
712 %amount of a task (plus de détails ?). In addition, as the asynchronous
713 %iteration model based algorithms are able to provide to applications
714 %the message lost tolerance, we cannot exactly quantify the amount of
715 %communications in an application; some algorithms can converge with
716 %receiving only few dependencies messages. One application's
717 %representation which fit perfectly with our model is the TIG (Task
718 %Interaction Graph), which only considers relations between tasks --
719 %the only thing which is predictable in our model. The figure
720 %\ref{fig:tig} presents an example of a TIG.
724 %On Figure \ref{fig:tig} we can see an application with 6 tasks, in
725 %which each task is in relation with tasks of previous and next rank,
726 %with two exceptions, the first and the last tasks, which can
727 %eventually be in relation, depending of the application. This is a
728 %commonly scheme in asynchronous iteration model; in general, tasks are
729 %in relation with some others which previous and next ranks, but in
730 %some cases, dependencies are more complex.
732 \subsection{Related work}
735 %In the previous section we have determined that we need to use TIG
736 %model based mapping algorithms to address our problem.
737 In the literature of the TIG mapping, we can find many algorithms,
738 which can be divided into two categories. First, in the
739 \textit{Edge-cuts optimization} class of algorithms, the aim is to
740 minimize the use of the penalizing links between clusters. As tasks
741 are depending on neighbors, which are called dependencies, the goal is
742 to choose nodes where distance, in term of network, is small to
743 improve communications between tasks. Here we can cite
744 Metis\cite{metis}, Chaco\cite{chaco} and PaGrid\cite{pagrid} which are
745 libraries containing such kind of algorithms. The main drawback of
746 edge-cuts algorithms is that they do not tackle the computing nodes
747 heterogeneity issues. They only focus on communication overheads.
748 % The Figure \ref{fig:edge} shows
749 % that the optimization is on edges of communications, which are
754 % \includegraphics[width=3.5cm]{images/edgecut}
755 % \caption{The edge-cuts optimization}
758 Then, in the \textit{Execution time optimization} class of algorithms
759 the aim is to minimize the whole execution time of the
760 application. They look for nodes which can provide the small execution
761 time of tasks using their computational power. Here we can cite
762 FastMap\cite{fastmap} and MiniMax\cite{minimax} as such kind of
763 algorithms. QM\cite{qm_these} is also an algorithm of this category,
764 but it aims to find for each task the node which can provide the best
765 execution time. QM works at the task level, whereas others work at the
768 % \ref{fig:et} shows that the optimization is on tasks, which are
773 % \includegraphics[width=3.5cm]{images/exectime}
774 % \caption{The execution time optimization}
778 The two classes of algorithms may fit with our goals, because in our
779 model we have both the computational power of nodes and communication
780 costs which may influence the applications performance. We can also
781 cite partitioning tools like Scotch \cite{scotch} which aims at
782 privileging the load balancing of their partitioning
783 schemes. Nevertheless, to the best of our knowledge, none of the
784 existing algorithms take into consideration the specificities of the
785 AIAC model (see next section).
786 %specifically address the AIAC mapping problem.
787 %As the existing mapping algorithms are not designed to fit
788 %with the AIAC mapping problem.
790 \section{AIAC mapping}
791 \label{sec:aiacmapping}
793 % In this section we present the specificities of the AIAC model, which
794 % are interesting in the mapping problem, and the solution we propose:
795 % the AIAC QM algorithm, which is an extended version of the QM
798 \subsection{Specificities of the AIAC mapping problem}
799 \label{sec:specAIACmapping}
801 An important point to take into consideration in the AIAC model is
802 that we do not allow the execution of multiple tasks on the same
803 computing node. This comes from the fact that the targeted
804 architectures are volatile distributed environments. Assigning
805 multiple tasks to a node provides a fall of performance when this
806 node fails. Indeed we should redeploy all of the tasks from this node
807 to another one, using last saves, which implies to search a new
808 available computing node, transfer saves to it and restart the
809 computation from this point (which could be far from this just before
812 Nevertheless, in order to benefit of multi-cores architectures, we use
813 a task level parallelism by running multi-threaded sequential solver
815 %In addition, it is more simple and efficient to parallelize at the
816 %task level using, as an example with the CG application, a
817 %multi-threaded linear solver, which benefits of the multi-cores
818 %architecture of computing nodes.
820 Another important point in the AIAC model is that we should take into
821 account precisely the locality issue. This comes from the fact that in
822 this model, the faster and more frequently a task receives its
823 dependencies, the faster it converges. Moreover, as the JaceP2P-V2
824 environment is fault tolerant and tasks save checkpoints on their
825 neighbors, it is more efficient to save on near nodes than on far
829 %As our problem is on task mapping, only considering the dependency
830 %relations between tasks, with a part of consideration on task weight,
831 %we should use TIG (\textit{task interaction graph}) mapping model.
833 %\section{Mapping algorithms}
836 \subsection{AIAC Quick-quality Map}
839 %After having describe the different kinds of mapping algorithms which
840 %can be found in the literature, we now present the three algorithms we
841 %use to do mapping in the JaceP2P-V2 environment.
843 We present here the solution we propose, called \textit{AIAC QM
844 algorithm}, to address the AIAC mapping problem. We decided to
845 improve the \textit{Quick-quality Map} (QM) algorithm since it is one
846 of the most accurate method to address the TIG mapping problem.
848 %\subsection{Modified Quick-quality Map}
849 %\label{sec:modifiedqm}
851 %As the previous algorithm describe in section \ref{sec:sma} showed
852 %that mapping provides a significant increase of applications
853 %performance (which can be seen in the section \ref{sec:experiments}),
854 %we decide to try another mapping algorithm, which is a modified
855 %version of the \textit{Quick-quality Map} (QM) algorithm.
858 %As explained in section \ref{sec:pb}, the asynchronous iteration model
859 %is specific, as it is not a good solution to map many tasks on the
860 %same node. This is why QM has been modified to take into account these
862 % Indeed, originally QM tries to map many tasks on the
863 %same node to improve the execution time of tasks by decreasing
864 %communications costs. This solution can be good if communications
865 %between tasks are heavy and if we consider that computing nodes are
866 %stable and are not volatile. As
868 %, we have modified some parts
869 %of it to fit with our constraints. This was an opportunity to be taken
870 %to insert a little part of ``edge-cuts'' optimization, as in our model
871 %communications have to be taken into account.
872 In its original version, this algorithm aims at prioritizing the
873 computational power of nodes. Indeed, its aim is to find the more
874 powerful node to map a task on. Moreover, a part of this algorithm is
875 designed to map multiple tasks on the same node, in order to improve
876 local communications. This solution can be efficient if communications
877 between tasks are heavy and if we consider that computing nodes are
878 stable and not volatile. This last point is in contradiction with
879 our model, as we authorize only the execution of one task on a single
880 node -- this allows to lose only the work of a single task in case of
881 node's fault, with a low cost on restarting mechanism. Instead
882 assigning multiple tasks on the same computing node, our mapping
883 algorithm tries to keep tasks locally, to improve communications, by
884 trying to assign tasks to computing nodes in the neighborhood
885 of which their neighbors are mapped on.
887 % The pseudo-code of AIAC QM is given in Algorithm \ref{alg:qmmodified}.
892 % \dontprintsemicolon
894 % \KwIn{Sets of tasks and computing nodes}
895 % \KwOut{Mapping of tasks to nodes}
899 % sort nodes by descending power\;
900 % map tasks in order on nodes\;
901 % set all tasks \textit{moveable}\;
906 % \While{one task is moveable}{
907 % \For{each task $t_{i}$ $\&\&$ $t_{i}$ is moveable }{
908 % $n_{c} \leftarrow$ current node of $t_{i}$\;
909 % $n_{n} \leftarrow t_{i}$\;
913 % \For{$k = 0 ; k < \frac{f \cdot n}{r} ; k++$}{
914 % select random node $n_{r}$ in $[0,\frac{n}{r}]$\;
915 % \If{ET($t_{i}$,$n_{r}$) $<$ ET($t_{i}$,$n_{n}$)}{
916 % $n_{n} \leftarrow n_{r} $\;
922 % \For{each node $n_{v}$ near $dep(t_{i})$}{
923 % \If{ET($t_{i}$,$n_{v}$) $<$ ET($t_{i}$,$n_{n}$)}{
924 % $n_{n} \leftarrow n_{v} $\;
930 % \If{$n_{n} \neq n_{c}$}{
931 % map $t_{i}$ on $n_{n}$\;
932 % update ET of $t_{i}$ and dep($t_{i}$)\;
938 % set $t_i$ not moveable\;
939 % $r \leftarrow r+1$ if all tasks have been considered\;
942 % \caption{The AIAC QM}
943 % \label{alg:qmmodified}
947 So, in this algorithm all nodes are first sorted in descending order
948 according to their computation power, and all tasks are mapped on
949 these nodes according to their identifier (they are also marked as
950 ``moveable''; it means that each task can be moved from a node to
951 another). As in the original QM algorithm, AIAC QM keeps track of the
952 \textit{number of rounds} $r$ ($r > 0$), that all tasks have been
953 searched for a better node. This allows to reduce at each round the
954 number of considered nodes. While there is at least one moveable task,
955 it performs for each moveable task the search for a better node. It
956 chooses a set of nodes, $\frac{f \cdot n}{r}$, where $f$ is defined as
957 the search factor and $n$ is the number of nodes. $r$ and $f \in
958 ]0,1]$ control the portion of nodes that will be considered where more
959 numerous the rounds are, the less the considered nodes will be. Then
960 the algorithm estimates the execution time $ET(v)$ of the task on each
961 node. If it is smaller than the current node on which the task is
962 mapped on, this node becomes the new potential node for task $t_i$.
964 After having randomly searched for a new node, the AIAC QM tries to
965 map the task on nodes that are neighbors of nodes of which the
966 dependencies of $t_i$ are mapped on. This is one of the major
967 modification to the original QM algorithm. It introduces a little part
968 of ``edge-cuts'' optimization. In the original version, it tries to
969 map the task $t_i$ on the same node of one of its dependencies. As
970 explain in \ref{sec:specAIACmapping}, this is not an acceptable
971 solution in our case. Instead, the algorithm now searches to map task
972 $t_i$ on nodes which are near the ones its dependencies are mapped
973 on. This search requires a parameter which indicates the maximum
974 distance at which nodes should be from the node of dependencies of
977 At the end of the algorithm, if a new node is found, $t_i$ is mapped
978 on and its execution time is updated and $t_i$ is set to ``not
979 moveable''. The execution time of each of its dependencies is also
980 updated, and if this new execution time is higher than the previous,
981 the task is set to ``moveable''. And finally, if all tasks have been
982 considered in this round, $r$ is incremented.
984 The complexity of the AIAC QM algorithm is about $O(n^2 \cdot
985 t \cdot ln(r))$. This complexity is the same as the original algorithm
986 (details are given in \cite{qm_these}, with an increase of a factor
987 $n$, corresponding to the edge-cuts part).
989 \section{Experimentation}
992 % We now describe the experiments we have conducted and their
993 % components, to evaluate the effects of the AIAC QM algorithm on
994 % application execution time.
996 \subsection{The NAS Parallel Benchmark Kernel CG and the Grid'5000 platform }
999 We used the ``Kernel CG'' of the NAS Parallel Benchmarks (NPB)
1000 \cite{nas} to evaluate the performance of the mapping
1001 algorithm. This benchmark is designed to be used on large
1002 architectures, because it tests communications over latency networks,
1003 by processing unstructured matrix vector multiplication. In this
1004 benchmark, a Conjugate Gradient is used to compute an approximation of
1005 the smallest eigenvalue of a large, sparse and symmetric positive
1006 definite matrix, by the inverse power method. In our tests, the whole
1007 matrix contains nonzero values, in order to stress more
1008 communications. As the Conjugate Gradient method cannot be executed
1009 with the asynchronous iteration model we have replaced it by another
1010 method called the multisplitting method. This latter supports the
1011 asynchronous iterative model.
1014 With the multisplitting algorithm, the $A$ matrix is split into
1015 horizontal rectangle parts.
1016 %as Figure \ref{fig:multisplit} shows.
1018 of these parts is assigned to a processor -- so the size of data
1019 depends on the matrix size but also on the number of participating
1020 nodes. In this way, a processor is in charge of computing its {\small $X Sub$}
1021 part by solving the following subsystem: {\small $ASub \times XSub = BSub -
1022 DepLeft \times XLeft - DepRight \times XRight$}.
1024 After solving {\small $XSub$}, the result must be sent to other
1025 processors which depend on it.
1027 % \begin{figure}[h!]
1029 % \includegraphics[width=7.4cm]{images/multisplit}
1030 % \caption{Data decomposition for the multisplitting method
1032 % \label{fig:multisplit}
1035 % The multisplitting method can be decomposed into four phases:
1038 % \item \textbf{Data decomposition}. In this phase, data are allocated
1039 % to each processor assuming the decomposition shown in Figure
1040 % \ref{fig:multisplit}. Then, each processor iterates until
1041 % convergence is reached.
1042 % \item \textbf{Computation}. At the beginning of the computation, each
1043 % processor computes
1044 % $BLoc = BSub - DepLeft \times XLeft - DepRight \times XRight$. Then,
1045 % it solves $ASub \times XSub = BLoc$ by using a
1046 % multi-threaded sequential version of the Conjugate Gradient method.
1047 % \item \textbf{Data exchange}. Each processor sends its $XSub$
1048 % part to its neighbors. Here, the neighborhood is closely related
1049 % to the density of the $A$ matrix. Clearly, a dense matrix implies an
1050 % \textit{all-to-all} communication scheme while a matrix with a low
1051 % bandwidth reduces the density of the communication scheme.
1052 % \item \textbf{Convergence detection} Each processor computes its local
1053 % convergence and sends it to a server node. When this one detects
1054 % that each processor has converged, it stops the whole computation
1058 %It can be pointed out here that it is possible to modify the data
1059 %decomposition in order to obtain non disjoint rectangle matrices. This
1060 %property of multisplitting methods, called \textit{overlapping}, can
1061 %bring significant improvements to convergence speed, but it is not the
1063 For more details about this method, interested readers are invited to
1064 see \cite{book_raph}. In our benchmark, the sequential solver part of
1065 the multisplitting method is the Conjugate Gradient, using the
1066 MTJ\cite{mtj} library. Its implementation is multi-threaded, to
1067 benefit from multi-core processors.
1069 We point out here that this benchmark is a typical AIAC
1070 application. In our study, we consider that the computational costs of
1071 tasks are approximately the same and that the communications costs are
1072 also the same (this comes from the difficulty to evaluate real costs
1073 in the AIAC model). For our experiments the bandwidth of matrices has
1074 been reduced in order to limit the dependencies and we fixed it to
1075 $35,000$. This bandwidth size generates, according to the problem's
1076 size, between 10 and 25 neighbors per tasks.
1078 % The general form of the TIG for this application is given
1079 % by Figure \ref{fig:tigcg}.
1081 % \begin{figure}[h!]
1083 % \includegraphics[width=8cm]{images/tigcg2}
1084 % \caption{Part of the form of the TIG representing an instance of the
1085 % NAS Kernel CG application}
1089 %This figure shows 6 tasks, which are represented by a circle in which
1090 %the identifier of the task is given.
1092 % The computational cost of a task is given by the number on the top
1093 % left-hand side of each circle (for example the cost of task 31 is
1094 % 1000). Communications between tasks are represented by edges on
1095 % which the amount of communication is given (for example, the
1096 % communication cost between tasks 29 and 30 is about 30).
1097 % Dotted lines represent communications with tasks which are not
1098 % represented on the figure. We can see here that each task has four
1099 % neighbors (the two previous and the two next). This amount of
1100 % neighbors is directly related to the bandwidth of the matrix (in this
1101 % example the bandwidth is very small). For more details about the
1102 % influence of the bandwidth on the amount of neighbors, interested
1103 % readers are invited to see \cite{largescale}.
1107 %\subsubsection*{The Grid'5000 platform}
1110 The platform used for our tests, called Grid’5000\cite{g5k}, is a
1111 French nationwide experimental set of clusters which provides a
1112 configurable and controllable instrument. We can find many clusters
1113 with different kinds of computers with various specifications and
1114 software. Clusters are spread over 9 sites,
1115 %as can be seen on Figure \ref{fig:g5ksite},
1116 and the computing power represents more than 5000
1117 computing cores interconnected by the ``Renater'' network. This
1118 network is the national network for research and education; it
1119 provides a large bandwidth with high latency. Intra-clusters networks
1120 present small bandwidth and low latencies.
1123 % \begin{figure}[h!]
1125 % \includegraphics[height=6.5cm]{images/g5k-noms}
1126 % \caption{The Grid'5000 sites map}
1127 % \label{fig:g5ksite}
1132 \subsection{Other mapping algorithms}
1133 \label{sec:othermaping}
1135 % In this section we present the two other mapping algorithms we used
1136 % in our experiments to compare the performance of the AIAC QM
1137 % algorithm. The first one was used to evaluate the benefits of a
1138 % mapping solution in section \ref{sec:benef}. The second one was used
1139 % to show the differences between the two mapping class, the ``execution
1140 % time'' and the ``edge-cuts'' optimizations, as it is a fully edge-cut
1141 % optimization based mapping algorithm.
1143 \subsubsection{A Simple Mapping algorithm}
1146 %As mentioned in section \ref{sec:pb}, the asynchronous iteration model
1147 %has some specificities which distinguishes it from other classical model
1150 %The first thing we have done was to be sure that a mapping algorithm
1151 %would enhance applications performance.
1152 The \textit{Simple Mapping algorithm} (SMa) was designed to
1153 show the benefits of a mapping algorithm in the JaceP2P-V2 platform.
1154 %The text of the \textit{Simple Mapping} if given by
1155 %Algorithm \ref{alg:sma} gives the pseudo-code of the \textit{Simple
1156 % Mapping algorithm}.
1157 %, in which we can see that it is very simple, with a complexity in $O(n^
1158 %2)$ resulting from sort methods.
1164 % \dontprintsemicolon
1165 % \KwIn{Sets of tasks and computing nodes}
1166 % \KwOut{Mapping of tasks to nodes}
1170 % sort computing nodes by cluster\;
1171 % sort clusters by size, from higher to lower\;
1172 % map tasks in order on sorted clusters\;
1173 % \caption{The Simple Mapping algorithm}
1178 %The aim of this algorithm is to do similarly to a very simple
1179 %edge-cuts optimization algorithm. To do that
1180 The algorithm puts each node in a cluster entity.
1181 %, which is given for now by the convention name of nodes
1182 %on Grid'5000 (for example azur-3.sophia.grid500.fr is the node 3 of
1183 %the azur cluster in the sophia site).
1184 Then it sorts clusters by their size, from the higher to the lower.
1185 %; this operation is the part which
1186 %is inspired by edge-cuts optimization based algorithms.
1187 Finally, all tasks are mapped in order on the sorted clusters; each
1188 task is assigned to a particular computing node of the chosen cluster.
1190 %Though this algorithm is trivial, it allows AIAC applications to run faster
1191 %on distributed clusters architectures, with a gain over $30\%$ on
1192 %execution, as experiments described in section \ref{sec:benef}.
1196 \subsubsection{Edge-cuts optimization}
1197 \label{sec:edgcutalgo}
1199 As explained in section \ref{sec:pb}, the asynchronous iteration model
1200 is so specific and unpredictable that we would like to evaluate the
1201 second kind of mapping algorithm, which aims to optimize the
1203 %Multilevel partitioning algorithms such as Metis and
1204 %Chaco fail to address the limitations imposed by heterogeneity in the
1205 %underlying targeted system. They assume that computing nodes and
1206 %network relying them are homogeneous. This is not corresponding to our
1207 %execution environment, which is fully heterogeneous. These methods are
1208 %based on ``graph growing'' (GGP) and/or ``greedy graph growing''
1209 %(GGGP) algorithms which aim to divide tasks into two, or for some
1210 %algorithm a power of two, partitions. In our case, we do not know in
1211 %advance the number of partitions we need. Indeed, it depends on the
1212 %amount of nodes in each cluster and on the number of tasks.
1214 %As GGP and GGGP algorithms seems to be efficient in specific cases, it
1215 %could be interesting to adapt one to our model, in order to evaluate a
1216 %real edge-cuts optimization algorithm.
1217 We choose the Farhat's algorithm\cite{farhat}, which has the ability
1218 to divide the graph into any number of partitions, thereby avoiding
1219 recursive bisection.
1220 %Therefore its running execution time is
1221 %independent of the desired number of subsections.
1223 % The adapted version of this algorithm, Farhat's Edge-Cut (F-EC),
1224 % evaluated in the JaceP2P-V2 environment is described in Algorithm
1225 % \ref{alg:edgecuts}.
1230 % \dontprintsemicolon
1232 % \KwIn{Sets of tasks and computing nodes}
1233 % \KwOut{Mapping of tasks to nodes}
1238 % sort nodes by cluster\;
1239 % $lTasks \leftarrow$ sort tasks by dep degree\;
1240 % $changeCluster \leftarrow$ true\;
1241 % $cTasks \leftarrow$ empty;
1245 % \While{one task is not mapped}{
1246 % \If{$changeCluster$}{
1247 % $curCluster \leftarrow$ nextCluster()\;
1248 % $places \leftarrow$ size($curCluster$)\;
1249 % $changeCluster \leftarrow$ false\;
1250 % $mTasks \leftarrow$ empty\;
1255 % \If{no task in cTasks}{
1256 % $cTasks \leftarrow$ first task from $lTasks$\;
1261 % $curTask \leftarrow$ first task in $cTasks$\;
1265 % \eIf{$( 1 + $dep(curTask)~$\cdot~\delta) <= places)$}{
1266 % remove $curTask$ from $cTasks$\;
1267 % add $curTask$ in $mTasks$\;
1268 % $places \leftarrow places - 1$\;
1269 % add dep(curTask) in cTasks\;
1271 % $changeCluster$ $\leftarrow$ true\;
1272 % associate $mTasks$ with $curCluster$\;
1276 % \caption{The Fahrat's Edge-Cut algorithm}
1277 % \label{alg:edgecuts}
1280 This algorithm aims to do a ``clusterization'' of the tasks. First, it
1281 groups computing nodes in clusters, which are sorted according to
1282 their number of nodes, from the higher to the lower. Tasks are ordered
1283 following their dependency degree, starting from the higher to the
1284 lower. Tasks in the top of the list have a higher priority to be
1285 mapped. Next, the algorithm tries to map on each cluster the maximum
1286 number of tasks. To map a task on a cluster, the algorithm evaluates
1287 if there is enough space to map the task and some of its
1288 dependencies. This amount of dependencies is fixed by a factor
1289 $\delta$, which is a parameter of the algorithm. In the positive case,
1290 the task is mapped on the current cluster and its dependencies become
1291 priority tasks to be mapped. This allows to keep the focus on the
1292 communicating tasks locality.
1293 %All computing nodes are first grouped in clusters.
1294 %%, using their full
1295 %%qualified name -- for now, no criteria is used to sort clusters, such
1296 %%are their power or size.
1297 %Next, tasks are inserted in a list $lTasks$, sorted in descending
1298 %according to their dependency degree. This allows to map tasks with
1299 %their dependencies to improve communications. Next begins the main
1302 %While not all tasks have been mapped the algorithm do the
1303 %following. First, at the beginning, it chooses the first available
1304 %cluster to be the current cluster to map tasks on, and sets the
1305 %variable $places$ to its size, in number of computing nodes, and
1306 %create a new tasks' list $mTasks$. During the execution of the
1307 %algorithm, passing in this block means that there is no more node
1308 %available in the current cluster, so it has to choose the next
1309 %cluster. Next, it looks in $cTasks$, which is a tasks list containing
1310 %tasks which are in instance to be mapped. If $cTasks$ is empty it
1311 %takes the first available task in $lTasks$ -- at the beginning it
1312 %takes the first one, which has the higher dependency degree.
1314 %Next, it takes the first task in $cTasks$ to try to map it on the
1315 %current cluster. The task is mapped on if there is enough available
1316 %computing nodes on the current cluster. This amount of node
1317 %corresponds to $1 + dep( curTask ) \cdot \delta$, which represents the
1318 %task plus the amount of its dependencies multiplied by a ``local
1319 %dependency factor'' $\delta$, which indicates how many dependencies
1320 %must be a least with $curTask$ on the same cluster. If the task could
1321 %be mapped on this cluster, $curTask$ is added in $mTasks$, which is a
1322 %tasks' list containing tasks which are currently mapped on current
1323 %cluster, and removed it from $cTasks$. The number of available nodes,
1324 %$places$, is decremented, and the dependencies of $curTask$ are added
1325 %to $cTasks$. This list is sorted in the same way as $lTasks$, indeed
1326 %tasks are added according to their dependency degree, from the higher
1327 %to the lower. Otherwise, if there is not enough or no more nodes
1328 %available in the cluster, it has to change the current cluster, so it
1329 %associates the current cluster and list of tasks mapped on, $mTasks$.
1332 \subsection{Experiments}
1333 \label{sec:experiments}
1335 After having described the different components of the experiments, we
1336 now present the impacts of the AIAC QM mapping on applications running
1337 with JaceP2P-V2 on a heterogeneous distributed clusters
1338 architecture. In the following, we note ``heterogeneity degree'' the
1339 degree of heterogeneity of distributed clusters; it is the ratio
1340 between the average and the standard deviation of the computing nodes
1341 power. This heterogeneity degree may vary from 0, nodes are
1342 homogeneous, to 10, nodes are totally heterogeneous. In these
1343 experiments, we consider that there is no computing nodes failing during
1344 applications execution.
1346 The application used to realize these experiments is the KernelCG of
1347 the NAS parallel benchmark, in the multi-splitting version. Two
1348 problem sizes were used: one using a matrix of size $550,000$ (named
1349 ``class E'') using 64 computing nodes and the other using a matrix of
1350 size $5,000,000$ (named ``class F'') using 128 nodes.
1353 %\ref{fig:tigcg} shows a part of a TIG of this application.
1363 %\subsubsection{About heterogeneity}
1364 %\label{sec:xphetero}
1366 %The first experiments concern the study of the impact of the
1367 Our experiments concern the study of the impact of the
1368 heterogeneity of the computing nodes on the mapping
1369 results. Heterogeneity is an important factor in high performance
1370 computing in the grid all the more so when using the asynchronous
1373 As mapping algorithms take in parameter a factor of research (for AIAC
1374 QM) and the amount of local dependencies (for F-EC), we fixed both to
1375 $50\%$. That means for AIAC QM that at each round the amount of
1376 considering nodes would be divided by two, and for F-EC that each task
1377 requires half of its dependencies on the same local cluster.
1379 Four experiments were done using four architectures having different
1380 heterogeneity degrees -- in two architectures computing nodes are more
1381 heterogeneous than in the others. In these experiments, we did not
1382 affect the networks heterogeneity, because of the difficulty to
1383 disturb and control network on Grid'5000; by default, networks are
1384 already quite heterogeneous. We needed more than 200 computing nodes
1385 to execute our application because of the small capacity of some
1386 clusters to execute the largest problems (there is not enough
1387 memory). The nodes used have more than 2 GB of RAM and both execute a
1388 Linux 64 bits distribution.
1390 The first architecture, Arc1.1, was composed of 113 computing nodes
1391 representing 440 computing cores, spread over 5 clusters in 4
1392 geographically distant sites. In Arc1.1 we used bi-cores (2 clusters), quad-cores (2
1393 clusters) and bi-quad-cores (1 cluster) machines. Its heterogeneity
1394 degree value is 6.43. This architecture was used to run class E of the CG
1395 application using 64 computing nodes. The second architecture, Arc1.2,
1396 used to execute class F of the CG application, using 128 computing
1397 nodes, was composed of 213 computing nodes representing 840 computing
1398 cores, with a heterogeneity degree of 6.49. This architecture was
1399 spread on the same clusters and sites as Arc1.1. The results of the
1400 experiments on Arc1.1 and Arc1.2 are given in Table \ref{tab:exph1E}
1401 and Table \ref{tab:exph1F}, which give the gains in execution time obtained
1402 in comparison to the version without mapping.
1406 \renewcommand{\arraystretch}{1.5}
1410 \begin{tabular}[h!]{|c||c|c|c|c|}
1412 Algorithm& None&SMa & AIAC QM & F-EC \\
1415 Execution time&150s&110s&101s&90s\\
1417 % Gains&--&$27\%$&$33\%$&\textcolor{blue}{$40\%$}\\
1418 Gains&--&$27\%$&$33\%$&$40\%$\\
1421 \caption{Gains in time of the execution of the class E of the CG
1422 application on Arc1.1 using 64 nodes}
1429 \renewcommand{\arraystretch}{1.5}
1433 \begin{tabular}[h!]{|c||c|c|c|c|}
1435 Algorithm& None &SMa & AIAC QM & F-EC \\
1438 Execution time&403s&265s&250s&218s\\
1440 % Gains&--&$34\%$&$38\%$&\textcolor{blue}{$46\%$}\\
1441 Gains&--&$34\%$&$38\%$&$46\%$\\
1444 \caption{Gains in time of the execution of the class F of the CG
1445 application on Arc1.2 using 128 nodes}
1450 At first, we can see that the Simple Mapping algorithm, though it is
1451 simple, provides a significant improvement of application execution
1452 time. This highlights that JaceP2P-V2 really needs a mapping algorithm
1453 in order to be more efficient. Then, we can see that the F-EC and the
1454 AIAC QM algorithms provide a better mapping than the Simple Mapping
1455 algorithms. We can see a significant difference between both
1456 algorithms. This comes from the homogeneity of clusters. In this case,
1457 the F-EC algorithm is more efficient since the minimization of the
1458 communications becomes more important than the tackle of the
1459 computational power heterogeneity problem.
1460 %Indeed, it is more benefic for ta becomes more important than the
1461 %tacklebecomes more important than the
1462 %tackle sks to have locally their
1463 %dependencies, which allows to improve communications, in case of
1464 %computing nodes are more homogeneous -- communications are more
1465 %important than computing power (that is why the F-EC algorithm is more
1467 The effect is that tasks do less iterations as they
1468 receive more frequently updated data from their neighbors. In
1469 addition, as tasks and their dependencies are on the same cluster,
1470 communications are improved, but also as computations take
1471 approximately the same time, the amount of iterations is reduced and
1472 the algorithm can converge more quickly.
1474 % Another important positive point is that gains are scalable, which allows
1475 % to foresee big improvements for very large applications.\\
1477 The third architecture, Arc2.1, was composed of 112 computing nodes,
1478 representing 394 computing cores, spread over 5 clusters in 5
1479 sites. In this architecture we used bi-cores (3 clusters),
1480 quad-cores (1 cluster) and bi-quad-cores (1 cluster) machines. Its
1481 heterogeneity degree's value is 8.41. This architecture was used to run
1482 class E of the CG application, using 64 computing nodes. The fourth
1483 architecture, Arc2.2, used to execute class F of the CG
1484 application, using 128 computing nodes, was composed of 212 computing
1485 nodes representing 754 computing cores, with a degree of heterogeneity
1486 of 8.44. This architecture was spread on the same clusters and sites
1487 as Arc2.1. The results of the experiments on Arc2.1 and Arc2.2 are
1488 given in Table \ref{tab:exph2E} and Table \ref{tab:exph2F}, which give the
1489 gains in execution time obtained in comparison to the version without
1494 \renewcommand{\arraystretch}{1.5}
1498 \begin{tabular}[h!]{|c||c|c|c|c|}
1500 Algorithm&None& SMa & AIAC QM & F-EC \\
1503 Execution time&498s&341s&273s&385s\\
1505 % Gains&$32\%$&\textcolor{blue}{$45\%$}&\textcolor{red}{$23\%$}\\
1506 Gains&--&$32\%$&$45\%$&$23\%$\\
1509 \caption{Gains in time of the execution of the class E of the CG
1510 application on Arc2.1 using 64 nodes}
1515 \renewcommand{\arraystretch}{1.5}
1519 \begin{tabular}[h!]{|c||c|c|c|c|}
1521 Algorithm& None&SMa & AIAC QM & F-EC \\
1524 Execution time&943s&594s&453s&660s\\
1526 % Gains&$37\%$&\textcolor{blue}{$52\%$}&\textcolor{red}{$30\%$}\\
1527 Gains&--&$37\%$&$52\%$&$30\%$\\
1530 \caption{Gains in time of the execution of the class F of the CG
1531 application on Arc2.2 using 128 nodes}
1536 To begin with, these experiments confirm that a mapping algorithm is
1537 needed and that improvements are always scalable. Then, we can see
1538 that the F-EC algorithm falls in performance and AIAC QM is
1539 improved. What is surprising is that the Simple Mapping algorithm is
1540 better than F-EC. This can be explained by the fact that as computing
1541 nodes are quite heterogeneous, computations are not the same, so it is
1542 not significant to map dependencies close to tasks. In this case, the
1543 most important is the power of computing nodes. So, in this kind of
1544 architecture, it is more efficient to choose the best computing nodes
1545 to compute iterations more quickly and to improve the convergence
1548 % Here, it is important to note that the AIAC QM algorithm offers a gain
1549 % of about $50\%$ on the execution time, that is to say that the
1550 % application takes half of the execution time than without mapping.
1552 % \subsubsection{Parameters variation}
1553 % \label{sec:xpvariation}
1555 % After having evaluated mapping algorithms on the heterogeneity of
1556 % distributed clusters, we now propose to change the parameters of AIAC
1557 % QM and F-EC algorithms, in order to determine which values are the
1560 % To do these experiments, we used an architecture composed of 122
1561 % computing nodes representing 506 computing cores, spread over 5
1562 % clusters in 5 sites. In this architecture we used bi-cores (2
1563 % clusters), quad-cores (2 clusters) and bi-quad-cores (1 cluster)
1564 % machines. Its heterogeneity degree value is 4.98.
1565 % %, which means that
1566 % %computing nodes power is very heterogeneous.
1568 % The parameters of each algorithm, $f$ (the search factor) for
1569 % AIAC QM and $\delta$ (the amount of local dependencies) for F-EC,
1570 % varied both with values $10\%$, $50\%$ and $90\%$. We used the CG
1571 % multi-splitting application on 64 computing nodes. The results of
1572 % these experiments are given in Table \ref{tab:expparams}. Results
1573 % reported in this table represent the gains in execution time provided
1574 % by each algorithm with different parameters values.
1577 % \renewcommand{\arraystretch}{1.5}
1581 % \begin{tabular}[h!]{|c||c|c|c|}
1583 % Parameters& $10\%$ & $50\%$ & $90\%$ \\
1586 % % Simple & \multicolumn{3}{c|}{\textcolor{blue}{$39\%$}}\\
1587 % SMa & \multicolumn{3}{c|}{$30\%$}\\
1589 % % AIAC QM & $35\%$ & \textcolor{blue}{$41\%$} & $35\%$ \\
1590 % AIAC QM & $30\%$ & $32\%$ & $30\%$ \\
1592 % % F-EC & $39\%$ & $35\%$ & \textcolor{blue}{$45\%$} \\
1593 % F-EC & $40\%$ & $37\%$ & $45\%$ \\
1596 % % \caption{Parameters variations using a $500'000$ problem size on an
1597 % % architecture of 5.37 heterogeneity degree}
1598 % \caption{Gains in execution time with mapping algorithms parameters
1599 % variations using the class E of the CG application using 64
1601 % % \vspace*{-0.4cm}
1602 % \label{tab:expparams}
1603 % % \vspace*{-0.9cm}
1606 % %First of all, we can see that the Simple mapping provides the same
1607 % %order of performance, as shown in the precedent section, so it is
1608 % %not affected by the heterogeneity degree. Secondly,
1609 % For the AIAC QM algorithm, we can note that the best value for its
1610 % parameter $f$ is about $50\%$, but its impact is not big enough to
1611 % indicate a specific configuration.
1612 % % With a low heterogeneity degree, this mapping algorithm provides a
1613 % % good performance improvement.
1614 % Finally, and this is not surprising, the F-EC algorithm is more
1615 % efficient with a factor $\delta$ near $100\%$, which directly comes
1616 % from its aim. But we can see that it is more efficient to have a
1617 % factor around $10\%$ than having one around $50\%$.
1619 % We can note here, with a lower heterogeneity degree than in previous
1620 % experiments, gains are lower and the difference between AIAC QM and
1621 % F-EC (with parameters at $50\%$) is lower. It can be explained as the
1622 % fact that more the heterogeneity degree tends to 0 more computing
1623 % nodes are the same, so a mapping solution will not be efficient,
1624 % except one only optimizing network latency.
1625 %These experiments show that the impact of parameters values does not
1626 %well influence the AIAC QM, whereas it is very important for the F-EC
1629 %\section{Discussion}
1630 %\label{sec:discussion}
1632 %In this paper three algorithms for mapping asynchronous iterative
1633 %applications on heterogeneous distributed architectures are described.
1634 %This approach is relatively new, so we had to study related works. We
1635 %assume in our model that the amount of computation, the computational
1636 %cost of each task, cannot be known in advance, and it is the same
1637 %about communications. Two mains class of algorithms are mainly used,
1638 %the ``execution time'' and the ``edge-cuts'' optimizations, with a
1639 %newer preference fort the first one. Indeed, the efficiency of second
1640 %one is criticized for its objectives, invoking the fact that these
1641 %algorithms do not optimize the right metric. It is true in a broad
1642 %spectrum of mapping domains, but we have shown that in our case, it
1643 %could be an efficient solution, depending on the architecture
1646 %As each experiment takes a lot of time and the Grid'5000 platform is
1647 %shared by many researchers, we could not conducted as many experiments
1648 %as we wanted and as we need to purpose an exhaustive view of this part
1649 %of the mapping domain. We cannot design a more general state of the
1650 %mapping of asynchronous iterative applications on distributed
1651 %architectures, but we can draw the main lines of future works.
1653 %%giving the first stones at the building of this specific part of the
1656 %We have shown that the heterogeneity in computing nodes power takes an
1657 %important part in an efficient mapping algorithm. This parameter and
1658 %probably the heterogeneity in network should really be more taken into
1659 %consideration. Maybe a good solution consists in designing of mapping
1660 %algorithms giving more important priority to one or to the other
1661 %optimization objectives. This leads to design a novel algorithm, which
1662 %takes into account the different points discussed in this paper, which
1663 %would probably be an hybrid algorithm, efficient with our model on the
1664 %targeted architectures.
1666 \section{Conclusion and future works}
1669 In this paper we have presented
1670 %three algorithms to address the
1671 %mapping problem for asynchronous iterative applications in
1672 %heterogeneous distributed architectures. As the asynchronous iteration
1673 %model is very specific, it was not clear of which kind of mapping
1674 %algorithm should be efficient on such a problem. The two main
1675 %approaches given in the literature, the ``execution time'' and the
1676 %``edge-cuts'' optimization algorithms, have been evaluated on
1677 %different architectures, with different heterogeneity degrees.
1678 %% These architectures varied in their
1679 %%heterogeneity, to evaluate the algorithms.
1681 %%We proposed three mapping algorithms for the JaceP2P-V2
1682 %%environment. The first is a simple way mapping, the Simple Mapping
1683 %%algorithm, which always provides a good and stable improvement of
1684 %%performance on all kinds of architectures.
1686 a specific mapping algorithm for the AIAC model, called AIAC QM. This
1687 algorithm is based on the execution time optimization but it also
1688 includes a small degree of edge-cuts optimization. Experiments show that
1689 the AIAC QM mapping algorithm is efficient on architectures with a
1690 high heterogeneity degree. This can be explained by the fact that all
1691 iteration computations are quite different, for our example, and the
1692 convergence is more quickly detected as the more powerful computing
1693 nodes progress in the computation.
1694 % The F-EC algorithm, which is based
1695 % on the ``edge-cuts'' optimization, is meanwhile efficient on
1696 % architectures with a low heterogeneity degree. This can be explained
1697 % by the fact that in such an environment, it is more accurate for a
1698 % task to have its dependencies locally on the same cluster in order to
1699 % have efficient communications and to allow iterations to be computed
1700 % together, which improves the convergence detection speed.
1701 % Experiments we conducted have shown gains in execution time up to
1702 % $50\%$, which denotes a division by 2 of this execution time, for a
1703 % typical AIAC application on more than 700 computing cores.
1704 % %Experiments have shown that
1705 % %the importance of the parameter of both algorithms, AIAC QM and F-EC,
1706 % %is not so essential for the first one, instead it is very critical for
1707 % %the second one, but we cannot be sure that it is true all the time on
1708 % %all kinds of architectures; it maybe depends on the heterogeneity
1709 % %degree of the network.
1710 % As we did not influence the network's heterogeneity,
1711 % % as we did for the computational power of nodes,
1712 % the evaluation of the network impact on the
1713 % application execution time would be one of our next work.
1715 %For now, these three mapping algorithms are implemented in an
1716 %additional library for the JaceP2P-V2 environment. The results
1717 %presented in this paper show that a mapping algorithm allows to
1718 %improve applications performance, but as the executing architectures
1719 %should have a variety of heterogeneity degree, we have to find a
1720 %compromise between the two approaches in order to have an efficient
1721 %mapping algorithm on all kinds of architectures. In the future, we
1722 %would like to design an efficient mapping algorithm to improve the
1723 %execution of asynchronous iteration applications on heterogeous
1724 %distributed architectures. As the algorithm should be integrated in
1725 %the JaceP2P-V2 environment, which is fully decentralized and fault
1726 %tolerant, the new mapping algorithm should have also these
1727 %characteristics, in order to retrieve a fully decentralized and fault
1728 %tolerant environment.
1729 % Our future works concern the amelioration of the AIAC QM algorithm, in
1730 % order to improve it on homogeneous distributed architectures. As the
1731 % F-EC mapping algorithm is efficient on such architectures, we will
1732 % give a more important consideration to the edge-cuts part of AIAC
1735 In our future work we plan to take into consideration the fault
1736 tolerance problem. In this study we have realized our experiments
1737 without computing node fault, which is not the real case. We have to
1738 take into account the AIAC QM algorithm about this important
1739 parameter. First we have to efficiently choose new nodes to replace
1740 failed ones. Secondly, as we do checkpointing to save tasks' states,
1741 we have to efficiently choose backup nodes not to fail in case
1742 a whole cluster fails, as we save on neighbors (which are
1743 in general on the same cluster for communication efficiency reasons),
1744 an important part of the application is lost and we cannot restart
1745 this part; so the whole application fails. A trade-off should be done
1746 by having some saving nodes in external clusters.
1748 % \subsubsection*{Acknowledgements}
1752 % This work was supported by the European Interreg IV From-P2P project
1753 % and the region of Franche-Comté.
1755 % Experiments presented in this paper were carried out using the
1756 % Grid'5000\cite{g5k} experimental testbed, being developed under the
1757 % INRIA ALADDIN development action with support from CNRS, RENATER and
1758 % several Universities as well as other funding bodies.
1761 \bibliographystyle{unsrt}
1763 \bibliography{biblio}