DEMAP: differential evolution mapping for network on chip optimization

Network-on-chip (NoC) is a new paradigm for system-on-chip (SoC) design, which facilitates the interconexion and integration of complex components. Since this technology is still new, significant research efforts are needed to accelerate and simplify the design phases. Mapping is a critical phase in the NoC design process, as a mismatch of application software components can have a significant impact on the performance of the final system. Therefore, it is essential to develop automated tools and methods to ensure this step. The main objective of this project is to develop a new approach that can be used to map applications on the NoC architecture to reduce communication costs. We have opted for an optimization algorithm, specifically the differential evolution algo-rithm, to achieve this goal. This is an open access article under the CC BY-SA license.


INTRODUCTION
The network-on-chip (NoC) concept originated from the need to accommodate the increasing size, complexity, and heterogeneity of applications running on systemon-chip (SoC).As the traditional communication bus between components failed to fulfill all the demands, the idea of establishing a network on a chip was conceived based on computer networks principles.A critical stage in designing a NoC is the mapping of intellectual property (IP) cores to the architecture.This process has a significant impact on the performance of the system, affecting factors such as energy usage, latency, and load distribution.This process is considered an NP-hard problem, as more than one critical performance factor must be considered to develop the optimal mapping algorithm.Thus, several methods have been proposed in the literature to address this issue, often relying on heuristic algorithms.Differential evolution (DE) is one such algorithm that delivers better performance with lower complexity.However, in this paper, we aim to enhance DE's efficacy by coordinating it with other techniques.The remainder of this paper is organized as follows: section 2 provides an overview of NoC; section 3 highlights some relevant studies; section 4 discusses the application mapping problems,, followed by a description of the Mapping problem with the differential evolution algorithm.In section 5, we showcase the experimental outcomes.In the last Section we conclude our work by a conclusion.

NOCS GENERALITIE
The idea of NoC is derived from the networks initially developed for supercomputers, comprises a group of interconnected devices on a single chip that communicate through packets sent over a scalable interconnection network.Compared to traditional bus architectures, NoC offers several advantages, such as energy efficiency, reliability, bandwidth scalability, and reusability [1].The topology of a NoC is determined by how its components are interconnected to create the on-chip interconnect, which can take on various forms, such as 2D mesh, torus, and ring.In addition to the topology, other characteristics of NoC include communication mode, flow control mechanisms to prevent deadlock issues, and storage strategies Figure 1 present a NoC with 9 tiles in 2D mesh topology.

Figure 1. A 3×3 2D mesh NoC
To design a NoC, the system involves multiple stages.Initially, the application is decomposed into a set of communication tasks that can be executed concurrently.After that, each task is assigned to an available core that is selected and scheduled.at the end, these cores must be mapped onto the NoC to complete the system design [2].
This paper specifically concentrates on the final stage of application mapping, which is a critical but still unresolved search problem.The optimal mapping solution can yield energy savings of up to 51.7% compared to ad hoc implementations, as demonstrated in [3].To achieve high performance, finding the optimal mapping solution is essential.For instance, if there are m tasks to be mapped onto an NoC consisting of n cores where (m <= n), the number of potential solutions can reach up to n!/(n − m)!.Application mapping is a combinatorial optimization problem that is classified as NP-hard.In order to find a suboptimal solution, heuristic algorithms are typically used.

RELATED WORK
In NoC mapping, various approaches have been proposed, with particular attention given to the twodimensional mesh topology.In this study, we review the most cited mapping techniques that consider monoobjective mapping.These techniques can be divided into two classes: meta-heuristic algorithms and heuristic approaches.
Meta-heuristic algorithms are widely used to solve NP-hard problems and strive to achieve a solution that is close to optimal.Examples of such algorithms include genetic algorithms, ant colony optimization, and particle swarm optimization.For example, GBMAP [4] and CGMAP [5] use genetic algorithms, and in [6], an ACO-based algorithm is proposed to minimize the bandwidth requirement.In reference [7], a technique for optimizing performance using deterministic initial solutions has been proposed.Specifically, a discrete multiple particle swarm optimization (PSO) based mapping technique was utilized, where the behavior of swarm intelligence serves as a meta-heuristic.
Unlike meta-heuristic algorithms, heuristic approaches are tailored to a specific problem and rely on specific cues to guide the search process.These cues are determined by the nature of the problem being addressed.For instance, NMAP [8] selects an application's core and maps them to tiles repeatedly, while BMAP [9] maps the cores according to traffic loads of cores.The CastNet algorithm described in reference [10] generates multiple solutions for mapping by using multiple tiles as initial tiles.The algorithm uses the DEMAP: differential evolution mapping for network on chip optimization (Maamar Bougherara)

