Julien Paganini
email: julien.paganini@xegen.fr

Pierre Pontarotti

Martin Flajnik

Search for MHC/TCR-Like Systems in Living Organisms

Keywords: convergent evolution, kin recognition, vegetative incompatibility, self incompatibility, somatic diversification, adaptive immune system evolution

Highly polymorphic loci evolved many times over the history of species. These polymorphic loci are involved in three types of functions: kind recognition, selfincompatibility, and the jawed vertebrate adaptive immune system (AIS). In the first part of this perspective, we reanalyzed and described some cases of polymorphic loci reported in the literature. There is a convergent evolution within each functional category and between functional categories, suggesting that the emergence of these self/non-self recognition loci has occurred multiple times throughout the evolutionary history. Most of the highly polymorphic loci are coding for proteins that have a homophilic interaction or heterophilic interaction between linked loci, leading to self or non-selfrecognition. The highly polymorphic MHCs, which are involved in the AIS have a different functional mechanism, as they interact through presented self or non-self-peptides with T cell receptors, whose diversity is generated by somatic recombination. Here we propose a mechanism called "the capacity of recognition competition mechanism" that might contribute to the evolution of MHC polymorphism. We propose that the published cases corresponding to these three biological categories represent a small part of what can be found throughout the tree of life, and that similar mechanisms will be found many times, including the one where polymorphic loci interact with somatically generated loci.

PREAMBLE

We develop this work mainly to determine whether MHC-like systems could be found in phyla other than vertebrates. We define an MHC-like system as consisting of a polymorphic presenting molecule (the MHC) that recognizes a small molecule and interacts with a receptor capable of somatic diversification. The possibility that MHC-like could be polymorphic is based on our earlier proposition: the MHC polymorphism is due to the limited binding properties of the MHC binding pocket, compared to the capacity of recognition of the T cell receptor [(1), see Figure 1A].

We developed here this proposal and named it "the capacity of recognition competition mechanism" (CRCM) (see below). We further propose that MHC-like systems evolved in other phyla than that of the jawed vertebrates.

This proposal is inspired by two kinds of observations:

The first kind of observation leads to the hypothesis that diversity, driven by somatic recombination, evolved many times during species evolution. Indeed the recombination activation gene (RAG), which is involved in the somatic TCR rearrangement, is a domesticated cut and paste transposon [START_REF] Tsakou-Ngouafo | Origins of the RAG Transposome and the MHC[END_REF][START_REF] Tsakou-Ngouafo | DDE Transposon as Public Goods. Evolutionary Biology-a Transdisciplinary Approach[END_REF] belonging to the DDE transposon family. It has to be noted that the number of DDE transposons found in nature is huge [START_REF] Tsakou-Ngouafo | DDE Transposon as Public Goods. Evolutionary Biology-a Transdisciplinary Approach[END_REF] and that DDE transposons have been co-opted several times as site specific recombinase.

The second kind of observation is that tripartite interaction is found in other cases that MHC plus peptide and TCR interact. This has been described in the following case: BTN3A1 recognizes, via an internal domain, a pathogen metabolite leading to a modification of the conformation of the extracellular domain leading to the activation of the Vg9Vd2 TCR [START_REF] Yang | A Structural Change in Butyrophilin Upon Phosphoantigen Binding Underlies Phosphoantigen-Mediated Vgamma9vdelta2 T Cell Activation[END_REF].

Our article is organized as follows: we first describe the different biological categories in which polymorphism loci are involved: 1) kind recognition, 2) self-incompatibility (interindividual recognition, 3) the MHC system involved in the jawed vertebrate adaptive immunity.

We will describe that recognition primarily occurs through the interaction of polymorphic ligands and polymorphic receptors and at least in one case of interaction between receptors driven by a somatic mutation and polymorphic ligands. We will then present the hypothesis that predicts the MHC-like systems exist in phyla other than jawed vertebrates.

