------------------------------------------------------------------------------ ------------------------------------------------------------------------------ -- This source file was automatically generated by Platypus -- see http://dossen.univ-brest.fr/apl -- -- Any modification of this file will be lost. -- Please see the "platypus" directory instead : it contains the Cheddar's -- model and its meta-model. ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ -- Cheddar is a GNU GPL real-time scheduling analysis tool. -- This program provides services to automatically check schedulability and -- other performance criteria of real-time architecture models. -- -- Copyright (C) 2002-2016 Frank Singhoff, Alain Plantec, Jerome Legrand -- -- The Cheddar project was started in 2002 by -- Frank Singhoff, Lab-STICC UMR 6285 laboratory, Université de Bretagne Occidentale -- -- Cheddar has been published in the "Agence de Protection des Programmes/France" in 2008. -- Since 2008, Ellidiss technologies also contributes to the development of -- Cheddar and provides industrial support. -- -- The full list of contributors and sponsors can be found in AUTHORS.txt and SPONSORS.txt -- -- This program is free software; you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation; either version 2 of the License, or -- (at your option) any later version. -- -- This program is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- GNU General Public License for more details. -- -- You should have received a copy of the GNU General Public License -- along with this program; if not, write to the Free Software -- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -- -- -- Contact : cheddar@listes.univ-brest.fr -- To post to this mailing list, you must be subscribed -- (see http//beru.univ-brest.fr/~singhoff/cheddar for details) -- ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ with Ada.Strings.Unbounded; use Ada.Strings.Unbounded; with Framework_Config; use Framework_Config; with id_generators; use id_generators; with Objects; use Objects; with standards_io; use standards_io; use standards_io.boolean_io; use standards_io.natural_io; with Convert_Strings; with Convert_Unbounded_Strings; with text_io; use text_io; with Ada.Finalization; with unbounded_strings; use unbounded_strings; use unbounded_strings.Unbounded_String_List_Package; with Unchecked_Deallocation; with Primitive_XML_Strings; use Primitive_XML_Strings; with Tables; with Lists; with ada.strings.unbounded.text_io; use ada.strings.unbounded.text_io; Package Memories is type Generic_Memory; type Generic_Memory_Ptr is access all Generic_Memory'Class; type DRAM_Memory; type DRAM_Memory_Ptr is access all DRAM_Memory'Class; type Kalray_Memory; type Kalray_Memory_Ptr is access all Kalray_Memory'Class; type Memory_Record; type Memory_Record_Ptr is access all Memory_Record; type Memory_Type is ( Generic_Memory_Type, DRAM_Type, Kalray_Type); procedure To_Memory_Type is new Convert_Strings(Memory_Type, Generic_Memory_Type); procedure To_Memory_Type is new Convert_Unbounded_Strings(Memory_Type, Generic_Memory_Type); function XML_String (obj : in Memory_Type) return Unbounded_String; function XML_Ref_String (obj : in Memory_Type) return Unbounded_String; package Memory_Type_io is new text_io.enumeration_io(Memory_Type); use Memory_Type_io; -- --------= Generic_Memory =-------- type Generic_Memory is new Named_Object with record size : Natural; access_latency : Natural; memory_category : Memory_Type; end record; procedure Initialize(obj : in out Generic_Memory); procedure Put(obj : in Generic_Memory); procedure Put(obj : in Generic_Memory_Ptr); procedure Put_Name(obj : in Generic_Memory_Ptr); procedure Build_Attributes_XML_String(obj : in Generic_Memory; result : in out Unbounded_String); function XML_String(obj : in Generic_Memory) return Unbounded_String; function XML_String(obj : in Generic_Memory_Ptr) return Unbounded_String; function XML_Ref_String(obj : in Generic_Memory) return Unbounded_String; function XML_Ref_String(obj : in Generic_Memory_Ptr) return Unbounded_String; function Get_Name (obj : in Generic_Memory) return Unbounded_String; function Get_Name (obj : in Generic_Memory_Ptr) return Unbounded_String; function Copy(obj : in Generic_Memory_Ptr) return Generic_Memory_Ptr; function Copy(obj : in Generic_Memory) return Generic_Memory_Ptr; function type_of(obj : in Generic_Memory) return unbounded_string_list; function type_of(obj : in Generic_Memory_Ptr) return unbounded_string_list; procedure Free is new Unchecked_Deallocation (Generic_Memory'Class, Generic_Memory_Ptr); package Memories_Table_Package is new Tables(Generic_Memory_Ptr, Max_Memories, Put, XML_String, XML_Ref_String); use Memories_Table_Package; subtype Memories_Range is Memories_Table_Package.table_range; subtype Memories_Range_Ptr is Memories_Table_Package.table_range_Ptr; subtype Memories_Table is Memories_Table_Package.table; subtype Memories_Table_Ptr is Memories_Table_Package.table_Ptr; package Generic_Memory_List_Package is new Lists(Generic_Memory_Ptr, Put, Free, XML_Ref_String); use Generic_Memory_List_Package; subtype Generic_Memory_Iterator is Generic_Memory_List_Package.iterator; subtype Generic_Memory_Iterator_Ptr is Generic_Memory_List_Package.iterator_Ptr; subtype Generic_Memory_List is Generic_Memory_List_Package.list; subtype Generic_Memory_List_Ptr is Generic_Memory_List_Package.list_Ptr; -- --------= DRAM_Memory =-------- type DRAM_Memory is new Generic_Memory with record shared_access_latency : Natural; private_access_latency : Natural; l_rw_inter : Natural; l_act_inter : Natural; l_pre_inter : Natural; n_reorder : Natural; l_conhit : Natural; l_conf : Natural; end record; procedure Initialize(obj : in out DRAM_Memory); procedure Put(obj : in DRAM_Memory); procedure Put(obj : in DRAM_Memory_Ptr); procedure Put_Name(obj : in DRAM_Memory_Ptr); procedure Build_Attributes_XML_String(obj : in DRAM_Memory; result : in out Unbounded_String); function XML_String(obj : in DRAM_Memory) return Unbounded_String; function XML_String(obj : in DRAM_Memory_Ptr) return Unbounded_String; function XML_Ref_String(obj : in DRAM_Memory) return Unbounded_String; function XML_Ref_String(obj : in DRAM_Memory_Ptr) return Unbounded_String; function Get_Name (obj : in DRAM_Memory) return Unbounded_String; function Get_Name (obj : in DRAM_Memory_Ptr) return Unbounded_String; function Copy(obj : in DRAM_Memory_Ptr) return Generic_Memory_Ptr; function Copy(obj : in DRAM_Memory) return Generic_Memory_Ptr; function type_of(obj : in DRAM_Memory) return unbounded_string_list; function type_of(obj : in DRAM_Memory_Ptr) return unbounded_string_list; procedure Free is new Unchecked_Deallocation (DRAM_Memory'Class, DRAM_Memory_Ptr); -- --------= Kalray_Memory =-------- type Kalray_Memory is new Generic_Memory with record nb_bank : Natural; partition_mode : Boolean; end record; procedure Initialize(obj : in out Kalray_Memory); procedure Put(obj : in Kalray_Memory); procedure Put(obj : in Kalray_Memory_Ptr); procedure Put_Name(obj : in Kalray_Memory_Ptr); procedure Build_Attributes_XML_String(obj : in Kalray_Memory; result : in out Unbounded_String); function XML_String(obj : in Kalray_Memory) return Unbounded_String; function XML_String(obj : in Kalray_Memory_Ptr) return Unbounded_String; function XML_Ref_String(obj : in Kalray_Memory) return Unbounded_String; function XML_Ref_String(obj : in Kalray_Memory_Ptr) return Unbounded_String; function Get_Name (obj : in Kalray_Memory) return Unbounded_String; function Get_Name (obj : in Kalray_Memory_Ptr) return Unbounded_String; function Copy(obj : in Kalray_Memory_Ptr) return Generic_Memory_Ptr; function Copy(obj : in Kalray_Memory) return Generic_Memory_Ptr; function type_of(obj : in Kalray_Memory) return unbounded_string_list; function type_of(obj : in Kalray_Memory_Ptr) return unbounded_string_list; procedure Free is new Unchecked_Deallocation (Kalray_Memory'Class, Kalray_Memory_Ptr); -- --------= Memory_Record =-------- type Memory_Record is record size : Natural; access_latency : Natural; memory_category : Memory_Type; shared_access_latency : Natural; private_access_latency : Natural; l_rw_inter : Natural; l_act_inter : Natural; l_pre_inter : Natural; n_reorder : Natural; l_conhit : Natural; l_conf : Natural; nb_bank : Natural; partition_mode : Boolean; end record; procedure Initialize(obj : out Memory_Record); procedure Put(obj : in Memory_Record); procedure Put(obj : in Memory_Record_Ptr); function Copy(obj : in Memory_Record_Ptr) return Memory_Record_Ptr; function Copy(obj : in Memory_Record) return Memory_Record_Ptr; procedure Build_Attributes_XML_String(obj : in Memory_Record; result : in out Unbounded_String); function XML_String(obj : in Memory_Record) return Unbounded_String; function XML_String(obj : in Memory_Record_Ptr) return Unbounded_String; function XML_Ref_String(obj : in Memory_Record) return Unbounded_String; procedure Free is new Unchecked_Deallocation (Memory_Record, Memory_Record_Ptr); End Memories;