❒
ISSN: 2722-2586 symmetric characteristics of a mesh to determine the optimal solution for each core, the number of available neighboring tiles for each tile is considered.Chmap [11] determines the priority of each core by analyzing the communication needs and the data in the spanning tree.Next, the algorithm maps the chosen cores to the suitable tiles based on their priorities by establishing the mapping order of the cores.The ONYX algorithm, presented in [12].This algorithm utilizes four moves to assign a core to the tiles on a lozenge-shaped path and achieves a lower communication cost than previous mapping techniques.The Spiral approach, described in [13], involves mapping the task with the highest priority at the center first, followed by the remaining tasks using a spiral path.Exact methods are also used in mapping but require a large amount of calculations over time, such as those based on integer linear programming (ILP) [14], or the branch and bound search method [15].

APPLICATION MAPPING PROBLEM
Our research focuses on mapping steps that involve two key inputs: NoC and its architecture, and the application that is supposed to run in the noc.In our case, we used a NoC with a 2D mesh topology shown in Figure 2.An application is made up of multiple concurrent tasks that need to be placed onto a core on the NoC.The goal of the mapping process is to achieve the best placement with minimum communication cost, which is a crucial factor that we consider in our paper.The optimal mapping solution is one that achieves the best placement while minimizing the communication costs.The resulting mapping solution is presented in the form of a table,where each task is represented by an index i, and the contents of the table represent the number of tiles assigned to each task during mapping.

NoC Model
The problem is defined using three distinct definitions.Definition 1: The core graph is constructed using a directional graph G(V, E).In this graph, each vertex v i represents a core, while a directional edge ei, j indicates the link between core vi and core v j .The weight of edge e i,j reflects the extent of communication between the two corresponding vertices.within the NOC architecture.Meanwhile, each edge l i,j represents a physical link originating from t i and terminating at t j .Definition 3: The mapping function that associates each vertex v i in the core graph with a vertex t j in the NOC architecture is defined as follows: In the core graph, each edge is considered as a flow of a single commodity, denoted as c k .This value represents the required bandwidth and can be expressed as vl c k .The set of all commodities is represented by To determine the quantity of communication between v i and v j , it is necessary to count the number of hops between tile i and tile j .On a 2D mesh NoC, the X-Y routing algorithm is employed, and the number of hops can be determined using (1).
In 2D mesh NoC the tiles i and j are represented by (X i , Y i ) and (X j , Y j ), respectively.

Objective function
This paper aims to minimize communication cost when mapping two tasks onto the NoC.The primary strategy involves reducing the number of hops required for each communication within the application.The calculation of the communication cost formula involves utilizing (2).
The source of a communication C k is denoted by src(C k ), while its destination is represented by dist(C k ).

Differential evolution (DE)
In 1997, Price and Storn [16] proposed DE as an enhanced version of genetic algorithms.Like genetic algorithms, DE relies on an initial population and employs the same operators crossover, mutation, and selection.However, DE utilizes these operators in a different order, as illustrated in Figure 3.
The primary distinction between genetic algorithms and DE lies in their respective approaches to building better solutions.Genetic algorithms utilize crossover, while DE relies on the operation of mutation.In DE, the mutation operation is the primary mechanism for searching and exploring potential regions in the search space, and the selection operator directs convergence towards those regions.
According to [16], the DE/x/y/z notation is frequently employed to describe a DE strategy.The symbol x denotes the vector that will undergo mutation, which may be either a randomly selected population vector (rand) or the vector with the lowest cost in the current population (best).y specifies the number of differential vectors employed to perturb the target vector, and z denotes the crossover scheme, which could be either exponential or binomial.

Mutation Operation:
In the DE algorithm, during the generation G, the population is perturbed by the mutation operator which modifies each individual X i,G using a corresponding mutant vector V i,G .The mutation operator can be generated using different strategies, among which the most frequently employed ones are listed in [18].
− DE/current-to-best/2: − DE/current-to-rand/2: The variable V i,G represents the mutant vector that is being created.The integers r 1 , r 2 , r 3 , r 4 , and r 5 are randomly generated constants within the range [1, N P ] and different from the index j.The variable X best,G corresponds to the best individual in the population at generation G.The scale factor F is a real constant that is typically selected in the range [0, 1] and determines the degree of amplification of the difference variation.