In this article, we discuss the diversity of life using examples of different clades of species. In order to better follow the text, we advise readers to refer to the Tree of Life [(4) http://tolweb.org/tree/].

KIND RECOGNITION

Kin recognition is the body's ability to distinguish between close genetic individual (kin) and less genetically related individual (non-kin). This capacity is found throughout the diversity of life. Different mechanisms have been implemented to enforce cooperation between cells. The interaction can be helpful or harmful [START_REF] Gardner | Greenbeards[END_REF] rewarding kinship and/or penalizing non-kinship. It is important to note that, the interaction can be limited at certain loci, a process named "kind recognition". Much discrimination appears to be achieved through kind recognition rather than kin-recognition. The genes involved in kind-recognition are named "green beard" genes. Many of the described Greenbeard genes are polymorphic. The recognition between the ligand and the receptor can correspond to homotypic or heterotypic interaction. In the case of heterotypic interaction, the genes coding for the interaction protein are linked in the genome. Recognition could be selfrecognition, and this has led to cooperation, non-self-recognition; in this case it will be harmful and missing self-harmful.

Bacteria

Kind recognition has been well described for two bacterial species: Proteus Mirabilis and Myxococcus Xanthus.

Proteus mirabilis

Proteus mirabilis is capable of forming swarming colonies. Genetically different colonies do not interact, while those of genetically identical populations merge [START_REF] Saak | The Self-Identity Protein IdsD is Communicated Between Cells in Swarming Proteus Mirabilis Colonies[END_REF]. Id proteins are important for the recognition mechanism. Indeed, IdsD and IdsE encode identity information for each colony. Heterotypic complex is formed between polymorphic IdsD and IdsE [START_REF] Cardarelli | Two Proteins Form a Heteromeric Bacterial Self-Recognition Complex in Which Variable Subdomains Determine Allele-Restricted Binding[END_REF] belonging to the same operon and therefore are strongly genetically linked. They bind also in vitro in an allelerestrictive manner. Saak and Gibbs [START_REF] Saak | The Self-Identity Protein IdsD is Communicated Between Cells in Swarming Proteus Mirabilis Colonies[END_REF] demonstrated that the non-interaction between IdsD and IdsE does not cause cell death. The non-interaction leads to restricting the expansion radius of the swarming colony. Therefore, P. mirabilis communicates Ids between neighboring cells for a helpful interaction [START_REF] Saak | The Self-Identity Protein IdsD is Communicated Between Cells in Swarming Proteus Mirabilis Colonies[END_REF].

Myxobacteria

At least two systems are involved in the recognition; they operate in a subsequent manner. The first step involves the TraA/TraB receptor-ligand binding. The second step is a verification step; a polymorphic toxin is delivered to the recognized cell. Genetically identical cells will express a related immunity factor and survive, while a cell that is not genetically identical will lack immunity and die [START_REF] Wielgoss | Kin Discrimination and Outer Membrane Exchange in Myxococcus Xanthus: A Comparative Analysis Among Natural Isolates[END_REF].

The first step involves receptor-ligand binding (TraA/TraB), Myxobacterial cells can exchange their outer membrane (OME) lipoproteins OME. TraA and TraB are cell surface proteins that must be present on both interacting cells. TraA/TraB catalyze the fusion of the OME; TraA is the receptor involved in recognition. Recognition occurs if the partnering cells have identical or very similar TraA receptors. TraA is polymorphic, with hundreds of different alleles [START_REF] Wall | Kin Recognition in Bacteria[END_REF] and here, the self-recognition led to a cooperative interaction (helpful) and the missing self is therefore harmful.

During the verification step, polymorphic toxins are delivered to the recognized cell. If the two cells are from the same strain, the recognized cell will express a cognate immunity factor and survive, whereas a cell that is not from the same strain will not possess the cognate receptor and therefore will be killed [START_REF] Vassallo | Infectious Polymorphic Toxins Delivered by Outer Membrane Exchange Discriminate Kin in Myxobacteria[END_REF]. This mechanism, as described for other bacteria, corresponds to a toxin-antitoxin system [START_REF] Zhang | Polymorphic Toxin Systems: Comprehensive Characterization of Trafficking Modes, Processing, Mechanisms of Action, Immunity and Ecology Using Comparative Genomics[END_REF]. The polymorphic toxins are delivered between cells in close contact (SitA toxins). Each toxin is associated with an antitoxin, which specifically neutralizes toxicity in the producing cell and in the cells from the same strain. As expected, the genes that code for the toxin and the antitoxin are genetically linked and are coded by the same operon. Here, the missing self is therefore harmful.

Eukaryotes

Several eukaryotes are able of kind recognition; some of these mechanisms are known at the molecular level. Several examples are found in unicellular eukaryotes.

Dictyostelium discoideum

Dictyostelium discoideum have a unicellular life phase, but they aggregate upon starvation and form fruiting bodies with viable spores and dead stalk cells. The cell aggregation can lead to chimerism. Dictyostelium avoids chimerism by preferential cooperation with kin. This recognition (that participates in cell-adhesion and signaling) involves the highly polymorphic TgrB1 and TgrC1 receptors that are encoded by two adjacent genes. A pair of TgrB1 and TgrC1 alleles from the same haplotype is necessary and sufficient for the self-recognition, which is mediated by differential cell-cell adhesion. TgrB1 and TgrC1 receptors mediate this adhesion through direct binding. In fact [START_REF] Benabentos | Polymorphic Members of the Lag Gene Family Mediate Kin Discrimination in Dictyostelium[END_REF][START_REF] Ostrowski | Genomic Signatures of Cooperation and Conflict in the Social Amoeba[END_REF][START_REF] Gruenheit | A Polychromatic 'Greenbeard' Locus Determines Patterns of Cooperation in a Social Amoeba[END_REF], here, the self-recognition led to a cooperative interaction (helpful).

Fungi (here the non-kin recognition is called Vegetative incompatibility)

The systems work at two different levels: one acts post-fusion and the other pre-fusion.

Self-/Non-Self-Discriminations That Act Post-Fusion

Non-self-harmful heterotypic linked loci or homotypic polymorphisms are distributed between several loci; the different loci have the same functional properties. Here, the mechanism is different than above since the interaction occurs in the non-self-manner in ascomycetes, and basidiomycetes allorecognition can result in vegetative incompatibility. This is done via programmed cell death that occurs after fusion of cells from different strains. The recognition involves the het loci, with co-expression of any combination of incompatible alleles resulting in vegetative incompatibility. The Het code for a recognition domain and a cell death inducing domain, these domains can be found on the same protein or on different proteins. The recognition domain includes at least one polymorphic site, which defines allele specificity. Polymorphism at het loci can also involve several genes maintained in tight linkage disequilibrium, which prevents recombination. This is important in the case of heterotypic interaction [START_REF] Saupe | Molecular Genetics of Heterokaryon Incompatibility in Filamentous Ascomycetes[END_REF][START_REF] Smith | Vegetative Incompatibility in the Het-6 Region of Neurospora Crassa is Mediated by Two Linked Genes[END_REF][START_REF] Kaneko | Nonallelic Interactions Between Het-C and a Polymorphic Locus, Pin-C, are Essential for Nonself Recognition and Programmed Cell Death in Neurospora Crassa[END_REF][START_REF] Paoletti | Vegetative Incompatibility in Fungi: From Recognition to Cell Death, Whatever Does the Trick[END_REF].

Recognition is driven by several loci with two or three alleles of high specificity supported by a low polymorphism and several paralogous loci. For example, 11 loci are functional in allorecognition in the ascomycete Neurospora crassa [START_REF] Zhao | Identification of Allorecognition Loci in Neurospora Crassa by Genomics and Evolutionary Approaches[END_REF].

Here, the loci are not linked; the explanation is that in natural population, events of out-crossing, which eventually lead to the formation of self-incompatible meiotic, descendants may occur very rarely. These fungi strains are pseudo-homothallic; they have two mating-types, but spores are binucleated and almost always carry nucleic of the two sexual types. So in the end, the strains can be self-fertile and can do very little outcrossing.

Self-/Non-Self-Discriminations That Act Pre-Fusion

In ascomycete fungi, several loci are involved in self-/non-selfdiscriminations that act before the fusion step during chemotropic interactions [START_REF] Heller | Characterization of Greenbeard Genes Involved in Long-Distance Kind Discrimination in a Microbial Eukaryote[END_REF]. This has been well studied in Neurospora crassa. Recognition and chemotropic interactions between genetically identical germinated asexual spores (germlings) require oscillation of a signal transduction protein complex. Different groups of communication can be identified, in which germlings within one communication group are able to interact, while germlings from different groups of communication groups avoid each other.

Three highly polymorphic genes (doc-1, doc-2, and doc-3) found in linkage disequilibrium are involved in the communication group phenotype. The exchange of doc-1 and doc-2 alleles from different communication group strains was necessary and sufficient to define communication group identity. The ligands are not known. The deletion of doc-1 and doc-2 allows self-communication and chemotrophic interactions between non-communication groups. It is possible doc-1 and doc-2 repress a functional cascade if non-genetically identical germlings are close. Therefore, the cascade is activated when the self is missing.

The question is whether the ligand gene is close to the doc loci, or do we have some kind of education (change at the somatic level)? This is an important point to raise and will be discussed in the hypothesis section of the article.

Metazoan

Kind recognitions have been described in several clades of colonial metazoan (and likely to be present in all the colonial metazoan) desmoponges, cnidarians, ascidians, bryozoans, see for review Grosberg (21); most of the cases have been evidenced via artificial tests, such as grafting. The cases characterized in vivo are described below.

Cnidarian: Hydractinia

Hydractinia polyps, which are asexual, can join and form colonies; the junction is done via vascular-type canals. These vascular-type canals allow the stem cells of one individual to migrate into the vasculature of the fusion partner. Three outcomes can be evidenced in transplantation assays: fusion, transitory fusion, and rejection. This is controlled by highly polymorphic loci Alr1 and Alr2 that encode self-ligand protein. If colonies share at least one allele at both genes, they fuse. If an allele is shared in only one of the two genes, the colonial fusion is transient. The rejection occurs when the two individuals have different alleles for the two genes.

Hundreds of Alr2 alleles have been described [START_REF] Rosengarten | Genetic Diversity of the Allodeterminant Alr2 in Hydractinia Symbiolongicarpus[END_REF][START_REF] Moreno | Evolutionary Genetics of the Hydroid Allodeterminant alr2[END_REF] in natural population of Hydractinia [START_REF] Rosengarten | Genetic Diversity of the Allodeterminant Alr2 in Hydractinia Symbiolongicarpus[END_REF][START_REF] Moreno | Evolutionary Genetics of the Hydroid Allodeterminant alr2[END_REF], while Alr1 are expected to be similarly polymorphic [START_REF] Rosengarten | Genetic Diversity of the Allodeterminant Alr2 in Hydractinia Symbiolongicarpus[END_REF].

Urochordate Botryllus

Botryllus schlosseri colonies' contact leads to fusion or rejection. In fusion, each colony's tunic border dissolves at the contact zone; the opposing matrices and ampullae fuse, leading to a continuous circulation system. In rejection, a cell mediated inflammatory reaction prevents vascular continuity. The cells involved in the cytotoxic reaction are the morula cells [see for review [START_REF] Tomaso | Allorecognition and Stem Cell Parasitism: A Tale of Competition, Selfish Genes and Greenbeards in a Basal Chordate[END_REF]]. The fusion or rejection outcome is controlled by the histocompatibility locus FUHC fusion/histocompatibility [START_REF] Scofield | Protochordate Allorecognition is Controlled by a MHC-like Gene System[END_REF]. Fusion will occur between two colonies if they share one or both haplotypes of the Fuhc locus, while rejection will occur if two colonies share no alleles.

Given the rarity of fusion observed between randomly paired colonies, FUHC has been inferred to be highly polymorphic. Several polymorphic loci are found in the FUHC cluster, one of them, BHF, seems to play a crucial role in the allorecognition [START_REF] Voskoboynik | Identification of a Colonial Chordate Histocompatibility Gene[END_REF][START_REF] Rosental | Complex Mammalian-Like Haematopoietic System Found in a Colonial Chordate[END_REF].

Voskoboynik and colleagues [START_REF] Voskoboynik | Identification of a Colonial Chordate Histocompatibility Gene[END_REF] showed that polymorphisms on the BHF locus agree with the fusion rejection pattern, and other polymorphic loci found in the vicinity of BHF have poor fusion/rejection predictability. These outcomes have been viewed with some skepticism [START_REF] Tomaso | Allorecognition and Stem Cell Parasitism: A Tale of Competition, Selfish Genes and Greenbeards in a Basal Chordate[END_REF]. Indeed, the same analysis suggested that cfuhcsec and cfuhctm, hsp40-l, which are separated respectively 227 bp and 8 kb each and are in strong linkage disequilibrium, had different predictive abilities. However, an interesting observation published in 2018 [START_REF] Rosental | Complex Mammalian-Like Haematopoietic System Found in a Colonial Chordate[END_REF] reported that B. schlosseri Morula cells do not express BHF protein on the cell membrane. This suggests the existence of an inhibitory receptor on the morula cytotoxic cells that can recognize self-BHF. It is important to note that one of the genes that is differentially expressed by cytotoxic morula cell is sFuHC. Given the mechanism of inhibition of BHF and the significantly high expression of sFuHC in cytotoxic morua cells, it is likely that FuHC acts as a BHF inhibitory recognition receptor.

SELF-INCOMPATIBILITY IN SEXUAL REPRODUCTION AND MATING SYSTEM

In animals and plants, the sexual reproduction is due to the fusion of two gamete types of different sizes (anisogamy). In both phyla, selfincompatibility has been developed for hermaphrodites species in order to avoid self-fertilization and thus polymorphism depression. The self-incompatibility can be determined at the organism phenotypic level or at the gametic genetic level. We will focus here on the studies investigating the gametic level.

In addition to plants and animals, most of eukaryotes reproduce via the same gamete type isogamy. In order to avoid "polymorphism depression", they use the mating system. The best studied case is the one of the basidiomycetes fungi.

Mating in Basidiomycetes Fungi

In Basidiomycetes fungi, sexual reproduction is often driven by two independent sets of mating type (MAT) specific genes that control different stages of the sexual cycle. This is supported by two unlinked loci: the HD and the P/R loci. The H/D loci encode transcriptional regulators. The encoded proteins are HD1 and HD2. They correspond to two classes of homeodomain transcription that form heterodimers regulating post-mating behavior [START_REF] Kües | 6 Mating Type in Basidiomycetes: Unipolar, Bipolar, and Tetrapolar Patterns of Sexuality. In: Evolution of Fungi and Fungal-Like Organisms The Mycota (a Comprehensive Treatise on Fungi as Experimental Systems for Basic and Applied Research)[END_REF][START_REF] Nieuwenhuis | Evolution of Uni-and Bifactorial Sexual Compatibility Systems in Fungi[END_REF]. The HD1 interacts with the HD2 from a different allelic form than the HD2 self and vice versa. The number of HD1-HD2 alleles, for example in Coprinopsis Cinera, is estimated at 160. PR locus encodes one pre-mating lipopeptide pheromones and their receptors (P/Rs), which mediate recognition of mating partners and cell fusion; the pheromone will interact with the receptor of a different allelic form in a given allelic group. The number of (P/R) loci in the case of Coprinopsis Cinera has been estimated at 79.

Self-Incompatibility in Plants and Animal

In plants and metazoan, biological mechanisms exist to avoid inbreeding for the hermaphrodite; self-incompatibility can be found at the morphological (structural barrier) or genotypic level.

Two different systems have been set up during the evolutionary history of hermaphrodites: helpful non-selfrecognition and harmful self-recognition.

Self-Incompatibility in Plant

Self-incompatibility is described in approximately 40% of flowering plant species and in at least 100 families. The selfincompatibility can be found at the morphological level (structural barrier) or at the genotypic level. At the genetic level, self-incompatibility system evolved at least three times during the eudicot evolution and at least once in monocots [START_REF] Niu | Lack of S-RNase-Based Gametophytic Self-Incompatibility in Orchids Suggests That This System Evolved After the Monocot-Eudicot Split[END_REF].

Non-Self-Recognition Protection: The Most Well Described Cases Is the One of Solanaceae SRNASE mediated gametophytic self-incompatibility. The SRNASE mediated gametophytic self-incompatibility occurred after the monocot-dicot split, but before the rosids asterids split. It was replaced many times by polymorphic incompatibility, phenotypic incompatibility in most of the cases and has been also replaced at the molecular level in the case of brassicaceae by the sp11 SRK system and PrsS/PrpS in papaveraceae (sister group of the rosids asterids group).

The male and female genes are linked. The female S determinant is an S-RNAse, the male S determinant encodes an F-box protein (SLF), which recognizes and detoxifies the female-determining S-RNases from another haplotype. The SLF forms multigene families (formed of several paralogs). Each paralogous SLF protein specifically interacts with one or more S-RNAse proteins of other S-haplotypes. High polymorphism and sequence divergence of the SRNase genes and conservation of a high sequence of SLF genes from different haplotypes are found [START_REF] Niu | Lack of S-RNase-Based Gametophytic Self-Incompatibility in Orchids Suggests That This System Evolved After the Monocot-Eudicot Split[END_REF][START_REF] Bod'ova | Evolutionary Pathways for the Generation of New Self-Incompatibility Haplotypes in a Nonself-Recognition System[END_REF][START_REF] Fujii | Non-Self-and Self-Recognition Models in Plant Self-Incompatibility[END_REF].

The explanation of the processes is that the SLF, the paralog recognizing the self S-RNAse, is counter-selected as this would result in polymorphism depression leading to decreased fitness (33).

Self-Incompatibility via Self-Recognition in Plant

Here, the recognition of self prevents fertilization. This results in tight coevolution between male and female determining components in a single haplotype. If the two loci are separated, fertilization can occur and cause inbreeding depression, so the two loci must co-evolve.

These self-histocompatibility mechanisms have been very well studied in two model groups: Brassicaceae and Papaveraceae.

Brassicaceae. The S-locus in the Brassicaceae carries two tightly linked and highly polymorphic S-determinant genes. The S-Locus protein 11 (SP11) or S-Locus cysteine rich protein (SCR) is the male S-determinant: SP11 is a secreted peptide located in the pollen coat. The S-locus Receptor Kinase (SRK) is the female S-determinant. SRK corresponds to a transmembrane protein belonging to the ser/ thr receptor kinase family. SRK is located on the plasma membrane of the stigma papilla cells. Direct and specific molecular interaction between SP11 and SRK from the same S-Haplotype induces the incompatibility response in the stigma leading to self-pollen rejection.

Papaveracea. Male and female S determinants carry two closely related and highly polymorphic genes. The female S determinant: PrsS encodes a small protein secreted by papilla cells of the stigma. The male S determinant: PrpS encodes a small protein with several predicted transmembrane folds. The system is not as well understood as that in the case of brassicaceae. However, the specific interaction between PrsS and PrpS from the same S-haplotype results in self-rejection of the self (same Shaplotype); specific PrsS binding to its cognate PrpS on pollen plasma membrane elicits Ca2+ influx in the pollen tube, which triggers SI responses, leading to programmed cell death.

Self-Incompatibility in Animals

Self-incompatibility has been described for many tunicates and cnidarians. However, the mechanism is only known for the ascidian Ciona Intestinalis [START_REF] Harada | Mechanism of Self-Sterility in a Hermaphroditic Chordate[END_REF][START_REF] Sawada | Self/non-Self Recognition Mechanisms in Sexual Reproduction: New Insight Into the Self-Incompatibility System Shared by Flowering Plants and Hermaphroditic Animals[END_REF]. The SI system in Ciona intestinalis is similar to those of Papaveracea and Brassicaceae. The products of the sperm-side and egg-side multiallelic SI genes, which are closely related and highly polymorphic, appear to be responsible for the Self-incompatibility, as revealed by genetic analysis. The male-side S-determinant located in sperm head surface in animals and femaleside S-determinant located in the vitelline coat of animal eggs recognize each other. When it is recognized as the same haplotype allele, fertilization is blocked.

Self-incompatibility can be found in other hermaphrodite animals, such as coral, but the self-incompatibility system does not seem to be driven by molecular mechanism [START_REF] Carlon | The Evolution of Mating Systems in Tropical Reef Corals[END_REF]. More investigations have to be carried out for animals. Nonetheless, it is likely that similar molecular systems will be found.

THE MHC SYSTEM

Two characteristics are specific to the MHC: 1) the system is involved in self non-self-interaction and interacts with a receptor (a tripartite recognition system); 2) the receptor (T cell receptor) diversifies at the somatic level. In order to better understand our hypothesis, it is useful to describe cases of self-self interaction and direct recognition using somatic diversification mechanisms.

Cell-Cell Recognition From the Same Individual, Interactions Between Loci Able to Perform Alternative Splicing and Regulation of Isoform Expression

Neural Development: Self-Avoidance During Neural Development Cases

During the neural development in many animals, self-avoidance ensures that a neuron's process arborizes to evenly fill a particular spatial domain [START_REF] Kramer | Developmental Arborization of Sensory Neurons in the Leech Haementeria Ghilianii. II. Experimentally Induced Variations in the Branching Pattern[END_REF]. At the individual neuron level, self-avoidance is driven by genes encoding cell-surface molecules [START_REF] Hattori | Dscam-Mediated Cell Recognition Regulates Neural Circuit Formation[END_REF][START_REF] Thu | Single-Cell Identity Generated by Combinatorial Homophilic Interactions Between Alpha, Beta, and Gamma Protocadherins[END_REF]. This is done by generating thousands of different isoforms due to alternative splicing, such a as Dscam1 in drosophila and homophilic avoidance [START_REF] Hattori | Dscam-Mediated Cell Recognition Regulates Neural Circuit Formation[END_REF], or, as in the case of vertebrates, by using a homophilic interaction between different isoforms from a multigene family (protocadherin), which are expressed in a combinatorial way; a single mismatch can infer with the combinatorial homophilic interaction [START_REF] Thu | Single-Cell Identity Generated by Combinatorial Homophilic Interactions Between Alpha, Beta, and Gamma Protocadherins[END_REF]. Consequently, the recognition of cell identity is due either to the homophilic recognition of a system capable of generating thousands of isoforms, or to a system using the combination of several possible isoforms.