Crossover operation
Following the mutation phase, the diversity of the population is increased through the application of the crossover operation in DE.This operation utilizes the mutant vector V i,G created during the mutation phase to exchange its components with the target vector X i,G , thereby producing the test vector U i,G .The crossover operation can be expressed using the formulation presented in [19].
In the aforementioned expression, j is an integer that varies between 1 and D. The variable rand j corresponds to the jth evaluation of a uniform random number generator that produces values within the interval [0, 1], as described in [20].The crossover rate, denoted by CR, is a constant specified by the user and takes values within the range [0, 1].Additionally, j rand is a random integer selected from the range [1, D], as stated in [20].

Selection operation
Once the test vector U i,G has been created through the crossover operation, the selection operation is carried out to maintain the population size for the next generation.To accomplish this, the objective function is evaluated for both the target vector X i,G and the test vector U i,G .The vector that yields a better fitness value is retained in the population for the subsequent generation.More specifically, if the fitness value of the test vector is superior to that of the target vector, then the test vector replaces the target vector.On the other hand, if the fitness value of the target vector is better, it remains in the population.The selection procedure is mathematically represented as shown in [21].
The three steps mutation, crossover and selection are repeated for each generation up to a termination criterion.The DE algorithm is characterized by the interaction between the different particles.The mechanism responsible for generating new potential solutions is the imitation of the global behavior of the neighborhood.Algorithm 1 presents a classic version of the DE [16]   EXPERIMENT RESULT To assess the performance of the NoC, a group of benchmarks, as described in reference [14], are employed.A benchmark comprises of a series of tasks that communicate with one another.Before presenting the result, it is crucial to specify the parameters that were employed in our study.A 4×4 NoC was utilized, and the parameters are listed in Table 1.After conducting multiple test attempts, we concluded that each application requires its own set of parameters to achieve the best results.Therefore, we have adopted the parameters presented in Table 2.We utilized multiple mutation operations to determine which one would lead us to the optimal outcome.The results obtained from the five mutation operations are shown in Table 3 Figure 5 enable a visual assessment of the mapping performance, based on the five mutation strategies utilized during the experiment, as executed by the DEMAP algorithm.The outcomes indicate that utilizing the best strategy consistently yields the optimal results, surpassing the alternative strategies employed in DEMAP.To further establish the effectiveness of our approach, we compared the results achieved using our best approach with some other techniques, as shown in Table 4  Based on the obtained outcomes, we can infer that DEMAP produces superior results compared to other meta-heuristic approaches.The results are also comparable to the best outcomes achieved using heuristic approaches, even though these approaches are typically more effective in optimizing a single objective.

CONCLUSION
The process of mapping applications onto a network-on-chip (NoC) is a complex task that is known to be NP-hard.To address this challenge, we introduce a novel approach based on evolutionary strategy, specifically the differential evolution (DE) algorithm.Our approach, named DEMAP, employs a mono-objective strategy that seeks to minimize the communication cost.The experiments were carried out on an actual Cores Graph, and the results indicate that DEMAP can produce better outcomes when the algorithm parameters are appropriately tuned.As a part of our future work, we plan to investigate the effectiveness of collaborative techniques in multi-objective optimization mapping and compare it with other established methods.

❒ ISSN: 2722- 2586 Figure 3 .
Figure 3. Genetic agorithm vs differential evolution algorithm.The parameters used in this algorithm 1 are: − D The dimension of the problem .− N The number of individuals.− F The values of the scale factor.− Cr The crossover rate.− M ax i t The maximum number of iterations M ax i t. − The Choice of Mutation Strategy.

❒ ISSN: 2722- 2586 Algorithm 1
Differential evolution algorithm Initialize the individuals of the population Evaluate all individus Initialize the best solution (Best) iteration := 0 while iteration < max iteration do for each individu do (a) Generate a mutant vector using the mutation operation4.4.1.(b) Generate the test vector using the crossover operation4.4.2.(c) Evaluate the try vector (d)If the test trial is better than the individual, replace it 4.4.3.end for Update The Best solution iteration := iteration + 1 end while Return the best solution 5.

Table 1 .
Parameter of DE used in experiment

Table 2 .
Parameter used in DEMAP algorithms

Table 4 .
. Figures 6 to 8 provide a visual comparison between the communication cost results of DEMAP mapping and the compared approach, allowing for an easy analysis of the best results.DEMAP result Compared to other approach