NK System

Individual Ly49 receptors in mouse and KIRs in humans are expressed in a stochastic and independent manner on NK cells. This mechanism allows the formation of a unique 'NK cell repertoire' in each individual, which is characterized by the coexistence of several NK cell subsets, each expressing from zero to five receptors. The composition of the NK cell repertoire is determined by several factors. Among these latter, the MHC repertoire is an important player as it affects the composition of the final Ly49/KIR repertoire and thus contributes to NK cell education. The NK cell education results from the differential interaction between the different MHC alleles and NK receptors.

It has to be noted that the interaction between the NK receptors and MHCs could be very ancient [START_REF] Vivier | The Evolution of Innate Lymphoid Cells[END_REF] and that the NK system may therefore have played a role in the emergence of MHC polymorphism [START_REF] Norman | Co-Evolution of Human Leukocyte Antigen (HLA) Class I Ligands With Killer-Cell Immunoglobulin-Like Receptors (KIR) in a Genetically Diverse Population of Sub-Saharan Africans[END_REF].

However, to date, the NK system is not well known outside of the mammalian phyla. This will be discussed later in the article.

Direct Recognition With Self and Non-Self via Somatic Diversifying Selection

Olfactory System (Direct Interaction With Non-Self)

The odorant receptor genes (ORs) encode seven transmembrane receptor proteins that form the largest mammalian protein family. ORs are expressed monogenically and monoallelicaly in each olfactory epithelium neuron. The olfactory system is fantastically discriminating, so it uses a combinatorial receptor coding scheme to encode olfactory identities. Indeed, one OR can recognize several odorant molecules, and one given odorant is recognized by multiple ORs. However, the different odorant molecules are recognized by different combinations of ORs [START_REF] Malnic | Combinatorial Receptor Codes for Odors[END_REF].

Immunoglobulin Diversity (Direct Interaction With the Self and Non-Self)

The jawed vertebrates' adaptive immune system includes the immunoglobulin, the T-cell receptors (TCR) and the MHC. Immunoglobulin and TCR recognize antigenic determinants through the variable (V) regions, whose diversity is generated by V(D)J module recombination. The Immunoglobulin and TCR repertoire is increased thanks to the junctional diversity. This process corresponds to the addition of non-templated encoded nucleotides (N) at V(D)J junctions. Immunoglobulin directly recognized antigen, while, in the case of TCR, the recognition of the antigen involved a presentation of the antigen via the MHC, see after in text. The recombination-activating gene products (RAG proteins) constitute the enzymatic core of the V(D)J recombination machinery of jawed vertebrates. RAG catalyzes random assembly of variable, diverse, and joining gene segments that are present in the jawed vertebrate genome in numerous copies and together with hyper-mutation generate the enormous diversity of the assembled antibodies and T-cell receptors. The rearrangement occurs via repetitive elements at the edge of the rearranging segments, having a conserved heptamer and nonamer sequence separated by a space of either 12 or 23 base pairs: the recombination signal sequences or RSS [see for review Teng [START_REF] Teng | Regulation and Evolution of the RAG Recombinase[END_REF] and references]. The VDJ recombination mechanism is similar to the DDE transposon. Indeed, the DDE transposons encode for a transposase coding gene flanked by two Terminal Inverted Repeats (TIRs). To achieve transposition, the transposase recognizes these TIRs to perform the excision of the transposon which is then, or in concert with the excision, reinserted into a new genomic location. A DDE transposon (DNA cut and paste transpososon) named the RAG transposon, which is homolog to the RAG VDJ, has been described in non-vertebrate species (see for review 1). A likely hypothesis is that that the RAG DDE transposon invaded in the jawed vertebrate ancestor an IG-Like gene eventually resulting in the antibody/TCR rearrangement [START_REF] Tsakou-Ngouafo | Origins of the RAG Transposome and the MHC[END_REF][START_REF] Fugmann | The Origins of the Rag Genes-From Transposition to V(D)J Recombination[END_REF].

A different recombination system is used in birds and some mammals to generate the immunoglobulin diversity. Indeed, only one pair of functional V and J segments are found for both the Ig light and heavy chain loci, and several pseudo V coding segments are found upstream the functional V segments in genes coding light and heavy chains. These pseudo-V segments are used as template for gene conversion to diversify the single functional V segment. To launch the diversification process, a break done by the Activation-induced deaminase (AID) within the single functional V segment is required [see for example [START_REF] Arakawa | Requirement of the Activation-Induced Deaminase (AID) Gene for Immunoglobulin Gene Conversion[END_REF]].

The Agnathe VLR System/Direct and Maybe Tripartite Recognition System

In cyclostomes (agnathe vertebrates), the variable lymphocyte receptors (VLRs), the VLR system involved in adaptive immunity includes a germline VLR that does not code for functional protein, but encodes instead the only portion of the amino and carboxyl termini of the mature VLRs. The sequences encoding those portions are separated by non-coding intervening regions. In lymphocytes, the germline VLRs are assembled by somatic DNA rearrangement into a mature VLR that encodes the functional receptor via the insertion of LRR cassette that flanks the germline VLR. The germline VLR is broken by the AID-APOBEC enzyme at the intervening sequences between the C terminal and N terminal portion of the VLR genes. Then, gene conversion starts, thanks to sequence identity between the intervening sequence and sequences surrounding the LRR cassettes [START_REF] Boehm | Quality Control in Self/Nonself Discrimination[END_REF]. The VLR could be secreted (expressed in agnathes B cell like): VLRB or transmembrane protein VLRA and VLRC (which are expressed in abT cell like gd T cell like). It is not known whether VLRA and VLRC interact with an MHC analogous structure.

MHC/T-Cell Receptor Somatic Diversity and Self Non-Self-Recognition: The Capacity of Recognition Competition Mechanism Hypothesis

The central interaction in cell-mediated adaptive immunity lies between the abT cell antigen receptor (ab TCR) and MHC class I and MHC class II antigen-presenting molecule loaded with peptides. MHCs are highly polymorphic genes: more than 6,000 MHC allomorphs have been described so far [START_REF] Robinson | Ipd-IMGT/HLA Database[END_REF]. The polymorphism is localized around the peptide-binding cleft of the MHC protein. The different MHC allomorphs have distinct peptide-binding preferences that are determined by anchor residues that reside within MHC pockets [START_REF] Rossjohn | T Cell Antigen Receptor Recognition of Antigen-Presenting Molecules[END_REF]. MHC allomorphs can present several thousand peptides [START_REF] Sarkizova | A Large Peptidome Dataset Improves HLA Class I Epitope Prediction Across Most of the Human Population[END_REF] with more or less overlaps between loci. The combination of MHC plus peptide is recognized by T cell receptors. The generation of the T cell receptor diversity occurs during T cell ontogeny in the thymus. The size of the TCR repertoire has been estimated to be around 2 × 107 [START_REF] Bradley | Using T Cell Receptor Repertoires to Understand the Principles of Adaptive Immune Recognition[END_REF]. Further, TCRs recognize multiple peptide/ MHC complexes (TCR cross-reactivity or polyspecificity) [START_REF] Mason | A Very High Level of Crossreactivity is an Essential Feature of the T-cell Receptor[END_REF][START_REF] Sewell | Why Must T Cells be Cross-Reactive?[END_REF][START_REF] Wucherpfennig | Polyspecificity of T Cell and B Cell Receptor Recognition[END_REF].

Therefore, MHC proteins have a limited capacity of presenting peptides compared to the capacity of the TCR to recognize different sets of MHC plus peptides. This could explain MHC polymorphism. Indeed, new variations given to a new peptide interaction that would be recognized by a T cell receptor could not be fixed in an individual as this would result in the loss of the binding property of another peptide from a given pathogen present in the environment. Therefore, the mutation will be counter-selected. However, the fixation can occur in an individual living in an environment where the pathogen is absent, leading to polymorphism. We name this mechanism: The capacity of recognition competition mechanism.

We first proposed this mechanism to explain the origin of the MHC polymorphism in the context of the origin of the adaptive system of jawed vertebrates [Figure 1 and (1)]. We proposed, before the origin of the jawed vertebrate adaptive immune system, that the pre-MHC system was able to recognize some Pathogen-associated molecular patterns (PAMPs) and present them to receptors able to recognize the pre-MHC plus the PAMPs. The evolution of the system was low and likely limited to some pathogens. Indeed, even if the receptors (T cell like receptor) could be encoded by large multigenic families, and this was likely (1), they could recognize only a few couples pre-MHC/PAMPs. Therefore, even though pre-MHC could recognize a new antigen, thanks to a new mutation, as this new couple will not be recognized by the T cell like receptor, substitutions will not be selected and eventually lost (maybe the new MHC variant will lose the possibility to interact with another pathogen).

T cell like receptors could have increased their diversification, thanks to the integration of the RAG transposon in the module of recognition of the ancestor of the T cell-like receptor. This event led to an increase in the recognition possibilities [START_REF] Tsakou-Ngouafo | Origins of the RAG Transposome and the MHC[END_REF][START_REF] Fugmann | The Origins of the Rag Genes-From Transposition to V(D)J Recombination[END_REF], as many receptors could be present, thanks to rearrangement. Therefore, mutations in the pre-MHC leading to a recognition of new pathogens could be positively selected. Of course, selection of polymorphic MHC could be also due to other interactions, such as the one with the NK receptor that can enhance the MHC polymorphism, but this is not incompatible with the capacity of recognition competition mechanism.

In the next paragraph, we will propose that receptors that encoded highly polymorphic loci interacting with receptors generated by somatic mutations could be present in many systems involved in the adaptive recognition processes.

PROPOSITION: THE TIP OF THE ICEBERG

Our analysis only describes a very small part of the cases present in nature. It is likely that the receptor for interacting polymorphic ligands will be found several times in the case of loci involved in the kin recognition and self-incompatibility.

Many cases of kind and self-incompatibility have been reported in the literature, but the molecular mechanism remains unknown.

For kind recognition, many examples are found in: protists (54), a colonial vertebrate [START_REF] Grosberg | The Evolution of Allorecognition Specificity[END_REF], and bacteria [START_REF] Wall | Kin Recognition in Bacteria[END_REF].

There are many cases of self-incompatibility in plants and animals [see for example [START_REF] Carlon | The Evolution of Mating Systems in Tropical Reef Corals[END_REF]] and it is likely that species with several types of mating are found in eukaryotes, because most of them are isogamous eukaryotes [START_REF] Speijer | Sex is a Ubiquitous, Ancient, and Inherent Attribute of Eukaryotic Life[END_REF]. We can predict that, in these cases, polymorphic interacting loci will be found. They will be easy to identity via population genomic analysis, as shown very nicely by Zhao et al. [START_REF] Zhao | Identification of Allorecognition Loci in Neurospora Crassa by Genomics and Evolutionary Approaches[END_REF].

What about the MHC-like systems? We mainly carried out these analyses in order to assess whether MHC-like systems could be found in phyla other than vertebrates. We defined an MHC-like system as a system that consists in presenting molecules encoded by polymorphic loci that recognize small molecules and interact with receptors generated via somatic diversification. The possibility that MHC-like could be polymorphic is based on our earlier proposition that the MHC polymorphism is due to the limited binding properties of the MHC binding pocket (1) (see Figure 1A) compared to the capacity of recognition of the T cell receptor (almost unlimited). A phenomenon that we called "the capacity of recognition competition mechanism" (see above).

We propose that other somatically diversifying systems could have driven the emergence of polymorphic loci via non-selfabiotic or biotic component. This is because mechanisms of the generation of somatic diversity and tripartite interactions evolved many times during life history. Indeed, rearranging processes involved in the gene somatic diversification evolved in a convergent manner via the convergent use of gene conversion (VLR) or via the use of site specific recombinase systems (RAG) [(1) see Figure 1B]. As mentioned earlier, RAG is a domesticated RAG transposon. The main difference between the VDJ RAG and the RAG transposon is the fact that the excised fragments in the case of the VDJ recombination lost the properties to insert new genomic location by losing the integrase activity of the transposase (1). This evolutionary functional shift did not require dramatic changes. This must be related to the fact that many DDE transposons have been recruited as site-specific recombination system several times during evolution [START_REF] Tsakou-Ngouafo | DDE Transposon as Public Goods. Evolutionary Biology-a Transdisciplinary Approach[END_REF]. As the number of DDE transposons found in nature is huge [START_REF] Aziz | Transposases are the Most Abundant, Most Ubiquitous Genes in Nature[END_REF], we propose that some of them could have been recruited as site specific recombinase involved in the generation of high somatic diversity and, therefore, in the capacity of recognition competition mechanism leading to polymorphic counter receptors.

The MHC system is not the only one capable of a tripartite interaction. Indeed, Vg9Vd2 T-cells detect tumor cells and microbial infections through the recognition of phosphoantigens (pAgs). The recognition is mediated by a member of the butrophylin family: butyrophilin 3A1 (BTN3A1). The intracellular domain of BTN3A 1: B30.2 binds pAg through a positively charged surface pocket inducing a modification of the conformation of the membrane butyrophilin BTN3A1. This conformation shift is recognized by the Vg9Vd2 TCR ( 58) and drives T cell activation. In that case, BTN3A1 is not polymorphic. However, this shows that tripartite interaction involving a presenting molecule that interacts with a self or non self molecule forming a complex recognized by a receptor evolved in a convergent manner.

CONCLUSION AND PERSPECTIVES

In conclusion, we hypothesize that other MHC-like systems will be found in other living organisms. In the next chapter we propose a strategy to search for them and discuss their possible function.

How to Find MHC-Like Systems?

The strategy combines two approaches: the search for polymorphic loci and for rearranging loci. If both loci are found for the same organism, it could be a MHC/TCR-like complex.

Search for polymorphic loci: To evidence such loci, the strategy to used is the following: to have a genome of reference and many sequenced genomes from the same species (no need to finish sequences); map the polymorphic sites and look for the most polymorphic loci (they can be several); they could be the candidate, see [START_REF] Zhao | Identification of Allorecognition Loci in Neurospora Crassa by Genomics and Evolutionary Approaches[END_REF][START_REF] Abi-Rached | Immune Diversity Sheds Light on Missing Variation in Worldwide Genetic Diversity Panels[END_REF][START_REF] Paganini | Validation of New HLA-F Alleles Assigned by Next-Generation Sequencing[END_REF].

Search for somatic diversification: Somatic diversification can occur via different mechanism rearrangements, expression of different combinations of paralogs, like the protocadherin example, but we will need a lot of paralogs. The same can be said for alternative splicing. The rearrangement strategy seems to be a more efficient system to generate diversity. Rearrangement can occur via different mechanisms (site directed recombination, gene conversion…). So far, many simple programmed rearrangements (rearranging two loci) have been described [see for a complete review [START_REF] Tsakou-Ngouafo | Origins of the RAG Transposome and the MHC[END_REF][START_REF] Tsakou-Ngouafo | DDE Transposon as Public Goods. Evolutionary Biology-a Transdisciplinary Approach[END_REF]]. Rearrangement should occur between several sets of paralogous genes with a combinational joining (a set of germ line linked paralog gene segments), able of combinational joining with segments of another set of linked paralog gene segments to create a functional loci (able to code for a protein) with the addition of diversity. This could be driven via gene conversion, where a module copy in a bona fide gene is replaced by a module. Except if the replacing modules are huge, we do not expect a lot of diversity from this process. However, the process that occurs via a domesticated DDE transposon is expected to increase diversity via the p diversity and n diversity. The p diversity is due to the way the domesticated DDE transposon cuts at the recognition sequence. We know that RAG and some families of DDE transposons [see for review [START_REF] Tsakou-Ngouafo | Origins of the RAG Transposome and the MHC[END_REF]] are able to create hairpin when they excise their hairpin and are then cut in an asymmetric way via the nuclease. Artemis will provide later palindromic diversity during the junction. Further, some nucleotides can be deleted, so domesticated DDE transposon able to generate hairpin could be the champion of the generation of diversity. The experimental in silico design would be as follows: look for a similar organization than the IG and TCR locus: we will look, for example, for a gene fragment named A and a gene fragment named B that are linked on the same transcript, with the following organization at the genomic level: A found in multi-copies, with each copy close to each other, followed by fragment B with the same organization as A. We will evidence the RSS bordering A and B by comparing the sequence flanking A and B with the TIR from the different transposon families. The family of transposons where the RSS comes from will therefore be identified, and this will allow the domesticated transposase to be evidenced. The genome of the cell or tissue where the domesticated transposase is expressed will be sequenced and compared to the germline genome.

What Could Be the Function of MHC-Like System?

Intuitively, we could think that the MHC-like system could be involved in other possible cases of adaptive immunity or in the recognition of very diverse elements present in the environment, such as odors that could influence our comportment. However, it could also be involved in kin recognition as well. Indeed, vertebrate MHC is involved-as its name says-in graft rejection in case of histocompatibility. The graft rejection is due in fact to the positive and negative selection of the TCR, which, depending on the MHC allotype (and also on the minor histocompatibility antigens), will result in two different repertoires, and some TCRs from the individual A reacts with the MHC of an individual B (if the allotype is different). Even if this is artificial (graft does not occur in nature, at least in vertebrate), it is still a possibility that h colonial species could use a MHC-like system.

FIGURE 1 |

 1 FIGURE 1 | We proposed a hypothetical model whereby the ancestral MHC-like molecule bound certain pathogen-associated molecular patterns (PAMPs), presenting them to ancestral TCR-like molecules. (A) The ancestral MHC-like molecule may have been limited to just a few pathogens and each ancestral TCR-like molecule might have recognized only a particular class of PAMP bound to the ancestral MHC-like molecule. A mutation in the ancestral MHC-like molecule may have allowed the binding of a new PAMP, but this new combination could not be recognized by the ancestral TCR-like molecule. As a result, the new MHC-like molecule would be lost by genetic drift. (B) The integration of the recombination-activating gene (RAG) transposon into an ancestral TCR-like gene may have led to a significantly increased probability of recognition by these original, non-diverse TCRs. Thus, mutations in the ancestral MHC-like molecule may have led to a conformational ability to bind new PAMPs; consequently, mutated MHC molecules could have been recognized by diverse TCRs thereafter, becoming evolutionarily selected via three mechanisms: peptide-binding promiscuity, allelic polymorphism, and expansion into multigene families. The expanded ability of this ancient MHC/ TCR system to recognize new PAMPs would presumably allow peptides to be bound, presented, and recognized during an immune response. We propose in the present article that this phenomenon could be universal. This figure has been reprinted with permission from Tsakou-Ngouafo et al. (1).

Frontiers in Immunology | www.frontiersin.org May 2021 | Volume 12 | Article 635521

Paganini and Pontarotti MHC-Like System Frontiers in Immunology | www.frontiersin.org May 2021 | Volume 12 | Article 635521

ACKNOWLEDGMENTS

The authors would like to thank many comparative immunologists and evolutionary biologist colleagues for helpful discussions and the Cookietrad Company for formatting and English editing.

FUNDING

This research was funded by the French Government under the "Investissements D'avenir" (Investments for the Future) programme managed by the Agence Nationale de la Recherche (ANR, fr: National Agency for Research), (reference: Mediterraneé Infection 10-IAHU-03) and XEGEN R&D company funding.

DATA AVAILABILITY STATEMENT

The original contributions presented in the study are included in the article/supplementary material. further inquiries can be directed to the corresponding authors.

AUTHOR CONTRIBUTIONS

Analysis and writing the manuscript: JP and PP. All authors contributed to the article and approved the submitted version.

Conflict of Interest:

The authors declare that the research was conducted in the absence of any commercial or financial relationships that could be construed as a potential conflict of interest.


Manel Khlif

Mohamed Shawky

Co-modelling and simulation with multilevel of granularity for real time electronic systems supervision

This paper describes a new modelling and simulation approach in order to observe the system behaviour and eventual faults. It is based on hardware-software co-modelling with multi-level of granularity to get multi-level of simulation speed. Our modelling approach let integrate the hardware specifications to the functional model in order to establish also hardware supervision models after HW/SW co-modelling and simulation.

To reach this objective we have to have a relationship between the desired accuracy of the supervision and the level of granularity of the hardware-software model, for every ECU (Electronic Computing Units) that belongs to an automotive embedded architecture.

Introduction

The technological development encourages the car manufacturers to propose advanced functions for driving assistance that involve more than one computing unit. In fact, a computing unit uses information issued from sensors or other computing units, illustrating a "system with distributed functions". In a vehicle, the functions are sometimes distributed on several components or subsystems (computing units, wires, sensors, actuators…), communicating with a specific interconnection network [START_REF] Paret | Multiplexed Networks for Embedded Systems: CAN, LIN, FlexRay, Safe-by-Wire[END_REF]. However, one of the disadvantages of this distribution is the difficulty of the real time supervision to detect and localize a hardware fault.

To bring out the advantages of a highly distributed architecture, we propose a modelling methodology that benefits from the existing link between the software and the hardware platforms.

Our contribution in this paper is related to the very first phase of model-based diagnosis [START_REF] Hamscher | Readings in model-based diagnosis[END_REF]. We reproduce the appropriate behaviour of the system in a set of comprehensible models showing at the same time the hardware and the software behaviours (Figure 1).

Functional models

Hardware description models

Hardware-software co-models

Co-simulation

System observation for diagnosis To present our contributions, this paper is structured as follows:

First, we present the need of hardware-software co-modelling for fault detection.

Then, we present the related works done in the field of the HW-SW co-design.

In section 4, we explain our contribution. We show a relationship between the accuracy required for fault detection and the level of granularity required for the hardware-software co-model. We try to find the good compromise between fault detection accuracy and the simulation accuracy.

In section 5, we use SystemC as a working environment for the hardware-software co-modelling of our embedded electronic architecture. We present the results in sections 6 and 7.

Finally, in the last section we conclude this paper and present our future works.

Need of Hardware-Software comodelling

Usually, car manufacturers use software models expressing the embedded functions. However, when the hardware architecture reaches a complicated level of functional distribution, it becomes difficult to a diagnosis designer to maintain the hardware-software link for each sub-function of the system in the diagnosis model, especially in systems with highly distributed functions.

We believe that every sub-function has a link with at least one hardware sub-component, and a hardware fault appears in the system as a functional fault. So if we detect the functional fault we can localize the hardware fault if we know exactly the existing link between the sub-function and the hardware subcomponent (Figure 2). The electronic distributed architecture that we study is embedded on board of a vehicle. Its "Software Architecture" describes the implementation of application functions proposed to us by a car manufacturer using the "Hardware Architecture" that represents all the hardware resources: it is composed of a set of ECUs connected by the interconnection bus CAN (Controller Area Network) [START_REF] Paret | Le bus CAN description : de la théorie à la pratique[END_REF].

Every ECU is composed by a processor, a memory, CAN interface and eventually Inputs/Outputs. We aim at modelling the functional distribution on this hardware architecture to simulate distributed real time software-hardware architecture. It allows the supervision designer to use the comodels for simulations to test and observe the system behaviour, off-line without being intrusive.

The existing techniques of fault detection and diagnosis, especially of electronic systems, are mainly based on functions and algorithms without hardware components description (architecture and behaviour), and need to be more accurate by expressing simultaneously both hardware and software behaviours, in order to lead to more accurate results of fault detection.

In the next section, we present some research works adding hardware information to the functional model in order to enhance systems manipulations.

Hardware-Software co-design for supervision

Within the context of co-design methodologies, concurrent hardware and software techniques have been proposed in the literature employing for example SpecC to add more detail at the specification level [START_REF] Gajski | SpecC: Specification Language and Methodlogy[END_REF]. The adoption of various formal languages for co-simulation, like SDL and C [START_REF] Gioulekas | Heterogeneous system level co-simulation for the design of telecommunication systems[END_REF] is mainly used for the design of reactive systems like telecom systems such as wireless protocols employing different and standardized formalisms. On the other hand, functional models compatibles with HDL (Hardware description language) models [START_REF] Wong | Hardware/software co-design language compatible with VHDL[END_REF] are used to get accurate hardware specifications using for example RTL (Register Transfer Level) level of modelling. However, when it concerns HW-SW codesign for tests and observation, system's behaviour and properties are specified in a single formal language such as in [START_REF]Modelling of Fault-Tolerant Computing Systems[END_REF] and [START_REF]Dependability Analysis in HW-SW codesign[END_REF].

In this paper, we are not interesting by dependability analysis (fault simulation, estimation of optimal diagnostic strategies, etc,), but we focus on on co-modelling the appropriate behaviour of a system for diagnosis.

Multilevel of granularity co-modelling

Our objective is also to develop a relationship between the accuracy of the expected on-line fault detection and the level of granularity of softwarehardware co-modelling (Figure 3).

Sub-system co-modeled with a "g" granularity level

Functional model

A fault

Hardware description model

The hardware source of fault As a first step, we have to model the hardware architecture as a set of hardware sub-components, and then we have to model the software platform as a set of sub-functions allocating them to the modelled hardware sub-systems. As a second step, we schedule the priorities of the sub-functions, allocating the needed accuracy level of supervision to each priority. Then, we allocate a granularity level of co-modelling to every priority, in order to co-model every subfunction with a corresponding granularity level (Figure 4).

s-f 1.2 s-f 2.3 s-f 3.1. . . ECU1 ECU 2 ECU 3 .
.

"a" <->"g"

Requested accuracy "a" for supervision Figure 4. Granularity-accuracy relationship

Working environment 5.1 SystemC

SystemC is a language built in standard C++ by extending the language with the use of class libraries. SystemC addresses the need for a system design and verification language that spans hardware and software.

One of the most promising systemC advantages is hardware-software co-modelling to develop virtual platforms, because it supports a unified language of hardware-software modelling [START_REF] Cai | Transaction level modelling: An overview[END_REF].

We have also selected SystemC as a working environment because it has many advantages:

• SystemC allows hierarchical modelling to express the multilevel of granularity modelling • It allows HW/SW modelling with the same language • The models could be easily connected to any other hardware models [START_REF] Bombana | SystemC-VHDL cosimulation and synthesis in the HW domain[END_REF], or functional models (e.g. in Simulink) [START_REF] Boland | Using Matlab and Simulink in a SystemC verification Environment[END_REF][14]

• SystemC environment includes also a simulator: it consists of a C++ library and an event-based motor for simulation • Any C or C++ library can be included in a HW/SW co-model Hence, we can describe the appropriate behaviour of the electronic embedded system with different levels of hierarchy. Thus, every sub-system that should be under supervision can be hierarchically comodelled.

The TLM modelling

Transaction-level modelling (TLM) is a high-level approach to model digital systems where details of communication among modules are separated from the details of the implementation of functional units or of the communication architecture. Communication mechanisms such as busses or FIFOs are modelled as channels, and are presented to modules using SystemC interface classes [START_REF] Grötker | System Design with SystemC[END_REF].

Cycle Accurate TLM use case describes a category of levels of abstraction that could be cut into finer divisions. A Cycle Accurate (CA) model is a TLM model that represents the stage of communication refinement, in which communication is modelled accurately down to the level of bus cycles, and even clock cycles. CA modelling allows hardware verification, evaluating the state of every component in every cycle and running software device drivers. CA simulation speed varies between 10 and 100 KHz. A CA model consists of a set of processes that run once per cycle. This fits with the use of SC_METHOD processes and non-blocking calls.

Sub-system co-model (with "g" granularity level)

In [START_REF]Transaction-Level Modelling with SystemC[END_REF], Ghenassia, F. shows that TLM projects do not require a lot of effort and time to be correctly modelled compared to RTL projects. In fact, a Cycle Accurate project may need approximately half of the time compared to an RTL project for its realization.

For these advantages, we have used the CA level to co-model our HW/SW platform as shown in the next section.

Co-modelling using multilevel of granularity

We co-modelled with TLM, hierarchically, each hardware-software sub-system beginning by the highest level of granularity. Thus, on each level of granularity, we find a set of models representing at the same time the functional behaviour and the hardware architecture. Another interesting feature is in simulation; it is possible to switch between two or more levels of granularity according to the criticality level of eventual faults and the diagnosis system needs (e.g.: functions priorities).

ECUs and CAN bus modelling

The whole architecture consists of n ECUs communicating through the CAN network. In this part of the work, we have modelled the CAN protocol real-time behaviour to realize communications between ECUs models. We have simplified the details to ease the modelling; by implementing a virtual arbiter in the bus. With the Transaction modelling, the communication between components is described as function calls.

Each ECU is master and slave at the same time and has one bidirectional port in each module (Figure 5). It is used to send orders to the bus (Requests) and getting data and information from the bus (Responses). Each ECU that wants to send a message sends a request to the bus. If at least 2 ECUs request a bus transmission at the same time (i.e. in a time shorter than a bus cycle), the bus arbiter selects the most important message by comparing arbitration fields in the two messages.

Only one clock is used for all processors when the level of granularity is high and the accuracy of the model for simulation is set to the ECU clock cycle.

It is important to note that full CAN protocol is used only in models with high level of granularity, expressing transactions between ECUs. With a more accurate level of granularity, the processor and the memory models of every ECU are wrapped into SystemC modules in order to communicate with other devices such as CAN controllers. Anyway, the transactions are kept cycle accurate.

Interfacing hardware-software models

The communication between hardware and software modules should be done through messages exchange. This message exchange is using a shared interface between the two sides implementing the appropriate methods for messages exchange and eventually using blocking calls (Figure 6).

We have co-modelled in SystemC a sub-function of Smart Distance Keeping (SDK); a given function from a truck manufacturer. "SDK" is the name given to the "enhanced Adaptive Cruise Control (ACC) function", mainly to distinguish a regulation only based on a fixed distance of 50m (ACC compliant to the regulations for heavy trucks) from a regulation that takes the relative vehicles dynamics into account. Thus, the SDK maintains a safe headway time, i.e the inter-vehicle distance is varying as a function of the velocity and is likely to be less than the legal 50 meters at intermediate speeds an embedded radar detects continuously the target [START_REF] Claeys | Chauffeur Assistant Functions. Report restricted to RENAULT TRUCKS[END_REF]. Figure 6 shows an example of the embedded radar interface sending the acquired date to an ECU (the hardware module), which is responsible for extracting the current distance between the two vehicles from the received data, to compare it with the safety distance.

Test and validation

The presented modelling method allows the supervision designer to simulate and test the system off-line with various levels of accuracy without being intrusive, or to re-use the TLM models for real time embedded simulation for fault detection. If the supervision designer uses the same models for the onboard simulation for fault detection, the duration of fault detection based on the simulation of a model in a level "i" of granularity is calculated as follows (1):

With N is the number of components (level i)

Fault detection duration (level i ) <= ∑ = N j 1 simulation duration (j) (1)
Thanks to the high-speed systemC simulation compared to RTL simulations, the supervisory system decreases the fault detection duration (see section 5).

We have tested our approach with Smart Distance Keeping system . The supervisory system can simulate the different SystemC co-models beginning by the highest level of hierarchy. In case of incoherence detection in a level of the hierarchy, SystemC brings the advantage of co-simulating the system with a more accurate level in order to increase the accuracy of incoherence detection and eventually localization. This possibility of different levels of simulation allows us to rapidly situate a path to the detected fault (Figure 7).

Conclusions and perspectives

We presented in this paper a co-modelling technique with multilevel of granularity under SystemC. Cycle accurate models of the CAN bus, CAN interfaces and ECUs including memories and processors has been comodelled with different levels of granularity. We have shown the impact of a multi-granularity hardwaresoftware model for the hardware real-time fault detection. This result shows that such modelling method is suitable to simulate distributed real time software-hardware architecture and allows the supervision designer to re-use the TLM models for embedded simulations for real time supervision or to simulate and test the system off-line without being intrusive.

As future work, we aim to extend the multilevel granularity modelling to other computing platforms, like SoC (System on Chip) for example; a technology that is gaining interest for car manufacturers. A SoC is a heterogeneous system, composed of software, hardware, requiring special development environments for specification, simulation, verification, compilation and execution. SoC are characterized by the re-use of different components (processors, memory, communication networks) connected on the same chip. The TLM is very suitable to model the architecture of a SoC, in order to enable development of the embedded software in advance of the hardware, and to carry out analyses early in the design cycle.

Figure 1 .

 1 Figure 1. Hardware and software models for system observation for diagnosis

1 2 ECUFigure 2 .

 122 Figure 2. software sub-functions and hardware components links

Figure 3 .

 3 Figure 3. Relationship between a sub-system comodel and hardware source of fault

Figure 5 .

 5 Figure 5. CAN bus TLM model

2 /Figure 6 .

 26 Figure 6. HW/SW interfacing

F1Figure 7 .

 7 Figure 7. Multilevel of granularity co-simulationIt is important to note that this approach of modelling for diagnosis is simple to implement when the embedded functions are cyclic, as progressive and repetitive simulations may be done with real input values.