hexsha
stringlengths
40
40
size
int64
3
1.05M
ext
stringclasses
163 values
lang
stringclasses
53 values
max_stars_repo_path
stringlengths
3
945
max_stars_repo_name
stringlengths
4
112
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
sequencelengths
1
10
max_stars_count
float64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
3
945
max_issues_repo_name
stringlengths
4
113
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
sequencelengths
1
10
max_issues_count
float64
1
116k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
3
945
max_forks_repo_name
stringlengths
4
113
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
sequencelengths
1
10
max_forks_count
float64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
3
1.05M
avg_line_length
float64
1
966k
max_line_length
int64
1
977k
alphanum_fraction
float64
0
1
9ab0bdb05b77205d9ac3869559b5ccddfd4608ac
4,862
adb
Ada
proj/ada_proj_basic/src/run_%{APPNAMELC}.adb
gerr135/kdevelop_templates
e11ab281d1ac3d6a989b0dd6eb3b5cf6ed2a4526
[ "Unlicense" ]
null
null
null
proj/ada_proj_basic/src/run_%{APPNAMELC}.adb
gerr135/kdevelop_templates
e11ab281d1ac3d6a989b0dd6eb3b5cf6ed2a4526
[ "Unlicense" ]
null
null
null
proj/ada_proj_basic/src/run_%{APPNAMELC}.adb
gerr135/kdevelop_templates
e11ab281d1ac3d6a989b0dd6eb3b5cf6ed2a4526
[ "Unlicense" ]
null
null
null
-- -- <one line to give the program's name and a brief idea of what it does.> -- -- 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. -- with Ada.Command_Line, GNAT.Command_Line; with Ada.Directories, Ada.Environment_Variables; with Ada.Text_IO, Ada.Integer_Text_IO; with Ada.Strings.Unbounded; use Ada.Strings.Unbounded; -- all methods in .Unbounded are easy to ident and have unique names, no need to hide visibility procedure run_%{APPNAME} is procedure printUsage is use Ada.Text_IO; begin Put_Line ("!!!DESCRIPTION!!!"); New_Line; Put_Line ("usage:"); Put_Line (" " & Ada.Command_Line.Command_Name & " [-h -g -n: -v] positional"); New_Line; Put_Line ("options:"); -- only short options for now Put_Line ("-h print this help"); Put_Line ("-g turn on debug output"); Put_Line ("-v be verbose"); Put_Line ("-n enter some number"); end printUsage; Finish : exception; -- normal termination -- Ada doesn't have an analog of sys.exit() in the standard, because of multitasking -- support directly by the language. So just raise this anywhere and catch at the top.. -- -- If you really miss this function, OS_Exit/OS_Abort are defined in -- GNAT.OS_Lib (one of gnat extensions). Just be aware that it does not play well with Spawn and other -- process-controll features!! type ParamRec is record -- mostly the commandline params. DepGraph and USE flags will go as separate vars name : Unbounded_String := Null_Unbounded_String; workDir : Unbounded_String := Null_Unbounded_String; val : Integer := 0; Debug : Boolean := False; end record; procedure processCommandLine (params : in out ParamRec) is -- this works very similarly to GNU getopt, except this one uses single '-' -- for both short and long options use Ada.Command_Line, GNAT.Command_Line, Ada.Text_IO, Ada.Integer_Text_IO; Options : constant String := "g h n: v"; Last:Positive; begin if Argument_Count < 1 then printUsage; raise Finish; end if; begin -- need to process local exceptions loop case Getopt (Options) is when ASCII.NUL => exit; -- end of option list when 'g' | 'v' => params.Debug := True; when 'h' => printUsage; raise Finish; when 'n' => Get(Parameter,Positive(params.val),Last); when others => raise Program_Error; -- serves to catch "damn, forgot to include that option here" end case; end loop; exception when Invalid_Switch => Put_Line ("Invalid Switch " & Full_Switch); raise Finish; when Invalid_Parameter => Put_Line ("No parameter for " & Full_Switch); raise Finish; when Data_Error => Put_Line ("Invalid numeric format for switch" & Full_Switch); raise Finish; end; -- get positional params loop declare S : constant String := Get_Argument (Do_Expansion => True); begin exit when S'Length = 0; if params.Debug then Put_Line ("alternative file was passed: '" & S &"'"); end if; params.name := To_Unbounded_String(S); end; end loop; -- process env vars declare -- just a visibility wrapper use Ada.Directories; begin if Ada.Environment_Variables.Exists ("ENV_VAR") then params.WorkDir := To_Unbounded_String (Ada.Environment_Variables.Value ("ENV_VAR")); else params.WorkDir := To_Unbounded_String (Current_Directory); end if; -- if not Exists (To_String (params.WorkDir)) or else Kind (To_String (params.WorkDir)) /= Directory then Put_Line ("The directory " & To_String (params.WorkDir) & " does not exist!"); raise Finish; end if; end; end processCommandLine; params : ParamRec; use Ada.Text_IO; begin -- main processCommandLine (params); Put_Line("basic test"); exception when Finish => null; end run_%{APPNAME};
36.556391
108
0.567051
04d63349195c62becd4a324e4c076bfb45bd9da7
400
ads
Ada
src/gpr_tools-gprslaves-nameserver-server.ads
persan/gprTools
0a67ea3179a1a5802ca45014ed00c044a945e5a1
[ "BSD-3-Clause" ]
2
2015-05-15T16:03:26.000Z
2018-12-26T19:32:41.000Z
src/gpr_tools-gprslaves-nameserver-server.ads
persan/gprTools
0a67ea3179a1a5802ca45014ed00c044a945e5a1
[ "BSD-3-Clause" ]
null
null
null
src/gpr_tools-gprslaves-nameserver-server.ads
persan/gprTools
0a67ea3179a1a5802ca45014ed00c044a945e5a1
[ "BSD-3-Clause" ]
null
null
null
with Gprslaves.DB; with GNAT.Spitbol.Table_VString; with AWS.Status; with AWS.Response; package GPR_Tools.Gprslaves.Nameserver.Server is procedure Register (Server : DB.Info_Struct); function Find (Keys : GNAT.Spitbol.Table_VString.Table) return DB.Host_Info_Vectors.Vector; function Request (Request : AWS.Status.Data) return AWS.Response.Data; end GPR_Tools.Gprslaves.Nameserver.Server;
33.333333
94
0.7975
1e8f1005be751372cf8441133f69d419fa3679fe
24,400
adb
Ada
source/xml/sax/matreshka-internals-xml-entity_tables.adb
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
24
2016-11-29T06:59:41.000Z
2021-08-30T11:55:16.000Z
source/xml/sax/matreshka-internals-xml-entity_tables.adb
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
2
2019-01-16T05:15:20.000Z
2019-02-03T10:03:32.000Z
source/xml/sax/matreshka-internals-xml-entity_tables.adb
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
4
2017-07-18T07:11:05.000Z
2020-06-21T03:02:25.000Z
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- XML Processor -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2010-2011, Vadim Godunko <[email protected]> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ with Ada.Unchecked_Deallocation; with League.Strings.Internals; package body Matreshka.Internals.XML.Entity_Tables is procedure Free is new Ada.Unchecked_Deallocation (Entity_Array, Entity_Array_Access); procedure New_Entity (Self : in out Entity_Table; Entity : out Entity_Identifier); -- Allocates new entity and returns its identifier. Reallocates internal -- memory when needed. ------------------------ -- Enclosing_Base_URI -- ------------------------ function Enclosing_Base_URI (Self : Entity_Table; Entity : Entity_Identifier) return not null Matreshka.Internals.Strings.Shared_String_Access is begin return Self.Data (Entity).Enclosing_Base_URI; end Enclosing_Base_URI; ---------------------- -- Enclosing_Entity -- ---------------------- function Enclosing_Entity (Self : Entity_Table; Entity : Entity_Identifier) return Matreshka.Internals.XML.Entity_Identifier is begin return Self.Data (Entity).Enclosing; end Enclosing_Entity; --------------------- -- Entity_Base_URI -- --------------------- function Entity_Base_URI (Self : Entity_Table; Entity : Entity_Identifier) return not null Matreshka.Internals.Strings.Shared_String_Access is begin return Self.Data (Entity).Entity_Base_URI; end Entity_Base_URI; -------------- -- Finalize -- -------------- procedure Finalize (Self : in out Entity_Table) is begin for J in Self.Data'First .. Self.Last loop Matreshka.Internals.Strings.Dereference (Self.Data (J).Replacement_Text); Matreshka.Internals.Strings.Dereference (Self.Data (J).Public_Id); Matreshka.Internals.Strings.Dereference (Self.Data (J).System_Id); Matreshka.Internals.Strings.Dereference (Self.Data (J).Enclosing_Base_URI); Matreshka.Internals.Strings.Dereference (Self.Data (J).Entity_Base_URI); end loop; Free (Self.Data); end Finalize; ------------------ -- First_Entity -- ------------------ function First_Entity (Self : Entity_Table) return Entity_Identifier is pragma Unreferenced (Self); begin return No_Entity + 1; end First_Entity; -------------------- -- First_Position -- -------------------- function First_Position (Self : Entity_Table; Entity : Entity_Identifier) return Matreshka.Internals.Utf16.Utf16_String_Index is begin return Self.Data (Entity).First_Position; end First_Position; ---------------- -- Initialize -- ---------------- procedure Initialize (Self : in out Entity_Table) is procedure Register_Predefined_Entity (Name : Matreshka.Internals.XML.Symbol_Identifier; Text : League.Strings.Universal_String); -- Creates predefined entity. -------------------------------- -- Register_Predefined_Entity -- -------------------------------- procedure Register_Predefined_Entity (Name : Matreshka.Internals.XML.Symbol_Identifier; Text : League.Strings.Universal_String) is T : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (Text); E : Entity_Identifier; begin Matreshka.Internals.Strings.Reference (T); New_Internal_General_Entity (Self, No_Entity, Name, T, E); end Register_Predefined_Entity; begin Self.Data := new Entity_Array (1 .. 16); Self.Last := 0; Register_Predefined_Entity (Symbol_lt, League.Strings.To_Universal_String ("&#60;")); Register_Predefined_Entity (Symbol_gt, League.Strings.To_Universal_String (">")); Register_Predefined_Entity (Symbol_amp, League.Strings.To_Universal_String ("&#38;")); Register_Predefined_Entity (Symbol_apos, League.Strings.To_Universal_String ("'")); Register_Predefined_Entity (Symbol_quot, League.Strings.To_Universal_String ("""")); end Initialize; ------------------------ -- Is_Document_Entity -- ------------------------ function Is_Document_Entity (Self : Entity_Table; Entity : Entity_Identifier) return Boolean is begin return Self.Data (Entity).Kind = Document_Entity; end Is_Document_Entity; --------------------------------------- -- Is_External_Parsed_General_Entity -- --------------------------------------- function Is_External_Parsed_General_Entity (Self : Entity_Table; Entity : Entity_Identifier) return Boolean is begin return Self.Data (Entity).Kind = External_Parsed_General_Entity; end Is_External_Parsed_General_Entity; ------------------------ -- Is_External_Subset -- ------------------------ function Is_External_Subset (Self : Entity_Table; Entity : Entity_Identifier) return Boolean is begin return Self.Data (Entity).Kind = External_Subset_Entity; end Is_External_Subset; ----------------------------------------- -- Is_External_Unparsed_General_Entity -- ----------------------------------------- function Is_External_Unparsed_General_Entity (Self : Entity_Table; Entity : Entity_Identifier) return Boolean is begin return Self.Data (Entity).Kind = External_Unparsed_General_Entity; end Is_External_Unparsed_General_Entity; -------------------------------- -- Is_Internal_General_Entity -- -------------------------------- function Is_Internal_General_Entity (Self : Entity_Table; Entity : Entity_Identifier) return Boolean is begin return Self.Data (Entity).Kind = Internal_General_Entity; end Is_Internal_General_Entity; ------------------------- -- Is_Parameter_Entity -- ------------------------- function Is_Parameter_Entity (Self : Entity_Table; Entity : Entity_Identifier) return Boolean is begin return Self.Data (Entity).Kind = Internal_Parameter_Entity or Self.Data (Entity).Kind = External_Parameter_Entity; end Is_Parameter_Entity; ------------------------------ -- Is_Parsed_General_Entity -- ------------------------------ function Is_Parsed_General_Entity (Self : Entity_Table; Entity : Entity_Identifier) return Boolean is begin return Self.Data (Entity).Kind = Internal_General_Entity or Self.Data (Entity).Kind = External_Parsed_General_Entity; end Is_Parsed_General_Entity; ----------------- -- Is_Resolved -- ----------------- function Is_Resolved (Self : Entity_Table; Entity : Entity_Identifier) return Boolean is begin return Self.Data (Entity).Is_Resolved; end Is_Resolved; ---------- -- Name -- ---------- function Name (Self : Entity_Table; Entity : Entity_Identifier) return Matreshka.Internals.XML.Symbol_Identifier is begin return Self.Data (Entity).Name; end Name; ------------------------- -- New_Document_Entity -- ------------------------- procedure New_Document_Entity (Self : in out Entity_Table; Public_Id : League.Strings.Universal_String; System_Id : League.Strings.Universal_String; Entity_Base_URI : League.Strings.Universal_String; Entity : out Entity_Identifier) is P : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (Public_Id); S : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (System_Id); B : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (Entity_Base_URI); begin New_Entity (Self, Entity); Matreshka.Internals.Strings.Reference (P); Matreshka.Internals.Strings.Reference (S); Matreshka.Internals.Strings.Reference (B); Self.Data (Entity) := (Kind => Document_Entity, Enclosing => No_Entity, Name => No_Symbol, Notation => No_Symbol, Public_Id => P, System_Id => S, Enclosing_Base_URI => Matreshka.Internals.Strings.Shared_Empty'Access, Entity_Base_URI => B, Is_Resolved => False, Replacement_Text => Matreshka.Internals.Strings.Shared_Empty'Access, First_Position => 0); end New_Document_Entity; ---------------- -- New_Entity -- ---------------- procedure New_Entity (Self : in out Entity_Table; Entity : out Entity_Identifier) is Aux : Entity_Array_Access := Self.Data; begin Self.Last := Self.Last + 1; Entity := Self.Last; if Self.Last > Self.Data'Last then Self.Data := new Entity_Array (Self.Data'First .. Self.Data'Last + 16); Self.Data (Aux'Range) := Aux.all; Free (Aux); end if; end New_Entity; ----------------------------------- -- New_External_Parameter_Entity -- ----------------------------------- procedure New_External_Parameter_Entity (Self : in out Entity_Table; Enclosing_Entity : Entity_Identifier; Name : Matreshka.Internals.XML.Symbol_Identifier; Public_Id : League.Strings.Universal_String; System_Id : League.Strings.Universal_String; Enclosing_Base_URI : League.Strings.Universal_String; Entity : out Entity_Identifier) is P : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (Public_Id); S : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (System_Id); B : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (Enclosing_Base_URI); begin New_Entity (Self, Entity); Matreshka.Internals.Strings.Reference (P); Matreshka.Internals.Strings.Reference (S); Matreshka.Internals.Strings.Reference (B); Self.Data (Entity) := (Kind => External_Parameter_Entity, Enclosing => Enclosing_Entity, Name => Name, Notation => No_Symbol, Public_Id => P, System_Id => S, Enclosing_Base_URI => B, Entity_Base_URI => Matreshka.Internals.Strings.Shared_Empty'Access, Is_Resolved => False, Replacement_Text => Matreshka.Internals.Strings.Shared_Empty'Access, First_Position => 0); end New_External_Parameter_Entity; ---------------------------------------- -- New_External_Parsed_General_Entity -- ---------------------------------------- procedure New_External_Parsed_General_Entity (Self : in out Entity_Table; Enclosing_Entity : Entity_Identifier; Name : Matreshka.Internals.XML.Symbol_Identifier; Public_Id : League.Strings.Universal_String; System_Id : League.Strings.Universal_String; Enclosing_Base_URI : League.Strings.Universal_String; Entity : out Entity_Identifier) is P : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (Public_Id); S : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (System_Id); B : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (Enclosing_Base_URI); begin New_Entity (Self, Entity); Matreshka.Internals.Strings.Reference (P); Matreshka.Internals.Strings.Reference (S); Matreshka.Internals.Strings.Reference (B); Self.Data (Entity) := (Kind => External_Parsed_General_Entity, Enclosing => Enclosing_Entity, Name => Name, Notation => No_Symbol, Public_Id => P, System_Id => S, Enclosing_Base_URI => B, Entity_Base_URI => Matreshka.Internals.Strings.Shared_Empty'Access, Is_Resolved => False, Replacement_Text => Matreshka.Internals.Strings.Shared_Empty'Access, First_Position => 0); end New_External_Parsed_General_Entity; -------------------------------- -- New_External_Subset_Entity -- -------------------------------- procedure New_External_Subset_Entity (Self : in out Entity_Table; Enclosing_Entity : Entity_Identifier; Public_Id : League.Strings.Universal_String; System_Id : League.Strings.Universal_String; Enclosing_Base_URI : League.Strings.Universal_String; Entity : out Entity_Identifier) is P : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (Public_Id); S : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (System_Id); B : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (Enclosing_Base_URI); begin New_Entity (Self, Entity); Matreshka.Internals.Strings.Reference (P); Matreshka.Internals.Strings.Reference (S); Matreshka.Internals.Strings.Reference (B); Self.Data (Entity) := (Kind => External_Subset_Entity, Enclosing => Enclosing_Entity, Name => No_Symbol, Notation => No_Symbol, Public_Id => P, System_Id => S, Enclosing_Base_URI => B, Entity_Base_URI => Matreshka.Internals.Strings.Shared_Empty'Access, Is_Resolved => False, Replacement_Text => Matreshka.Internals.Strings.Shared_Empty'Access, First_Position => 0); end New_External_Subset_Entity; ------------------------------------------ -- New_External_Unparsed_General_Entity -- ------------------------------------------ procedure New_External_Unparsed_General_Entity (Self : in out Entity_Table; Enclosing_Entity : Entity_Identifier; Name : Matreshka.Internals.XML.Symbol_Identifier; Notation : Symbol_Identifier; Entity : out Entity_Identifier) is begin New_Entity (Self, Entity); Self.Data (Entity) := (Kind => External_Unparsed_General_Entity, Enclosing => Enclosing_Entity, Name => Name, Notation => Notation, Public_Id => Matreshka.Internals.Strings.Shared_Empty'Access, System_Id => Matreshka.Internals.Strings.Shared_Empty'Access, Enclosing_Base_URI => Matreshka.Internals.Strings.Shared_Empty'Access, Entity_Base_URI => Matreshka.Internals.Strings.Shared_Empty'Access, Is_Resolved => False, Replacement_Text => Matreshka.Internals.Strings.Shared_Empty'Access, First_Position => 0); end New_External_Unparsed_General_Entity; --------------------------------- -- New_Internal_General_Entity -- --------------------------------- procedure New_Internal_General_Entity (Self : in out Entity_Table; Enclosing_Entity : Entity_Identifier; Name : Matreshka.Internals.XML.Symbol_Identifier; Replacement_Text : not null Matreshka.Internals.Strings.Shared_String_Access; Entity : out Entity_Identifier) is begin New_Entity (Self, Entity); Self.Data (Entity) := (Kind => Internal_General_Entity, Enclosing => Enclosing_Entity, Name => Name, Notation => No_Symbol, Public_Id => Matreshka.Internals.Strings.Shared_Empty'Access, System_Id => Matreshka.Internals.Strings.Shared_Empty'Access, Enclosing_Base_URI => Matreshka.Internals.Strings.Shared_Empty'Access, Entity_Base_URI => Matreshka.Internals.Strings.Shared_Empty'Access, Is_Resolved => True, Replacement_Text => Replacement_Text, First_Position => 0); end New_Internal_General_Entity; ----------------------------------- -- New_Internal_Parameter_Entity -- ----------------------------------- procedure New_Internal_Parameter_Entity (Self : in out Entity_Table; Enclosing_Entity : Entity_Identifier; Name : Matreshka.Internals.XML.Symbol_Identifier; Replacement_Text : not null Matreshka.Internals.Strings.Shared_String_Access; Entity : out Entity_Identifier) is begin New_Entity (Self, Entity); Self.Data (Entity) := (Kind => Internal_Parameter_Entity, Enclosing => Enclosing_Entity, Name => Name, Notation => No_Symbol, Public_Id => Matreshka.Internals.Strings.Shared_Empty'Access, System_Id => Matreshka.Internals.Strings.Shared_Empty'Access, Enclosing_Base_URI => Matreshka.Internals.Strings.Shared_Empty'Access, Entity_Base_URI => Matreshka.Internals.Strings.Shared_Empty'Access, Is_Resolved => True, Replacement_Text => Replacement_Text, First_Position => 0); end New_Internal_Parameter_Entity; ----------------- -- Next_Entity -- ----------------- procedure Next_Entity (Self : Entity_Table; Entity : in out Entity_Identifier) is begin if Entity = Self.Last then Entity := No_Entity; else Entity := Entity + 1; end if; end Next_Entity; -------------- -- Notation -- -------------- function Notation (Self : Entity_Table; Entity : Entity_Identifier) return Matreshka.Internals.XML.Symbol_Identifier is begin return Self.Data (Entity).Notation; end Notation; --------------- -- Public_Id -- --------------- function Public_Id (Self : Entity_Table; Entity : Entity_Identifier) return not null Matreshka.Internals.Strings.Shared_String_Access is begin return Self.Data (Entity).Public_Id; end Public_Id; ---------------------- -- Replacement_Text -- ---------------------- function Replacement_Text (Self : Entity_Table; Entity : Entity_Identifier) return Matreshka.Internals.Strings.Shared_String_Access is begin return Self.Data (Entity).Replacement_Text; end Replacement_Text; ----------- -- Reset -- ----------- procedure Reset (Self : in out Entity_Table) is begin Finalize (Self); Initialize (Self); end Reset; ------------------------- -- Set_Entity_Base_URI -- ------------------------- procedure Set_Entity_Base_URI (Self : in out Entity_Table; Entity : Entity_Identifier; Entity_Base_URI : League.Strings.Universal_String) is B : constant Matreshka.Internals.Strings.Shared_String_Access := League.Strings.Internals.Internal (Entity_Base_URI); begin Matreshka.Internals.Strings.Dereference (Self.Data (Entity).Entity_Base_URI); Self.Data (Entity).Entity_Base_URI := B; Matreshka.Internals.Strings.Reference (Self.Data (Entity).Entity_Base_URI); end Set_Entity_Base_URI; ------------------------ -- Set_First_Position -- ------------------------ procedure Set_First_Position (Self : in out Entity_Table; Entity : Entity_Identifier; Position : Matreshka.Internals.Utf16.Utf16_String_Index) is begin Self.Data (Entity).First_Position := Position; end Set_First_Position; --------------------- -- Set_Is_Resolved -- --------------------- procedure Set_Is_Resolved (Self : in out Entity_Table; Entity : Entity_Identifier; To : Boolean) is begin Self.Data (Entity).Is_Resolved := To; end Set_Is_Resolved; -------------------------- -- Set_Replacement_Text -- -------------------------- procedure Set_Replacement_Text (Self : in out Entity_Table; Entity : Entity_Identifier; Replacement_Text : not null Matreshka.Internals.Strings.Shared_String_Access) is begin Self.Data (Entity).Replacement_Text := Replacement_Text; end Set_Replacement_Text; --------------- -- System_Id -- --------------- function System_Id (Self : Entity_Table; Entity : Entity_Identifier) return not null Matreshka.Internals.Strings.Shared_String_Access is begin return Self.Data (Entity).System_Id; end System_Id; end Matreshka.Internals.XML.Entity_Tables;
35.777126
84
0.569631
04f171dda4528cf76fbccb7a4639bdbda65c1270
2,951
ads
Ada
gcc-gcc-7_3_0-release/gcc/ada/s-wwdcha.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/ada/s-wwdcha.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/ada/s-wwdcha.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- S Y S T E M . W W D _ C H A R -- -- -- -- S p e c -- -- -- -- Copyright (C) 1992-2009, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This package contains the routine used for Character'Wide_[Wide_]Width package System.WWd_Char is pragma Pure; function Wide_Width_Character (Lo, Hi : Character) return Natural; -- Compute Wide_Width attribute for non-static type derived from -- Character. The arguments are the low and high bounds for the type. function Wide_Wide_Width_Character (Lo, Hi : Character) return Natural; -- Compute Wide_Wide_Width attribute for non-static type derived from -- Character. The arguments are the low and high bounds for the type. end System.WWd_Char;
64.152174
79
0.442223
4159e03d0ace69479671968543626dc836b5ab8c
1,842
ads
Ada
src/ado-utils.ads
Letractively/ada-ado
f0863c6975ae1a2c5349daee1e98a04fe11ba11e
[ "Apache-2.0" ]
null
null
null
src/ado-utils.ads
Letractively/ada-ado
f0863c6975ae1a2c5349daee1e98a04fe11ba11e
[ "Apache-2.0" ]
null
null
null
src/ado-utils.ads
Letractively/ada-ado
f0863c6975ae1a2c5349daee1e98a04fe11ba11e
[ "Apache-2.0" ]
null
null
null
----------------------------------------------------------------------- -- ado-utils -- Utility operations for ADO -- Copyright (C) 2013 Stephane Carrez -- Written by Stephane Carrez ([email protected]) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Ada.Containers; with Ada.Containers.Vectors; with Util.Beans.Objects; package ADO.Utils is -- Build a bean object from the identifier. function To_Object (Id : in ADO.Identifier) return Util.Beans.Objects.Object; -- Build the identifier from the bean object. function To_Identifier (Value : in Util.Beans.Objects.Object) return ADO.Identifier; -- Compute the hash of the identifier. function Hash (Key : in ADO.Identifier) return Ada.Containers.Hash_Type; package Identifier_Vectors is new Ada.Containers.Vectors (Index_Type => Positive, Element_Type => ADO.Identifier, "=" => "="); subtype Identifier_Vector is Identifier_Vectors.Vector; subtype Identifier_Cursor is Identifier_Vectors.Cursor; -- Return the identifier list as a comma separated list of identifiers. function To_Parameter_List (List : in Identifier_Vector) return String; end ADO.Utils;
40.933333
87
0.65418
8b1012a263f3636b0f07fd15d1f321b2df4459c7
5,075
ads
Ada
tools/scitools/conf/understand/ada/ada12/s-bitops.ads
brucegua/moocos
575c161cfa35e220f10d042e2e5ca18773691695
[ "Apache-2.0" ]
1
2020-01-20T21:26:46.000Z
2020-01-20T21:26:46.000Z
tools/scitools/conf/understand/ada/ada12/s-bitops.ads
brucegua/moocos
575c161cfa35e220f10d042e2e5ca18773691695
[ "Apache-2.0" ]
null
null
null
tools/scitools/conf/understand/ada/ada12/s-bitops.ads
brucegua/moocos
575c161cfa35e220f10d042e2e5ca18773691695
[ "Apache-2.0" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS -- -- -- -- S Y S T E M . B I T _ O P S -- -- -- -- S p e c -- -- -- -- Copyright (C) 1992-2009, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- -- -- -- -- -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- Operations on packed bit strings pragma Compiler_Unit; with System; package System.Bit_Ops is -- Note: in all the following routines, the System.Address parameters -- represent the address of the first byte of an array used to represent -- a packed array (of type System.Unsigned_Types.Packed_Bytes{1,2,4}) -- The length in bits is passed as a separate parameter. Note that all -- addresses must be of byte aligned arrays. procedure Bit_And (Left : System.Address; Llen : Natural; Right : System.Address; Rlen : Natural; Result : System.Address); -- Bitwise "and" of given bit string with result being placed in Result. -- The and operation is allowed to destroy unused bits in the last byte, -- i.e. to leave them set in an undefined manner. Note that Left, Right -- and Result always have the same length in bits (Len). function Bit_Eq (Left : System.Address; Llen : Natural; Right : System.Address; Rlen : Natural) return Boolean; -- Left and Right are the addresses of two bit packed arrays with Llen -- and Rlen being the respective length in bits. The routine compares the -- two bit strings for equality, being careful not to include the unused -- bits in the final byte. Note that the result is always False if Rlen -- is not equal to Llen. procedure Bit_Not (Opnd : System.Address; Len : Natural; Result : System.Address); -- Bitwise "not" of given bit string with result being placed in Result. -- The not operation is allowed to destroy unused bits in the last byte, -- i.e. to leave them set in an undefined manner. Note that Result and -- Opnd always have the same length in bits (Len). procedure Bit_Or (Left : System.Address; Llen : Natural; Right : System.Address; Rlen : Natural; Result : System.Address); -- Bitwise "or" of given bit string with result being placed in Result. -- The or operation is allowed to destroy unused bits in the last byte, -- i.e. to leave them set in an undefined manner. Note that Left, Right -- and Result always have the same length in bits (Len). procedure Bit_Xor (Left : System.Address; Llen : Natural; Right : System.Address; Rlen : Natural; Result : System.Address); -- Bitwise "xor" of given bit string with result being placed in Result. -- The xor operation is allowed to destroy unused bits in the last byte, -- i.e. to leave them set in an undefined manner. Note that Left, Right -- and Result always have the same length in bits (Len). end System.Bit_Ops;
50.75
78
0.498128
a00776cd45726860041725cafe9562a9d7385a76
1,248
ada
Ada
Task/Sort-an-array-of-composite-structures/Ada/sort-an-array-of-composite-structures-2.ada
mullikine/RosettaCodeData
4f0027c6ce83daa36118ee8b67915a13cd23ab67
[ "Info-ZIP" ]
1
2018-11-09T22:08:38.000Z
2018-11-09T22:08:38.000Z
Task/Sort-an-array-of-composite-structures/Ada/sort-an-array-of-composite-structures-2.ada
mullikine/RosettaCodeData
4f0027c6ce83daa36118ee8b67915a13cd23ab67
[ "Info-ZIP" ]
null
null
null
Task/Sort-an-array-of-composite-structures/Ada/sort-an-array-of-composite-structures-2.ada
mullikine/RosettaCodeData
4f0027c6ce83daa36118ee8b67915a13cd23ab67
[ "Info-ZIP" ]
1
2018-11-09T22:08:40.000Z
2018-11-09T22:08:40.000Z
with Ada.Strings.Unbounded; use Ada.Strings.Unbounded; with Ada.Text_IO; use Ada.Text_IO; with Ada.Containers.Ordered_Sets; procedure Sort_Composites is function "+" (S : String) return Unbounded_String renames To_Unbounded_String; type A_Composite is record Name : Unbounded_String; Value : Unbounded_String; end record; function "<" (L, R : A_Composite) return Boolean is begin return L.Name < R.Name; end "<"; procedure Put_Line (C : A_Composite) is begin Put_Line (To_String (C.Name) & " " & To_String (C.Value)); end Put_Line; package Composite_Sets is new Ada.Containers.Ordered_Sets (A_Composite); procedure Put_Line (C : Composite_Sets.Cursor) is begin Put_Line (Composite_Sets.Element (C)); end Put_Line; Data : Composite_Sets.Set; begin Data.Insert (New_Item => (Name => +"Joe", Value => +"5531")); Data.Insert (New_Item => (Name => +"Adam", Value => +"2341")); Data.Insert (New_Item => (Name => +"Bernie", Value => +"122")); Data.Insert (New_Item => (Name => +"Walter", Value => +"1234")); Data.Insert (New_Item => (Name => +"David", Value => +"19")); Data.Iterate (Put_Line'Access); end Sort_Composites;
29.023256
81
0.641026
13c6c3e26c4900a9890041377a92288457b0ce9e
3,514
adb
Ada
examples/sax_events_printer/put_line.adb
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
24
2016-11-29T06:59:41.000Z
2021-08-30T11:55:16.000Z
examples/sax_events_printer/put_line.adb
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
2
2019-01-16T05:15:20.000Z
2019-02-03T10:03:32.000Z
examples/sax_events_printer/put_line.adb
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
4
2017-07-18T07:11:05.000Z
2020-06-21T03:02:25.000Z
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- XML Processor -- -- -- -- Examples Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2010, Vadim Godunko <[email protected]> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ with Ada.Wide_Wide_Text_IO; procedure Put_Line (Item : League.Strings.Universal_String) is begin Ada.Wide_Wide_Text_IO.Put_Line (Item.To_Wide_Wide_String); end Put_Line;
70.28
78
0.405236
8b257b62b41ba6234423d8038d2d16e368df240b
8,050
ads
Ada
gcc-gcc-7_3_0-release/gcc/ada/a-ngelfu.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/ada/a-ngelfu.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/ada/a-ngelfu.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- ADA.NUMERICS.GENERIC_ELEMENTARY_FUNCTIONS -- -- -- -- S p e c -- -- -- -- Copyright (C) 2012-2015, Free Software Foundation, Inc. -- -- -- -- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. The copyright notice above, and the license provisions that follow -- -- apply solely to the Post aspects that have been added to the spec. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ generic type Float_Type is digits <>; package Ada.Numerics.Generic_Elementary_Functions is pragma Pure; function Sqrt (X : Float_Type'Base) return Float_Type'Base with Post => Sqrt'Result >= 0.0 and then (if X = 0.0 then Sqrt'Result = 0.0) and then (if X = 1.0 then Sqrt'Result = 1.0) -- Finally if X is positive, the result of Sqrt is positive (because -- the sqrt of numbers greater than 1 is greater than or equal to 1, -- and the sqrt of numbers less than 1 is greater than the argument). -- This property is useful in particular for static analysis. The -- property that X is positive is not expressed as (X > 0.0), as -- the value X may be held in registers that have larger range and -- precision on some architecture (for example, on x86 using x387 -- FPU, as opposed to SSE2). So, it might be possible for X to be -- 2.0**(-5000) or so, which could cause the number to compare as -- greater than 0, but Sqrt would still return a zero result. -- Note: we use the comparison with Succ (0.0) here because this is -- more amenable to CodePeer analysis than the use of 'Machine. and then (if X >= Float_Type'Succ (0.0) then Sqrt'Result > 0.0); function Log (X : Float_Type'Base) return Float_Type'Base with Post => (if X = 1.0 then Log'Result = 0.0); function Log (X, Base : Float_Type'Base) return Float_Type'Base with Post => (if X = 1.0 then Log'Result = 0.0); function Exp (X : Float_Type'Base) return Float_Type'Base with Post => (if X = 0.0 then Exp'Result = 1.0); function "**" (Left, Right : Float_Type'Base) return Float_Type'Base with Post => "**"'Result >= 0.0 and then (if Right = 0.0 then "**"'Result = 1.0) and then (if Right = 1.0 then "**"'Result = Left) and then (if Left = 1.0 then "**"'Result = 1.0) and then (if Left = 0.0 then "**"'Result = 0.0); function Sin (X : Float_Type'Base) return Float_Type'Base with Post => Sin'Result in -1.0 .. 1.0 and then (if X = 0.0 then Sin'Result = 0.0); function Sin (X, Cycle : Float_Type'Base) return Float_Type'Base with Post => Sin'Result in -1.0 .. 1.0 and then (if X = 0.0 then Sin'Result = 0.0); function Cos (X : Float_Type'Base) return Float_Type'Base with Post => Cos'Result in -1.0 .. 1.0 and then (if X = 0.0 then Cos'Result = 1.0); function Cos (X, Cycle : Float_Type'Base) return Float_Type'Base with Post => Cos'Result in -1.0 .. 1.0 and then (if X = 0.0 then Cos'Result = 1.0); function Tan (X : Float_Type'Base) return Float_Type'Base with Post => (if X = 0.0 then Tan'Result = 0.0); function Tan (X, Cycle : Float_Type'Base) return Float_Type'Base with Post => (if X = 0.0 then Tan'Result = 0.0); function Cot (X : Float_Type'Base) return Float_Type'Base; function Cot (X, Cycle : Float_Type'Base) return Float_Type'Base; function Arcsin (X : Float_Type'Base) return Float_Type'Base with Post => (if X = 0.0 then Arcsin'Result = 0.0); function Arcsin (X, Cycle : Float_Type'Base) return Float_Type'Base with Post => (if X = 0.0 then Arcsin'Result = 0.0); function Arccos (X : Float_Type'Base) return Float_Type'Base with Post => (if X = 1.0 then Arccos'Result = 0.0); function Arccos (X, Cycle : Float_Type'Base) return Float_Type'Base with Post => (if X = 1.0 then Arccos'Result = 0.0); function Arctan (Y : Float_Type'Base; X : Float_Type'Base := 1.0) return Float_Type'Base with Post => (if X > 0.0 and then Y = 0.0 then Arctan'Result = 0.0); function Arctan (Y : Float_Type'Base; X : Float_Type'Base := 1.0; Cycle : Float_Type'Base) return Float_Type'Base with Post => (if X > 0.0 and then Y = 0.0 then Arctan'Result = 0.0); function Arccot (X : Float_Type'Base; Y : Float_Type'Base := 1.0) return Float_Type'Base with Post => (if X > 0.0 and then Y = 0.0 then Arccot'Result = 0.0); function Arccot (X : Float_Type'Base; Y : Float_Type'Base := 1.0; Cycle : Float_Type'Base) return Float_Type'Base with Post => (if X > 0.0 and then Y = 0.0 then Arccot'Result = 0.0); function Sinh (X : Float_Type'Base) return Float_Type'Base with Post => (if X = 0.0 then Sinh'Result = 0.0); function Cosh (X : Float_Type'Base) return Float_Type'Base with Post => Cosh'Result >= 1.0 and then (if X = 0.0 then Cosh'Result = 1.0); function Tanh (X : Float_Type'Base) return Float_Type'Base with Post => Tanh'Result in -1.0 .. 1.0 and then (if X = 0.0 then Tanh'Result = 0.0); function Coth (X : Float_Type'Base) return Float_Type'Base with Post => abs Coth'Result >= 1.0; function Arcsinh (X : Float_Type'Base) return Float_Type'Base with Post => (if X = 0.0 then Arcsinh'Result = 0.0); function Arccosh (X : Float_Type'Base) return Float_Type'Base with Post => Arccosh'Result >= 0.0 and then (if X = 1.0 then Arccosh'Result = 0.0); function Arctanh (X : Float_Type'Base) return Float_Type'Base with Post => (if X = 0.0 then Arctanh'Result = 0.0); function Arccoth (X : Float_Type'Base) return Float_Type'Base; end Ada.Numerics.Generic_Elementary_Functions;
47.076023
78
0.552547
a064988974dd94a9b4b88e014647aa5fd587c685
87
ads
Ada
ZeroMQ/filecode/examples/Ada/zmq-examples.ads
JailbreakFox/LightWeightLib
70e209f6d2941335f48e4692299d885117bd61ee
[ "BSD-2-Clause" ]
2
2015-04-07T14:37:24.000Z
2015-11-06T00:31:01.000Z
ZeroMQ/filecode/examples/Ada/zmq-examples.ads
JailbreakFox/LightWeightLib
70e209f6d2941335f48e4692299d885117bd61ee
[ "BSD-2-Clause" ]
null
null
null
ZeroMQ/filecode/examples/Ada/zmq-examples.ads
JailbreakFox/LightWeightLib
70e209f6d2941335f48e4692299d885117bd61ee
[ "BSD-2-Clause" ]
null
null
null
package ZMQ.Examples is END_MESSAGE : constant String := "<END>"; end ZMQ.Examples;
21.75
44
0.712644
1eda6d1015411e4c40fe6a26f23bd0119d019824
11,313
adb
Ada
src/apsepp-test_node_class.adb
thierr26/ada-apsepp
6eb87079ea57707db4ee1e2215fa170af66b1913
[ "MIT" ]
null
null
null
src/apsepp-test_node_class.adb
thierr26/ada-apsepp
6eb87079ea57707db4ee1e2215fa170af66b1913
[ "MIT" ]
null
null
null
src/apsepp-test_node_class.adb
thierr26/ada-apsepp
6eb87079ea57707db4ee1e2215fa170af66b1913
[ "MIT" ]
null
null
null
-- Copyright (C) 2019 Thierry Rascle <[email protected]> -- MIT license. Please refer to the LICENSE file. with Ada.Assertions, Apsepp.Test_Reporter_Class, Apsepp.Test_Node_Class.Private_Test_Reporter; package body Apsepp.Test_Node_Class is ---------------------------------------------------------------------------- function Initial_Routine_State (Routine_Index : Test_Routine_Index := 1) return Routine_State is (Routine_Index => Routine_Index, Assert_Count => Prot_Test_Assert_Count.Create (0), Assert_Outcome => Passed); ---------------------------------------------------------------------------- protected body Routine_State_Map_Handler is ----------------------------------------------------- procedure Switch_Key_If_Needed (Node_Tag : Tag) is use Routine_State_Hashed_Maps; procedure Update_Map_With_Work_Data is C : constant Cursor := M.Find (T); begin if C = No_Element then M.Insert (Key => T, New_Item => S); else M.Replace_Element (Position => C, New_Item => S); end if; end Update_Map_With_Work_Data; procedure Extract_Work_Data is C : constant Cursor := M.Find (Node_Tag); begin T := Node_Tag; S := (if C = No_Element then Initial_Routine_State else Element (C)); end Extract_Work_Data; begin if T /= Node_Tag then if T /= No_Tag then Update_Map_With_Work_Data; end if; Extract_Work_Data; end if; end Switch_Key_If_Needed; ----------------------------------------------------- procedure Reset_Routine_State (Node_Tag : Tag; Routine_Index : Test_Routine_Index) is begin Switch_Key_If_Needed (Node_Tag); S := Initial_Routine_State (Routine_Index); end Reset_Routine_State; ----------------------------------------------------- procedure Increment_Assert_Count (Node_Tag : Tag) is begin Switch_Key_If_Needed (Node_Tag); Prot_Test_Assert_Count.Inc (S.Assert_Count); end Increment_Assert_Count; ----------------------------------------------------- procedure Set_Failed_Outcome (Node_Tag : Tag) is begin Switch_Key_If_Needed (Node_Tag); S.Assert_Outcome := Failed; end Set_Failed_Outcome; ----------------------------------------------------- procedure Get_Assert_Count (Node_Tag : Tag; Routine_Index : out Test_Routine_Index; Count : out O_P_I_Test_Assert_Count) is begin Switch_Key_If_Needed (Node_Tag); Routine_Index := S.Routine_Index; Count := S.Assert_Count; end Get_Assert_Count; ----------------------------------------------------- procedure Get_Assert_Outcome (Node_Tag : Tag; Outcome : out Test_Outcome) is begin Switch_Key_If_Needed (Node_Tag); Outcome := S.Assert_Outcome; end Get_Assert_Outcome; ----------------------------------------------------- procedure Delete (Node_Tag : Tag) is use Routine_State_Hashed_Maps; begin if M.Length = 0 then T := No_Tag; else declare C : Cursor := M.Find (Node_Tag); begin if C /= No_Element then M.Delete (C); end if; if T = Node_Tag and then M.Length > 0 then declare C_First : constant Cursor := M.First; begin T := Key (C_First); S := Element (C_First); end; elsif T = Node_Tag then T := No_Tag; end if; end; end if; end Delete; ----------------------------------------------------- function Invariant return Boolean is ( ( T /= No_Tag or else M.Length = 0 ) and then not M.Contains (No_Tag) ); ----------------------------------------------------- function Count return Count_Type is (M.Length + (if T = No_Tag or else M.Contains (T) then 0 else 1)); ----------------------------------------------------- function To_Array return Tag_Routine_State_Array is use Routine_State_Hashed_Maps; N : constant Count_Type := Count; Ret : Tag_Routine_State_Array (1 .. N); procedure Populate_Current is begin if N /= 0 then Ret(1).T := T; Ret(1).S := S; end if; end Populate_Current; procedure Populate_Others is K : Index_Type := 1; procedure Process (C : Cursor) is Key_C : constant Tag := Key (C); begin if Key_C /= T then K := K + 1; Ret(K).T := Key_C; Ret(K).S := Element (C); end if; end Process; begin M.Iterate (Process'Access); Ada.Assertions.Assert ((N = 0 and then K = 1) or else (N > 0 and then K = N)); end Populate_Others; begin Populate_Current; Populate_Others; return Ret; end To_Array; ----------------------------------------------------- end Routine_State_Map_Handler; ---------------------------------------------------------------------------- procedure Run_Test_Routines (Obj : Test_Node_Interfa'Class; Outcome : out Test_Outcome; Kind : Run_Kind) is use Ada.Assertions, Private_Test_Reporter; pragma Unreferenced (Kind); T : constant Tag := Obj'Tag; K : Test_Routine_Count := 0; R : Test_Routine := Null_Test_Routine'Access; Err : Boolean := False; -- "Unexpected error" flag. ----------------------------------------------------- function Done return Boolean is N : constant Test_Routine_Count := Obj.Routine_Count; Ret : Boolean := K >= N; begin if Err and then not Ret then Ret := True; Outcome := Failed; Test_Reporter.Report_Test_Routines_Cancellation (Obj'Tag, K + 1, N); end if; return Ret; end Done; ----------------------------------------------------- begin Outcome := Passed; while not Done loop K := K + 1; Err := True; Routine_State_Map_Handler.Reset_Routine_State (T, K); Test_Reporter.Report_Test_Routine_Start (T, K); begin R := Obj.Routine (K); begin Obj.Setup_Routine; declare Assert_Outcome : Test_Outcome; begin R.all; Err := False; Routine_State_Map_Handler.Get_Assert_Outcome (T, Assert_Outcome); case Assert_Outcome is when Failed => raise Assertion_Error; -- Causes a jump to -- Assertion_Error handler -- below. Happens when a test -- assertion has failed but has -- been handled in the test -- routine. when Passed => null; end case; Test_Reporter.Report_Passed_Test_Routine (T, K); exception when Run_E : Assertion_Error => Routine_State_Map_Handler.Get_Assert_Outcome (T, Assert_Outcome); Err := False; Outcome := Failed; case Assert_Outcome is when Failed => -- Exception very likely originates in -- a failed test assertion and not in -- an "unexpected error". Test_Reporter.Report_Failed_Test_Routine (T, K); when Passed => -- Exception may originates in a failed -- contract. Test_Reporter.Report_Unexpected_Routine_Exception (T, K, Run_E); end case; when Run_E : others => -- Exception originates in an -- unexpected error. Test_Reporter.Report_Unexpected_Routine_Exception (T, K, Run_E); end; exception when Setup_E : others => Test_Reporter.Report_Failed_Test_Routine_Setup (T, K, Setup_E); end; exception when Access_E : others => Test_Reporter.Report_Failed_Test_Routine_Access (T, K, Access_E); end; end loop; Routine_State_Map_Handler.Delete (T); end Run_Test_Routines; ---------------------------------------------------------------------------- procedure Assert (Node_Tag : Tag; Cond : Boolean; Message : String := "") is use Ada.Assertions, Private_Test_Reporter, Prot_Test_Assert_Count; K : Test_Routine_Index; Count : O_P_I_Test_Assert_Count; begin Routine_State_Map_Handler.Increment_Assert_Count (Node_Tag); Routine_State_Map_Handler.Get_Assert_Count (Node_Tag, K, Count); if Cond then Test_Reporter.Report_Passed_Test_Assert (Node_Tag, K, not Sat (Count), Val (Count)); else Routine_State_Map_Handler.Set_Failed_Outcome (Node_Tag); begin raise Assertion_Error with Message; exception when E : others => Test_Reporter.Report_Failed_Test_Assert (Node_Tag, K, not Sat (Count), Val (Count), E); raise; end; end if; end Assert; ---------------------------------------------------------------------------- begin Ada.Assertions.Assert (Routine_State_Map_Handler.Invariant); end Apsepp.Test_Node_Class;
28.568182
79
0.43366
8bb453387d87c6311fbbf9d2cd58089fdf2549b6
1,087
adb
Ada
Sources/Library/generic_realtime_buffer.adb
ForYouEyesOnly/Space-Convoy
be4904f6a02695f7c4c5c3c965f4871cd3250003
[ "MIT" ]
1
2019-09-21T09:40:34.000Z
2019-09-21T09:40:34.000Z
Sources/Library/generic_realtime_buffer.adb
ForYouEyesOnly/Space-Convoy
be4904f6a02695f7c4c5c3c965f4871cd3250003
[ "MIT" ]
null
null
null
Sources/Library/generic_realtime_buffer.adb
ForYouEyesOnly/Space-Convoy
be4904f6a02695f7c4c5c3c965f4871cd3250003
[ "MIT" ]
1
2019-09-25T12:29:27.000Z
2019-09-25T12:29:27.000Z
package body Generic_Realtime_Buffer is --------- -- Put -- --------- procedure Put (B : in out Realtime_Buffer; Item : Element) is begin if B.Elements_In_Buffer = No_Of_Elements'Last then B.Read_From := B.Read_From + 1; else B.Elements_In_Buffer := B.Elements_In_Buffer + 1; end if; B.Buffer (B.Write_To) := Item; B.Write_To := B.Write_To + 1; end Put; --------- -- Get -- --------- procedure Get (B : in out Realtime_Buffer; Item : out Element) is begin if B.Elements_In_Buffer > 0 then Item := B.Buffer (B.Read_From); B.Read_From := B.Read_From + 1; B.Elements_In_Buffer := B.Elements_In_Buffer - 1; else raise Calling_Get_On_Empty_Buffer; end if; end Get; ----------------------- -- Element_Available -- ----------------------- function Element_Available (B : Realtime_Buffer) return Boolean is begin return B.Elements_In_Buffer > 0; end Element_Available; end Generic_Realtime_Buffer;
23.630435
69
0.559338
1e594fd23d8f6c0cc2caf8aa284be96cb0c87571
1,673
ads
Ada
lib/aflexnat/external_file_manager.ads
alvaromb/Compilemon
de5f88f084705868d38e301d95bb4a19a46a1156
[ "MIT" ]
1
2018-08-11T01:51:27.000Z
2018-08-11T01:51:27.000Z
lib/aflexnat/external_file_manager.ads
alvaromb/Compilemon
de5f88f084705868d38e301d95bb4a19a46a1156
[ "MIT" ]
null
null
null
lib/aflexnat/external_file_manager.ads
alvaromb/Compilemon
de5f88f084705868d38e301d95bb4a19a46a1156
[ "MIT" ]
null
null
null
-- Copyright (c) 1990 Regents of the University of California. -- All rights reserved. -- -- This software was developed by John Self of the Arcadia project -- at the University of California, Irvine. -- -- Redistribution and use in source and binary forms are permitted -- provided that the above copyright notice and this paragraph are -- duplicated in all such forms and that any documentation, -- advertising materials, and other materials related to such -- distribution and use acknowledge that the software was developed -- by the University of California, Irvine. The name of the -- University may not be used to endorse or promote products derived -- from this software without specific prior written permission. -- THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR -- IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED -- WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. -- TITLE external_file_manager -- AUTHOR: John Self (UCI) -- DESCRIPTION opens external files for other functions -- NOTES This package opens external files, and thus may be system dependent -- because of limitations on file names. -- This version is for the VADS 5.5 Ada development system. -- $Header: /co/ua/self/arcadia/aflex/ada/src/RCS/file_managerS.a,v 1.4 90/01/12 15:20:00 self Exp Locker: self $ with text_io; use text_io; package external_file_manager is procedure GET_IO_FILE(F : in out FILE_TYPE); procedure GET_DFA_FILE(F : in out FILE_TYPE); procedure GET_SCANNER_FILE(F : in out FILE_TYPE); procedure GET_BACKTRACK_FILE(F : in out FILE_TYPE); procedure INITIALIZE_FILES; end external_file_manager;
47.8
114
0.767484
8b08f7f85471ee84291e8ed995171f6c753dddec
3,806
ads
Ada
source/amf/ocl/amf-internals-tables-ocl_notification.ads
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
24
2016-11-29T06:59:41.000Z
2021-08-30T11:55:16.000Z
source/amf/ocl/amf-internals-tables-ocl_notification.ads
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
2
2019-01-16T05:15:20.000Z
2019-02-03T10:03:32.000Z
source/amf/ocl/amf-internals-tables-ocl_notification.ads
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
4
2017-07-18T07:11:05.000Z
2020-06-21T03:02:25.000Z
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Ada Modeling Framework -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2012, Vadim Godunko <[email protected]> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ -- Helper subprograms for element modification notification. ------------------------------------------------------------------------------ with AMF.OCL; package AMF.Internals.Tables.OCL_Notification is procedure Notify_Attribute_Set (Element : AMF.Internals.AMF_Element; Property : AMF.Internals.CMOF_Element; Old_Value : AMF.OCL.OCL_Collection_Kind; New_Value : AMF.OCL.OCL_Collection_Kind); end AMF.Internals.Tables.OCL_Notification;
66.77193
78
0.419075
04f2fb93d99539bb928bd1c50ba9891e41201519
379
ads
Ada
stm32f4/stm32gd-spi.ads
ekoeppen/STM32_Generic_Ada_Drivers
4ff29c3026c4b24280baf22a5b81ea9969375466
[ "MIT" ]
1
2021-04-06T07:57:56.000Z
2021-04-06T07:57:56.000Z
stm32f4/stm32gd-spi.ads
ekoeppen/STM32_Generic_Ada_Drivers
4ff29c3026c4b24280baf22a5b81ea9969375466
[ "MIT" ]
null
null
null
stm32f4/stm32gd-spi.ads
ekoeppen/STM32_Generic_Ada_Drivers
4ff29c3026c4b24280baf22a5b81ea9969375466
[ "MIT" ]
2
2018-05-29T13:59:31.000Z
2019-02-03T19:48:08.000Z
with STM32_SVD; use STM32_SVD; with STM32_SVD.SPI; package STM32GD.SPI is pragma Preelaborate; SPI_1 : STM32_SVD.SPI.SPI_Peripheral renames STM32_SVD.SPI.SPI1_Periph; type SPI_Data_Size is (Data_Size_8b, Data_Size_16b); type SPI_Data_8b is array (Natural range <>) of Byte; type SPI_Data_16b is array (Natural range <>) of Byte; end STM32GD.SPI;
19.947368
74
0.730871
8b6e1aa2518d05602c883cebb9b1bc7faa8823a3
1,126
ads
Ada
mat/src/mat-interrupts.ads
stcarrez/mat
fb242feb5662b8130680cd06e50da7ef40b95bd7
[ "Apache-2.0" ]
7
2015-01-18T23:04:30.000Z
2021-04-06T14:07:56.000Z
mat/src/mat-interrupts.ads
stcarrez/mat
fb242feb5662b8130680cd06e50da7ef40b95bd7
[ "Apache-2.0" ]
null
null
null
mat/src/mat-interrupts.ads
stcarrez/mat
fb242feb5662b8130680cd06e50da7ef40b95bd7
[ "Apache-2.0" ]
null
null
null
----------------------------------------------------------------------- -- mat-interrupts - SIGINT management to stop long running commands -- Copyright (C) 2015 Stephane Carrez -- Written by Stephane Carrez ([email protected]) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- package MAT.Interrupts is -- Install the SIGINT handler. procedure Install; -- Reset the interrupted flag. procedure Clear; -- Check if we have been interrupted. function Is_Interrupted return Boolean; end MAT.Interrupts;
36.322581
76
0.639432
a07eb03221de6beaaf74fe01b85da303c19dbf61
48,948
ads
Ada
arch/ARM/STM32/svd/stm32f40x/stm32_svd-rcc.ads
shakram02/Ada_Drivers_Library
a407ca7ddbc2d9756647016c2f8fd8ef24a239ff
[ "BSD-3-Clause" ]
192
2016-06-01T18:32:04.000Z
2022-03-26T22:52:31.000Z
arch/ARM/STM32/svd/stm32f40x/stm32_svd-rcc.ads
morbos/Ada_Drivers_Library
a4ab26799be60997c38735f4056160c4af597ef7
[ "BSD-3-Clause" ]
239
2016-05-26T20:02:01.000Z
2022-03-31T09:46:56.000Z
arch/ARM/STM32/svd/stm32f40x/stm32_svd-rcc.ads
morbos/Ada_Drivers_Library
a4ab26799be60997c38735f4056160c4af597ef7
[ "BSD-3-Clause" ]
142
2016-06-05T08:12:20.000Z
2022-03-24T17:37:17.000Z
-- This spec has been automatically generated from STM32F40x.svd pragma Restrictions (No_Elaboration_Code); pragma Ada_2012; pragma Style_Checks (Off); with HAL; with System; package STM32_SVD.RCC is pragma Preelaborate; --------------- -- Registers -- --------------- subtype CR_HSITRIM_Field is HAL.UInt5; subtype CR_HSICAL_Field is HAL.UInt8; -- clock control register type CR_Register is record -- Internal high-speed clock enable HSION : Boolean := True; -- Read-only. Internal high-speed clock ready flag HSIRDY : Boolean := True; -- unspecified Reserved_2_2 : HAL.Bit := 16#0#; -- Internal high-speed clock trimming HSITRIM : CR_HSITRIM_Field := 16#10#; -- Read-only. Internal high-speed clock calibration HSICAL : CR_HSICAL_Field := 16#0#; -- HSE clock enable HSEON : Boolean := False; -- Read-only. HSE clock ready flag HSERDY : Boolean := False; -- HSE clock bypass HSEBYP : Boolean := False; -- Clock security system enable CSSON : Boolean := False; -- unspecified Reserved_20_23 : HAL.UInt4 := 16#0#; -- Main PLL (PLL) enable PLLON : Boolean := False; -- Read-only. Main PLL (PLL) clock ready flag PLLRDY : Boolean := False; -- PLLI2S enable PLLI2SON : Boolean := False; -- Read-only. PLLI2S clock ready flag PLLI2SRDY : Boolean := False; -- unspecified Reserved_28_31 : HAL.UInt4 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for CR_Register use record HSION at 0 range 0 .. 0; HSIRDY at 0 range 1 .. 1; Reserved_2_2 at 0 range 2 .. 2; HSITRIM at 0 range 3 .. 7; HSICAL at 0 range 8 .. 15; HSEON at 0 range 16 .. 16; HSERDY at 0 range 17 .. 17; HSEBYP at 0 range 18 .. 18; CSSON at 0 range 19 .. 19; Reserved_20_23 at 0 range 20 .. 23; PLLON at 0 range 24 .. 24; PLLRDY at 0 range 25 .. 25; PLLI2SON at 0 range 26 .. 26; PLLI2SRDY at 0 range 27 .. 27; Reserved_28_31 at 0 range 28 .. 31; end record; subtype PLLCFGR_PLLM_Field is HAL.UInt6; subtype PLLCFGR_PLLN_Field is HAL.UInt9; subtype PLLCFGR_PLLP_Field is HAL.UInt2; subtype PLLCFGR_PLLQ_Field is HAL.UInt4; -- PLL configuration register type PLLCFGR_Register is record -- Division factor for the main PLL (PLL) and audio PLL (PLLI2S) input -- clock PLLM : PLLCFGR_PLLM_Field := 16#10#; -- Main PLL (PLL) multiplication factor for VCO PLLN : PLLCFGR_PLLN_Field := 16#C0#; -- unspecified Reserved_15_15 : HAL.Bit := 16#0#; -- Main PLL (PLL) division factor for main system clock PLLP : PLLCFGR_PLLP_Field := 16#0#; -- unspecified Reserved_18_21 : HAL.UInt4 := 16#0#; -- Main PLL(PLL) and audio PLL (PLLI2S) entry clock source PLLSRC : Boolean := False; -- unspecified Reserved_23_23 : HAL.Bit := 16#0#; -- Main PLL (PLL) division factor for USB OTG FS, SDIO and random number -- generator clocks PLLQ : PLLCFGR_PLLQ_Field := 16#4#; -- unspecified Reserved_28_31 : HAL.UInt4 := 16#2#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for PLLCFGR_Register use record PLLM at 0 range 0 .. 5; PLLN at 0 range 6 .. 14; Reserved_15_15 at 0 range 15 .. 15; PLLP at 0 range 16 .. 17; Reserved_18_21 at 0 range 18 .. 21; PLLSRC at 0 range 22 .. 22; Reserved_23_23 at 0 range 23 .. 23; PLLQ at 0 range 24 .. 27; Reserved_28_31 at 0 range 28 .. 31; end record; subtype CFGR_SW_Field is HAL.UInt2; subtype CFGR_SWS_Field is HAL.UInt2; subtype CFGR_HPRE_Field is HAL.UInt4; -- CFGR_PPRE array element subtype CFGR_PPRE_Element is HAL.UInt3; -- CFGR_PPRE array type CFGR_PPRE_Field_Array is array (1 .. 2) of CFGR_PPRE_Element with Component_Size => 3, Size => 6; -- Type definition for CFGR_PPRE type CFGR_PPRE_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PPRE as a value Val : HAL.UInt6; when True => -- PPRE as an array Arr : CFGR_PPRE_Field_Array; end case; end record with Unchecked_Union, Size => 6; for CFGR_PPRE_Field use record Val at 0 range 0 .. 5; Arr at 0 range 0 .. 5; end record; subtype CFGR_RTCPRE_Field is HAL.UInt5; subtype CFGR_MCO1_Field is HAL.UInt2; subtype CFGR_MCO1PRE_Field is HAL.UInt3; subtype CFGR_MCO2PRE_Field is HAL.UInt3; subtype CFGR_MCO2_Field is HAL.UInt2; -- clock configuration register type CFGR_Register is record -- System clock switch SW : CFGR_SW_Field := 16#0#; -- Read-only. System clock switch status SWS : CFGR_SWS_Field := 16#0#; -- AHB prescaler HPRE : CFGR_HPRE_Field := 16#0#; -- unspecified Reserved_8_9 : HAL.UInt2 := 16#0#; -- APB Low speed prescaler (APB1) PPRE : CFGR_PPRE_Field := (As_Array => False, Val => 16#0#); -- HSE division factor for RTC clock RTCPRE : CFGR_RTCPRE_Field := 16#0#; -- Microcontroller clock output 1 MCO1 : CFGR_MCO1_Field := 16#0#; -- I2S clock selection I2SSRC : Boolean := False; -- MCO1 prescaler MCO1PRE : CFGR_MCO1PRE_Field := 16#0#; -- MCO2 prescaler MCO2PRE : CFGR_MCO2PRE_Field := 16#0#; -- Microcontroller clock output 2 MCO2 : CFGR_MCO2_Field := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for CFGR_Register use record SW at 0 range 0 .. 1; SWS at 0 range 2 .. 3; HPRE at 0 range 4 .. 7; Reserved_8_9 at 0 range 8 .. 9; PPRE at 0 range 10 .. 15; RTCPRE at 0 range 16 .. 20; MCO1 at 0 range 21 .. 22; I2SSRC at 0 range 23 .. 23; MCO1PRE at 0 range 24 .. 26; MCO2PRE at 0 range 27 .. 29; MCO2 at 0 range 30 .. 31; end record; -- clock interrupt register type CIR_Register is record -- Read-only. LSI ready interrupt flag LSIRDYF : Boolean := False; -- Read-only. LSE ready interrupt flag LSERDYF : Boolean := False; -- Read-only. HSI ready interrupt flag HSIRDYF : Boolean := False; -- Read-only. HSE ready interrupt flag HSERDYF : Boolean := False; -- Read-only. Main PLL (PLL) ready interrupt flag PLLRDYF : Boolean := False; -- Read-only. PLLI2S ready interrupt flag PLLI2SRDYF : Boolean := False; -- unspecified Reserved_6_6 : HAL.Bit := 16#0#; -- Read-only. Clock security system interrupt flag CSSF : Boolean := False; -- LSI ready interrupt enable LSIRDYIE : Boolean := False; -- LSE ready interrupt enable LSERDYIE : Boolean := False; -- HSI ready interrupt enable HSIRDYIE : Boolean := False; -- HSE ready interrupt enable HSERDYIE : Boolean := False; -- Main PLL (PLL) ready interrupt enable PLLRDYIE : Boolean := False; -- PLLI2S ready interrupt enable PLLI2SRDYIE : Boolean := False; -- unspecified Reserved_14_15 : HAL.UInt2 := 16#0#; -- Write-only. LSI ready interrupt clear LSIRDYC : Boolean := False; -- Write-only. LSE ready interrupt clear LSERDYC : Boolean := False; -- Write-only. HSI ready interrupt clear HSIRDYC : Boolean := False; -- Write-only. HSE ready interrupt clear HSERDYC : Boolean := False; -- Write-only. Main PLL(PLL) ready interrupt clear PLLRDYC : Boolean := False; -- Write-only. PLLI2S ready interrupt clear PLLI2SRDYC : Boolean := False; -- unspecified Reserved_22_22 : HAL.Bit := 16#0#; -- Write-only. Clock security system interrupt clear CSSC : Boolean := False; -- unspecified Reserved_24_31 : HAL.UInt8 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for CIR_Register use record LSIRDYF at 0 range 0 .. 0; LSERDYF at 0 range 1 .. 1; HSIRDYF at 0 range 2 .. 2; HSERDYF at 0 range 3 .. 3; PLLRDYF at 0 range 4 .. 4; PLLI2SRDYF at 0 range 5 .. 5; Reserved_6_6 at 0 range 6 .. 6; CSSF at 0 range 7 .. 7; LSIRDYIE at 0 range 8 .. 8; LSERDYIE at 0 range 9 .. 9; HSIRDYIE at 0 range 10 .. 10; HSERDYIE at 0 range 11 .. 11; PLLRDYIE at 0 range 12 .. 12; PLLI2SRDYIE at 0 range 13 .. 13; Reserved_14_15 at 0 range 14 .. 15; LSIRDYC at 0 range 16 .. 16; LSERDYC at 0 range 17 .. 17; HSIRDYC at 0 range 18 .. 18; HSERDYC at 0 range 19 .. 19; PLLRDYC at 0 range 20 .. 20; PLLI2SRDYC at 0 range 21 .. 21; Reserved_22_22 at 0 range 22 .. 22; CSSC at 0 range 23 .. 23; Reserved_24_31 at 0 range 24 .. 31; end record; -- AHB1 peripheral reset register type AHB1RSTR_Register is record -- IO port A reset GPIOARST : Boolean := False; -- IO port B reset GPIOBRST : Boolean := False; -- IO port C reset GPIOCRST : Boolean := False; -- IO port D reset GPIODRST : Boolean := False; -- IO port E reset GPIOERST : Boolean := False; -- IO port F reset GPIOFRST : Boolean := False; -- IO port G reset GPIOGRST : Boolean := False; -- IO port H reset GPIOHRST : Boolean := False; -- IO port I reset GPIOIRST : Boolean := False; -- unspecified Reserved_9_11 : HAL.UInt3 := 16#0#; -- CRC reset CRCRST : Boolean := False; -- unspecified Reserved_13_20 : HAL.UInt8 := 16#0#; -- DMA2 reset DMA1RST : Boolean := False; -- DMA2 reset DMA2RST : Boolean := False; -- unspecified Reserved_23_24 : HAL.UInt2 := 16#0#; -- Ethernet MAC reset ETHMACRST : Boolean := False; -- unspecified Reserved_26_28 : HAL.UInt3 := 16#0#; -- USB OTG HS module reset OTGHSRST : Boolean := False; -- unspecified Reserved_30_31 : HAL.UInt2 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for AHB1RSTR_Register use record GPIOARST at 0 range 0 .. 0; GPIOBRST at 0 range 1 .. 1; GPIOCRST at 0 range 2 .. 2; GPIODRST at 0 range 3 .. 3; GPIOERST at 0 range 4 .. 4; GPIOFRST at 0 range 5 .. 5; GPIOGRST at 0 range 6 .. 6; GPIOHRST at 0 range 7 .. 7; GPIOIRST at 0 range 8 .. 8; Reserved_9_11 at 0 range 9 .. 11; CRCRST at 0 range 12 .. 12; Reserved_13_20 at 0 range 13 .. 20; DMA1RST at 0 range 21 .. 21; DMA2RST at 0 range 22 .. 22; Reserved_23_24 at 0 range 23 .. 24; ETHMACRST at 0 range 25 .. 25; Reserved_26_28 at 0 range 26 .. 28; OTGHSRST at 0 range 29 .. 29; Reserved_30_31 at 0 range 30 .. 31; end record; -- AHB2 peripheral reset register type AHB2RSTR_Register is record -- Camera interface reset DCMIRST : Boolean := False; -- unspecified Reserved_1_5 : HAL.UInt5 := 16#0#; -- Random number generator module reset RNGRST : Boolean := False; -- USB OTG FS module reset OTGFSRST : Boolean := False; -- unspecified Reserved_8_31 : HAL.UInt24 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for AHB2RSTR_Register use record DCMIRST at 0 range 0 .. 0; Reserved_1_5 at 0 range 1 .. 5; RNGRST at 0 range 6 .. 6; OTGFSRST at 0 range 7 .. 7; Reserved_8_31 at 0 range 8 .. 31; end record; -- AHB3 peripheral reset register type AHB3RSTR_Register is record -- Flexible static memory controller module reset FSMCRST : Boolean := False; -- unspecified Reserved_1_31 : HAL.UInt31 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for AHB3RSTR_Register use record FSMCRST at 0 range 0 .. 0; Reserved_1_31 at 0 range 1 .. 31; end record; -- APB1 peripheral reset register type APB1RSTR_Register is record -- TIM2 reset TIM2RST : Boolean := False; -- TIM3 reset TIM3RST : Boolean := False; -- TIM4 reset TIM4RST : Boolean := False; -- TIM5 reset TIM5RST : Boolean := False; -- TIM6 reset TIM6RST : Boolean := False; -- TIM7 reset TIM7RST : Boolean := False; -- TIM12 reset TIM12RST : Boolean := False; -- TIM13 reset TIM13RST : Boolean := False; -- TIM14 reset TIM14RST : Boolean := False; -- unspecified Reserved_9_10 : HAL.UInt2 := 16#0#; -- Window watchdog reset WWDGRST : Boolean := False; -- unspecified Reserved_12_13 : HAL.UInt2 := 16#0#; -- SPI 2 reset SPI2RST : Boolean := False; -- SPI 3 reset SPI3RST : Boolean := False; -- unspecified Reserved_16_16 : HAL.Bit := 16#0#; -- USART 2 reset UART2RST : Boolean := False; -- USART 3 reset UART3RST : Boolean := False; -- USART 4 reset UART4RST : Boolean := False; -- USART 5 reset UART5RST : Boolean := False; -- I2C 1 reset I2C1RST : Boolean := False; -- I2C 2 reset I2C2RST : Boolean := False; -- I2C3 reset I2C3RST : Boolean := False; -- unspecified Reserved_24_24 : HAL.Bit := 16#0#; -- CAN1 reset CAN1RST : Boolean := False; -- CAN2 reset CAN2RST : Boolean := False; -- unspecified Reserved_27_27 : HAL.Bit := 16#0#; -- Power interface reset PWRRST : Boolean := False; -- DAC reset DACRST : Boolean := False; -- unspecified Reserved_30_31 : HAL.UInt2 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for APB1RSTR_Register use record TIM2RST at 0 range 0 .. 0; TIM3RST at 0 range 1 .. 1; TIM4RST at 0 range 2 .. 2; TIM5RST at 0 range 3 .. 3; TIM6RST at 0 range 4 .. 4; TIM7RST at 0 range 5 .. 5; TIM12RST at 0 range 6 .. 6; TIM13RST at 0 range 7 .. 7; TIM14RST at 0 range 8 .. 8; Reserved_9_10 at 0 range 9 .. 10; WWDGRST at 0 range 11 .. 11; Reserved_12_13 at 0 range 12 .. 13; SPI2RST at 0 range 14 .. 14; SPI3RST at 0 range 15 .. 15; Reserved_16_16 at 0 range 16 .. 16; UART2RST at 0 range 17 .. 17; UART3RST at 0 range 18 .. 18; UART4RST at 0 range 19 .. 19; UART5RST at 0 range 20 .. 20; I2C1RST at 0 range 21 .. 21; I2C2RST at 0 range 22 .. 22; I2C3RST at 0 range 23 .. 23; Reserved_24_24 at 0 range 24 .. 24; CAN1RST at 0 range 25 .. 25; CAN2RST at 0 range 26 .. 26; Reserved_27_27 at 0 range 27 .. 27; PWRRST at 0 range 28 .. 28; DACRST at 0 range 29 .. 29; Reserved_30_31 at 0 range 30 .. 31; end record; -- APB2 peripheral reset register type APB2RSTR_Register is record -- TIM1 reset TIM1RST : Boolean := False; -- TIM8 reset TIM8RST : Boolean := False; -- unspecified Reserved_2_3 : HAL.UInt2 := 16#0#; -- USART1 reset USART1RST : Boolean := False; -- USART6 reset USART6RST : Boolean := False; -- unspecified Reserved_6_7 : HAL.UInt2 := 16#0#; -- ADC interface reset (common to all ADCs) ADCRST : Boolean := False; -- unspecified Reserved_9_10 : HAL.UInt2 := 16#0#; -- SDIO reset SDIORST : Boolean := False; -- SPI 1 reset SPI1RST : Boolean := False; -- unspecified Reserved_13_13 : HAL.Bit := 16#0#; -- System configuration controller reset SYSCFGRST : Boolean := False; -- unspecified Reserved_15_15 : HAL.Bit := 16#0#; -- TIM9 reset TIM9RST : Boolean := False; -- TIM10 reset TIM10RST : Boolean := False; -- TIM11 reset TIM11RST : Boolean := False; -- unspecified Reserved_19_31 : HAL.UInt13 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for APB2RSTR_Register use record TIM1RST at 0 range 0 .. 0; TIM8RST at 0 range 1 .. 1; Reserved_2_3 at 0 range 2 .. 3; USART1RST at 0 range 4 .. 4; USART6RST at 0 range 5 .. 5; Reserved_6_7 at 0 range 6 .. 7; ADCRST at 0 range 8 .. 8; Reserved_9_10 at 0 range 9 .. 10; SDIORST at 0 range 11 .. 11; SPI1RST at 0 range 12 .. 12; Reserved_13_13 at 0 range 13 .. 13; SYSCFGRST at 0 range 14 .. 14; Reserved_15_15 at 0 range 15 .. 15; TIM9RST at 0 range 16 .. 16; TIM10RST at 0 range 17 .. 17; TIM11RST at 0 range 18 .. 18; Reserved_19_31 at 0 range 19 .. 31; end record; -- AHB1 peripheral clock register type AHB1ENR_Register is record -- IO port A clock enable GPIOAEN : Boolean := False; -- IO port B clock enable GPIOBEN : Boolean := False; -- IO port C clock enable GPIOCEN : Boolean := False; -- IO port D clock enable GPIODEN : Boolean := False; -- IO port E clock enable GPIOEEN : Boolean := False; -- IO port F clock enable GPIOFEN : Boolean := False; -- IO port G clock enable GPIOGEN : Boolean := False; -- IO port H clock enable GPIOHEN : Boolean := False; -- IO port I clock enable GPIOIEN : Boolean := False; -- unspecified Reserved_9_11 : HAL.UInt3 := 16#0#; -- CRC clock enable CRCEN : Boolean := False; -- unspecified Reserved_13_17 : HAL.UInt5 := 16#0#; -- Backup SRAM interface clock enable BKPSRAMEN : Boolean := False; -- unspecified Reserved_19_20 : HAL.UInt2 := 16#2#; -- DMA1 clock enable DMA1EN : Boolean := False; -- DMA2 clock enable DMA2EN : Boolean := False; -- unspecified Reserved_23_24 : HAL.UInt2 := 16#0#; -- Ethernet MAC clock enable ETHMACEN : Boolean := False; -- Ethernet Transmission clock enable ETHMACTXEN : Boolean := False; -- Ethernet Reception clock enable ETHMACRXEN : Boolean := False; -- Ethernet PTP clock enable ETHMACPTPEN : Boolean := False; -- USB OTG HS clock enable OTGHSEN : Boolean := False; -- USB OTG HSULPI clock enable OTGHSULPIEN : Boolean := False; -- unspecified Reserved_31_31 : HAL.Bit := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for AHB1ENR_Register use record GPIOAEN at 0 range 0 .. 0; GPIOBEN at 0 range 1 .. 1; GPIOCEN at 0 range 2 .. 2; GPIODEN at 0 range 3 .. 3; GPIOEEN at 0 range 4 .. 4; GPIOFEN at 0 range 5 .. 5; GPIOGEN at 0 range 6 .. 6; GPIOHEN at 0 range 7 .. 7; GPIOIEN at 0 range 8 .. 8; Reserved_9_11 at 0 range 9 .. 11; CRCEN at 0 range 12 .. 12; Reserved_13_17 at 0 range 13 .. 17; BKPSRAMEN at 0 range 18 .. 18; Reserved_19_20 at 0 range 19 .. 20; DMA1EN at 0 range 21 .. 21; DMA2EN at 0 range 22 .. 22; Reserved_23_24 at 0 range 23 .. 24; ETHMACEN at 0 range 25 .. 25; ETHMACTXEN at 0 range 26 .. 26; ETHMACRXEN at 0 range 27 .. 27; ETHMACPTPEN at 0 range 28 .. 28; OTGHSEN at 0 range 29 .. 29; OTGHSULPIEN at 0 range 30 .. 30; Reserved_31_31 at 0 range 31 .. 31; end record; -- AHB2 peripheral clock enable register type AHB2ENR_Register is record -- Camera interface enable DCMIEN : Boolean := False; -- unspecified Reserved_1_5 : HAL.UInt5 := 16#0#; -- Random number generator clock enable RNGEN : Boolean := False; -- USB OTG FS clock enable OTGFSEN : Boolean := False; -- unspecified Reserved_8_31 : HAL.UInt24 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for AHB2ENR_Register use record DCMIEN at 0 range 0 .. 0; Reserved_1_5 at 0 range 1 .. 5; RNGEN at 0 range 6 .. 6; OTGFSEN at 0 range 7 .. 7; Reserved_8_31 at 0 range 8 .. 31; end record; -- AHB3 peripheral clock enable register type AHB3ENR_Register is record -- Flexible static memory controller module clock enable FSMCEN : Boolean := False; -- unspecified Reserved_1_31 : HAL.UInt31 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for AHB3ENR_Register use record FSMCEN at 0 range 0 .. 0; Reserved_1_31 at 0 range 1 .. 31; end record; -- APB1 peripheral clock enable register type APB1ENR_Register is record -- TIM2 clock enable TIM2EN : Boolean := False; -- TIM3 clock enable TIM3EN : Boolean := False; -- TIM4 clock enable TIM4EN : Boolean := False; -- TIM5 clock enable TIM5EN : Boolean := False; -- TIM6 clock enable TIM6EN : Boolean := False; -- TIM7 clock enable TIM7EN : Boolean := False; -- TIM12 clock enable TIM12EN : Boolean := False; -- TIM13 clock enable TIM13EN : Boolean := False; -- TIM14 clock enable TIM14EN : Boolean := False; -- unspecified Reserved_9_10 : HAL.UInt2 := 16#0#; -- Window watchdog clock enable WWDGEN : Boolean := False; -- unspecified Reserved_12_13 : HAL.UInt2 := 16#0#; -- SPI2 clock enable SPI2EN : Boolean := False; -- SPI3 clock enable SPI3EN : Boolean := False; -- unspecified Reserved_16_16 : HAL.Bit := 16#0#; -- USART 2 clock enable USART2EN : Boolean := False; -- USART3 clock enable USART3EN : Boolean := False; -- UART4 clock enable UART4EN : Boolean := False; -- UART5 clock enable UART5EN : Boolean := False; -- I2C1 clock enable I2C1EN : Boolean := False; -- I2C2 clock enable I2C2EN : Boolean := False; -- I2C3 clock enable I2C3EN : Boolean := False; -- unspecified Reserved_24_24 : HAL.Bit := 16#0#; -- CAN 1 clock enable CAN1EN : Boolean := False; -- CAN 2 clock enable CAN2EN : Boolean := False; -- unspecified Reserved_27_27 : HAL.Bit := 16#0#; -- Power interface clock enable PWREN : Boolean := False; -- DAC interface clock enable DACEN : Boolean := False; -- unspecified Reserved_30_31 : HAL.UInt2 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for APB1ENR_Register use record TIM2EN at 0 range 0 .. 0; TIM3EN at 0 range 1 .. 1; TIM4EN at 0 range 2 .. 2; TIM5EN at 0 range 3 .. 3; TIM6EN at 0 range 4 .. 4; TIM7EN at 0 range 5 .. 5; TIM12EN at 0 range 6 .. 6; TIM13EN at 0 range 7 .. 7; TIM14EN at 0 range 8 .. 8; Reserved_9_10 at 0 range 9 .. 10; WWDGEN at 0 range 11 .. 11; Reserved_12_13 at 0 range 12 .. 13; SPI2EN at 0 range 14 .. 14; SPI3EN at 0 range 15 .. 15; Reserved_16_16 at 0 range 16 .. 16; USART2EN at 0 range 17 .. 17; USART3EN at 0 range 18 .. 18; UART4EN at 0 range 19 .. 19; UART5EN at 0 range 20 .. 20; I2C1EN at 0 range 21 .. 21; I2C2EN at 0 range 22 .. 22; I2C3EN at 0 range 23 .. 23; Reserved_24_24 at 0 range 24 .. 24; CAN1EN at 0 range 25 .. 25; CAN2EN at 0 range 26 .. 26; Reserved_27_27 at 0 range 27 .. 27; PWREN at 0 range 28 .. 28; DACEN at 0 range 29 .. 29; Reserved_30_31 at 0 range 30 .. 31; end record; -- APB2 peripheral clock enable register type APB2ENR_Register is record -- TIM1 clock enable TIM1EN : Boolean := False; -- TIM8 clock enable TIM8EN : Boolean := False; -- unspecified Reserved_2_3 : HAL.UInt2 := 16#0#; -- USART1 clock enable USART1EN : Boolean := False; -- USART6 clock enable USART6EN : Boolean := False; -- unspecified Reserved_6_7 : HAL.UInt2 := 16#0#; -- ADC1 clock enable ADC1EN : Boolean := False; -- ADC2 clock enable ADC2EN : Boolean := False; -- ADC3 clock enable ADC3EN : Boolean := False; -- SDIO clock enable SDIOEN : Boolean := False; -- SPI1 clock enable SPI1EN : Boolean := False; -- unspecified Reserved_13_13 : HAL.Bit := 16#0#; -- System configuration controller clock enable SYSCFGEN : Boolean := False; -- unspecified Reserved_15_15 : HAL.Bit := 16#0#; -- TIM9 clock enable TIM9EN : Boolean := False; -- TIM10 clock enable TIM10EN : Boolean := False; -- TIM11 clock enable TIM11EN : Boolean := False; -- unspecified Reserved_19_31 : HAL.UInt13 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for APB2ENR_Register use record TIM1EN at 0 range 0 .. 0; TIM8EN at 0 range 1 .. 1; Reserved_2_3 at 0 range 2 .. 3; USART1EN at 0 range 4 .. 4; USART6EN at 0 range 5 .. 5; Reserved_6_7 at 0 range 6 .. 7; ADC1EN at 0 range 8 .. 8; ADC2EN at 0 range 9 .. 9; ADC3EN at 0 range 10 .. 10; SDIOEN at 0 range 11 .. 11; SPI1EN at 0 range 12 .. 12; Reserved_13_13 at 0 range 13 .. 13; SYSCFGEN at 0 range 14 .. 14; Reserved_15_15 at 0 range 15 .. 15; TIM9EN at 0 range 16 .. 16; TIM10EN at 0 range 17 .. 17; TIM11EN at 0 range 18 .. 18; Reserved_19_31 at 0 range 19 .. 31; end record; -- AHB1 peripheral clock enable in low power mode register type AHB1LPENR_Register is record -- IO port A clock enable during sleep mode GPIOALPEN : Boolean := True; -- IO port B clock enable during Sleep mode GPIOBLPEN : Boolean := True; -- IO port C clock enable during Sleep mode GPIOCLPEN : Boolean := True; -- IO port D clock enable during Sleep mode GPIODLPEN : Boolean := True; -- IO port E clock enable during Sleep mode GPIOELPEN : Boolean := True; -- IO port F clock enable during Sleep mode GPIOFLPEN : Boolean := True; -- IO port G clock enable during Sleep mode GPIOGLPEN : Boolean := True; -- IO port H clock enable during Sleep mode GPIOHLPEN : Boolean := True; -- IO port I clock enable during Sleep mode GPIOILPEN : Boolean := True; -- unspecified Reserved_9_11 : HAL.UInt3 := 16#0#; -- CRC clock enable during Sleep mode CRCLPEN : Boolean := True; -- unspecified Reserved_13_14 : HAL.UInt2 := 16#0#; -- Flash interface clock enable during Sleep mode FLITFLPEN : Boolean := True; -- SRAM 1interface clock enable during Sleep mode SRAM1LPEN : Boolean := True; -- SRAM 2 interface clock enable during Sleep mode SRAM2LPEN : Boolean := True; -- Backup SRAM interface clock enable during Sleep mode BKPSRAMLPEN : Boolean := True; -- unspecified Reserved_19_20 : HAL.UInt2 := 16#0#; -- DMA1 clock enable during Sleep mode DMA1LPEN : Boolean := True; -- DMA2 clock enable during Sleep mode DMA2LPEN : Boolean := True; -- unspecified Reserved_23_24 : HAL.UInt2 := 16#0#; -- Ethernet MAC clock enable during Sleep mode ETHMACLPEN : Boolean := True; -- Ethernet transmission clock enable during Sleep mode ETHMACTXLPEN : Boolean := True; -- Ethernet reception clock enable during Sleep mode ETHMACRXLPEN : Boolean := True; -- Ethernet PTP clock enable during Sleep mode ETHMACPTPLPEN : Boolean := True; -- USB OTG HS clock enable during Sleep mode OTGHSLPEN : Boolean := True; -- USB OTG HS ULPI clock enable during Sleep mode OTGHSULPILPEN : Boolean := True; -- unspecified Reserved_31_31 : HAL.Bit := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for AHB1LPENR_Register use record GPIOALPEN at 0 range 0 .. 0; GPIOBLPEN at 0 range 1 .. 1; GPIOCLPEN at 0 range 2 .. 2; GPIODLPEN at 0 range 3 .. 3; GPIOELPEN at 0 range 4 .. 4; GPIOFLPEN at 0 range 5 .. 5; GPIOGLPEN at 0 range 6 .. 6; GPIOHLPEN at 0 range 7 .. 7; GPIOILPEN at 0 range 8 .. 8; Reserved_9_11 at 0 range 9 .. 11; CRCLPEN at 0 range 12 .. 12; Reserved_13_14 at 0 range 13 .. 14; FLITFLPEN at 0 range 15 .. 15; SRAM1LPEN at 0 range 16 .. 16; SRAM2LPEN at 0 range 17 .. 17; BKPSRAMLPEN at 0 range 18 .. 18; Reserved_19_20 at 0 range 19 .. 20; DMA1LPEN at 0 range 21 .. 21; DMA2LPEN at 0 range 22 .. 22; Reserved_23_24 at 0 range 23 .. 24; ETHMACLPEN at 0 range 25 .. 25; ETHMACTXLPEN at 0 range 26 .. 26; ETHMACRXLPEN at 0 range 27 .. 27; ETHMACPTPLPEN at 0 range 28 .. 28; OTGHSLPEN at 0 range 29 .. 29; OTGHSULPILPEN at 0 range 30 .. 30; Reserved_31_31 at 0 range 31 .. 31; end record; -- AHB2 peripheral clock enable in low power mode register type AHB2LPENR_Register is record -- Camera interface enable during Sleep mode DCMILPEN : Boolean := True; -- unspecified Reserved_1_5 : HAL.UInt5 := 16#18#; -- Random number generator clock enable during Sleep mode RNGLPEN : Boolean := True; -- USB OTG FS clock enable during Sleep mode OTGFSLPEN : Boolean := True; -- unspecified Reserved_8_31 : HAL.UInt24 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for AHB2LPENR_Register use record DCMILPEN at 0 range 0 .. 0; Reserved_1_5 at 0 range 1 .. 5; RNGLPEN at 0 range 6 .. 6; OTGFSLPEN at 0 range 7 .. 7; Reserved_8_31 at 0 range 8 .. 31; end record; -- AHB3 peripheral clock enable in low power mode register type AHB3LPENR_Register is record -- Flexible static memory controller module clock enable during Sleep -- mode FSMCLPEN : Boolean := True; -- unspecified Reserved_1_31 : HAL.UInt31 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for AHB3LPENR_Register use record FSMCLPEN at 0 range 0 .. 0; Reserved_1_31 at 0 range 1 .. 31; end record; -- APB1 peripheral clock enable in low power mode register type APB1LPENR_Register is record -- TIM2 clock enable during Sleep mode TIM2LPEN : Boolean := True; -- TIM3 clock enable during Sleep mode TIM3LPEN : Boolean := True; -- TIM4 clock enable during Sleep mode TIM4LPEN : Boolean := True; -- TIM5 clock enable during Sleep mode TIM5LPEN : Boolean := True; -- TIM6 clock enable during Sleep mode TIM6LPEN : Boolean := True; -- TIM7 clock enable during Sleep mode TIM7LPEN : Boolean := True; -- TIM12 clock enable during Sleep mode TIM12LPEN : Boolean := True; -- TIM13 clock enable during Sleep mode TIM13LPEN : Boolean := True; -- TIM14 clock enable during Sleep mode TIM14LPEN : Boolean := True; -- unspecified Reserved_9_10 : HAL.UInt2 := 16#0#; -- Window watchdog clock enable during Sleep mode WWDGLPEN : Boolean := True; -- unspecified Reserved_12_13 : HAL.UInt2 := 16#0#; -- SPI2 clock enable during Sleep mode SPI2LPEN : Boolean := True; -- SPI3 clock enable during Sleep mode SPI3LPEN : Boolean := True; -- unspecified Reserved_16_16 : HAL.Bit := 16#0#; -- USART2 clock enable during Sleep mode USART2LPEN : Boolean := True; -- USART3 clock enable during Sleep mode USART3LPEN : Boolean := True; -- UART4 clock enable during Sleep mode UART4LPEN : Boolean := True; -- UART5 clock enable during Sleep mode UART5LPEN : Boolean := True; -- I2C1 clock enable during Sleep mode I2C1LPEN : Boolean := True; -- I2C2 clock enable during Sleep mode I2C2LPEN : Boolean := True; -- I2C3 clock enable during Sleep mode I2C3LPEN : Boolean := True; -- unspecified Reserved_24_24 : HAL.Bit := 16#0#; -- CAN 1 clock enable during Sleep mode CAN1LPEN : Boolean := True; -- CAN 2 clock enable during Sleep mode CAN2LPEN : Boolean := True; -- unspecified Reserved_27_27 : HAL.Bit := 16#0#; -- Power interface clock enable during Sleep mode PWRLPEN : Boolean := True; -- DAC interface clock enable during Sleep mode DACLPEN : Boolean := True; -- unspecified Reserved_30_31 : HAL.UInt2 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for APB1LPENR_Register use record TIM2LPEN at 0 range 0 .. 0; TIM3LPEN at 0 range 1 .. 1; TIM4LPEN at 0 range 2 .. 2; TIM5LPEN at 0 range 3 .. 3; TIM6LPEN at 0 range 4 .. 4; TIM7LPEN at 0 range 5 .. 5; TIM12LPEN at 0 range 6 .. 6; TIM13LPEN at 0 range 7 .. 7; TIM14LPEN at 0 range 8 .. 8; Reserved_9_10 at 0 range 9 .. 10; WWDGLPEN at 0 range 11 .. 11; Reserved_12_13 at 0 range 12 .. 13; SPI2LPEN at 0 range 14 .. 14; SPI3LPEN at 0 range 15 .. 15; Reserved_16_16 at 0 range 16 .. 16; USART2LPEN at 0 range 17 .. 17; USART3LPEN at 0 range 18 .. 18; UART4LPEN at 0 range 19 .. 19; UART5LPEN at 0 range 20 .. 20; I2C1LPEN at 0 range 21 .. 21; I2C2LPEN at 0 range 22 .. 22; I2C3LPEN at 0 range 23 .. 23; Reserved_24_24 at 0 range 24 .. 24; CAN1LPEN at 0 range 25 .. 25; CAN2LPEN at 0 range 26 .. 26; Reserved_27_27 at 0 range 27 .. 27; PWRLPEN at 0 range 28 .. 28; DACLPEN at 0 range 29 .. 29; Reserved_30_31 at 0 range 30 .. 31; end record; -- APB2 peripheral clock enabled in low power mode register type APB2LPENR_Register is record -- TIM1 clock enable during Sleep mode TIM1LPEN : Boolean := True; -- TIM8 clock enable during Sleep mode TIM8LPEN : Boolean := True; -- unspecified Reserved_2_3 : HAL.UInt2 := 16#0#; -- USART1 clock enable during Sleep mode USART1LPEN : Boolean := True; -- USART6 clock enable during Sleep mode USART6LPEN : Boolean := True; -- unspecified Reserved_6_7 : HAL.UInt2 := 16#0#; -- ADC1 clock enable during Sleep mode ADC1LPEN : Boolean := True; -- ADC2 clock enable during Sleep mode ADC2LPEN : Boolean := True; -- ADC 3 clock enable during Sleep mode ADC3LPEN : Boolean := True; -- SDIO clock enable during Sleep mode SDIOLPEN : Boolean := True; -- SPI 1 clock enable during Sleep mode SPI1LPEN : Boolean := True; -- unspecified Reserved_13_13 : HAL.Bit := 16#0#; -- System configuration controller clock enable during Sleep mode SYSCFGLPEN : Boolean := True; -- unspecified Reserved_15_15 : HAL.Bit := 16#0#; -- TIM9 clock enable during sleep mode TIM9LPEN : Boolean := True; -- TIM10 clock enable during Sleep mode TIM10LPEN : Boolean := True; -- TIM11 clock enable during Sleep mode TIM11LPEN : Boolean := True; -- unspecified Reserved_19_31 : HAL.UInt13 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for APB2LPENR_Register use record TIM1LPEN at 0 range 0 .. 0; TIM8LPEN at 0 range 1 .. 1; Reserved_2_3 at 0 range 2 .. 3; USART1LPEN at 0 range 4 .. 4; USART6LPEN at 0 range 5 .. 5; Reserved_6_7 at 0 range 6 .. 7; ADC1LPEN at 0 range 8 .. 8; ADC2LPEN at 0 range 9 .. 9; ADC3LPEN at 0 range 10 .. 10; SDIOLPEN at 0 range 11 .. 11; SPI1LPEN at 0 range 12 .. 12; Reserved_13_13 at 0 range 13 .. 13; SYSCFGLPEN at 0 range 14 .. 14; Reserved_15_15 at 0 range 15 .. 15; TIM9LPEN at 0 range 16 .. 16; TIM10LPEN at 0 range 17 .. 17; TIM11LPEN at 0 range 18 .. 18; Reserved_19_31 at 0 range 19 .. 31; end record; -- BDCR_RTCSEL array type BDCR_RTCSEL_Field_Array is array (0 .. 1) of Boolean with Component_Size => 1, Size => 2; -- Type definition for BDCR_RTCSEL type BDCR_RTCSEL_Field (As_Array : Boolean := False) is record case As_Array is when False => -- RTCSEL as a value Val : HAL.UInt2; when True => -- RTCSEL as an array Arr : BDCR_RTCSEL_Field_Array; end case; end record with Unchecked_Union, Size => 2; for BDCR_RTCSEL_Field use record Val at 0 range 0 .. 1; Arr at 0 range 0 .. 1; end record; -- Backup domain control register type BDCR_Register is record -- External low-speed oscillator enable LSEON : Boolean := False; -- Read-only. External low-speed oscillator ready LSERDY : Boolean := False; -- External low-speed oscillator bypass LSEBYP : Boolean := False; -- unspecified Reserved_3_7 : HAL.UInt5 := 16#0#; -- RTC clock source selection RTCSEL : BDCR_RTCSEL_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_10_14 : HAL.UInt5 := 16#0#; -- RTC clock enable RTCEN : Boolean := False; -- Backup domain software reset BDRST : Boolean := False; -- unspecified Reserved_17_31 : HAL.UInt15 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for BDCR_Register use record LSEON at 0 range 0 .. 0; LSERDY at 0 range 1 .. 1; LSEBYP at 0 range 2 .. 2; Reserved_3_7 at 0 range 3 .. 7; RTCSEL at 0 range 8 .. 9; Reserved_10_14 at 0 range 10 .. 14; RTCEN at 0 range 15 .. 15; BDRST at 0 range 16 .. 16; Reserved_17_31 at 0 range 17 .. 31; end record; -- clock control & status register type CSR_Register is record -- Internal low-speed oscillator enable LSION : Boolean := False; -- Read-only. Internal low-speed oscillator ready LSIRDY : Boolean := False; -- unspecified Reserved_2_23 : HAL.UInt22 := 16#0#; -- Remove reset flag RMVF : Boolean := False; -- BOR reset flag BORRSTF : Boolean := True; -- PIN reset flag PADRSTF : Boolean := True; -- POR/PDR reset flag PORRSTF : Boolean := True; -- Software reset flag SFTRSTF : Boolean := False; -- Independent watchdog reset flag WDGRSTF : Boolean := False; -- Window watchdog reset flag WWDGRSTF : Boolean := False; -- Low-power reset flag LPWRRSTF : Boolean := False; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for CSR_Register use record LSION at 0 range 0 .. 0; LSIRDY at 0 range 1 .. 1; Reserved_2_23 at 0 range 2 .. 23; RMVF at 0 range 24 .. 24; BORRSTF at 0 range 25 .. 25; PADRSTF at 0 range 26 .. 26; PORRSTF at 0 range 27 .. 27; SFTRSTF at 0 range 28 .. 28; WDGRSTF at 0 range 29 .. 29; WWDGRSTF at 0 range 30 .. 30; LPWRRSTF at 0 range 31 .. 31; end record; subtype SSCGR_MODPER_Field is HAL.UInt13; subtype SSCGR_INCSTEP_Field is HAL.UInt15; -- spread spectrum clock generation register type SSCGR_Register is record -- Modulation period MODPER : SSCGR_MODPER_Field := 16#0#; -- Incrementation step INCSTEP : SSCGR_INCSTEP_Field := 16#0#; -- unspecified Reserved_28_29 : HAL.UInt2 := 16#0#; -- Spread Select SPREADSEL : Boolean := False; -- Spread spectrum modulation enable SSCGEN : Boolean := False; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for SSCGR_Register use record MODPER at 0 range 0 .. 12; INCSTEP at 0 range 13 .. 27; Reserved_28_29 at 0 range 28 .. 29; SPREADSEL at 0 range 30 .. 30; SSCGEN at 0 range 31 .. 31; end record; subtype PLLI2SCFGR_PLLI2SNx_Field is HAL.UInt9; subtype PLLI2SCFGR_PLLI2SRx_Field is HAL.UInt3; -- PLLI2S configuration register type PLLI2SCFGR_Register is record -- unspecified Reserved_0_5 : HAL.UInt6 := 16#0#; -- PLLI2S multiplication factor for VCO PLLI2SNx : PLLI2SCFGR_PLLI2SNx_Field := 16#C0#; -- unspecified Reserved_15_27 : HAL.UInt13 := 16#0#; -- PLLI2S division factor for I2S clocks PLLI2SRx : PLLI2SCFGR_PLLI2SRx_Field := 16#2#; -- unspecified Reserved_31_31 : HAL.Bit := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for PLLI2SCFGR_Register use record Reserved_0_5 at 0 range 0 .. 5; PLLI2SNx at 0 range 6 .. 14; Reserved_15_27 at 0 range 15 .. 27; PLLI2SRx at 0 range 28 .. 30; Reserved_31_31 at 0 range 31 .. 31; end record; ----------------- -- Peripherals -- ----------------- -- Reset and clock control type RCC_Peripheral is record -- clock control register CR : aliased CR_Register; -- PLL configuration register PLLCFGR : aliased PLLCFGR_Register; -- clock configuration register CFGR : aliased CFGR_Register; -- clock interrupt register CIR : aliased CIR_Register; -- AHB1 peripheral reset register AHB1RSTR : aliased AHB1RSTR_Register; -- AHB2 peripheral reset register AHB2RSTR : aliased AHB2RSTR_Register; -- AHB3 peripheral reset register AHB3RSTR : aliased AHB3RSTR_Register; -- APB1 peripheral reset register APB1RSTR : aliased APB1RSTR_Register; -- APB2 peripheral reset register APB2RSTR : aliased APB2RSTR_Register; -- AHB1 peripheral clock register AHB1ENR : aliased AHB1ENR_Register; -- AHB2 peripheral clock enable register AHB2ENR : aliased AHB2ENR_Register; -- AHB3 peripheral clock enable register AHB3ENR : aliased AHB3ENR_Register; -- APB1 peripheral clock enable register APB1ENR : aliased APB1ENR_Register; -- APB2 peripheral clock enable register APB2ENR : aliased APB2ENR_Register; -- AHB1 peripheral clock enable in low power mode register AHB1LPENR : aliased AHB1LPENR_Register; -- AHB2 peripheral clock enable in low power mode register AHB2LPENR : aliased AHB2LPENR_Register; -- AHB3 peripheral clock enable in low power mode register AHB3LPENR : aliased AHB3LPENR_Register; -- APB1 peripheral clock enable in low power mode register APB1LPENR : aliased APB1LPENR_Register; -- APB2 peripheral clock enabled in low power mode register APB2LPENR : aliased APB2LPENR_Register; -- Backup domain control register BDCR : aliased BDCR_Register; -- clock control & status register CSR : aliased CSR_Register; -- spread spectrum clock generation register SSCGR : aliased SSCGR_Register; -- PLLI2S configuration register PLLI2SCFGR : aliased PLLI2SCFGR_Register; end record with Volatile; for RCC_Peripheral use record CR at 16#0# range 0 .. 31; PLLCFGR at 16#4# range 0 .. 31; CFGR at 16#8# range 0 .. 31; CIR at 16#C# range 0 .. 31; AHB1RSTR at 16#10# range 0 .. 31; AHB2RSTR at 16#14# range 0 .. 31; AHB3RSTR at 16#18# range 0 .. 31; APB1RSTR at 16#20# range 0 .. 31; APB2RSTR at 16#24# range 0 .. 31; AHB1ENR at 16#30# range 0 .. 31; AHB2ENR at 16#34# range 0 .. 31; AHB3ENR at 16#38# range 0 .. 31; APB1ENR at 16#40# range 0 .. 31; APB2ENR at 16#44# range 0 .. 31; AHB1LPENR at 16#50# range 0 .. 31; AHB2LPENR at 16#54# range 0 .. 31; AHB3LPENR at 16#58# range 0 .. 31; APB1LPENR at 16#60# range 0 .. 31; APB2LPENR at 16#64# range 0 .. 31; BDCR at 16#70# range 0 .. 31; CSR at 16#74# range 0 .. 31; SSCGR at 16#80# range 0 .. 31; PLLI2SCFGR at 16#84# range 0 .. 31; end record; -- Reset and clock control RCC_Periph : aliased RCC_Peripheral with Import, Address => System'To_Address (16#40023800#); end STM32_SVD.RCC;
36.33853
79
0.556632
a05a53c91ce10051035770e62b9fcc318d0fe983
2,603
adb
Ada
out/cambriolage.adb
Melyodas/metalang
399a9f1a71402c979d7f8024d4f98f081c80e771
[ "BSD-2-Clause" ]
22
2017-04-24T10:00:45.000Z
2021-04-01T10:11:05.000Z
out/cambriolage.adb
Melyodas/metalang
399a9f1a71402c979d7f8024d4f98f081c80e771
[ "BSD-2-Clause" ]
12
2017-03-26T18:34:21.000Z
2019-03-21T19:13:03.000Z
out/cambriolage.adb
Melyodas/metalang
399a9f1a71402c979d7f8024d4f98f081c80e771
[ "BSD-2-Clause" ]
7
2017-10-14T13:33:33.000Z
2021-03-18T15:18:50.000Z
with ada.text_io, ada.Integer_text_IO, Ada.Text_IO.Text_Streams, Ada.Strings.Fixed, Interfaces.C; use ada.text_io, ada.Integer_text_IO, Ada.Strings, Ada.Strings.Fixed, Interfaces.C; procedure cambriolage is type stringptr is access all char_array; procedure PInt(i : in Integer) is begin String'Write (Text_Streams.Stream (Current_Output), Trim(Integer'Image(i), Left)); end; procedure SkipSpaces is C : Character; Eol : Boolean; begin loop Look_Ahead(C, Eol); exit when Eol or C /= ' '; Get(C); end loop; end; function max2_0(a : in Integer; b : in Integer) return Integer is begin if a > b then return a; else return b; end if; end; type c is Array (Integer range <>) of Integer; type c_PTR is access c; type d is Array (Integer range <>) of c_PTR; type d_PTR is access d; function nbPassePartout(n : in Integer; passepartout : in d_PTR; m : in Integer; serrures : in d_PTR) return Integer is pp : c_PTR; max_recent_pp : Integer; max_recent : Integer; max_ancient_pp : Integer; max_ancient : Integer; begin max_ancient := 0; max_recent := 0; for i in integer range 0..m - 1 loop if serrures(i)(0) = (-1) and then serrures(i)(1) > max_ancient then max_ancient := serrures(i)(1); end if; if serrures(i)(0) = 1 and then serrures(i)(1) > max_recent then max_recent := serrures(i)(1); end if; end loop; max_ancient_pp := 0; max_recent_pp := 0; for i in integer range 0..n - 1 loop pp := passepartout(i); if pp(0) >= max_ancient and then pp(1) >= max_recent then return 1; end if; max_ancient_pp := max2_0(max_ancient_pp, pp(0)); max_recent_pp := max2_0(max_recent_pp, pp(1)); end loop; if max_ancient_pp >= max_ancient and then max_recent_pp >= max_recent then return 2; else return 0; end if; end; serrures : d_PTR; passepartout : d_PTR; out_0 : Integer; out1 : c_PTR; out01 : Integer; out0 : c_PTR; n : Integer; m : Integer; begin Get(n); SkipSpaces; passepartout := new d (0..n - 1); for i in integer range 0..n - 1 loop out0 := new c (0..1); for j in integer range 0..1 loop Get(out01); SkipSpaces; out0(j) := out01; end loop; passepartout(i) := out0; end loop; Get(m); SkipSpaces; serrures := new d (0..m - 1); for k in integer range 0..m - 1 loop out1 := new c (0..1); for l in integer range 0..1 loop Get(out_0); SkipSpaces; out1(l) := out_0; end loop; serrures(k) := out1; end loop; PInt(nbPassePartout(n, passepartout, m, serrures)); end;
23.663636
119
0.641952
9a59996558713e5150a4a5de847e7f7d7f71dbdd
18,531
adb
Ada
src/gnat/stylesw.adb
Letractively/ada-gen
d06d03821057f9177f2350e32dd09e467df08612
[ "Apache-2.0" ]
null
null
null
src/gnat/stylesw.adb
Letractively/ada-gen
d06d03821057f9177f2350e32dd09e467df08612
[ "Apache-2.0" ]
null
null
null
src/gnat/stylesw.adb
Letractively/ada-gen
d06d03821057f9177f2350e32dd09e467df08612
[ "Apache-2.0" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- S T Y L E S W -- -- -- -- B o d y -- -- -- -- Copyright (C) 1992-2010, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT 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 distributed with GNAT; see file COPYING3. If not, go to -- -- http://www.gnu.org/licenses for a complete copy of the license. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with Hostparm; use Hostparm; with Opt; use Opt; package body Stylesw is -- The following constant defines the default style options for -gnaty Default_Style : constant String := "3" & -- indentation level is 3 "a" & -- check attribute casing "A" & -- check array attribute indexes "b" & -- check no blanks at end of lines "c" & -- check comment formats "e" & -- check end/exit labels present "f" & -- check no form/feeds vertical tabs in source "h" & -- check no horizontal tabs in source "i" & -- check if-then layout "k" & -- check casing rules for keywords "l" & -- check reference manual layout "m" & -- check line length <= 79 characters "n" & -- check casing of package Standard idents "p" & -- check pragma casing "r" & -- check casing for identifier references "s" & -- check separate subprogram specs present "t"; -- check token separation rules -- The following constant defines the GNAT style options, showing them -- as additions to the standard default style check options. GNAT_Style : constant String := Default_Style & "d" & -- check no DOS line terminators "I" & -- check mode IN "S" & -- check separate lines after THEN or ELSE "u" & -- check no unnecessary blank lines "x"; -- check extra parentheses around conditionals -- Note: we intend GNAT_Style to also include the following, but we do -- not yet have the whole tool suite clean with respect to this. -- "B" & -- check boolean operators ------------------------------- -- Reset_Style_Check_Options -- ------------------------------- procedure Reset_Style_Check_Options is begin Style_Check_Indentation := 0; Style_Check_Array_Attribute_Index := False; Style_Check_Attribute_Casing := False; Style_Check_Blanks_At_End := False; Style_Check_Blank_Lines := False; Style_Check_Boolean_And_Or := False; Style_Check_Comments := False; Style_Check_DOS_Line_Terminator := False; Style_Check_End_Labels := False; Style_Check_Form_Feeds := False; Style_Check_Horizontal_Tabs := False; Style_Check_If_Then_Layout := False; Style_Check_Keyword_Casing := False; Style_Check_Layout := False; Style_Check_Max_Line_Length := False; Style_Check_Max_Nesting_Level := False; Style_Check_Missing_Overriding := False; Style_Check_Mode_In := False; Style_Check_Order_Subprograms := False; Style_Check_Pragma_Casing := False; Style_Check_References := False; Style_Check_Separate_Stmt_Lines := False; Style_Check_Specs := False; Style_Check_Standard := False; Style_Check_Tokens := False; Style_Check_Xtra_Parens := False; end Reset_Style_Check_Options; --------------------- -- RM_Column_Check -- --------------------- function RM_Column_Check return Boolean is begin return Style_Check and Style_Check_Layout; end RM_Column_Check; ------------------------------ -- Save_Style_Check_Options -- ------------------------------ procedure Save_Style_Check_Options (Options : out Style_Check_Options) is P : Natural := 0; procedure Add (C : Character; S : Boolean); -- Add given character C to string if switch S is true procedure Add_Nat (N : Nat); -- Add given natural number to string --------- -- Add -- --------- procedure Add (C : Character; S : Boolean) is begin if S then P := P + 1; Options (P) := C; end if; end Add; ------------- -- Add_Nat -- ------------- procedure Add_Nat (N : Nat) is begin if N > 9 then Add_Nat (N / 10); end if; P := P + 1; Options (P) := Character'Val (Character'Pos ('0') + N mod 10); end Add_Nat; -- Start of processing for Save_Style_Check_Options begin for K in Options'Range loop Options (K) := ' '; end loop; Add (Character'Val (Style_Check_Indentation + Character'Pos ('0')), Style_Check_Indentation /= 0); Add ('a', Style_Check_Attribute_Casing); Add ('A', Style_Check_Array_Attribute_Index); Add ('b', Style_Check_Blanks_At_End); Add ('B', Style_Check_Boolean_And_Or); Add ('c', Style_Check_Comments); Add ('d', Style_Check_DOS_Line_Terminator); Add ('e', Style_Check_End_Labels); Add ('f', Style_Check_Form_Feeds); Add ('h', Style_Check_Horizontal_Tabs); Add ('i', Style_Check_If_Then_Layout); Add ('I', Style_Check_Mode_In); Add ('k', Style_Check_Keyword_Casing); Add ('l', Style_Check_Layout); Add ('n', Style_Check_Standard); Add ('o', Style_Check_Order_Subprograms); Add ('O', Style_Check_Missing_Overriding); Add ('p', Style_Check_Pragma_Casing); Add ('r', Style_Check_References); Add ('s', Style_Check_Specs); Add ('S', Style_Check_Separate_Stmt_Lines); Add ('t', Style_Check_Tokens); Add ('u', Style_Check_Blank_Lines); Add ('x', Style_Check_Xtra_Parens); if Style_Check_Max_Line_Length then P := P + 1; Options (P) := 'M'; Add_Nat (Style_Max_Line_Length); end if; if Style_Check_Max_Nesting_Level then P := P + 1; Options (P) := 'L'; Add_Nat (Style_Max_Nesting_Level); end if; pragma Assert (P <= Options'Last); while P < Options'Last loop P := P + 1; Options (P) := ' '; end loop; end Save_Style_Check_Options; ------------------------------------- -- Set_Default_Style_Check_Options -- ------------------------------------- procedure Set_Default_Style_Check_Options is begin Reset_Style_Check_Options; Set_Style_Check_Options (Default_Style); end Set_Default_Style_Check_Options; ---------------------------------- -- Set_GNAT_Style_Check_Options -- ---------------------------------- procedure Set_GNAT_Style_Check_Options is begin Reset_Style_Check_Options; Set_Style_Check_Options (GNAT_Style); end Set_GNAT_Style_Check_Options; ----------------------------- -- Set_Style_Check_Options -- ----------------------------- -- Version used when no error checking is required procedure Set_Style_Check_Options (Options : String) is OK : Boolean; EC : Natural; pragma Warnings (Off, EC); begin Set_Style_Check_Options (Options, OK, EC); pragma Assert (OK); end Set_Style_Check_Options; -- Normal version with error checking procedure Set_Style_Check_Options (Options : String; OK : out Boolean; Err_Col : out Natural) is C : Character; On : Boolean := True; -- Set to False if minus encountered -- Set to True if plus encountered Last_Option : Character := ' '; -- Set to last character encountered procedure Add_Img (N : Natural); -- Concatenates image of N at end of Style_Msg_Buf procedure Bad_Style_Switch (Msg : String); -- Called if bad style switch found. Msg is set in Style_Msg_Buf and -- Style_Msg_Len. OK is set False. ------------- -- Add_Img -- ------------- procedure Add_Img (N : Natural) is begin if N >= 10 then Add_Img (N / 10); end if; Style_Msg_Len := Style_Msg_Len + 1; Style_Msg_Buf (Style_Msg_Len) := Character'Val (N mod 10 + Character'Pos ('0')); end Add_Img; ---------------------- -- Bad_Style_Switch -- ---------------------- procedure Bad_Style_Switch (Msg : String) is begin OK := False; Style_Msg_Len := Msg'Length; Style_Msg_Buf (1 .. Style_Msg_Len) := Msg; end Bad_Style_Switch; -- Start of processing for Set_Style_Check_Options begin Err_Col := Options'First; while Err_Col <= Options'Last loop C := Options (Err_Col); Last_Option := C; Err_Col := Err_Col + 1; -- Turning switches on if On then case C is when '+' => null; when '-' => On := False; when '0' .. '9' => Style_Check_Indentation := Character'Pos (C) - Character'Pos ('0'); when 'a' => Style_Check_Attribute_Casing := True; when 'A' => Style_Check_Array_Attribute_Index := True; when 'b' => Style_Check_Blanks_At_End := True; when 'B' => Style_Check_Boolean_And_Or := True; when 'c' => Style_Check_Comments := True; when 'd' => Style_Check_DOS_Line_Terminator := True; when 'e' => Style_Check_End_Labels := True; when 'f' => Style_Check_Form_Feeds := True; when 'g' => Set_GNAT_Style_Check_Options; when 'h' => Style_Check_Horizontal_Tabs := True; when 'i' => Style_Check_If_Then_Layout := True; when 'I' => Style_Check_Mode_In := True; when 'k' => Style_Check_Keyword_Casing := True; when 'l' => Style_Check_Layout := True; when 'L' => Style_Max_Nesting_Level := 0; if Err_Col > Options'Last or else Options (Err_Col) not in '0' .. '9' then Bad_Style_Switch ("invalid nesting level"); return; end if; loop Style_Max_Nesting_Level := Style_Max_Nesting_Level * 10 + Character'Pos (Options (Err_Col)) - Character'Pos ('0'); if Style_Max_Nesting_Level > 999 then Bad_Style_Switch ("max nesting level (999) exceeded in style check"); return; end if; Err_Col := Err_Col + 1; exit when Err_Col > Options'Last or else Options (Err_Col) not in '0' .. '9'; end loop; Style_Check_Max_Nesting_Level := Style_Max_Nesting_Level /= 0; when 'm' => Style_Check_Max_Line_Length := True; Style_Max_Line_Length := 79; when 'M' => Style_Max_Line_Length := 0; if Err_Col > Options'Last or else Options (Err_Col) not in '0' .. '9' then Bad_Style_Switch ("invalid line length in style check"); return; end if; loop Style_Max_Line_Length := Style_Max_Line_Length * 10 + Character'Pos (Options (Err_Col)) - Character'Pos ('0'); if Style_Max_Line_Length > Int (Max_Line_Length) then OK := False; Style_Msg_Buf (1 .. 27) := "max line length allowed is "; Style_Msg_Len := 27; Add_Img (Natural (Max_Line_Length)); return; end if; Err_Col := Err_Col + 1; exit when Err_Col > Options'Last or else Options (Err_Col) not in '0' .. '9'; end loop; Style_Check_Max_Line_Length := Style_Max_Line_Length /= 0; when 'n' => Style_Check_Standard := True; when 'N' => Reset_Style_Check_Options; when 'o' => Style_Check_Order_Subprograms := True; when 'O' => Style_Check_Missing_Overriding := True; when 'p' => Style_Check_Pragma_Casing := True; when 'r' => Style_Check_References := True; when 's' => Style_Check_Specs := True; when 'S' => Style_Check_Separate_Stmt_Lines := True; when 't' => Style_Check_Tokens := True; when 'u' => Style_Check_Blank_Lines := True; when 'x' => Style_Check_Xtra_Parens := True; when 'y' => Set_Default_Style_Check_Options; when ' ' => null; when others => Err_Col := Err_Col - 1; Bad_Style_Switch ("invalid style switch: " & C); return; end case; -- Turning switches off else case C is when '+' => On := True; when '-' => null; when '0' .. '9' => Style_Check_Indentation := 0; when 'a' => Style_Check_Attribute_Casing := False; when 'A' => Style_Check_Array_Attribute_Index := False; when 'b' => Style_Check_Blanks_At_End := False; when 'B' => Style_Check_Boolean_And_Or := False; when 'c' => Style_Check_Comments := False; when 'd' => Style_Check_DOS_Line_Terminator := False; when 'e' => Style_Check_End_Labels := False; when 'f' => Style_Check_Form_Feeds := False; when 'g' => Reset_Style_Check_Options; when 'h' => Style_Check_Horizontal_Tabs := False; when 'i' => Style_Check_If_Then_Layout := False; when 'I' => Style_Check_Mode_In := False; when 'k' => Style_Check_Keyword_Casing := False; when 'l' => Style_Check_Layout := False; when 'L' => Style_Max_Nesting_Level := 0; when 'm' => Style_Check_Max_Line_Length := False; when 'M' => Style_Max_Line_Length := 0; Style_Check_Max_Line_Length := False; when 'n' => Style_Check_Standard := False; when 'o' => Style_Check_Order_Subprograms := False; when 'p' => Style_Check_Pragma_Casing := False; when 'r' => Style_Check_References := False; when 's' => Style_Check_Specs := False; when 'S' => Style_Check_Separate_Stmt_Lines := False; when 't' => Style_Check_Tokens := False; when 'u' => Style_Check_Blank_Lines := False; when 'x' => Style_Check_Xtra_Parens := False; when ' ' => null; when others => Err_Col := Err_Col - 1; Bad_Style_Switch ("invalid style switch: " & C); return; end case; end if; end loop; -- Turn on style checking if other than N at end of string Style_Check := (Last_Option /= 'N'); OK := True; end Set_Style_Check_Options; end Stylesw;
32.45359
79
0.472559
4b81b0a5907fd486d05dd8951c7f4ee11aba9426
3,401
ads
Ada
firehog/ncurses/Ada95/samples/status.ads
KipodAfterFree/KAF-2019-FireHog
5f6ee3c3c3329459bc9daeabc1a16ff4619508d9
[ "MIT" ]
null
null
null
firehog/ncurses/Ada95/samples/status.ads
KipodAfterFree/KAF-2019-FireHog
5f6ee3c3c3329459bc9daeabc1a16ff4619508d9
[ "MIT" ]
null
null
null
firehog/ncurses/Ada95/samples/status.ads
KipodAfterFree/KAF-2019-FireHog
5f6ee3c3c3329459bc9daeabc1a16ff4619508d9
[ "MIT" ]
1
2019-12-26T10:18:16.000Z
2019-12-26T10:18:16.000Z
------------------------------------------------------------------------------ -- -- -- GNAT ncurses Binding Samples -- -- -- -- Status -- -- -- -- S P E C -- -- -- ------------------------------------------------------------------------------ -- Copyright (c) 1998 Free Software Foundation, Inc. -- -- -- -- Permission is hereby granted, free of charge, to any person obtaining a -- -- copy of this software and associated documentation files (the -- -- "Software"), to deal in the Software without restriction, including -- -- without limitation the rights to use, copy, modify, merge, publish, -- -- distribute, distribute with modifications, sublicense, and/or sell -- -- copies of the Software, and to permit persons to whom the Software is -- -- furnished to do so, subject to the following conditions: -- -- -- -- The above copyright notice and this permission notice shall be included -- -- in all copies or substantial portions of the Software. -- -- -- -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- -- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- -- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- -- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- -- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- -- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- -- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- -- -- -- Except as contained in this notice, the name(s) of the above copyright -- -- holders shall not be used in advertising or otherwise to promote the -- -- sale, use or other dealings in this Software without prior written -- -- authorization. -- ------------------------------------------------------------------------------ -- Author: Juergen Pfeifer <[email protected]> 1996 -- Version Control -- $Revision: 1.3 $ -- Binding Version 00.93 ------------------------------------------------------------------------------ -- This package has been contributed by Laurent Pautet <[email protected]> -- -- -- with Ada.Interrupts.Names; package Status is protected Process is procedure Stop; function Continue return Boolean; pragma Attach_Handler (Stop, Ada.Interrupts.Names.SIGINT); private Done : Boolean := False; end Process; end Status;
60.732143
78
0.422523
1eeefa58da7ef0c6293376ae2f0b4f545c77d9a7
3,855
ads
Ada
tools/scitools/conf/understand/ada/ada12/a-ticoio.ads
brucegua/moocos
575c161cfa35e220f10d042e2e5ca18773691695
[ "Apache-2.0" ]
1
2020-01-20T21:26:46.000Z
2020-01-20T21:26:46.000Z
tools/scitools/conf/understand/ada/ada12/a-ticoio.ads
brucegua/moocos
575c161cfa35e220f10d042e2e5ca18773691695
[ "Apache-2.0" ]
null
null
null
tools/scitools/conf/understand/ada/ada12/a-ticoio.ads
brucegua/moocos
575c161cfa35e220f10d042e2e5ca18773691695
[ "Apache-2.0" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- A D A . T E X T _ I O . C O M P L E X _ I O -- -- -- -- S p e c -- -- -- -- Copyright (C) 1992-2009, Free Software Foundation, Inc. -- -- -- -- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. The copyright notice above, and the license provisions that follow -- -- apply solely to the contents of the part following the private keyword. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- -- -- -- -- -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with Ada.Numerics.Generic_Complex_Types; generic with package Complex_Types is new Ada.Numerics.Generic_Complex_Types (<>); package Ada.Text_IO.Complex_IO is Default_Fore : Field := 2; Default_Aft : Field := Complex_Types.Real'Digits - 1; Default_Exp : Field := 3; procedure Get (File : File_Type; Item : out Complex_Types.Complex; Width : Field := 0); procedure Get (Item : out Complex_Types.Complex; Width : Field := 0); procedure Put (File : File_Type; Item : Complex_Types.Complex; Fore : Field := Default_Fore; Aft : Field := Default_Aft; Exp : Field := Default_Exp); procedure Put (Item : Complex_Types.Complex; Fore : Field := Default_Fore; Aft : Field := Default_Aft; Exp : Field := Default_Exp); procedure Get (From : String; Item : out Complex_Types.Complex; Last : out Positive); procedure Put (To : out String; Item : Complex_Types.Complex; Aft : Field := Default_Aft; Exp : Field := Default_Exp); private pragma Inline (Get); pragma Inline (Put); end Ada.Text_IO.Complex_IO;
45.352941
78
0.419715
5908614eb1a00fc2c642175a576fe05c1e06e95e
2,575
adb
Ada
support/MinGW/lib/gcc/mingw32/9.2.0/adainclude/a-shcain.adb
orb-zhuchen/Orb
6da2404b949ac28bde786e08bf4debe4a27cd3a0
[ "CNRI-Python-GPL-Compatible", "MIT" ]
null
null
null
support/MinGW/lib/gcc/mingw32/9.2.0/adainclude/a-shcain.adb
orb-zhuchen/Orb
6da2404b949ac28bde786e08bf4debe4a27cd3a0
[ "CNRI-Python-GPL-Compatible", "MIT" ]
null
null
null
support/MinGW/lib/gcc/mingw32/9.2.0/adainclude/a-shcain.adb
orb-zhuchen/Orb
6da2404b949ac28bde786e08bf4debe4a27cd3a0
[ "CNRI-Python-GPL-Compatible", "MIT" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- GNAT LIBRARY COMPONENTS -- -- -- -- A D A . S T R I N G S . H A S H _ C A S E _ I N S E N S I T I V E -- -- -- -- B o d y -- -- -- -- Copyright (C) 2004-2019, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- This unit was originally developed by Matthew J Heaney. -- ------------------------------------------------------------------------------ with Ada.Characters.Handling; use Ada.Characters.Handling; with System.String_Hash; function Ada.Strings.Hash_Case_Insensitive (Key : String) return Containers.Hash_Type is use Ada.Containers; function Hash is new System.String_Hash.Hash (Character, String, Hash_Type); begin return Hash (To_Lower (Key)); end Ada.Strings.Hash_Case_Insensitive;
61.309524
78
0.425243
9a9a8a123bbecd0754e5bfe93511213699bc6159
3,611
ads
Ada
source/amf/uml/amf-uml-initial_nodes-hash.ads
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
24
2016-11-29T06:59:41.000Z
2021-08-30T11:55:16.000Z
source/amf/uml/amf-uml-initial_nodes-hash.ads
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
2
2019-01-16T05:15:20.000Z
2019-02-03T10:03:32.000Z
source/amf/uml/amf-uml-initial_nodes-hash.ads
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
4
2017-07-18T07:11:05.000Z
2020-06-21T03:02:25.000Z
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Ada Modeling Framework -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2011-2012, Vadim Godunko <[email protected]> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ -- This file is generated, don't edit it. ------------------------------------------------------------------------------ with AMF.Elements.Generic_Hash; function AMF.UML.Initial_Nodes.Hash is new AMF.Elements.Generic_Hash (UML_Initial_Node, UML_Initial_Node_Access);
72.22
78
0.402382
062c39bbf8763a7f73e47bf9341ba9745729f6cc
964
adb
Ada
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/allocator_maxalign1.adb
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/allocator_maxalign1.adb
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/allocator_maxalign1.adb
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
-- { dg-do run } with System.Storage_Elements; use System.Storage_Elements; with Ada.Unchecked_Deallocation; procedure Allocator_Maxalign1 is Max_Alignment : constant := Standard'Maximum_Alignment; type Block is record X : Integer; end record; for Block'Alignment use Standard'Maximum_Alignment; type Block_Access is access all Block; procedure Free is new Ada.Unchecked_Deallocation (Block, Block_Access); N_Blocks : constant := 500; Blocks : array (1 .. N_Blocks) of Block_Access; begin if Block'Alignment /= Max_Alignment then raise Program_Error; end if; for K in 1 .. 4 loop for I in Blocks'Range loop Blocks (I) := new Block; if Blocks (I).all'Address mod Block'Alignment /= 0 then raise Program_Error; end if; Blocks(I).all.X := I; end loop; for I in Blocks'Range loop Free (Blocks (I)); end loop; end loop; end;
22.418605
74
0.651452
1e1bd628f271e5cc280ff45a15632c16a10946a8
100
ads
Ada
tests/game-test_data-tests-attributes_container.ads
thindil/steamsky
d5d7fea622f7994c91017c4cd7ba5e188153556c
[ "TCL", "MIT" ]
80
2017-04-08T23:14:07.000Z
2022-02-10T22:30:51.000Z
tests/game-test_data-tests-attributes_container.ads
thindil/steamsky
d5d7fea622f7994c91017c4cd7ba5e188153556c
[ "TCL", "MIT" ]
89
2017-06-24T08:18:26.000Z
2021-11-12T04:37:36.000Z
tests/game-test_data-tests-attributes_container.ads
thindil/steamsky
d5d7fea622f7994c91017c4cd7ba5e188153556c
[ "TCL", "MIT" ]
9
2018-04-14T16:37:25.000Z
2020-03-21T14:33:49.000Z
package Game.Test_Data.Tests.Attributes_Container is end Game.Test_Data.Tests.Attributes_Container;
33.333333
52
0.88
22798b5347623b884be57008614c5dc51feacd0b
4,152
ada
Ada
gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/ce/ce3705e.ada
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/ce/ce3705e.ada
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/testsuite/ada/acats/tests/ce/ce3705e.ada
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
-- CE3705E.ADA -- Grant of Unlimited Rights -- -- Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687, -- F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained -- unlimited rights in the software and documentation contained herein. -- Unlimited rights are defined in DFAR 252.227-7013(a)(19). By making -- this public release, the Government intends to confer upon all -- recipients unlimited rights equal to those held by the Government. -- These rights include rights to use, duplicate, release or disclose the -- released technical data and computer software in whole or in part, in -- any manner and for any purpose whatsoever, and to have or permit others -- to do so. -- -- DISCLAIMER -- -- ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR -- DISCLOSED ARE AS IS. THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED -- WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE -- SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE -- OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A -- PARTICULAR PURPOSE OF SAID MATERIAL. --* -- OBJECTIVE: -- CHECK THAT DATA_ERROR, NOT END_ERROR, IS RAISED WHEN FEWER THAN -- WIDTH CHARACTERS REMAIN IN THE FILE, AND THE REMAINING CHARACTERS -- SATISFY THE SYNTAX FOR A REAL LITERAL. -- APPLICABILITY CRITERIA: -- THIS TEST IS ONLY APPLICABLE TO IMPLEMENTATIONS WHICH SUPPORT -- TEXT FILES. -- HISTORY: -- JLH 07/20/88 CREATED ORIGINAL TEST. WITH REPORT; USE REPORT; WITH TEXT_IO; USE TEXT_IO; PROCEDURE CE3705E IS PACKAGE IIO IS NEW INTEGER_IO (INTEGER); USE IIO; FILE : FILE_TYPE; ITEM : INTEGER; INCOMPLETE : EXCEPTION; BEGIN TEST ("CE3705E", "CHECK THAT DATA_ERROR, NOT END_ERROR, IS " & "RAISED WHEN FEWER THAN WIDTH CHARACTERS " & "REMAIN IN THE FILE, AND THE REMAINING " & "CHARACTERS SATISFY THE SYNTAX FOR A REAL " & "LITERAL"); BEGIN BEGIN CREATE (FILE, OUT_FILE, LEGAL_FILE_NAME); EXCEPTION WHEN USE_ERROR => NOT_APPLICABLE ("USE_ERROR RAISED ON CREATE " & "WITH MODE OUT_FILE"); RAISE INCOMPLETE; WHEN NAME_ERROR => NOT_APPLICABLE ("NAME_ERROR RAISED ON CREATE " & "WITH MODE OUT_FILE"); RAISE INCOMPLETE; WHEN OTHERS => FAILED ("UNEXPECTED EXCEPTION RAISED ON CREATE"); RAISE INCOMPLETE; END; PUT (FILE, "16#FFF#"); NEW_LINE (FILE); PUT (FILE, "3.14159_26"); CLOSE (FILE); BEGIN OPEN (FILE, IN_FILE, LEGAL_FILE_NAME); EXCEPTION WHEN USE_ERROR => NOT_APPLICABLE ("USE_ERROR RAISED ON OPEN " & "WITH MODE IN_FILE"); RAISE INCOMPLETE; WHEN OTHERS => FAILED ("UNEXPECTED EXCEPTION RAISED ON OPEN"); RAISE INCOMPLETE; END; GET (FILE, ITEM); IF ITEM /= 4095 THEN FAILED ("INCORRECT VALUE READ"); END IF; BEGIN GET (FILE, ITEM, WIDTH => 11); FAILED ("DATA_ERROR NOT RAISED"); EXCEPTION WHEN END_ERROR => FAILED ("END_ERROR INSTEAD OF DATA_ERROR RAISED"); WHEN DATA_ERROR => NULL; WHEN OTHERS => FAILED ("UNEXPECTED EXCEPTION RAISED ON GET"); END; BEGIN DELETE (FILE); EXCEPTION WHEN USE_ERROR => NULL; END; EXCEPTION WHEN INCOMPLETE => NULL; END; RESULT; END CE3705E;
33.216
79
0.542148
590bc060f7f6f6392f0758452f03328af21d8cf8
2,542
adb
Ada
src/common/trendy_terminal-completions.adb
pyjarrett/archaic_terminal
ce1e5331a66ed9aa7ae0dc6c41ffa4851919a1f8
[ "Apache-2.0" ]
3
2021-11-03T18:27:41.000Z
2022-03-01T18:15:34.000Z
src/common/trendy_terminal-completions.adb
pyjarrett/archaic_terminal
ce1e5331a66ed9aa7ae0dc6c41ffa4851919a1f8
[ "Apache-2.0" ]
2
2021-09-05T13:35:39.000Z
2021-09-11T21:27:38.000Z
src/common/trendy_terminal-completions.adb
pyjarrett/trendy_terminal
ce1e5331a66ed9aa7ae0dc6c41ffa4851919a1f8
[ "Apache-2.0" ]
null
null
null
------------------------------------------------------------------------------- -- Copyright 2021, The Trendy Terminal Developers (see AUTHORS file) -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- http://www.apache.org/licenses/LICENSE-2.0 -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ------------------------------------------------------------------------------- with Ada.Containers; package body Trendy_Terminal.Completions is procedure Clear (Self : in out Completion_Set) is begin Self.Lines.Clear; Self.Index := 1; end Clear; function Is_Empty (Self : Completion_Set) return Boolean is use type Ada.Containers.Count_Type; begin return Self.Lines.Length = 0; end Is_Empty; procedure Fill (Self : in out Completion_Set; Lines : Trendy_Terminal.Lines.Line_Vectors.Vector) is use type Ada.Containers.Count_Type; begin Self.Lines := Lines; Self.Index := 1; end Fill; procedure Set_Index (Self : in out Completion_Set; Index : Integer) is begin Self.Index := Index; if Self.Index <= 0 then Self.Index := Length (Self); else Self.Index := Self.Index mod Length (Self); if Self.Index = 0 then Self.Index := Length (Self); end if; end if; end Set_Index; procedure Move_Forward (Self : in out Completion_Set) is begin Set_Index (Self, Self.Index + 1); end Move_Forward; procedure Move_Backward (Self : in out Completion_Set) is begin Set_Index (Self, Self.Index - 1); end Move_Backward; function Get_Current (Self : in out Completion_Set) return String is begin return Trendy_Terminal.Lines.Current (Self.Lines (Self.Index)); end Get_Current; function Get_Index (Self : in out Completion_Set) return Integer is begin return Self.Index; end Get_Index; function Length (Self : Completion_Set) return Integer is begin return Integer (Self.Lines.Length); end Length; end Trendy_Terminal.Completions;
31
79
0.620771
a05259f75dec031de9748363b907c9ae3bdb9a70
6,374
adb
Ada
boards/crazyflie/src/stm32-board.adb
morbos/Ada_Drivers_Library
a4ab26799be60997c38735f4056160c4af597ef7
[ "BSD-3-Clause" ]
2
2018-05-16T03:56:39.000Z
2019-07-31T13:53:56.000Z
boards/crazyflie/src/stm32-board.adb
morbos/Ada_Drivers_Library
a4ab26799be60997c38735f4056160c4af597ef7
[ "BSD-3-Clause" ]
null
null
null
boards/crazyflie/src/stm32-board.adb
morbos/Ada_Drivers_Library
a4ab26799be60997c38735f4056160c4af597ef7
[ "BSD-3-Clause" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- Copyright (C) 2015, AdaCore -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions are -- -- met: -- -- 1. Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- 2. Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in -- -- the documentation and/or other materials provided with the -- -- distribution. -- -- 3. Neither the name of STMicroelectronics nor the names of its -- -- contributors may be used to endorse or promote products derived -- -- from this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -- -- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -- -- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -- -- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -- -- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -- -- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- -- -- -- This file is based on: -- -- -- -- @file stm32f4_discovery.c -- -- @author MCD Application Team -- -- @version V1.1.0 -- -- @date 19-June-2014 -- -- @brief This file provides set of firmware functions to manage Leds -- -- and push-button available on STM32F42-Discovery Kit from -- -- STMicroelectronics. -- -- -- -- COPYRIGHT(c) 2014 STMicroelectronics -- ------------------------------------------------------------------------------ package body STM32.Board is ------------- -- Turn_On -- ------------- procedure Turn_On (This : in out User_LED) is begin if This = LED_Blue_L then Set (This); else Clear (This); end if; end Turn_On; -------------- -- Turn_Off -- -------------- procedure Turn_Off (This : in out User_LED) is begin if This = LED_Blue_L then Clear (This); else Set (This); end if; end Turn_Off; ----------- -- Is_On -- ----------- function Is_On (This : User_LED) return Boolean is begin if This = LED_Blue_L then return Set (This); else return not Set (This); end if; end Is_On; ------------------ -- All_LEDs_Off -- ------------------ procedure All_LEDs_Off is begin Set (RG_LEDs); Clear (LED_Blue_L); end All_LEDs_Off; ----------------- -- All_LEDs_On -- ----------------- procedure All_LEDs_On is begin Clear (RG_LEDs); Set (LED_Blue_L); end All_LEDs_On; --------------------- -- Initialize_LEDs -- --------------------- procedure Initialize_LEDs is Configuration : GPIO_Port_Configuration; begin Enable_Clock (All_LEDs); Configuration.Mode := Mode_Out; Configuration.Output_Type := Push_Pull; Configuration.Speed := Speed_100MHz; Configuration.Resistors := Floating; Configure_IO (All_LEDs, Config => Configuration); All_LEDs_Off; end Initialize_LEDs; ------------------------- -- Initialize_I2C_GPIO -- ------------------------- procedure Initialize_I2C_GPIO (Port : in out I2C_Port) is Id : constant I2C_Port_Id := As_Port_Id (Port); Points : constant GPIO_Points (1 .. 2) := (if Id = I2C_Id_1 then (PB6, PB7) else (PA8, PC9)); begin if Id = I2C_Id_2 then raise Unknown_Device with "This I2C_Port cannot be used on this board"; end if; Enable_Clock (Points); Enable_Clock (Port); Reset (Port); Configure_Alternate_Function (Points, GPIO_AF_I2C2_4); Configure_IO (Points, (Speed => Speed_25MHz, Mode => Mode_AF, Output_Type => Open_Drain, Resistors => Floating)); Lock (Points); end Initialize_I2C_GPIO; ------------------- -- TP_I2C_Config -- ------------------- procedure Configure_I2C (Port : in out I2C_Port) is begin if not STM32.I2C.Port_Enabled (Port) then Configure (This => Port, Conf => (Clock_Speed => 400_000, Mode => I2C_Mode, Duty_Cycle => DutyCycle_16_9, Addressing_Mode => Addressing_Mode_7bit, Own_Address => 0, others => <>)); end if; end Configure_I2C; end STM32.Board;
36.011299
78
0.459366
04d553b4b4b5ce2bb97f6600878e2a5f4416154f
3,434
ads
Ada
awa/src/awa-events-dispatchers-actions.ads
Letractively/ada-awa
3c82a4d29ed6c1209a2ac7d5fe123c142f3cffbe
[ "Apache-2.0" ]
null
null
null
awa/src/awa-events-dispatchers-actions.ads
Letractively/ada-awa
3c82a4d29ed6c1209a2ac7d5fe123c142f3cffbe
[ "Apache-2.0" ]
null
null
null
awa/src/awa-events-dispatchers-actions.ads
Letractively/ada-awa
3c82a4d29ed6c1209a2ac7d5fe123c142f3cffbe
[ "Apache-2.0" ]
null
null
null
----------------------------------------------------------------------- -- awa-events-dispatchers-actions -- Event dispatcher to Ada bean actions -- Copyright (C) 2012 Stephane Carrez -- Written by Stephane Carrez ([email protected]) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Ada.Containers.Doubly_Linked_Lists; with EL.Expressions; with EL.Beans; with AWA.Events.Queues; with AWA.Applications; -- The <b>AWA.Events.Dispatchers.Actions</b> package implements an event dispatcher -- which calls a set of Ada bean action methods that have been registered on the dispatcher -- during configuration time. package AWA.Events.Dispatchers.Actions is -- ------------------------------ -- Event action dispatcher -- ------------------------------ type Action_Dispatcher (Application : AWA.Applications.Application_Access) is new Dispatcher with private; -- Dispatch the event identified by <b>Event</b>. -- The event actions which are associated with the event are executed synchronously. procedure Dispatch (Manager : in Action_Dispatcher; Event : in Module_Event'Class); -- Add an action invoked when an event is dispatched through this dispatcher. -- When the event queue dispatches the event, the Ada bean identified by the method action -- represented by <b>Action</b> is created and initialized by evaluating and setting the -- parameters defined in <b>Params</b>. The action method is then invoked. procedure Add_Action (Manager : in out Action_Dispatcher; Action : in EL.Expressions.Method_Expression; Params : in EL.Beans.Param_Vectors.Vector); -- Create a new dispatcher associated with the application. function Create_Dispatcher (Application : in AWA.Applications.Application_Access) return Dispatcher_Access; private -- An event action records a method expression which identifies an Ada bean and a method -- that must be invoked when the event is dispatched. The Ada bean instance is populated -- by evaluating and setting the set of properties before calling the action method. type Event_Action is record Action : EL.Expressions.Method_Expression; Properties : EL.Beans.Param_Vectors.Vector; end record; -- A list of event actions. package Event_Action_Lists is new Ada.Containers.Doubly_Linked_Lists (Element_Type => Event_Action); -- The dispatcher maintains a list of event actions to which the events are dispatched. type Action_Dispatcher (Application : AWA.Applications.Application_Access) is new Dispatcher with record Actions : Event_Action_Lists.List; Queue : AWA.Events.Queues.Queue_Ref; end record; end AWA.Events.Dispatchers.Actions;
44.025641
94
0.679383
1ab14f0a8526dd9f99e8162a41a07cf5abc80c67
916
ads
Ada
gdb/testsuite/gdb.ada/aliased_array/pck.ads
greyblue9/binutils-gdb
05377632b124fe7600eea7f4ee0e9a35d1b0cbdc
[ "BSD-3-Clause" ]
1
2020-10-14T03:24:35.000Z
2020-10-14T03:24:35.000Z
gdb/testsuite/gdb.ada/aliased_array/pck.ads
greyblue9/binutils-gdb
05377632b124fe7600eea7f4ee0e9a35d1b0cbdc
[ "BSD-3-Clause" ]
null
null
null
gdb/testsuite/gdb.ada/aliased_array/pck.ads
greyblue9/binutils-gdb
05377632b124fe7600eea7f4ee0e9a35d1b0cbdc
[ "BSD-3-Clause" ]
null
null
null
-- Copyright 2012-2021 Free Software Foundation, Inc. -- -- 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 3 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, see <http://www.gnu.org/licenses/>. with System; package Pck is type Bounded is array (Integer range <>) of Integer; function New_Bounded (Low, High : Integer) return Bounded; procedure Do_Nothing (A : System.Address); end Pck;
41.636364
73
0.735808
1a192d2d60ab2d0ff80146c6cf994f0488d67316
6,593
ads
Ada
source/nodes/program-nodes-extended_return_statements.ads
optikos/oasis
9f64d46d26d964790d69f9db681c874cfb3bf96d
[ "MIT" ]
null
null
null
source/nodes/program-nodes-extended_return_statements.ads
optikos/oasis
9f64d46d26d964790d69f9db681c874cfb3bf96d
[ "MIT" ]
null
null
null
source/nodes/program-nodes-extended_return_statements.ads
optikos/oasis
9f64d46d26d964790d69f9db681c874cfb3bf96d
[ "MIT" ]
2
2019-09-14T23:18:50.000Z
2019-10-02T10:11:40.000Z
-- Copyright (c) 2019 Maxim Reznik <[email protected]> -- -- SPDX-License-Identifier: MIT -- License-Filename: LICENSE ------------------------------------------------------------- with Program.Lexical_Elements; with Program.Elements.Return_Object_Specifications; with Program.Element_Vectors; with Program.Elements.Exception_Handlers; with Program.Elements.Extended_Return_Statements; with Program.Element_Visitors; package Program.Nodes.Extended_Return_Statements is pragma Preelaborate; type Extended_Return_Statement is new Program.Nodes.Node and Program.Elements.Extended_Return_Statements .Extended_Return_Statement and Program.Elements.Extended_Return_Statements .Extended_Return_Statement_Text with private; function Create (Return_Token : not null Program.Lexical_Elements .Lexical_Element_Access; Return_Object : not null Program.Elements .Return_Object_Specifications.Return_Object_Specification_Access; Do_Token : Program.Lexical_Elements.Lexical_Element_Access; Statements : Program.Element_Vectors.Element_Vector_Access; Exception_Token : Program.Lexical_Elements.Lexical_Element_Access; Exception_Handlers : Program.Elements.Exception_Handlers .Exception_Handler_Vector_Access; End_Token : Program.Lexical_Elements.Lexical_Element_Access; Return_Token_2 : Program.Lexical_Elements.Lexical_Element_Access; Semicolon_Token : not null Program.Lexical_Elements .Lexical_Element_Access) return Extended_Return_Statement; type Implicit_Extended_Return_Statement is new Program.Nodes.Node and Program.Elements.Extended_Return_Statements .Extended_Return_Statement with private; function Create (Return_Object : not null Program.Elements .Return_Object_Specifications.Return_Object_Specification_Access; Statements : Program.Element_Vectors.Element_Vector_Access; Exception_Handlers : Program.Elements.Exception_Handlers .Exception_Handler_Vector_Access; Is_Part_Of_Implicit : Boolean := False; Is_Part_Of_Inherited : Boolean := False; Is_Part_Of_Instance : Boolean := False) return Implicit_Extended_Return_Statement with Pre => Is_Part_Of_Implicit or Is_Part_Of_Inherited or Is_Part_Of_Instance; private type Base_Extended_Return_Statement is abstract new Program.Nodes.Node and Program.Elements.Extended_Return_Statements .Extended_Return_Statement with record Return_Object : not null Program.Elements .Return_Object_Specifications.Return_Object_Specification_Access; Statements : Program.Element_Vectors.Element_Vector_Access; Exception_Handlers : Program.Elements.Exception_Handlers .Exception_Handler_Vector_Access; end record; procedure Initialize (Self : aliased in out Base_Extended_Return_Statement'Class); overriding procedure Visit (Self : not null access Base_Extended_Return_Statement; Visitor : in out Program.Element_Visitors.Element_Visitor'Class); overriding function Return_Object (Self : Base_Extended_Return_Statement) return not null Program.Elements.Return_Object_Specifications .Return_Object_Specification_Access; overriding function Statements (Self : Base_Extended_Return_Statement) return Program.Element_Vectors.Element_Vector_Access; overriding function Exception_Handlers (Self : Base_Extended_Return_Statement) return Program.Elements.Exception_Handlers .Exception_Handler_Vector_Access; overriding function Is_Extended_Return_Statement_Element (Self : Base_Extended_Return_Statement) return Boolean; overriding function Is_Statement_Element (Self : Base_Extended_Return_Statement) return Boolean; type Extended_Return_Statement is new Base_Extended_Return_Statement and Program.Elements.Extended_Return_Statements .Extended_Return_Statement_Text with record Return_Token : not null Program.Lexical_Elements .Lexical_Element_Access; Do_Token : Program.Lexical_Elements.Lexical_Element_Access; Exception_Token : Program.Lexical_Elements.Lexical_Element_Access; End_Token : Program.Lexical_Elements.Lexical_Element_Access; Return_Token_2 : Program.Lexical_Elements.Lexical_Element_Access; Semicolon_Token : not null Program.Lexical_Elements .Lexical_Element_Access; end record; overriding function To_Extended_Return_Statement_Text (Self : aliased in out Extended_Return_Statement) return Program.Elements.Extended_Return_Statements .Extended_Return_Statement_Text_Access; overriding function Return_Token (Self : Extended_Return_Statement) return not null Program.Lexical_Elements.Lexical_Element_Access; overriding function Do_Token (Self : Extended_Return_Statement) return Program.Lexical_Elements.Lexical_Element_Access; overriding function Exception_Token (Self : Extended_Return_Statement) return Program.Lexical_Elements.Lexical_Element_Access; overriding function End_Token (Self : Extended_Return_Statement) return Program.Lexical_Elements.Lexical_Element_Access; overriding function Return_Token_2 (Self : Extended_Return_Statement) return Program.Lexical_Elements.Lexical_Element_Access; overriding function Semicolon_Token (Self : Extended_Return_Statement) return not null Program.Lexical_Elements.Lexical_Element_Access; type Implicit_Extended_Return_Statement is new Base_Extended_Return_Statement with record Is_Part_Of_Implicit : Boolean; Is_Part_Of_Inherited : Boolean; Is_Part_Of_Instance : Boolean; end record; overriding function To_Extended_Return_Statement_Text (Self : aliased in out Implicit_Extended_Return_Statement) return Program.Elements.Extended_Return_Statements .Extended_Return_Statement_Text_Access; overriding function Is_Part_Of_Implicit (Self : Implicit_Extended_Return_Statement) return Boolean; overriding function Is_Part_Of_Inherited (Self : Implicit_Extended_Return_Statement) return Boolean; overriding function Is_Part_Of_Instance (Self : Implicit_Extended_Return_Statement) return Boolean; end Program.Nodes.Extended_Return_Statements;
38.109827
75
0.757167
3828cc13b2bc8d0521e7db5a8aa3492d1d184cfb
2,821
adb
Ada
gcc-gcc-7_3_0-release/gcc/ada/s-assert.adb
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/ada/s-assert.adb
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/ada/s-assert.adb
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- S Y S T E M . A S S E R T I O N S -- -- -- -- B o d y -- -- -- -- Copyright (C) 1992-2014, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ pragma Compiler_Unit_Warning; with Ada.Exceptions; with System.Exceptions_Debug; package body System.Assertions is -------------------------- -- Raise_Assert_Failure -- -------------------------- procedure Raise_Assert_Failure (Msg : String) is begin System.Exceptions_Debug.Debug_Raise_Assert_Failure; Ada.Exceptions.Raise_Exception (Assert_Failure'Identity, Msg); end Raise_Assert_Failure; end System.Assertions;
56.42
78
0.416164
1a2940f0e0379e9eaa168cc97bc16ead6c049896
30,728
adb
Ada
regtests/server/src/server/testapi-skeletons.adb
jquorning/swagger-ada
9df95a920643b37f22a8fb2450786df00099dc9a
[ "Apache-2.0" ]
17
2017-09-09T15:52:14.000Z
2022-01-23T01:18:06.000Z
regtests/server/src/server/testapi-skeletons.adb
jquorning/swagger-ada
9df95a920643b37f22a8fb2450786df00099dc9a
[ "Apache-2.0" ]
13
2020-10-04T16:04:42.000Z
2022-03-25T19:33:03.000Z
regtests/server/src/server/testapi-skeletons.adb
jquorning/swagger-ada
9df95a920643b37f22a8fb2450786df00099dc9a
[ "Apache-2.0" ]
4
2021-01-06T08:43:55.000Z
2022-03-11T21:45:06.000Z
-- REST API Validation -- API to validate -- -- The version of the OpenAPI document: 1.0.0 -- Contact: [email protected] -- -- NOTE: This package is auto generated by OpenAPI-Generator 5.2.1-SNAPSHOT. -- https://openapi-generator.tech -- Do not edit the class manually. pragma Warnings (Off, "*is not referenced"); with Swagger.Streams; with Swagger.Servers.Operation; package body TestAPI.Skeletons is pragma Style_Checks ("-mr"); pragma Warnings (Off, "*use clause for package*"); use Swagger.Streams; package body Skeleton is package API_Orch_Store is new Swagger.Servers.Operation (Handler => Orch_Store, Method => Swagger.Servers.POST, URI => URI_Prefix & "/orchestration"); -- procedure Orch_Store (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Input : Swagger.Value_Type; Impl : Implementation_Type; Inline_Object_3Type : InlineObject3_Type; begin Swagger.Servers.Read (Req, Input); TestAPI.Models.Deserialize (Input, "InlineObject3_Type", Inline_Object_3Type); Impl.Orch_Store (Inline_Object_3Type, Context); end Orch_Store; package API_Do_Create_Ticket is new Swagger.Servers.Operation (Handler => Do_Create_Ticket, Method => Swagger.Servers.POST, URI => URI_Prefix & "/tickets"); -- Create a ticket procedure Do_Create_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Impl : Implementation_Type; Title : Swagger.UString; Owner : Swagger.Nullable_UString; Status : Swagger.Nullable_UString; Description : Swagger.Nullable_UString; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Write_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Parameter (Context, "owner", Owner); Swagger.Servers.Get_Parameter (Context, "status", Status); Swagger.Servers.Get_Parameter (Context, "title", Title); Swagger.Servers.Get_Parameter (Context, "description", Description); Impl.Do_Create_Ticket (Title, Owner, Status, Description, Context); end Do_Create_Ticket; package API_Do_Delete_Ticket is new Swagger.Servers.Operation (Handler => Do_Delete_Ticket, Method => Swagger.Servers.DELETE, URI => URI_Prefix & "/tickets/{tid}"); -- Delete a ticket procedure Do_Delete_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Impl : Implementation_Type; Tid : Swagger.Long; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Write_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Path_Parameter (Req, 1, Tid); Impl.Do_Delete_Ticket (Tid, Context); end Do_Delete_Ticket; package API_Do_Head_Ticket is new Swagger.Servers.Operation (Handler => Do_Head_Ticket, Method => Swagger.Servers.HEAD, URI => URI_Prefix & "/tickets"); -- List the tickets procedure Do_Head_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Impl : Implementation_Type; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Read_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Impl.Do_Head_Ticket (Context); end Do_Head_Ticket; package API_Do_Patch_Ticket is new Swagger.Servers.Operation (Handler => Do_Patch_Ticket, Method => Swagger.Servers.PATCH, URI => URI_Prefix & "/tickets/{tid}"); -- Patch a ticket procedure Do_Patch_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Impl : Implementation_Type; Tid : Swagger.Long; Owner : Swagger.Nullable_UString; Status : Swagger.Nullable_UString; Title : Swagger.Nullable_UString; Description : Swagger.Nullable_UString; Result : TestAPI.Models.Ticket_Type; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Write_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Path_Parameter (Req, 1, Tid); Swagger.Servers.Get_Parameter (Context, "owner", Owner); Swagger.Servers.Get_Parameter (Context, "status", Status); Swagger.Servers.Get_Parameter (Context, "title", Title); Swagger.Servers.Get_Parameter (Context, "description", Description); Impl.Do_Patch_Ticket (Tid, Owner, Status, Title, Description, Result, Context); if Context.Get_Status = 200 then Stream.Start_Document; TestAPI.Models.Serialize (Stream, "", Result); Stream.End_Document; end if; end Do_Patch_Ticket; package API_Do_Update_Ticket is new Swagger.Servers.Operation (Handler => Do_Update_Ticket, Method => Swagger.Servers.PUT, URI => URI_Prefix & "/tickets/{tid}"); -- Update a ticket procedure Do_Update_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Impl : Implementation_Type; Tid : Swagger.Long; Owner : Swagger.Nullable_UString; Status : Swagger.Nullable_UString; Title : Swagger.Nullable_UString; Description : Swagger.Nullable_UString; Result : TestAPI.Models.Ticket_Type; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Write_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Path_Parameter (Req, 1, Tid); Swagger.Servers.Get_Parameter (Context, "owner", Owner); Swagger.Servers.Get_Parameter (Context, "status", Status); Swagger.Servers.Get_Parameter (Context, "title", Title); Swagger.Servers.Get_Parameter (Context, "description", Description); Impl.Do_Update_Ticket (Tid, Owner, Status, Title, Description, Result, Context); if Context.Get_Status = 200 then Stream.Start_Document; TestAPI.Models.Serialize (Stream, "", Result); Stream.End_Document; end if; end Do_Update_Ticket; package API_Do_Get_Ticket is new Swagger.Servers.Operation (Handler => Do_Get_Ticket, Method => Swagger.Servers.GET, URI => URI_Prefix & "/tickets/{tid}"); -- Get a ticket procedure Do_Get_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Impl : Implementation_Type; Tid : Swagger.Long; Result : TestAPI.Models.Ticket_Type; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Read_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Path_Parameter (Req, 1, Tid); Impl.Do_Get_Ticket (Tid, Result, Context); if Context.Get_Status = 200 then Stream.Start_Document; TestAPI.Models.Serialize (Stream, "", Result); Stream.End_Document; end if; end Do_Get_Ticket; package API_Do_List_Tickets is new Swagger.Servers.Operation (Handler => Do_List_Tickets, Method => Swagger.Servers.GET, URI => URI_Prefix & "/tickets"); -- List the tickets procedure Do_List_Tickets (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Impl : Implementation_Type; Status : Swagger.Nullable_UString; Owner : Swagger.Nullable_UString; Result : TestAPI.Models.Ticket_Type_Vectors.Vector; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Read_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Query_Parameter (Req, "status", Status); Swagger.Servers.Get_Query_Parameter (Req, "owner", Owner); Impl.Do_List_Tickets (Status, Owner, Result, Context); if Context.Get_Status = 200 then Stream.Start_Document; TestAPI.Models.Serialize (Stream, "", Result); Stream.End_Document; end if; end Do_List_Tickets; package API_Do_Options_Ticket is new Swagger.Servers.Operation (Handler => Do_Options_Ticket, Method => Swagger.Servers.OPTIONS, URI => URI_Prefix & "/tickets/{tid}"); -- Get a ticket procedure Do_Options_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Impl : Implementation_Type; Tid : Swagger.Long; Result : TestAPI.Models.Ticket_Type; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Read_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Path_Parameter (Req, 1, Tid); Impl.Do_Options_Ticket (Tid, Result, Context); if Context.Get_Status = 200 then Stream.Start_Document; TestAPI.Models.Serialize (Stream, "", Result); Stream.End_Document; end if; end Do_Options_Ticket; procedure Register (Server : in out Swagger.Servers.Application_Type'Class) is begin Swagger.Servers.Register (Server, API_Orch_Store.Definition); Swagger.Servers.Register (Server, API_Do_Create_Ticket.Definition); Swagger.Servers.Register (Server, API_Do_Delete_Ticket.Definition); Swagger.Servers.Register (Server, API_Do_Head_Ticket.Definition); Swagger.Servers.Register (Server, API_Do_Patch_Ticket.Definition); Swagger.Servers.Register (Server, API_Do_Update_Ticket.Definition); Swagger.Servers.Register (Server, API_Do_Get_Ticket.Definition); Swagger.Servers.Register (Server, API_Do_List_Tickets.Definition); Swagger.Servers.Register (Server, API_Do_Options_Ticket.Definition); end Register; end Skeleton; package body Shared_Instance is -- procedure Orch_Store (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Input : Swagger.Value_Type; Inline_Object_3Type : InlineObject3_Type; begin Swagger.Servers.Read (Req, Input); TestAPI.Models.Deserialize (Input, "InlineObject3_Type", Inline_Object_3Type); Server.Orch_Store (Inline_Object_3Type, Context); end Orch_Store; package API_Orch_Store is new Swagger.Servers.Operation (Handler => Orch_Store, Method => Swagger.Servers.POST, URI => URI_Prefix & "/orchestration"); -- Create a ticket procedure Do_Create_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Title : Swagger.UString; Owner : Swagger.Nullable_UString; Status : Swagger.Nullable_UString; Description : Swagger.Nullable_UString; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Write_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Parameter (Context, "owner", Owner); Swagger.Servers.Get_Parameter (Context, "status", Status); Swagger.Servers.Get_Parameter (Context, "title", Title); Swagger.Servers.Get_Parameter (Context, "description", Description); Server.Do_Create_Ticket (Title, Owner, Status, Description, Context); end Do_Create_Ticket; package API_Do_Create_Ticket is new Swagger.Servers.Operation (Handler => Do_Create_Ticket, Method => Swagger.Servers.POST, URI => URI_Prefix & "/tickets"); -- Delete a ticket procedure Do_Delete_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Tid : Swagger.Long; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Write_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Path_Parameter (Req, 1, Tid); Server.Do_Delete_Ticket (Tid, Context); end Do_Delete_Ticket; package API_Do_Delete_Ticket is new Swagger.Servers.Operation (Handler => Do_Delete_Ticket, Method => Swagger.Servers.DELETE, URI => URI_Prefix & "/tickets/{tid}"); -- List the tickets procedure Do_Head_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Read_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Server.Do_Head_Ticket (Context); end Do_Head_Ticket; package API_Do_Head_Ticket is new Swagger.Servers.Operation (Handler => Do_Head_Ticket, Method => Swagger.Servers.HEAD, URI => URI_Prefix & "/tickets"); -- Patch a ticket procedure Do_Patch_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Tid : Swagger.Long; Owner : Swagger.Nullable_UString; Status : Swagger.Nullable_UString; Title : Swagger.Nullable_UString; Description : Swagger.Nullable_UString; Result : TestAPI.Models.Ticket_Type; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Write_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Path_Parameter (Req, 1, Tid); Swagger.Servers.Get_Parameter (Context, "owner", Owner); Swagger.Servers.Get_Parameter (Context, "status", Status); Swagger.Servers.Get_Parameter (Context, "title", Title); Swagger.Servers.Get_Parameter (Context, "description", Description); Server.Do_Patch_Ticket (Tid, Owner, Status, Title, Description, Result, Context); if Context.Get_Status = 200 then Stream.Start_Document; TestAPI.Models.Serialize (Stream, "", Result); Stream.End_Document; end if; end Do_Patch_Ticket; package API_Do_Patch_Ticket is new Swagger.Servers.Operation (Handler => Do_Patch_Ticket, Method => Swagger.Servers.PATCH, URI => URI_Prefix & "/tickets/{tid}"); -- Update a ticket procedure Do_Update_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Tid : Swagger.Long; Owner : Swagger.Nullable_UString; Status : Swagger.Nullable_UString; Title : Swagger.Nullable_UString; Description : Swagger.Nullable_UString; Result : TestAPI.Models.Ticket_Type; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Write_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Path_Parameter (Req, 1, Tid); Swagger.Servers.Get_Parameter (Context, "owner", Owner); Swagger.Servers.Get_Parameter (Context, "status", Status); Swagger.Servers.Get_Parameter (Context, "title", Title); Swagger.Servers.Get_Parameter (Context, "description", Description); Server.Do_Update_Ticket (Tid, Owner, Status, Title, Description, Result, Context); if Context.Get_Status = 200 then Stream.Start_Document; TestAPI.Models.Serialize (Stream, "", Result); Stream.End_Document; end if; end Do_Update_Ticket; package API_Do_Update_Ticket is new Swagger.Servers.Operation (Handler => Do_Update_Ticket, Method => Swagger.Servers.PUT, URI => URI_Prefix & "/tickets/{tid}"); -- Get a ticket procedure Do_Get_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Tid : Swagger.Long; Result : TestAPI.Models.Ticket_Type; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Read_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Path_Parameter (Req, 1, Tid); Server.Do_Get_Ticket (Tid, Result, Context); if Context.Get_Status = 200 then Stream.Start_Document; TestAPI.Models.Serialize (Stream, "", Result); Stream.End_Document; end if; end Do_Get_Ticket; package API_Do_Get_Ticket is new Swagger.Servers.Operation (Handler => Do_Get_Ticket, Method => Swagger.Servers.GET, URI => URI_Prefix & "/tickets/{tid}"); -- List the tickets procedure Do_List_Tickets (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Status : Swagger.Nullable_UString; Owner : Swagger.Nullable_UString; Result : TestAPI.Models.Ticket_Type_Vectors.Vector; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Read_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Query_Parameter (Req, "status", Status); Swagger.Servers.Get_Query_Parameter (Req, "owner", Owner); Server.Do_List_Tickets (Status, Owner, Result, Context); if Context.Get_Status = 200 then Stream.Start_Document; TestAPI.Models.Serialize (Stream, "", Result); Stream.End_Document; end if; end Do_List_Tickets; package API_Do_List_Tickets is new Swagger.Servers.Operation (Handler => Do_List_Tickets, Method => Swagger.Servers.GET, URI => URI_Prefix & "/tickets"); -- Get a ticket procedure Do_Options_Ticket (Req : in out Swagger.Servers.Request'Class; Reply : in out Swagger.Servers.Response'Class; Stream : in out Swagger.Servers.Output_Stream'Class; Context : in out Swagger.Servers.Context_Type) is Tid : Swagger.Long; Result : TestAPI.Models.Ticket_Type; begin if not Context.Is_Authenticated then Context.Set_Error (401, "Not authenticated"); return; end if; if not Context.Has_Permission (ACL_Read_Ticket.Permission) then Context.Set_Error (403, "Permission denied"); return; end if; Swagger.Servers.Get_Path_Parameter (Req, 1, Tid); Server.Do_Options_Ticket (Tid, Result, Context); if Context.Get_Status = 200 then Stream.Start_Document; TestAPI.Models.Serialize (Stream, "", Result); Stream.End_Document; end if; end Do_Options_Ticket; package API_Do_Options_Ticket is new Swagger.Servers.Operation (Handler => Do_Options_Ticket, Method => Swagger.Servers.OPTIONS, URI => URI_Prefix & "/tickets/{tid}"); procedure Register (Server : in out Swagger.Servers.Application_Type'Class) is begin Swagger.Servers.Register (Server, API_Orch_Store.Definition); Swagger.Servers.Register (Server, API_Do_Create_Ticket.Definition); Swagger.Servers.Register (Server, API_Do_Delete_Ticket.Definition); Swagger.Servers.Register (Server, API_Do_Head_Ticket.Definition); Swagger.Servers.Register (Server, API_Do_Patch_Ticket.Definition); Swagger.Servers.Register (Server, API_Do_Update_Ticket.Definition); Swagger.Servers.Register (Server, API_Do_Get_Ticket.Definition); Swagger.Servers.Register (Server, API_Do_List_Tickets.Definition); Swagger.Servers.Register (Server, API_Do_Options_Ticket.Definition); end Register; protected body Server is -- procedure Orch_Store (Inline_Object_3Type : in InlineObject3_Type; Context : in out Swagger.Servers.Context_Type) is begin Impl.Orch_Store (Inline_Object_3Type, Context); end Orch_Store; -- Create a ticket procedure Do_Create_Ticket (Title : in Swagger.UString; Owner : in Swagger.Nullable_UString; Status : in Swagger.Nullable_UString; Description : in Swagger.Nullable_UString; Context : in out Swagger.Servers.Context_Type) is begin Impl.Do_Create_Ticket (Title, Owner, Status, Description, Context); end Do_Create_Ticket; -- Delete a ticket procedure Do_Delete_Ticket (Tid : in Swagger.Long; Context : in out Swagger.Servers.Context_Type) is begin Impl.Do_Delete_Ticket (Tid, Context); end Do_Delete_Ticket; -- List the tickets procedure Do_Head_Ticket (Context : in out Swagger.Servers.Context_Type) is begin Impl.Do_Head_Ticket (Context); end Do_Head_Ticket; -- Patch a ticket procedure Do_Patch_Ticket (Tid : in Swagger.Long; Owner : in Swagger.Nullable_UString; Status : in Swagger.Nullable_UString; Title : in Swagger.Nullable_UString; Description : in Swagger.Nullable_UString; Result : out TestAPI.Models.Ticket_Type; Context : in out Swagger.Servers.Context_Type) is begin Impl.Do_Patch_Ticket (Tid, Owner, Status, Title, Description, Result, Context); end Do_Patch_Ticket; -- Update a ticket procedure Do_Update_Ticket (Tid : in Swagger.Long; Owner : in Swagger.Nullable_UString; Status : in Swagger.Nullable_UString; Title : in Swagger.Nullable_UString; Description : in Swagger.Nullable_UString; Result : out TestAPI.Models.Ticket_Type; Context : in out Swagger.Servers.Context_Type) is begin Impl.Do_Update_Ticket (Tid, Owner, Status, Title, Description, Result, Context); end Do_Update_Ticket; -- Get a ticket procedure Do_Get_Ticket (Tid : in Swagger.Long; Result : out TestAPI.Models.Ticket_Type; Context : in out Swagger.Servers.Context_Type) is begin Impl.Do_Get_Ticket (Tid, Result, Context); end Do_Get_Ticket; -- List the tickets procedure Do_List_Tickets (Status : in Swagger.Nullable_UString; Owner : in Swagger.Nullable_UString; Result : out TestAPI.Models.Ticket_Type_Vectors.Vector; Context : in out Swagger.Servers.Context_Type) is begin Impl.Do_List_Tickets (Status, Owner, Result, Context); end Do_List_Tickets; -- Get a ticket procedure Do_Options_Ticket (Tid : in Swagger.Long; Result : out TestAPI.Models.Ticket_Type; Context : in out Swagger.Servers.Context_Type) is begin Impl.Do_Options_Ticket (Tid, Result, Context); end Do_Options_Ticket; end Server; end Shared_Instance; end TestAPI.Skeletons;
39.34443
87
0.581945
4b416062881c3152dd13567a3aa028afaa3bd1c1
7,307
adb
Ada
source/containers/a-colili.adb
ytomino/drake
4e4bdcd8b8e23a11a29b31d3a8861fdf60090ea2
[ "MIT" ]
33
2015-04-04T09:19:36.000Z
2021-11-10T05:33:34.000Z
source/containers/a-colili.adb
ytomino/drake
4e4bdcd8b8e23a11a29b31d3a8861fdf60090ea2
[ "MIT" ]
8
2017-11-14T13:05:07.000Z
2018-08-09T15:28:49.000Z
source/containers/a-colili.adb
ytomino/drake
4e4bdcd8b8e23a11a29b31d3a8861fdf60090ea2
[ "MIT" ]
9
2015-02-03T17:09:53.000Z
2021-11-12T01:16:05.000Z
package body Ada.Containers.Linked_Lists is procedure Reverse_Iterate ( Last : Node_Access; Process : not null access procedure (Position : not null Node_Access)) is Position : Node_Access := Last; begin while Position /= null loop Process (Position); Position := Previous (Position); end loop; end Reverse_Iterate; function Reverse_Find ( Last : Node_Access; Params : System.Address; Equivalent : not null access function ( Right : not null Node_Access; Params : System.Address) return Boolean) return Node_Access is I : Node_Access := Last; begin while I /= null loop if Equivalent (I, Params) then return I; end if; I := Previous (I); end loop; return null; end Reverse_Find; function Equivalent ( Left_Last, Right_Last : Node_Access; Equivalent : not null access function ( Left, Right : not null Node_Access) return Boolean) return Boolean is I : Node_Access := Left_Last; J : Node_Access := Right_Last; begin while I /= null and then J /= null loop if not Equivalent (I, J) then return False; end if; I := Previous (I); J := Previous (J); end loop; return I = null and then J = null; end Equivalent; procedure Free ( First : in out Node_Access; Last : in out Node_Access; Length : in out Count_Type; Free : not null access procedure (Object : in out Node_Access)) is Position : Node_Access := Last; begin while Position /= null loop declare Prev : constant Node_Access := Previous (Position); begin Free (Position); Length := Length - 1; Position := Prev; end; end loop; First := null; Last := null; end Free; procedure Copy ( Target_First : out Node_Access; Target_Last : out Node_Access; Length : out Count_Type; Source_Last : Node_Access; Copy : not null access procedure ( Target : out Node_Access; Source : not null Node_Access)) is I : Node_Access := Source_Last; New_Node : Node_Access; begin Target_First := null; Target_Last := null; Length := 0; while I /= null loop Copy (New_Node, I); Insert ( First => Target_First, Last => Target_Last, Length => Length, Before => Target_First, New_Item => New_Node); I := Previous (I); end loop; end Copy; procedure Reverse_Elements ( Target_First : in out Node_Access; Target_Last : in out Node_Access; Length : in out Count_Type) is Source_First : Node_Access := Target_First; Source_Last : Node_Access := Target_Last; Source_Length : Count_Type := Length; Position : Node_Access; begin Target_First := null; Target_Last := null; Length := 0; while Source_Last /= null loop Position := Source_Last; Remove (Source_First, Source_Last, Source_Length, Position, null); Insert (Target_First, Target_Last, Length, null, Position); end loop; end Reverse_Elements; function Is_Sorted ( Last : Node_Access; LT : not null access function ( Left, Right : not null Node_Access) return Boolean) return Boolean is I : Node_Access := Last; begin if I = null then return True; else loop declare Prev : constant Node_Access := Previous (I); begin exit when Prev = null; if LT (I, Prev) then return False; end if; I := Prev; end; end loop; return True; end if; end Is_Sorted; procedure Merge ( Target_First : in out Node_Access; Target_Last : in out Node_Access; Length : in out Count_Type; Source_First : in out Node_Access; Source_Last : in out Node_Access; Source_Length : in out Count_Type; LT : not null access function ( Left, Right : not null Node_Access) return Boolean) is Left_First : Node_Access := Target_First; Left_Last : Node_Access := Target_Last; Left_Length : Count_Type := Length; I : Node_Access := Left_Last; J : Node_Access := Source_Last; begin Target_First := null; Target_Last := null; Length := 0; while I /= null and then J /= null loop if LT (J, I) then declare Prev : constant Node_Access := Previous (I); begin Remove (Left_First, Left_Last, Left_Length, I, null); Insert (Target_First, Target_Last, Length, Target_First, I); I := Prev; end; else declare Prev : constant Node_Access := Previous (J); begin Remove (Source_First, Source_Last, Source_Length, J, null); Insert (Target_First, Target_Last, Length, Target_First, J); J := Prev; end; end if; end loop; while I /= null loop declare Prev : constant Node_Access := Previous (I); begin Remove (Left_First, Left_Last, Left_Length, I, null); Insert (Target_First, Target_Last, Length, Target_First, I); I := Prev; end; end loop; while J /= null loop declare Prev : constant Node_Access := Previous (J); begin Remove (Source_First, Source_Last, Source_Length, J, null); Insert (Target_First, Target_Last, Length, Target_First, J); J := Prev; end; end loop; end Merge; procedure Merge_Sort ( Target_First : in out Node_Access; Target_Last : in out Node_Access; Length : in out Count_Type; LT : not null access function ( Left, Right : not null Node_Access) return Boolean) is begin if Length >= 2 then declare Left_First : Node_Access; Left_Last : Node_Access; Left_Length : Count_Type; Right_First : Node_Access := Target_First; Right_Last : Node_Access := Target_Last; Right_Length : Count_Type := Length; begin Split ( Left_First, Left_Last, Left_Length, Right_First, Right_Last, Right_Length, Length / 2); Merge_Sort ( Left_First, Left_Last, Left_Length, LT => LT); Merge_Sort ( Right_First, Right_Last, Right_Length, LT => LT); Merge ( Left_First, Left_Last, Left_Length, Right_First, Right_Last, Right_Length, LT => LT); Target_First := Left_First; Target_Last := Left_Last; Length := Left_Length; end; end if; end Merge_Sort; end Ada.Containers.Linked_Lists;
29.46371
76
0.551252
8b9fad297c933cd984ade657e95a44eb05d5bd2c
6,246
adb
Ada
bb-runtimes/runtimes/ravenscar-full-stm32f3x4/gnat/s-pack05.adb
JCGobbi/Nucleo-STM32F334R8
2a0b1b4b2664c92773703ac5e95dcb71979d051c
[ "BSD-3-Clause" ]
null
null
null
bb-runtimes/runtimes/ravenscar-full-stm32f3x4/gnat/s-pack05.adb
JCGobbi/Nucleo-STM32F334R8
2a0b1b4b2664c92773703ac5e95dcb71979d051c
[ "BSD-3-Clause" ]
null
null
null
bb-runtimes/runtimes/ravenscar-full-stm32f3x4/gnat/s-pack05.adb
JCGobbi/Nucleo-STM32F334R8
2a0b1b4b2664c92773703ac5e95dcb71979d051c
[ "BSD-3-Clause" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- S Y S T E M . P A C K _ 0 5 -- -- -- -- B o d y -- -- -- -- Copyright (C) 1992-2021, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- -- -- -- -- -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with System.Storage_Elements; with System.Unsigned_Types; package body System.Pack_05 is subtype Bit_Order is System.Bit_Order; Reverse_Bit_Order : constant Bit_Order := Bit_Order'Val (1 - Bit_Order'Pos (System.Default_Bit_Order)); subtype Ofs is System.Storage_Elements.Storage_Offset; subtype Uns is System.Unsigned_Types.Unsigned; subtype N07 is System.Unsigned_Types.Unsigned range 0 .. 7; use type System.Storage_Elements.Storage_Offset; use type System.Unsigned_Types.Unsigned; type Cluster is record E0, E1, E2, E3, E4, E5, E6, E7 : Bits_05; end record; for Cluster use record E0 at 0 range 0 * Bits .. 0 * Bits + Bits - 1; E1 at 0 range 1 * Bits .. 1 * Bits + Bits - 1; E2 at 0 range 2 * Bits .. 2 * Bits + Bits - 1; E3 at 0 range 3 * Bits .. 3 * Bits + Bits - 1; E4 at 0 range 4 * Bits .. 4 * Bits + Bits - 1; E5 at 0 range 5 * Bits .. 5 * Bits + Bits - 1; E6 at 0 range 6 * Bits .. 6 * Bits + Bits - 1; E7 at 0 range 7 * Bits .. 7 * Bits + Bits - 1; end record; for Cluster'Size use Bits * 8; for Cluster'Alignment use Integer'Min (Standard'Maximum_Alignment, 1 + 1 * Boolean'Pos (Bits mod 2 = 0) + 2 * Boolean'Pos (Bits mod 4 = 0)); -- Use maximum possible alignment, given the bit field size, since this -- will result in the most efficient code possible for the field. type Cluster_Ref is access Cluster; type Rev_Cluster is new Cluster with Bit_Order => Reverse_Bit_Order, Scalar_Storage_Order => Reverse_Bit_Order; type Rev_Cluster_Ref is access Rev_Cluster; ------------ -- Get_05 -- ------------ function Get_05 (Arr : System.Address; N : Natural; Rev_SSO : Boolean) return Bits_05 is A : constant System.Address := Arr + Bits * Ofs (Uns (N) / 8); C : Cluster_Ref with Address => A'Address, Import; RC : Rev_Cluster_Ref with Address => A'Address, Import; begin if Rev_SSO then case N07 (Uns (N) mod 8) is when 0 => return RC.E0; when 1 => return RC.E1; when 2 => return RC.E2; when 3 => return RC.E3; when 4 => return RC.E4; when 5 => return RC.E5; when 6 => return RC.E6; when 7 => return RC.E7; end case; else case N07 (Uns (N) mod 8) is when 0 => return C.E0; when 1 => return C.E1; when 2 => return C.E2; when 3 => return C.E3; when 4 => return C.E4; when 5 => return C.E5; when 6 => return C.E6; when 7 => return C.E7; end case; end if; end Get_05; ------------ -- Set_05 -- ------------ procedure Set_05 (Arr : System.Address; N : Natural; E : Bits_05; Rev_SSO : Boolean) is A : constant System.Address := Arr + Bits * Ofs (Uns (N) / 8); C : Cluster_Ref with Address => A'Address, Import; RC : Rev_Cluster_Ref with Address => A'Address, Import; begin if Rev_SSO then case N07 (Uns (N) mod 8) is when 0 => RC.E0 := E; when 1 => RC.E1 := E; when 2 => RC.E2 := E; when 3 => RC.E3 := E; when 4 => RC.E4 := E; when 5 => RC.E5 := E; when 6 => RC.E6 := E; when 7 => RC.E7 := E; end case; else case N07 (Uns (N) mod 8) is when 0 => C.E0 := E; when 1 => C.E1 := E; when 2 => C.E2 := E; when 3 => C.E3 := E; when 4 => C.E4 := E; when 5 => C.E5 := E; when 6 => C.E6 := E; when 7 => C.E7 := E; end case; end if; end Set_05; end System.Pack_05;
39.531646
78
0.434198
4b1b30ef7ce3aee9298ec58c4fcdbfdd050866a7
315
adb
Ada
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/case_null.adb
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/case_null.adb
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/case_null.adb
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
-- { dg-do compile } -- { dg-options "-gnatws" } package body Case_Null is procedure P1 (X : T) is begin case X is when S1 => -- { dg-error "not.*static" } null; when e => null; when others => null; end case; end P1; end Case_Null;
18.529412
50
0.469841
8b0be0a22f616b8183bb1229b957fbe98dce418c
7,247
adb
Ada
llvm-gcc-4.2-2.9/gcc/ada/a-taster.adb
vidkidz/crossbridge
ba0bf94aee0ce6cf7eb5be882382e52bc57ba396
[ "MIT" ]
1
2016-04-09T02:58:13.000Z
2016-04-09T02:58:13.000Z
llvm-gcc-4.2-2.9/gcc/ada/a-taster.adb
vidkidz/crossbridge
ba0bf94aee0ce6cf7eb5be882382e52bc57ba396
[ "MIT" ]
null
null
null
llvm-gcc-4.2-2.9/gcc/ada/a-taster.adb
vidkidz/crossbridge
ba0bf94aee0ce6cf7eb5be882382e52bc57ba396
[ "MIT" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- A D A . T A S K _ T E R M I N A T I O N -- -- -- -- B o d y -- -- -- -- Copyright (C) 2005-2006, Free Software Foundation, Inc. -- -- -- -- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. The copyright notice above, and the license provisions that follow -- -- apply solely to the contents of the part following the private keyword. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT 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 distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, -- -- Boston, MA 02110-1301, USA. -- -- -- -- As a special exception, if other files instantiate generics from this -- -- unit, or you link this unit with other files to produce an executable, -- -- this unit does not by itself cause the resulting executable to be -- -- covered by the GNU General Public License. This exception does not -- -- however invalidate any other reasons why the executable file might be -- -- covered by the GNU Public License. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with System.Tasking; -- used for Task_Id with System.Task_Primitives.Operations; -- used for Self -- Write_Lock -- Unlock -- Lock_RTS -- Unlock_RTS with System.Parameters; -- used for Single_Lock with System.Soft_Links; -- use for Abort_Defer -- Abort_Undefer with Unchecked_Conversion; package body Ada.Task_Termination is use type Ada.Task_Identification.Task_Id; package STPO renames System.Task_Primitives.Operations; package SSL renames System.Soft_Links; use System.Parameters; ----------------------- -- Local subprograms -- ----------------------- function To_TT is new Unchecked_Conversion (System.Tasking.Termination_Handler, Termination_Handler); function To_ST is new Unchecked_Conversion (Termination_Handler, System.Tasking.Termination_Handler); function To_Task_Id is new Unchecked_Conversion (Ada.Task_Identification.Task_Id, System.Tasking.Task_Id); ----------------------------------- -- Current_Task_Fallback_Handler -- ----------------------------------- function Current_Task_Fallback_Handler return Termination_Handler is begin -- There is no need for explicit protection against race conditions -- for this function because this function can only be executed by -- Self, and the Fall_Back_Handler can only be modified by Self. return To_TT (STPO.Self.Common.Fall_Back_Handler); end Current_Task_Fallback_Handler; ------------------------------------- -- Set_Dependents_Fallback_Handler -- ------------------------------------- procedure Set_Dependents_Fallback_Handler (Handler : Termination_Handler) is Self : constant System.Tasking.Task_Id := STPO.Self; begin SSL.Abort_Defer.all; if Single_Lock then STPO.Lock_RTS; end if; STPO.Write_Lock (Self); Self.Common.Fall_Back_Handler := To_ST (Handler); STPO.Unlock (Self); if Single_Lock then STPO.Unlock_RTS; end if; SSL.Abort_Undefer.all; end Set_Dependents_Fallback_Handler; -------------------------- -- Set_Specific_Handler -- -------------------------- procedure Set_Specific_Handler (T : Ada.Task_Identification.Task_Id; Handler : Termination_Handler) is begin -- Tasking_Error is raised if the task identified by T has already -- terminated. Program_Error is raised if the value of T is -- Null_Task_Id. if T = Ada.Task_Identification.Null_Task_Id then raise Program_Error; elsif Ada.Task_Identification.Is_Terminated (T) then raise Tasking_Error; else declare Target : constant System.Tasking.Task_Id := To_Task_Id (T); begin SSL.Abort_Defer.all; if Single_Lock then STPO.Lock_RTS; end if; STPO.Write_Lock (Target); Target.Common.Specific_Handler := To_ST (Handler); STPO.Unlock (Target); if Single_Lock then STPO.Unlock_RTS; end if; SSL.Abort_Undefer.all; end; end if; end Set_Specific_Handler; ---------------------- -- Specific_Handler -- ---------------------- function Specific_Handler (T : Ada.Task_Identification.Task_Id) return Termination_Handler is begin -- Tasking_Error is raised if the task identified by T has already -- terminated. Program_Error is raised if the value of T is -- Null_Task_Id. if T = Ada.Task_Identification.Null_Task_Id then raise Program_Error; elsif Ada.Task_Identification.Is_Terminated (T) then raise Tasking_Error; else declare Target : constant System.Tasking.Task_Id := To_Task_Id (T); TH : Termination_Handler; begin SSL.Abort_Defer.all; if Single_Lock then STPO.Lock_RTS; end if; STPO.Write_Lock (Target); TH := To_TT (Target.Common.Specific_Handler); STPO.Unlock (Target); if Single_Lock then STPO.Unlock_RTS; end if; SSL.Abort_Undefer.all; return TH; end; end if; end Specific_Handler; end Ada.Task_Termination;
34.509524
78
0.531254
a0c2665879cae6b6d59788a6f083962b36e931fb
337
adb
Ada
memsim-master/src/parser-parse_stats.adb
strenkml/EE368
00f15bce9e65badddc613355643b1061fd4a8195
[ "MIT" ]
null
null
null
memsim-master/src/parser-parse_stats.adb
strenkml/EE368
00f15bce9e65badddc613355643b1061fd4a8195
[ "MIT" ]
null
null
null
memsim-master/src/parser-parse_stats.adb
strenkml/EE368
00f15bce9e65badddc613355643b1061fd4a8195
[ "MIT" ]
null
null
null
with Memory.Stats; separate (Parser) procedure Parse_Stats(parser : in out Parser_Type; result : out Memory_Pointer) is mem : Memory_Pointer := null; begin if Get_Type(parser) = Open then Parse_Memory(parser, mem); end if; result := Memory_Pointer(Stats.Create_Stats(mem)); end Parse_Stats;
21.0625
54
0.670623
1e0ba3f8a2f5dc48d2fd51fda7e2d9aa4a1a2d54
4,619
adb
Ada
1-base/math/source/generic/pure/geometry/any_math-any_geometry-any_d3-any_modeller.adb
charlie5/lace-alire
9ace9682cf4daac7adb9f980c2868d6225b8111c
[ "0BSD" ]
1
2022-01-20T07:13:42.000Z
2022-01-20T07:13:42.000Z
1-base/math/source/generic/pure/geometry/any_math-any_geometry-any_d3-any_modeller.adb
charlie5/lace-alire
9ace9682cf4daac7adb9f980c2868d6225b8111c
[ "0BSD" ]
null
null
null
1-base/math/source/generic/pure/geometry/any_math-any_geometry-any_d3-any_modeller.adb
charlie5/lace-alire
9ace9682cf4daac7adb9f980c2868d6225b8111c
[ "0BSD" ]
null
null
null
with ada.Strings.Hash; package body any_Math.any_Geometry.any_d3.any_Modeller is use ada.Containers; function Hash (Site : in my_Vertex) return ada.Containers.Hash_type is use ada.Strings; begin return Hash ( Site (1)'Image & Site (2)'Image & Site (3)'Image); end Hash; function demand_Index (Self : in out Item; for_Vertex : in my_Vertex) return Natural -- -- If the vertex exists in the map, return the associated index. -- Otherwise add the new vertex and return it's index. -- is use Vertex_Maps_of_Index; Cursor : constant Vertex_Maps_of_Index.Cursor := Self.Index_Map.find (for_Vertex); begin if has_Element (Cursor) then return Element (Cursor); end if; Self.Vertices.append (Vertex (for_Vertex)); declare new_Index : constant Natural := Natural (Self.Vertices.Length); begin Self.Index_Map.insert (for_Vertex, new_Index); return new_Index; end; end demand_Index; function "<" (Left, Right : in Index_Triangle) return Boolean is begin if Left (1) < Right (1) then return True; end if; if Left (1) > Right (1) then return False; end if; if Left (2) < Right (2) then return True; end if; if Left (2) > Right (2) then return False; end if; if Left (3) < Right (3) then return True; end if; return False; end "<"; procedure add_Triangle (Self : in out Item; Vertex_1, Vertex_2, Vertex_3 : in Site) is vertex_1_Index : constant Natural := demand_Index (Self, my_Vertex (Vertex_1)); vertex_2_Index : constant Natural := demand_Index (Self, my_Vertex (Vertex_2)); vertex_3_Index : constant Natural := demand_Index (Self, my_Vertex (Vertex_3)); new_Triangle : constant index_Triangle := (vertex_1_Index, vertex_2_Index, vertex_3_Index); new_Triangle_rotated_1 : constant index_Triangle := (vertex_3_Index, vertex_1_Index, vertex_2_Index); new_Triangle_rotated_2 : constant index_Triangle := (vertex_2_Index, vertex_3_Index, vertex_1_Index); begin if new_Triangle (1) = new_Triangle (2) or else new_Triangle (1) = new_Triangle (3) or else new_Triangle (2) = new_Triangle (3) then null; -- Discard collapsed triangle. else if Self.Triangles.contains (new_triangle) or else Self.Triangles.contains (new_triangle_rotated_1) or else Self.Triangles.contains (new_triangle_rotated_2) then null; -- Triangle is already present. else Self.Triangles.include (new_Triangle); end if; end if; end add_Triangle; procedure clear (Self : in out Item) is begin Self.Triangles.clear; Self.Vertices .clear; Self.Index_Map.clear; end clear; function Triangle_Count (Self : in Item) return Natural is begin return Natural (Self.Triangles.Length); end triangle_Count; function Model (Self : in Item) return a_Model is Result : a_Model := (Site_Count => Integer (Self.Vertices.Length), Tri_Count => Integer (Self.Triangles.Length), Sites => <>, Triangles => <>); begin for i in 1 .. Index (Result.site_Count) loop Result.Sites (i) := Self.Vertices.Element (i); end loop; declare use Index_Triangle_Sets; Cursor : Index_Triangle_Sets.Cursor := Self.Triangles.First; begin for i in 1 .. Result.Tri_Count loop Result.Triangles (i) := Element (Cursor); next (Cursor); end loop; end; return Result; end Model; function bounding_Sphere_Radius (Self : in out Item) return Real is use Functions; begin if Self.bounding_Sphere_Radius = Real'First then for Each of Self.Vertices loop Self.bounding_sphere_Radius := Real'Max (Self.bounding_sphere_Radius, SqRt ( Each (1) * Each (1) + Each (2) * Each (2) + Each (3) * Each (3))); end loop; end if; return Self.bounding_sphere_Radius; end bounding_sphere_Radius; end any_Math.any_Geometry.any_d3.any_Modeller;
29.050314
107
0.581944
1e90d347a32c379d1ef261dccb004fcdc0861544
4,566
ads
Ada
llvm-gcc-4.2-2.9/gcc/ada/g-busorg.ads
vidkidz/crossbridge
ba0bf94aee0ce6cf7eb5be882382e52bc57ba396
[ "MIT" ]
1
2016-04-09T02:58:13.000Z
2016-04-09T02:58:13.000Z
llvm-gcc-4.2-2.9/gcc/ada/g-busorg.ads
vidkidz/crossbridge
ba0bf94aee0ce6cf7eb5be882382e52bc57ba396
[ "MIT" ]
null
null
null
llvm-gcc-4.2-2.9/gcc/ada/g-busorg.ads
vidkidz/crossbridge
ba0bf94aee0ce6cf7eb5be882382e52bc57ba396
[ "MIT" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- G N A T . B U B B L E _ S O R T _ G -- -- -- -- S p e c -- -- -- -- Copyright (C) 1995-2005, AdaCore -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT 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 distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, -- -- Boston, MA 02110-1301, USA. -- -- -- -- As a special exception, if other files instantiate generics from this -- -- unit, or you link this unit with other files to produce an executable, -- -- this unit does not by itself cause the resulting executable to be -- -- covered by the GNU General Public License. This exception does not -- -- however invalidate any other reasons why the executable file might be -- -- covered by the GNU Public License. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- Bubblesort generic package using formal procedures -- This package provides a generic bubble sort routine that can be used with -- different types of data. -- See also GNAT.Bubble_Sort, a version that works with subprogram access -- parameters, allowing code sharing. The generic version is slightly more -- efficient but does not allow code sharing and has an interface that is -- more awkward to use. The generic version is also Pure, while the access -- subprograqm version can only be Preelaborate. -- There is also GNAT.Bubble_Sort_A, which is now considered obsolete, but -- was an older version working with subprogram parameters. This version -- is retained for baccwards compatibility with old versions of GNAT. generic -- The data to be sorted is assumed to be indexed by integer values from -- 1 to N, where N is the number of items to be sorted. In addition, the -- index value zero is used for a temporary location used during the sort. with procedure Move (From : Natural; To : Natural); -- A procedure that moves the data item with index value From to the data -- item with index value To (the old value in To being lost). An index -- value of zero is used for moves from and to a single temporary location -- used by the sort. with function Lt (Op1, Op2 : Natural) return Boolean; -- A function that compares two items and returns True if the item with -- index Op1 is less than the item with Index Op2, and False if the Op2 -- item is greater than or equal to the Op1 item. package GNAT.Bubble_Sort_G is pragma Pure; procedure Sort (N : Natural); -- This procedures sorts items in the range from 1 to N into ascending -- order making calls to Lt to do required comparisons, and Move to move -- items around. Note that, as described above, both Move and Lt use a -- single temporary location with index value zero. This sort is stable, -- that is the order of equal elements in the input is preserved. end GNAT.Bubble_Sort_G;
60.078947
78
0.549715
38c2bd2744163f20ae0e8cdf20bb1e2eb34e29e5
950
adb
Ada
Read Only/gdb-7.12.1/gdb/testsuite/gdb.ada/mi_dyn_arr/foo.adb
samyvic/OS-Project
1622bc1641876584964effd91d65ef02e92728e1
[ "Apache-2.0" ]
null
null
null
Read Only/gdb-7.12.1/gdb/testsuite/gdb.ada/mi_dyn_arr/foo.adb
samyvic/OS-Project
1622bc1641876584964effd91d65ef02e92728e1
[ "Apache-2.0" ]
null
null
null
Read Only/gdb-7.12.1/gdb/testsuite/gdb.ada/mi_dyn_arr/foo.adb
samyvic/OS-Project
1622bc1641876584964effd91d65ef02e92728e1
[ "Apache-2.0" ]
null
null
null
-- Copyright 2014-2017 Free Software Foundation, Inc. -- -- 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 3 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, see <http://www.gnu.org/licenses/>. with Pck; use Pck; procedure Foo is -- The goal here is to have an array whose bounds are not -- known at compile time. BT : Bounded := New_Bounded (Low => 1, High => 3); begin Do_Nothing (BT'Address); -- STOP end Foo;
38
73
0.714737
add7b9e28fd7480b6653370ed0b8100b69f1b199
120
ads
Ada
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/limited_with.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/limited_with.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/limited_with.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
limited with Pack1; package limited_with is procedure Print_2 (Obj : access Pack1.Nested.Rec_Typ); end limited_with;
24
57
0.791667
046b8f4effe34124f5c3b722b49eef978c337a85
2,461
ads
Ada
awa/src/awa-modules-lifecycles.ads
My-Colaborations/ada-awa
cc2dee291a14e4df0dbc9c10285bf284a7f1caa8
[ "Apache-2.0" ]
81
2015-01-18T23:02:30.000Z
2022-03-19T17:34:57.000Z
awa/src/awa-modules-lifecycles.ads
My-Colaborations/ada-awa
cc2dee291a14e4df0dbc9c10285bf284a7f1caa8
[ "Apache-2.0" ]
20
2015-12-09T19:26:19.000Z
2022-03-23T14:32:43.000Z
awa/src/awa-modules-lifecycles.ads
My-Colaborations/ada-awa
cc2dee291a14e4df0dbc9c10285bf284a7f1caa8
[ "Apache-2.0" ]
16
2015-06-29T02:44:06.000Z
2021-09-23T18:47:50.000Z
----------------------------------------------------------------------- -- awa-modules-lifecycles -- Lifecycle listeners -- Copyright (C) 2012, 2013, 2014 Stephane Carrez -- Written by Stephane Carrez ([email protected]) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Util.Listeners.Lifecycles; generic type Element_Type (<>) is limited private; package AWA.Modules.Lifecycles is package LF is new Util.Listeners.Lifecycles (Element_Type); subtype Listener is LF.Listener; -- Inform the the life cycle listeners registered in `List` that the item passed in `Item` -- has been created (calls `On_Create`). procedure Notify_Create (Service : in AWA.Modules.Module_Manager'Class; Item : in Element_Type); procedure Notify_Create (Service : in AWA.Modules.Module'Class; Item : in Element_Type); pragma Inline (Notify_Create); -- Inform the the life cycle listeners registered in `List` that the item passed in `Item` -- has been updated (calls `On_Update`). procedure Notify_Update (Service : in AWA.Modules.Module_Manager'Class; Item : in Element_Type); procedure Notify_Update (Service : in AWA.Modules.Module'Class; Item : in Element_Type); pragma Inline (Notify_Update); -- Inform the the life cycle listeners registered in `List` that the item passed in `Item` -- has been deleted (calls `On_Delete`). procedure Notify_Delete (Service : in AWA.Modules.Module_Manager'Class; Item : in Element_Type); procedure Notify_Delete (Service : in AWA.Modules.Module'Class; Item : in Element_Type); pragma Inline (Notify_Delete); end AWA.Modules.Lifecycles;
46.433962
95
0.625356
a0dda2cb8492da8436169b6442ce568ab9cd590a
1,348
ads
Ada
tier-1/xcb/source/thin/xcb-xcb_glx_get_mapiv_cookie_t.ads
charlie5/cBound
741be08197a61ad9c72553e3302f3b669902216d
[ "0BSD" ]
2
2015-11-12T11:16:20.000Z
2021-08-24T22:32:04.000Z
tier-1/xcb/source/thin/xcb-xcb_glx_get_mapiv_cookie_t.ads
charlie5/cBound
741be08197a61ad9c72553e3302f3b669902216d
[ "0BSD" ]
1
2018-06-05T05:19:35.000Z
2021-11-20T01:13:23.000Z
tier-1/xcb/source/thin/xcb-xcb_glx_get_mapiv_cookie_t.ads
charlie5/cBound
741be08197a61ad9c72553e3302f3b669902216d
[ "0BSD" ]
null
null
null
-- This file is generated by SWIG. Please do not modify by hand. -- with Interfaces.C; with Interfaces.C; with Interfaces.C.Pointers; package xcb.xcb_glx_get_mapiv_cookie_t is -- Item -- type Item is record sequence : aliased Interfaces.C.unsigned; end record; -- Item_Array -- type Item_Array is array (Interfaces.C.size_t range <>) of aliased xcb.xcb_glx_get_mapiv_cookie_t .Item; -- Pointer -- package C_Pointers is new Interfaces.C.Pointers (Index => Interfaces.C.size_t, Element => xcb.xcb_glx_get_mapiv_cookie_t.Item, Element_Array => xcb.xcb_glx_get_mapiv_cookie_t.Item_Array, Default_Terminator => (others => <>)); subtype Pointer is C_Pointers.Pointer; -- Pointer_Array -- type Pointer_Array is array (Interfaces.C.size_t range <>) of aliased xcb.xcb_glx_get_mapiv_cookie_t .Pointer; -- Pointer_Pointer -- package C_Pointer_Pointers is new Interfaces.C.Pointers (Index => Interfaces.C.size_t, Element => xcb.xcb_glx_get_mapiv_cookie_t.Pointer, Element_Array => xcb.xcb_glx_get_mapiv_cookie_t.Pointer_Array, Default_Terminator => null); subtype Pointer_Pointer is C_Pointer_Pointers.Pointer; end xcb.xcb_glx_get_mapiv_cookie_t;
26.431373
79
0.672849
a0b75f5a17700747a24fbd5e614415d22f40c6d8
3,895
ads
Ada
support/MinGW/lib/gcc/mingw32/9.2.0/adainclude/s-sequio.ads
orb-zhuchen/Orb
6da2404b949ac28bde786e08bf4debe4a27cd3a0
[ "CNRI-Python-GPL-Compatible", "MIT" ]
null
null
null
support/MinGW/lib/gcc/mingw32/9.2.0/adainclude/s-sequio.ads
orb-zhuchen/Orb
6da2404b949ac28bde786e08bf4debe4a27cd3a0
[ "CNRI-Python-GPL-Compatible", "MIT" ]
null
null
null
support/MinGW/lib/gcc/mingw32/9.2.0/adainclude/s-sequio.ads
orb-zhuchen/Orb
6da2404b949ac28bde786e08bf4debe4a27cd3a0
[ "CNRI-Python-GPL-Compatible", "MIT" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- S Y S T E M . S E Q U E N T I A L _ I O -- -- -- -- S p e c -- -- -- -- Copyright (C) 1992-2019, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This package contains the declaration of the control block used for -- Sequential_IO. This must be declared at the outer library level. It also -- contains code that is shared between instances of Sequential_IO. with System.File_Control_Block; with Ada.Streams; package System.Sequential_IO is package FCB renames System.File_Control_Block; type Sequential_AFCB is new FCB.AFCB with null record; -- No additional fields required for Sequential_IO function AFCB_Allocate (Control_Block : Sequential_AFCB) return FCB.AFCB_Ptr; procedure AFCB_Close (File : not null access Sequential_AFCB); procedure AFCB_Free (File : not null access Sequential_AFCB); procedure Read (File : in out Sequential_AFCB; Item : out Ada.Streams.Stream_Element_Array; Last : out Ada.Streams.Stream_Element_Offset); -- Required overriding of Read, not actually used for Sequential_IO procedure Write (File : in out Sequential_AFCB; Item : Ada.Streams.Stream_Element_Array); -- Required overriding of Write, not actually used for Sequential_IO type File_Type is access all Sequential_AFCB; -- File_Type in individual instantiations is derived from this type procedure Create (File : in out File_Type; Mode : FCB.File_Mode := FCB.Out_File; Name : String := ""; Form : String := ""); procedure Open (File : in out File_Type; Mode : FCB.File_Mode; Name : String; Form : String := ""); end System.Sequential_IO;
49.303797
78
0.504493
1e018ffe18ab3a2c17f2455e64dd5105fe584228
6,575
ads
Ada
tools-src/gnu/gcc/gcc/ada/g-catiio.ads
modern-tomato/tomato
96f09fab4929c6ddde5c9113f1b2476ad37133c4
[ "FSFAP" ]
80
2015-01-02T10:14:04.000Z
2021-06-07T06:29:49.000Z
tools-src/gnu/gcc/gcc/ada/g-catiio.ads
modern-tomato/tomato
96f09fab4929c6ddde5c9113f1b2476ad37133c4
[ "FSFAP" ]
9
2015-05-14T11:03:12.000Z
2018-01-04T07:12:58.000Z
tools-src/gnu/gcc/gcc/ada/g-catiio.ads
modern-tomato/tomato
96f09fab4929c6ddde5c9113f1b2476ad37133c4
[ "FSFAP" ]
69
2015-01-02T10:45:56.000Z
2021-09-06T07:52:13.000Z
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- G N A T . C A L E N D A R . T I M E _ I O -- -- -- -- S p e c -- -- -- -- $Revision$ -- -- -- Copyright (C) 1999-2001 Ada Core Technologies, Inc. -- -- -- -- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. The copyright notice above, and the license provisions that follow -- -- apply solely to the contents of the part following the private keyword. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT 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 distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, -- -- MA 02111-1307, USA. -- -- -- -- As a special exception, if other files instantiate generics from this -- -- unit, or you link this unit with other files to produce an executable, -- -- this unit does not by itself cause the resulting executable to be -- -- covered by the GNU General Public License. This exception does not -- -- however invalidate any other reasons why the executable file might be -- -- covered by the GNU Public License. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- It is now maintained by Ada Core Technologies Inc (http://www.gnat.com). -- -- -- ------------------------------------------------------------------------------ -- This package augments standard Ada.Text_IO with facilities for input -- and output of time values in standardized format. package GNAT.Calendar.Time_IO is Picture_Error : exception; type Picture_String is new String; -- This is a string to describe date and time output format. The string is -- a set of standard character and special tag that are replaced by the -- corresponding values. It follows the GNU Date specification. Here are -- the recognized directives : -- -- % a literal % -- n a newline -- t a horizontal tab -- -- Time fields: -- -- %H hour (00..23) -- %I hour (01..12) -- %k hour ( 0..23) -- %l hour ( 1..12) -- %M minute (00..59) -- %p locale's AM or PM -- %r time, 12-hour (hh:mm:ss [AP]M) -- %s seconds since 1970-01-01 00:00:00 UTC -- (a nonstandard extension) -- %S second (00..59) -- %T time, 24-hour (hh:mm:ss) -- -- Date fields: -- -- %a locale's abbreviated weekday name (Sun..Sat) -- %A locale's full weekday name, variable length -- (Sunday..Saturday) -- %b locale's abbreviated month name (Jan..Dec) -- %B locale's full month name, variable length -- (January..December) -- %c locale's date and time (Sat Nov 04 12:02:33 EST 1989) -- %d day of month (01..31) -- %D date (mm/dd/yy) -- %h same as %b -- %j day of year (001..366) -- %m month (01..12) -- %U week number of year with Sunday as first day of week -- (00..53) -- %w day of week (0..6) with 0 corresponding to Sunday -- %W week number of year with Monday as first day of week -- (00..53) -- %x locale's date representation (mm/dd/yy) -- %y last two digits of year (00..99) -- %Y year (1970...) -- -- By default, date pads numeric fields with zeroes. GNU date -- recognizes the following nonstandard numeric modifiers: -- -- - (hyphen) do not pad the field -- _ (underscore) pad the field with spaces ISO_Date : constant Picture_String; -- This format follow the ISO 8601 standard. The format is "YYYY-MM-DD", -- four digits year, month and day number separated by minus. US_Date : constant Picture_String; -- This format is the common US date format: "MM/DD/YY", -- month and day number, two digits year separated by slashes. European_Date : constant Picture_String; -- This format is the common European date format: "DD/MM/YY", -- day and month number, two digits year separated by slashes. function Image (Date : Ada.Calendar.Time; Picture : Picture_String) return String; -- Return Date as a string with format Picture. -- raise Picture_Error if picture string is wrong procedure Put_Time (Date : Ada.Calendar.Time; Picture : Picture_String); -- Put Date with format Picture. -- raise Picture_Error if picture string is wrong private ISO_Date : constant Picture_String := "%Y-%m-%d"; US_Date : constant Picture_String := "%m/%d/%y"; European_Date : constant Picture_String := "%d/%m/%y"; end GNAT.Calendar.Time_IO;
49.810606
78
0.484106
4bf9309bb5a33cc6506b409a05c9da9d58cd7a2a
3,152
ads
Ada
gcc-gcc-7_3_0-release/gcc/ada/s-valwch.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/ada/s-valwch.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/ada/s-valwch.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- S Y S T E M . V A L _ W C H A R -- -- -- -- S p e c -- -- -- -- Copyright (C) 1992-2009, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- Processing for Wide_[Wide_]Value attribute with System.WCh_Con; package System.Val_WChar is pragma Pure; function Value_Wide_Character (Str : String; EM : System.WCh_Con.WC_Encoding_Method) return Wide_Character; -- Computes Wide_Character'Value (Str). The parameter EM is the encoding -- method used for any Wide_Character sequences in Str. Note that brackets -- notation is always permitted. function Value_Wide_Wide_Character (Str : String; EM : System.WCh_Con.WC_Encoding_Method) return Wide_Wide_Character; -- Computes Wide_Character'Value (Str). The parameter EM is the encoding -- method used for any wide_character sequences in Str. Note that brackets -- notation is always permitted. end System.Val_WChar;
58.37037
78
0.459074
8b4bdf54bd4f9ab5767bf1c84fb37c62aef15b45
956
adb
Ada
gdb-7.3/gdb/testsuite/gdb.ada/complete/foo.adb
vidkidz/crossbridge
ba0bf94aee0ce6cf7eb5be882382e52bc57ba396
[ "MIT" ]
1
2016-04-09T02:58:13.000Z
2016-04-09T02:58:13.000Z
gdb-7.3/gdb/testsuite/gdb.ada/complete/foo.adb
vidkidz/crossbridge
ba0bf94aee0ce6cf7eb5be882382e52bc57ba396
[ "MIT" ]
null
null
null
gdb-7.3/gdb/testsuite/gdb.ada/complete/foo.adb
vidkidz/crossbridge
ba0bf94aee0ce6cf7eb5be882382e52bc57ba396
[ "MIT" ]
null
null
null
-- Copyright 2008, 2009, 2010, 2011 Free Software Foundation, Inc. -- -- 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 3 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, see <http://www.gnu.org/licenses/>. with Pck; use Pck; procedure Foo is Some_Local_Variable : Integer := 1; External_Identical_Two : Integer := 74; begin My_Global_Variable := Some_Local_Variable + 1; -- START Proc (External_Identical_Two); end Foo;
36.769231
73
0.733264
38a0ae44b8647f862cb458dbf988790ee2d68a57
230
ads
Ada
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/vect9.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/vect9.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/vect9.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
with Vect9_Pkg; use Vect9_Pkg; package Vect9 is type Rec is record Data : Vector_Access; end record; procedure Proc (This : in Rec; CV : in Unit_Vector; Data : in out Unit_Vector); end Vect9;
15.333333
33
0.630435
582e0b8e7974889ca0c416ba6fa4115aeddda1b2
5,391
ads
Ada
src/camera/pixy/src/host/pantilt_in_ada/specs/x86_64_linux_gnu_sys_time_h.ads
wowHollis/SmartCart
f377f34fc452f90866e9d4c8a4e031314e633adb
[ "MIT" ]
1
2019-05-30T00:52:06.000Z
2019-05-30T00:52:06.000Z
src/camera/pixy/src/host/pantilt_in_ada/specs/x86_64_linux_gnu_sys_time_h.ads
wowHollis/SmartCart
f377f34fc452f90866e9d4c8a4e031314e633adb
[ "MIT" ]
1
2015-05-11T19:51:54.000Z
2015-05-11T19:51:54.000Z
src/camera/pixy/src/host/pantilt_in_ada/specs/x86_64_linux_gnu_sys_time_h.ads
wowHollis/SmartCart
f377f34fc452f90866e9d4c8a4e031314e633adb
[ "MIT" ]
null
null
null
-- -- Copyright (c) 2015, John Leimon <[email protected]> -- -- Permission to use, copy, modify, and/or distribute this software for any -- purpose with or without fee is hereby granted, provided that the above copyright -- notice and this permission notice appear in all copies. -- -- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD -- TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN -- NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR -- CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR -- PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, -- ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -- pragma Ada_2005; pragma Style_Checks (Off); with Interfaces.C; use Interfaces.C; with x86_64_linux_gnu_bits_time_h; with Interfaces.C.Strings; package x86_64_linux_gnu_sys_time_h is -- arg-macro: procedure TIMEVAL_TO_TIMESPEC (tv, ts) -- { (ts).tv_sec := (tv).tv_sec; (ts).tv_nsec := (tv).tv_usec * 1000; } -- arg-macro: procedure TIMESPEC_TO_TIMEVAL (tv, ts) -- { (tv).tv_sec := (ts).tv_sec; (tv).tv_usec := (ts).tv_nsec / 1000; } -- unsupported macro: ITIMER_REAL ITIMER_REAL -- unsupported macro: ITIMER_VIRTUAL ITIMER_VIRTUAL -- unsupported macro: ITIMER_PROF ITIMER_PROF -- arg-macro: function timerisset (tvp) -- return (tvp).tv_sec or else (tvp).tv_usec; -- arg-macro: function timerclear (tvp) -- return (tvp).tv_sec := (tvp).tv_usec := 0; -- arg-macro: function timercmp (a, b, CMP) -- return ((a).tv_sec = (b).tv_sec) ? ((a).tv_usec CMP (b).tv_usec) : ((a).tv_sec CMP (b).tv_sec); -- arg-macro: procedure timeradd (a, b, result) -- do { (result).tv_sec := (a).tv_sec + (b).tv_sec; (result).tv_usec := (a).tv_usec + (b).tv_usec; if ((result).tv_usec >= 1000000) { ++(result).tv_sec; (result).tv_usec -= 1000000; } } while (0) -- arg-macro: procedure timersub (a, b, result) -- do { (result).tv_sec := (a).tv_sec - (b).tv_sec; (result).tv_usec := (a).tv_usec - (b).tv_usec; if ((result).tv_usec < 0) { --(result).tv_sec; (result).tv_usec += 1000000; } } while (0) type timezone is record tz_minuteswest : aliased int; -- /usr/include/x86_64-linux-gnu/sys/time.h:57 tz_dsttime : aliased int; -- /usr/include/x86_64-linux-gnu/sys/time.h:58 end record; pragma Convention (C_Pass_By_Copy, timezone); -- /usr/include/x86_64-linux-gnu/sys/time.h:55 type uu_timezone_ptr_t is access all timezone; -- /usr/include/x86_64-linux-gnu/sys/time.h:61 function gettimeofday (uu_tv : access x86_64_linux_gnu_bits_time_h.timeval; uu_tz : uu_timezone_ptr_t) return int; -- /usr/include/x86_64-linux-gnu/sys/time.h:71 pragma Import (C, gettimeofday, "gettimeofday"); function settimeofday (uu_tv : access constant x86_64_linux_gnu_bits_time_h.timeval; uu_tz : access constant timezone) return int; -- /usr/include/x86_64-linux-gnu/sys/time.h:77 pragma Import (C, settimeofday, "settimeofday"); function adjtime (uu_delta : access constant x86_64_linux_gnu_bits_time_h.timeval; uu_olddelta : access x86_64_linux_gnu_bits_time_h.timeval) return int; -- /usr/include/x86_64-linux-gnu/sys/time.h:85 pragma Import (C, adjtime, "adjtime"); type uu_itimer_which is (ITIMER_REAL, ITIMER_VIRTUAL, ITIMER_PROF); pragma Convention (C, uu_itimer_which); -- /usr/include/x86_64-linux-gnu/sys/time.h:91 type itimerval is record it_interval : aliased x86_64_linux_gnu_bits_time_h.timeval; -- /usr/include/x86_64-linux-gnu/sys/time.h:110 it_value : aliased x86_64_linux_gnu_bits_time_h.timeval; -- /usr/include/x86_64-linux-gnu/sys/time.h:112 end record; pragma Convention (C_Pass_By_Copy, itimerval); -- /usr/include/x86_64-linux-gnu/sys/time.h:107 subtype uu_itimer_which_t is int; -- /usr/include/x86_64-linux-gnu/sys/time.h:120 function getitimer (uu_which : uu_itimer_which_t; uu_value : access itimerval) return int; -- /usr/include/x86_64-linux-gnu/sys/time.h:125 pragma Import (C, getitimer, "getitimer"); function setitimer (uu_which : uu_itimer_which_t; uu_new : access constant itimerval; uu_old : access itimerval) return int; -- /usr/include/x86_64-linux-gnu/sys/time.h:131 pragma Import (C, setitimer, "setitimer"); function utimes (uu_file : Interfaces.C.Strings.chars_ptr; uu_tvp : access constant x86_64_linux_gnu_bits_time_h.timeval) return int; -- /usr/include/x86_64-linux-gnu/sys/time.h:138 pragma Import (C, utimes, "utimes"); function lutimes (uu_file : Interfaces.C.Strings.chars_ptr; uu_tvp : access constant x86_64_linux_gnu_bits_time_h.timeval) return int; -- /usr/include/x86_64-linux-gnu/sys/time.h:143 pragma Import (C, lutimes, "lutimes"); function futimes (uu_fd : int; uu_tvp : access constant x86_64_linux_gnu_bits_time_h.timeval) return int; -- /usr/include/x86_64-linux-gnu/sys/time.h:147 pragma Import (C, futimes, "futimes"); function futimesat (uu_fd : int; uu_file : Interfaces.C.Strings.chars_ptr; uu_tvp : access constant x86_64_linux_gnu_bits_time_h.timeval) return int; -- /usr/include/x86_64-linux-gnu/sys/time.h:154 pragma Import (C, futimesat, "futimesat"); end x86_64_linux_gnu_sys_time_h;
55.010204
204
0.713597
1eb266e9e0e318022fa6a58c6527de3cb9c156b1
3,949
ads
Ada
source/web/tools/a2js/webapi/html/webapi-ui_events-focus.ads
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
24
2016-11-29T06:59:41.000Z
2021-08-30T11:55:16.000Z
source/web/tools/a2js/webapi/html/webapi-ui_events-focus.ads
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
2
2019-01-16T05:15:20.000Z
2019-02-03T10:03:32.000Z
source/web/tools/a2js/webapi/html/webapi-ui_events-focus.ads
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
4
2017-07-18T07:11:05.000Z
2020-06-21T03:02:25.000Z
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Web Framework -- -- -- -- Web API Definition -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2015, Vadim Godunko <[email protected]> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ with WebAPI.DOM.Event_Targets; package WebAPI.UI_Events.Focus is pragma Preelaborate; type Focus_Event is limited interface and WebAPI.UI_Events.UI_Event; not overriding function Get_Related_Target (Self : not null access constant Focus_Event) return WebAPI.DOM.Event_Targets.Event_Target_Access is abstract with Import => True, Convention => JavaScript_Property_Getter, Link_Name => "relatedTarget"; -- Used to identify a secondary EventTarget related to a Focus event, -- depending on the type of event. end WebAPI.UI_Events.Focus;
63.693548
78
0.4353
1ef9c813524ba0ab80ee69eb6dec463285fb23c9
132
adb
Ada
src/lab-code/spark_depends/diff.adb
hannesb0/rtpl18
6cd1ff776b98695713de88586391139447edb320
[ "MIT" ]
null
null
null
src/lab-code/spark_depends/diff.adb
hannesb0/rtpl18
6cd1ff776b98695713de88586391139447edb320
[ "MIT" ]
null
null
null
src/lab-code/spark_depends/diff.adb
hannesb0/rtpl18
6cd1ff776b98695713de88586391139447edb320
[ "MIT" ]
null
null
null
procedure Diff (X, Y : in Natural; Z : out Natural) with SPARK_Mode, Depends => (Z => (X, Y)) is begin Z := X + X; end Diff;
16.5
56
0.575758
a07c4e568c678ad373fc80d69bf803e6ec0f9605
265
ads
Ada
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/loop_optimization4_pkg.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/loop_optimization4_pkg.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/testsuite/gnat.dg/loop_optimization4_pkg.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
package Loop_Optimization4_Pkg is Max_Debug_Buffer_Len : Natural := 8 * 1024; Debug_Buffer : String (1 .. Max_Debug_Buffer_Len); Debug_Buffer_Len : Natural range 0 .. Max_Debug_Buffer_Len; procedure Add (Phrase : String); end Loop_Optimization4_Pkg;
26.5
62
0.754717
9affd31f2336c88046e0e1208594e37fd33a79ad
18,309
ads
Ada
source/amf/uml/amf-internals-umldi_uml_object_diagrams.ads
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
24
2016-11-29T06:59:41.000Z
2021-08-30T11:55:16.000Z
source/amf/uml/amf-internals-umldi_uml_object_diagrams.ads
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
2
2019-01-16T05:15:20.000Z
2019-02-03T10:03:32.000Z
source/amf/uml/amf-internals-umldi_uml_object_diagrams.ads
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
4
2017-07-18T07:11:05.000Z
2020-06-21T03:02:25.000Z
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Ada Modeling Framework -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2012, Vadim Godunko <[email protected]> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ with AMF.CMOF.Elements; with AMF.DI.Styles; with AMF.Internals.UMLDI_UML_Diagrams; with AMF.UML.Comments.Collections; with AMF.UML.Dependencies.Collections; with AMF.UML.Elements.Collections; with AMF.UML.Named_Elements; with AMF.UML.Namespaces.Collections; with AMF.UML.Packages.Collections; with AMF.UML.Parameterable_Elements; with AMF.UML.String_Expressions; with AMF.UML.Template_Parameters; with AMF.UMLDI.UML_Labels; with AMF.UMLDI.UML_Object_Diagrams; with AMF.UMLDI.UML_Styles; with AMF.Visitors; with League.Strings; package AMF.Internals.UMLDI_UML_Object_Diagrams is type UMLDI_UML_Object_Diagram_Proxy is limited new AMF.Internals.UMLDI_UML_Diagrams.UMLDI_UML_Diagram_Proxy and AMF.UMLDI.UML_Object_Diagrams.UMLDI_UML_Object_Diagram with null record; overriding function Get_Heading (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UMLDI.UML_Labels.UMLDI_UML_Label_Access; -- Getter of UMLDiagram::heading. -- overriding procedure Set_Heading (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : AMF.UMLDI.UML_Labels.UMLDI_UML_Label_Access); -- Setter of UMLDiagram::heading. -- overriding function Get_Is_Frame (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return Boolean; -- Getter of UMLDiagram::isFrame. -- -- Indicates when diagram frames shall be shown. overriding procedure Set_Is_Frame (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : Boolean); -- Setter of UMLDiagram::isFrame. -- -- Indicates when diagram frames shall be shown. overriding function Get_Is_Iso (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return Boolean; -- Getter of UMLDiagram::isIso. -- -- Indicate when ISO notation rules shall be followed. overriding procedure Set_Is_Iso (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : Boolean); -- Setter of UMLDiagram::isIso. -- -- Indicate when ISO notation rules shall be followed. overriding function Get_Is_Icon (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return Boolean; -- Getter of UMLDiagramElement::isIcon. -- -- For modelElements that have an option to be shown with shapes other -- than rectangles, such as Actors, or with other identifying shapes -- inside them, such as arrows distinguishing InputPins and OutputPins, or -- edges that have an option to be shown with lines other than solid with -- open arrow heads, such as Realization. A value of true for isIcon -- indicates the alternative notation shall be shown. overriding procedure Set_Is_Icon (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : Boolean); -- Setter of UMLDiagramElement::isIcon. -- -- For modelElements that have an option to be shown with shapes other -- than rectangles, such as Actors, or with other identifying shapes -- inside them, such as arrows distinguishing InputPins and OutputPins, or -- edges that have an option to be shown with lines other than solid with -- open arrow heads, such as Realization. A value of true for isIcon -- indicates the alternative notation shall be shown. overriding function Get_Local_Style (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UMLDI.UML_Styles.UMLDI_UML_Style_Access; -- Getter of UMLDiagramElement::localStyle. -- -- Restricts owned styles to UMLStyles. overriding procedure Set_Local_Style (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : AMF.UMLDI.UML_Styles.UMLDI_UML_Style_Access); -- Setter of UMLDiagramElement::localStyle. -- -- Restricts owned styles to UMLStyles. overriding function Get_Model_Element (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.Elements.Collections.Set_Of_UML_Element; -- Getter of UMLDiagramElement::modelElement. -- -- Restricts UMLDiagramElements to show UML Elements, rather than other -- language elements. overriding function Get_Model_Element (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.CMOF.Elements.CMOF_Element_Access; -- Getter of DiagramElement::modelElement. -- -- a reference to a depicted model element, which can be any MOF-based -- element overriding function Get_Local_Style (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.DI.Styles.DI_Style_Access; -- Getter of DiagramElement::localStyle. -- -- a reference to an optional locally-owned style for this diagram element. overriding procedure Set_Local_Style (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : AMF.DI.Styles.DI_Style_Access); -- Setter of DiagramElement::localStyle. -- -- a reference to an optional locally-owned style for this diagram element. overriding function Get_Name (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return League.Strings.Universal_String; -- Getter of Diagram::name. -- -- the name of the diagram. overriding procedure Set_Name (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : League.Strings.Universal_String); -- Setter of Diagram::name. -- -- the name of the diagram. overriding function Get_Documentation (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return League.Strings.Universal_String; -- Getter of Diagram::documentation. -- -- the documentation of the diagram. overriding procedure Set_Documentation (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : League.Strings.Universal_String); -- Setter of Diagram::documentation. -- -- the documentation of the diagram. overriding function Get_Resolution (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.Real; -- Getter of Diagram::resolution. -- -- the resolution of the diagram expressed in user units per inch. overriding procedure Set_Resolution (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : AMF.Real); -- Setter of Diagram::resolution. -- -- the resolution of the diagram expressed in user units per inch. overriding function Get_Client_Dependency (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.Dependencies.Collections.Set_Of_UML_Dependency; -- Getter of NamedElement::clientDependency. -- -- Indicates the dependencies that reference the client. overriding function Get_Name (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.Optional_String; -- Getter of NamedElement::name. -- -- The name of the NamedElement. overriding procedure Set_Name (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : AMF.Optional_String); -- Setter of NamedElement::name. -- -- The name of the NamedElement. overriding function Get_Name_Expression (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.String_Expressions.UML_String_Expression_Access; -- Getter of NamedElement::nameExpression. -- -- The string expression used to define the name of this named element. overriding procedure Set_Name_Expression (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : AMF.UML.String_Expressions.UML_String_Expression_Access); -- Setter of NamedElement::nameExpression. -- -- The string expression used to define the name of this named element. overriding function Get_Namespace (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.Namespaces.UML_Namespace_Access; -- Getter of NamedElement::namespace. -- -- Specifies the namespace that owns the NamedElement. overriding function Get_Qualified_Name (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.Optional_String; -- Getter of NamedElement::qualifiedName. -- -- A name which allows the NamedElement to be identified within a -- hierarchy of nested Namespaces. It is constructed from the names of the -- containing namespaces starting at the root of the hierarchy and ending -- with the name of the NamedElement itself. overriding function Get_Owned_Comment (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.Comments.Collections.Set_Of_UML_Comment; -- Getter of Element::ownedComment. -- -- The Comments owned by this element. overriding function Get_Owned_Element (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.Elements.Collections.Set_Of_UML_Element; -- Getter of Element::ownedElement. -- -- The Elements owned by this element. overriding function Get_Owner (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.Elements.UML_Element_Access; -- Getter of Element::owner. -- -- The Element that owns this element. overriding function Get_Owning_Template_Parameter (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.Template_Parameters.UML_Template_Parameter_Access; -- Getter of ParameterableElement::owningTemplateParameter. -- -- The formal template parameter that owns this element. overriding procedure Set_Owning_Template_Parameter (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : AMF.UML.Template_Parameters.UML_Template_Parameter_Access); -- Setter of ParameterableElement::owningTemplateParameter. -- -- The formal template parameter that owns this element. overriding function Get_Template_Parameter (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.Template_Parameters.UML_Template_Parameter_Access; -- Getter of ParameterableElement::templateParameter. -- -- The template parameter that exposes this element as a formal parameter. overriding procedure Set_Template_Parameter (Self : not null access UMLDI_UML_Object_Diagram_Proxy; To : AMF.UML.Template_Parameters.UML_Template_Parameter_Access); -- Setter of ParameterableElement::templateParameter. -- -- The template parameter that exposes this element as a formal parameter. overriding function All_Namespaces (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.Namespaces.Collections.Ordered_Set_Of_UML_Namespace; -- Operation NamedElement::allNamespaces. -- -- The query allNamespaces() gives the sequence of namespaces in which the -- NamedElement is nested, working outwards. overriding function All_Owning_Packages (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.Packages.Collections.Set_Of_UML_Package; -- Operation NamedElement::allOwningPackages. -- -- The query allOwningPackages() returns all the directly or indirectly -- owning packages. overriding function Is_Distinguishable_From (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy; N : AMF.UML.Named_Elements.UML_Named_Element_Access; Ns : AMF.UML.Namespaces.UML_Namespace_Access) return Boolean; -- Operation NamedElement::isDistinguishableFrom. -- -- The query isDistinguishableFrom() determines whether two NamedElements -- may logically co-exist within a Namespace. By default, two named -- elements are distinguishable if (a) they have unrelated types or (b) -- they have related types but different names. overriding function Namespace (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.Namespaces.UML_Namespace_Access; -- Operation NamedElement::namespace. -- -- Missing derivation for NamedElement::/namespace : Namespace overriding function Qualified_Name (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return League.Strings.Universal_String; -- Operation NamedElement::qualifiedName. -- -- When there is a name, and all of the containing namespaces have a name, -- the qualified name is constructed from the names of the containing -- namespaces. overriding function Separator (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return League.Strings.Universal_String; -- Operation NamedElement::separator. -- -- The query separator() gives the string that is used to separate names -- when constructing a qualified name. overriding function All_Owned_Elements (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return AMF.UML.Elements.Collections.Set_Of_UML_Element; -- Operation Element::allOwnedElements. -- -- The query allOwnedElements() gives all of the direct and indirect owned -- elements of an element. overriding function Is_Compatible_With (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy; P : AMF.UML.Parameterable_Elements.UML_Parameterable_Element_Access) return Boolean; -- Operation ParameterableElement::isCompatibleWith. -- -- The query isCompatibleWith() determines if this parameterable element -- is compatible with the specified parameterable element. By default -- parameterable element P is compatible with parameterable element Q if -- the kind of P is the same or a subtype as the kind of Q. Subclasses -- should override this operation to specify different compatibility -- constraints. overriding function Is_Template_Parameter (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy) return Boolean; -- Operation ParameterableElement::isTemplateParameter. -- -- The query isTemplateParameter() determines if this parameterable -- element is exposed as a formal template parameter. overriding procedure Enter_Element (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy; Visitor : in out AMF.Visitors.Abstract_Visitor'Class; Control : in out AMF.Visitors.Traverse_Control); overriding procedure Leave_Element (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy; Visitor : in out AMF.Visitors.Abstract_Visitor'Class; Control : in out AMF.Visitors.Traverse_Control); overriding procedure Visit_Element (Self : not null access constant UMLDI_UML_Object_Diagram_Proxy; Iterator : in out AMF.Visitors.Abstract_Iterator'Class; Visitor : in out AMF.Visitors.Abstract_Visitor'Class; Control : in out AMF.Visitors.Traverse_Control); end AMF.Internals.UMLDI_UML_Object_Diagrams;
43.906475
83
0.679338
3886365669ba3fc0762b59c7b8f671d32941b468
811
adb
Ada
src/gdb/gdb-7.11/gdb/testsuite/gdb.ada/expr_delims/pck.adb
alrooney/unum-sdk
bbccb10b0cd3500feccbbef22e27ea111c3d18eb
[ "Apache-2.0" ]
31
2018-08-01T21:25:24.000Z
2022-02-14T07:52:34.000Z
src/gdb/gdb-7.11/gdb/testsuite/gdb.ada/expr_delims/pck.adb
alrooney/unum-sdk
bbccb10b0cd3500feccbbef22e27ea111c3d18eb
[ "Apache-2.0" ]
40
2018-12-03T19:48:52.000Z
2021-03-10T06:34:26.000Z
src/gdb/gdb-7.11/gdb/testsuite/gdb.ada/expr_delims/pck.adb
alrooney/unum-sdk
bbccb10b0cd3500feccbbef22e27ea111c3d18eb
[ "Apache-2.0" ]
20
2018-11-16T21:19:22.000Z
2021-10-18T23:08:24.000Z
-- Copyright 2013-2016 Free Software Foundation, Inc. -- -- 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 3 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, see <http://www.gnu.org/licenses/>. package body Pck is procedure Put(S : String) is begin null; end Put; end Pck;
33.791667
73
0.722565
13c6f784b555c4efcc2c74d96bb6133edf0df659
8,990
ads
Ada
extern/gnat_sdl/gnat_sdl2/src/sdl_mutex_h.ads
AdaCore/training_material
6651eb2c53f8c39649b8e0b3c757bc8ff963025a
[ "CC-BY-4.0" ]
15
2020-10-07T08:56:45.000Z
2022-02-08T23:13:22.000Z
extern/gnat_sdl/gnat_sdl2/src/sdl_mutex_h.ads
AdaCore/training_material
6651eb2c53f8c39649b8e0b3c757bc8ff963025a
[ "CC-BY-4.0" ]
20
2020-11-05T14:35:20.000Z
2022-01-13T15:59:33.000Z
extern/gnat_sdl/gnat_sdl2/src/sdl_mutex_h.ads
AdaCore/training_material
6651eb2c53f8c39649b8e0b3c757bc8ff963025a
[ "CC-BY-4.0" ]
6
2020-10-08T15:57:06.000Z
2021-08-31T12:03:08.000Z
pragma Ada_2005; pragma Style_Checks (Off); with Interfaces.C; use Interfaces.C; with SDL_stdinc_h; package SDL_mutex_h is SDL_MUTEX_TIMEDOUT : constant := 1; -- ..\SDL2_tmp\SDL_mutex.h:44 -- unsupported macro: SDL_MUTEX_MAXWAIT (~(Uint32)0) -- arg-macro: procedure SDL_mutexP (m) -- SDL_LockMutex(m) -- arg-macro: procedure SDL_mutexV (m) -- SDL_UnlockMutex(m) -- Simple DirectMedia Layer -- Copyright (C) 1997-2018 Sam Lantinga <[email protected]> -- This software is provided 'as-is', without any express or implied -- warranty. In no event will the authors be held liable for any damages -- arising from the use of this software. -- Permission is granted to anyone to use this software for any purpose, -- including commercial applications, and to alter it and redistribute it -- freely, subject to the following restrictions: -- 1. The origin of this software must not be misrepresented; you must not -- claim that you wrote the original software. If you use this software -- in a product, an acknowledgment in the product documentation would be -- appreciated but is not required. -- 2. Altered source versions must be plainly marked as such, and must not be -- misrepresented as being the original software. -- 3. This notice may not be removed or altered from any source distribution. -- --* -- * \file SDL_mutex.h -- * -- * Functions to provide thread synchronization primitives. -- -- Set up for C function definitions, even when using C++ --* -- * Synchronization functions which can time out return this value -- * if they time out. -- --* -- * This is the timeout value which corresponds to never time out. -- --* -- * \name Mutex functions -- -- @{ -- The SDL mutex structure, defined in SDL_sysmutex.c type SDL_mutex is null record; -- incomplete struct --* -- * Create a mutex, initialized unlocked. -- function SDL_CreateMutex return access SDL_mutex; -- ..\SDL2_tmp\SDL_mutex.h:64 pragma Import (C, SDL_CreateMutex, "SDL_CreateMutex"); --* -- * Lock the mutex. -- * -- * \return 0, or -1 on error. -- function SDL_LockMutex (mutex : access SDL_mutex) return int; -- ..\SDL2_tmp\SDL_mutex.h:72 pragma Import (C, SDL_LockMutex, "SDL_LockMutex"); --* -- * Try to lock the mutex -- * -- * \return 0, SDL_MUTEX_TIMEDOUT, or -1 on error -- function SDL_TryLockMutex (mutex : access SDL_mutex) return int; -- ..\SDL2_tmp\SDL_mutex.h:79 pragma Import (C, SDL_TryLockMutex, "SDL_TryLockMutex"); --* -- * Unlock the mutex. -- * -- * \return 0, or -1 on error. -- * -- * \warning It is an error to unlock a mutex that has not been locked by -- * the current thread, and doing so results in undefined behavior. -- function SDL_UnlockMutex (mutex : access SDL_mutex) return int; -- ..\SDL2_tmp\SDL_mutex.h:90 pragma Import (C, SDL_UnlockMutex, "SDL_UnlockMutex"); --* -- * Destroy a mutex. -- procedure SDL_DestroyMutex (mutex : access SDL_mutex); -- ..\SDL2_tmp\SDL_mutex.h:95 pragma Import (C, SDL_DestroyMutex, "SDL_DestroyMutex"); -- @} -- Mutex functions --* -- * \name Semaphore functions -- -- @{ -- The SDL semaphore structure, defined in SDL_syssem.c type SDL_semaphore is null record; -- incomplete struct subtype SDL_sem is SDL_semaphore; -- ..\SDL2_tmp\SDL_mutex.h:107 --* -- * Create a semaphore, initialized with value, returns NULL on failure. -- function SDL_CreateSemaphore (initial_value : SDL_stdinc_h.Uint32) return access SDL_sem; -- ..\SDL2_tmp\SDL_mutex.h:112 pragma Import (C, SDL_CreateSemaphore, "SDL_CreateSemaphore"); --* -- * Destroy a semaphore. -- procedure SDL_DestroySemaphore (sem : access SDL_sem); -- ..\SDL2_tmp\SDL_mutex.h:117 pragma Import (C, SDL_DestroySemaphore, "SDL_DestroySemaphore"); --* -- * This function suspends the calling thread until the semaphore pointed -- * to by \c sem has a positive count. It then atomically decreases the -- * semaphore count. -- function SDL_SemWait (sem : access SDL_sem) return int; -- ..\SDL2_tmp\SDL_mutex.h:124 pragma Import (C, SDL_SemWait, "SDL_SemWait"); --* -- * Non-blocking variant of SDL_SemWait(). -- * -- * \return 0 if the wait succeeds, ::SDL_MUTEX_TIMEDOUT if the wait would -- * block, and -1 on error. -- function SDL_SemTryWait (sem : access SDL_sem) return int; -- ..\SDL2_tmp\SDL_mutex.h:132 pragma Import (C, SDL_SemTryWait, "SDL_SemTryWait"); --* -- * Variant of SDL_SemWait() with a timeout in milliseconds. -- * -- * \return 0 if the wait succeeds, ::SDL_MUTEX_TIMEDOUT if the wait does not -- * succeed in the allotted time, and -1 on error. -- * -- * \warning On some platforms this function is implemented by looping with a -- * delay of 1 ms, and so should be avoided if possible. -- function SDL_SemWaitTimeout (sem : access SDL_sem; ms : SDL_stdinc_h.Uint32) return int; -- ..\SDL2_tmp\SDL_mutex.h:143 pragma Import (C, SDL_SemWaitTimeout, "SDL_SemWaitTimeout"); --* -- * Atomically increases the semaphore's count (not blocking). -- * -- * \return 0, or -1 on error. -- function SDL_SemPost (sem : access SDL_sem) return int; -- ..\SDL2_tmp\SDL_mutex.h:150 pragma Import (C, SDL_SemPost, "SDL_SemPost"); --* -- * Returns the current count of the semaphore. -- function SDL_SemValue (sem : access SDL_sem) return SDL_stdinc_h.Uint32; -- ..\SDL2_tmp\SDL_mutex.h:155 pragma Import (C, SDL_SemValue, "SDL_SemValue"); -- @} -- Semaphore functions --* -- * \name Condition variable functions -- -- @{ -- The SDL condition variable structure, defined in SDL_syscond.c type SDL_cond is null record; -- incomplete struct --* -- * Create a condition variable. -- * -- * Typical use of condition variables: -- * -- * Thread A: -- * SDL_LockMutex(lock); -- * while ( ! condition ) { -- * SDL_CondWait(cond, lock); -- * } -- * SDL_UnlockMutex(lock); -- * -- * Thread B: -- * SDL_LockMutex(lock); -- * ... -- * condition = true; -- * ... -- * SDL_CondSignal(cond); -- * SDL_UnlockMutex(lock); -- * -- * There is some discussion whether to signal the condition variable -- * with the mutex locked or not. There is some potential performance -- * benefit to unlocking first on some platforms, but there are some -- * potential race conditions depending on how your code is structured. -- * -- * In general it's safer to signal the condition variable while the -- * mutex is locked. -- function SDL_CreateCond return access SDL_cond; -- ..\SDL2_tmp\SDL_mutex.h:197 pragma Import (C, SDL_CreateCond, "SDL_CreateCond"); --* -- * Destroy a condition variable. -- procedure SDL_DestroyCond (cond : access SDL_cond); -- ..\SDL2_tmp\SDL_mutex.h:202 pragma Import (C, SDL_DestroyCond, "SDL_DestroyCond"); --* -- * Restart one of the threads that are waiting on the condition variable. -- * -- * \return 0 or -1 on error. -- function SDL_CondSignal (cond : access SDL_cond) return int; -- ..\SDL2_tmp\SDL_mutex.h:209 pragma Import (C, SDL_CondSignal, "SDL_CondSignal"); --* -- * Restart all threads that are waiting on the condition variable. -- * -- * \return 0 or -1 on error. -- function SDL_CondBroadcast (cond : access SDL_cond) return int; -- ..\SDL2_tmp\SDL_mutex.h:216 pragma Import (C, SDL_CondBroadcast, "SDL_CondBroadcast"); --* -- * Wait on the condition variable, unlocking the provided mutex. -- * -- * \warning The mutex must be locked before entering this function! -- * -- * The mutex is re-locked once the condition variable is signaled. -- * -- * \return 0 when it is signaled, or -1 on error. -- function SDL_CondWait (cond : access SDL_cond; mutex : access SDL_mutex) return int; -- ..\SDL2_tmp\SDL_mutex.h:227 pragma Import (C, SDL_CondWait, "SDL_CondWait"); --* -- * Waits for at most \c ms milliseconds, and returns 0 if the condition -- * variable is signaled, ::SDL_MUTEX_TIMEDOUT if the condition is not -- * signaled in the allotted time, and -1 on error. -- * -- * \warning On some platforms this function is implemented by looping with a -- * delay of 1 ms, and so should be avoided if possible. -- function SDL_CondWaitTimeout (cond : access SDL_cond; mutex : access SDL_mutex; ms : SDL_stdinc_h.Uint32) return int; -- ..\SDL2_tmp\SDL_mutex.h:237 pragma Import (C, SDL_CondWaitTimeout, "SDL_CondWaitTimeout"); -- @} -- Condition variable functions -- Ends C function definitions when using C++ -- vi: set ts=4 sw=4 expandtab: end SDL_mutex_h;
32.690909
124
0.651279
c74ed9bfd9de6e17c8b842bb5a1e5f8cba1e9472
1,952
ads
Ada
3-mid/opengl/source/lean/io/opengl-io-wavefront.ads
charlie5/lace-alire
9ace9682cf4daac7adb9f980c2868d6225b8111c
[ "0BSD" ]
1
2022-01-20T07:13:42.000Z
2022-01-20T07:13:42.000Z
3-mid/opengl/source/lean/io/opengl-io-wavefront.ads
charlie5/lace-alire
9ace9682cf4daac7adb9f980c2868d6225b8111c
[ "0BSD" ]
null
null
null
3-mid/opengl/source/lean/io/opengl-io-wavefront.ads
charlie5/lace-alire
9ace9682cf4daac7adb9f980c2868d6225b8111c
[ "0BSD" ]
null
null
null
package openGL.IO.wavefront -- -- Provides a function to convert a Wavefront model file (*.obj) to an openGL IO model. -- is --------- -- Group -- type group_Kind is (object_Name, group_Name, smoothing_Group, merging_Group); type Group (Kind : group_Kind := group_Name) is record case Kind is when object_Name => object_Name : Text; when group_Name => group_Name : Text; when smoothing_Group => smooth_group_Id : Natural; when merging_Group => null; end case; end record; function Image (Self : in Group) return String; -------- -- Face -- type face_Kind is (a_Group, a_Facet); type Face (Kind : face_Kind := a_Facet) is record case Kind is when a_Group => Group : wavefront.Group; when a_Facet => Facet : openGL.IO.Face; end case; end record; type Faces is array (long_Index_t range <>) of Face; function Image (Self : in wavefront.Face) return String; function to_Model (model_File : in String) return IO.Model; type Model is record material_Library : Text; material_Name : Text; object_Name : Text; group_Name : Text; Sites : access openGL.Sites; Coords : access openGL.Coordinates_2D; Normals : access openGL.Normals; Faces : access wavefront.Faces; end record; function to_Model (model_Path : in String) return wavefront.Model; procedure write (the_Model : in wavefront.Model; to_File : in String); ----------- -- Utility -- function to_Vector_3 (Self : in String) return Vector_3; function to_Coordinate (Self : in String) return Coordinate_2D; function to_Text (Self : in String) return Text; end openGL.IO.wavefront;
25.350649
88
0.58043
8bf3c775bec5113969c4f1a196e897d309497bc0
141,847
adb
Ada
Vivado_HLS_Tutorial/Design_Analysis/lab1/dct_prj/solution4/.autopilot/db/dct_read_data.bind.adb
williambong/Vivado
68efafbc44b65c0bb047dbafc0ff7f1b56ee36bb
[ "MIT" ]
null
null
null
Vivado_HLS_Tutorial/Design_Analysis/lab1/dct_prj/solution4/.autopilot/db/dct_read_data.bind.adb
williambong/Vivado
68efafbc44b65c0bb047dbafc0ff7f1b56ee36bb
[ "MIT" ]
null
null
null
Vivado_HLS_Tutorial/Design_Analysis/lab1/dct_prj/solution4/.autopilot/db/dct_read_data.bind.adb
williambong/Vivado
68efafbc44b65c0bb047dbafc0ff7f1b56ee36bb
[ "MIT" ]
null
null
null
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> <!DOCTYPE boost_serialization> <boost_serialization signature="serialization::archive" version="11"> <syndb class_id="0" tracking_level="0" version="0"> <userIPLatency>-1</userIPLatency> <userIPName></userIPName> <cdfg class_id="1" tracking_level="1" version="0" object_id="_0"> <name>dct_read_data</name> <ret_bitwidth>0</ret_bitwidth> <ports class_id="2" tracking_level="0" version="0"> <count>9</count> <item_version>0</item_version> <item class_id="3" tracking_level="1" version="0" object_id="_1"> <Value class_id="4" tracking_level="0" version="0"> <Obj class_id="5" tracking_level="0" version="0"> <type>1</type> <id>1</id> <name>input_r</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo class_id="6" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>input</originalName> <rtlName></rtlName> <coreName>RAM</coreName> </Obj> <bitwidth>16</bitwidth> </Value> <direction>0</direction> <if_type>1</if_type> <array_size>64</array_size> <bit_vecs class_id="7" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_2"> <Value> <Obj> <type>1</type> <id>2</id> <name>buf_0</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>buf[0]</originalName> <rtlName></rtlName> <coreName>RAM</coreName> </Obj> <bitwidth>16</bitwidth> </Value> <direction>1</direction> <if_type>1</if_type> <array_size>8</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_3"> <Value> <Obj> <type>1</type> <id>3</id> <name>buf_1</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>buf[1]</originalName> <rtlName></rtlName> <coreName>RAM</coreName> </Obj> <bitwidth>16</bitwidth> </Value> <direction>1</direction> <if_type>1</if_type> <array_size>8</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_4"> <Value> <Obj> <type>1</type> <id>4</id> <name>buf_2</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>buf[2]</originalName> <rtlName></rtlName> <coreName>RAM</coreName> </Obj> <bitwidth>16</bitwidth> </Value> <direction>1</direction> <if_type>1</if_type> <array_size>8</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_5"> <Value> <Obj> <type>1</type> <id>5</id> <name>buf_3</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>buf[3]</originalName> <rtlName></rtlName> <coreName>RAM</coreName> </Obj> <bitwidth>16</bitwidth> </Value> <direction>1</direction> <if_type>1</if_type> <array_size>8</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_6"> <Value> <Obj> <type>1</type> <id>6</id> <name>buf_4</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>buf[4]</originalName> <rtlName></rtlName> <coreName>RAM</coreName> </Obj> <bitwidth>16</bitwidth> </Value> <direction>1</direction> <if_type>1</if_type> <array_size>8</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_7"> <Value> <Obj> <type>1</type> <id>7</id> <name>buf_5</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>buf[5]</originalName> <rtlName></rtlName> <coreName>RAM</coreName> </Obj> <bitwidth>16</bitwidth> </Value> <direction>1</direction> <if_type>1</if_type> <array_size>8</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_8"> <Value> <Obj> <type>1</type> <id>8</id> <name>buf_6</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>buf[6]</originalName> <rtlName></rtlName> <coreName>RAM</coreName> </Obj> <bitwidth>16</bitwidth> </Value> <direction>1</direction> <if_type>1</if_type> <array_size>8</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_9"> <Value> <Obj> <type>1</type> <id>9</id> <name>buf_7</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>buf[7]</originalName> <rtlName></rtlName> <coreName>RAM</coreName> </Obj> <bitwidth>16</bitwidth> </Value> <direction>1</direction> <if_type>1</if_type> <array_size>8</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> </ports> <nodes class_id="8" tracking_level="0" version="0"> <count>48</count> <item_version>0</item_version> <item class_id="9" tracking_level="1" version="0" object_id="_10"> <Value> <Obj> <type>0</type> <id>10</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>103</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item class_id="10" tracking_level="0" version="0"> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second class_id="11" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="12" tracking_level="0" version="0"> <first class_id="13" tracking_level="0" version="0"> <first>dct.cpp</first> <second>read_data</second> </first> <second>103</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>77</item> </oprand_edges> <opcode>br</opcode> </item> <item class_id_reference="9" object_id="_11"> <Value> <Obj> <type>0</type> <id>12</id> <name>indvar_flatten</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>7</bitwidth> </Value> <oprand_edges> <count>4</count> <item_version>0</item_version> <item>79</item> <item>80</item> <item>81</item> <item>82</item> </oprand_edges> <opcode>phi</opcode> </item> <item class_id_reference="9" object_id="_12"> <Value> <Obj> <type>0</type> <id>13</id> <name>r</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>105</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>105</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>4</bitwidth> </Value> <oprand_edges> <count>4</count> <item_version>0</item_version> <item>84</item> <item>85</item> <item>86</item> <item>87</item> </oprand_edges> <opcode>phi</opcode> </item> <item class_id_reference="9" object_id="_13"> <Value> <Obj> <type>0</type> <id>14</id> <name>c</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>c</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>4</bitwidth> </Value> <oprand_edges> <count>4</count> <item_version>0</item_version> <item>88</item> <item>89</item> <item>90</item> <item>91</item> </oprand_edges> <opcode>phi</opcode> </item> <item class_id_reference="9" object_id="_14"> <Value> <Obj> <type>0</type> <id>15</id> <name>exitcond_flatten</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>1</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>92</item> <item>94</item> </oprand_edges> <opcode>icmp</opcode> </item> <item class_id_reference="9" object_id="_15"> <Value> <Obj> <type>0</type> <id>16</id> <name>indvar_flatten_next</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>7</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>95</item> <item>97</item> </oprand_edges> <opcode>add</opcode> </item> <item class_id_reference="9" object_id="_16"> <Value> <Obj> <type>0</type> <id>17</id> <name></name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>98</item> <item>99</item> <item>100</item> </oprand_edges> <opcode>br</opcode> </item> <item class_id_reference="9" object_id="_17"> <Value> <Obj> <type>0</type> <id>21</id> <name>exitcond</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>105</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>105</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>1</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>105</item> <item>107</item> </oprand_edges> <opcode>icmp</opcode> </item> <item class_id_reference="9" object_id="_18"> <Value> <Obj> <type>0</type> <id>22</id> <name>c_mid2</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>105</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>105</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>4</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>108</item> <item>109</item> <item>110</item> </oprand_edges> <opcode>select</opcode> </item> <item class_id_reference="9" object_id="_19"> <Value> <Obj> <type>0</type> <id>23</id> <name>r_s</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>103</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>103</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>4</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>111</item> <item>112</item> </oprand_edges> <opcode>add</opcode> </item> <item class_id_reference="9" object_id="_20"> <Value> <Obj> <type>0</type> <id>24</id> <name>r_mid2</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>105</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>105</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>4</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>113</item> <item>114</item> <item>115</item> </oprand_edges> <opcode>select</opcode> </item> <item class_id_reference="9" object_id="_21"> <Value> <Obj> <type>0</type> <id>25</id> <name>tmp_2</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>105</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>105</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>116</item> </oprand_edges> <opcode>trunc</opcode> </item> <item class_id_reference="9" object_id="_22"> <Value> <Obj> <type>0</type> <id>26</id> <name>tmp</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>6</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>118</item> <item>119</item> <item>121</item> </oprand_edges> <opcode>bitconcatenate</opcode> </item> <item class_id_reference="9" object_id="_23"> <Value> <Obj> <type>0</type> <id>27</id> <name>tmp_s</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>64</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>122</item> </oprand_edges> <opcode>zext</opcode> </item> <item class_id_reference="9" object_id="_24"> <Value> <Obj> <type>0</type> <id>28</id> <name>c_cast2</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>105</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>105</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>6</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>123</item> </oprand_edges> <opcode>zext</opcode> </item> <item class_id_reference="9" object_id="_25"> <Value> <Obj> <type>0</type> <id>32</id> <name>tmp_5</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>6</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>124</item> <item>125</item> </oprand_edges> <opcode>add</opcode> </item> <item class_id_reference="9" object_id="_26"> <Value> <Obj> <type>0</type> <id>33</id> <name>tmp_6</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>64</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>126</item> </oprand_edges> <opcode>zext</opcode> </item> <item class_id_reference="9" object_id="_27"> <Value> <Obj> <type>0</type> <id>34</id> <name>input_addr</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>6</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>127</item> <item>129</item> <item>130</item> </oprand_edges> <opcode>getelementptr</opcode> </item> <item class_id_reference="9" object_id="_28"> <Value> <Obj> <type>0</type> <id>35</id> <name>input_load</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>131</item> </oprand_edges> <opcode>load</opcode> </item> <item class_id_reference="9" object_id="_29"> <Value> <Obj> <type>0</type> <id>36</id> <name>tmp_3</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>105</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>105</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>132</item> </oprand_edges> <opcode>trunc</opcode> </item> <item class_id_reference="9" object_id="_30"> <Value> <Obj> <type>0</type> <id>37</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>16</count> <item_version>0</item_version> <item>133</item> <item>134</item> <item>135</item> <item>136</item> <item>138</item> <item>139</item> <item>141</item> <item>142</item> <item>144</item> <item>145</item> <item>147</item> <item>148</item> <item>150</item> <item>151</item> <item>153</item> <item>154</item> </oprand_edges> <opcode>switch</opcode> </item> <item class_id_reference="9" object_id="_31"> <Value> <Obj> <type>0</type> <id>39</id> <name>buf_6_addr</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>191</item> <item>192</item> <item>193</item> </oprand_edges> <opcode>getelementptr</opcode> </item> <item class_id_reference="9" object_id="_32"> <Value> <Obj> <type>0</type> <id>40</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>194</item> <item>195</item> </oprand_edges> <opcode>store</opcode> </item> <item class_id_reference="9" object_id="_33"> <Value> <Obj> <type>0</type> <id>41</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>196</item> </oprand_edges> <opcode>br</opcode> </item> <item class_id_reference="9" object_id="_34"> <Value> <Obj> <type>0</type> <id>43</id> <name>buf_5_addr</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>185</item> <item>186</item> <item>187</item> </oprand_edges> <opcode>getelementptr</opcode> </item> <item class_id_reference="9" object_id="_35"> <Value> <Obj> <type>0</type> <id>44</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>188</item> <item>189</item> </oprand_edges> <opcode>store</opcode> </item> <item class_id_reference="9" object_id="_36"> <Value> <Obj> <type>0</type> <id>45</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>190</item> </oprand_edges> <opcode>br</opcode> </item> <item class_id_reference="9" object_id="_37"> <Value> <Obj> <type>0</type> <id>47</id> <name>buf_4_addr</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>179</item> <item>180</item> <item>181</item> </oprand_edges> <opcode>getelementptr</opcode> </item> <item class_id_reference="9" object_id="_38"> <Value> <Obj> <type>0</type> <id>48</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>182</item> <item>183</item> </oprand_edges> <opcode>store</opcode> </item> <item class_id_reference="9" object_id="_39"> <Value> <Obj> <type>0</type> <id>49</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>184</item> </oprand_edges> <opcode>br</opcode> </item> <item class_id_reference="9" object_id="_40"> <Value> <Obj> <type>0</type> <id>51</id> <name>buf_3_addr</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>173</item> <item>174</item> <item>175</item> </oprand_edges> <opcode>getelementptr</opcode> </item> <item class_id_reference="9" object_id="_41"> <Value> <Obj> <type>0</type> <id>52</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>176</item> <item>177</item> </oprand_edges> <opcode>store</opcode> </item> <item class_id_reference="9" object_id="_42"> <Value> <Obj> <type>0</type> <id>53</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>178</item> </oprand_edges> <opcode>br</opcode> </item> <item class_id_reference="9" object_id="_43"> <Value> <Obj> <type>0</type> <id>55</id> <name>buf_2_addr</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>167</item> <item>168</item> <item>169</item> </oprand_edges> <opcode>getelementptr</opcode> </item> <item class_id_reference="9" object_id="_44"> <Value> <Obj> <type>0</type> <id>56</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>170</item> <item>171</item> </oprand_edges> <opcode>store</opcode> </item> <item class_id_reference="9" object_id="_45"> <Value> <Obj> <type>0</type> <id>57</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>172</item> </oprand_edges> <opcode>br</opcode> </item> <item class_id_reference="9" object_id="_46"> <Value> <Obj> <type>0</type> <id>59</id> <name>buf_1_addr</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>161</item> <item>162</item> <item>163</item> </oprand_edges> <opcode>getelementptr</opcode> </item> <item class_id_reference="9" object_id="_47"> <Value> <Obj> <type>0</type> <id>60</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>164</item> <item>165</item> </oprand_edges> <opcode>store</opcode> </item> <item class_id_reference="9" object_id="_48"> <Value> <Obj> <type>0</type> <id>61</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>166</item> </oprand_edges> <opcode>br</opcode> </item> <item class_id_reference="9" object_id="_49"> <Value> <Obj> <type>0</type> <id>63</id> <name>buf_0_addr</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>155</item> <item>156</item> <item>157</item> </oprand_edges> <opcode>getelementptr</opcode> </item> <item class_id_reference="9" object_id="_50"> <Value> <Obj> <type>0</type> <id>64</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>158</item> <item>159</item> </oprand_edges> <opcode>store</opcode> </item> <item class_id_reference="9" object_id="_51"> <Value> <Obj> <type>0</type> <id>65</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>160</item> </oprand_edges> <opcode>br</opcode> </item> <item class_id_reference="9" object_id="_52"> <Value> <Obj> <type>0</type> <id>67</id> <name>buf_7_addr</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>197</item> <item>198</item> <item>199</item> </oprand_edges> <opcode>getelementptr</opcode> </item> <item class_id_reference="9" object_id="_53"> <Value> <Obj> <type>0</type> <id>68</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>200</item> <item>201</item> </oprand_edges> <opcode>store</opcode> </item> <item class_id_reference="9" object_id="_54"> <Value> <Obj> <type>0</type> <id>69</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>106</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>106</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>202</item> </oprand_edges> <opcode>br</opcode> </item> <item class_id_reference="9" object_id="_55"> <Value> <Obj> <type>0</type> <id>72</id> <name>c_1</name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>105</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>105</second> </item> </second> </item> </inlineStackInfo> <originalName>c</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>4</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>101</item> <item>103</item> </oprand_edges> <opcode>add</opcode> </item> <item class_id_reference="9" object_id="_56"> <Value> <Obj> <type>0</type> <id>73</id> <name></name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>104</item> </oprand_edges> <opcode>br</opcode> </item> <item class_id_reference="9" object_id="_57"> <Value> <Obj> <type>0</type> <id>75</id> <name></name> <fileName>dct.cpp</fileName> <fileDirectory>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</fileDirectory> <lineNumber>108</lineNumber> <contextFuncName>read_data</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>d:/opt/source/Vivado/Vivado_HLS_Tutorial/Design_Analysis/lab1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>dct.cpp</first> <second>read_data</second> </first> <second>108</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>0</count> <item_version>0</item_version> </oprand_edges> <opcode>ret</opcode> </item> </nodes> <consts class_id="15" tracking_level="0" version="0"> <count>14</count> <item_version>0</item_version> <item class_id="16" tracking_level="1" version="0" object_id="_58"> <Value> <Obj> <type>2</type> <id>78</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>7</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_59"> <Value> <Obj> <type>2</type> <id>83</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>4</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_60"> <Value> <Obj> <type>2</type> <id>93</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>7</bitwidth> </Value> <const_type>0</const_type> <content>64</content> </item> <item class_id_reference="16" object_id="_61"> <Value> <Obj> <type>2</type> <id>96</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>7</bitwidth> </Value> <const_type>0</const_type> <content>1</content> </item> <item class_id_reference="16" object_id="_62"> <Value> <Obj> <type>2</type> <id>102</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>4</bitwidth> </Value> <const_type>0</const_type> <content>1</content> </item> <item class_id_reference="16" object_id="_63"> <Value> <Obj> <type>2</type> <id>106</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>4</bitwidth> </Value> <const_type>0</const_type> <content>8</content> </item> <item class_id_reference="16" object_id="_64"> <Value> <Obj> <type>2</type> <id>120</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_65"> <Value> <Obj> <type>2</type> <id>128</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>64</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_66"> <Value> <Obj> <type>2</type> <id>137</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <const_type>0</const_type> <content>1</content> </item> <item class_id_reference="16" object_id="_67"> <Value> <Obj> <type>2</type> <id>140</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <const_type>0</const_type> <content>2</content> </item> <item class_id_reference="16" object_id="_68"> <Value> <Obj> <type>2</type> <id>143</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <const_type>0</const_type> <content>3</content> </item> <item class_id_reference="16" object_id="_69"> <Value> <Obj> <type>2</type> <id>146</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <const_type>0</const_type> <content>4</content> </item> <item class_id_reference="16" object_id="_70"> <Value> <Obj> <type>2</type> <id>149</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <const_type>0</const_type> <content>5</content> </item> <item class_id_reference="16" object_id="_71"> <Value> <Obj> <type>2</type> <id>152</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>3</bitwidth> </Value> <const_type>0</const_type> <content>6</content> </item> </consts> <blocks class_id="17" tracking_level="0" version="0"> <count>13</count> <item_version>0</item_version> <item class_id="18" tracking_level="1" version="0" object_id="_72"> <Obj> <type>3</type> <id>11</id> <name></name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>1</count> <item_version>0</item_version> <item>10</item> </node_objs> </item> <item class_id_reference="18" object_id="_73"> <Obj> <type>3</type> <id>18</id> <name></name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>6</count> <item_version>0</item_version> <item>12</item> <item>13</item> <item>14</item> <item>15</item> <item>16</item> <item>17</item> </node_objs> </item> <item class_id_reference="18" object_id="_74"> <Obj> <type>3</type> <id>38</id> <name>.reset</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>14</count> <item_version>0</item_version> <item>21</item> <item>22</item> <item>23</item> <item>24</item> <item>25</item> <item>26</item> <item>27</item> <item>28</item> <item>32</item> <item>33</item> <item>34</item> <item>35</item> <item>36</item> <item>37</item> </node_objs> </item> <item class_id_reference="18" object_id="_75"> <Obj> <type>3</type> <id>42</id> <name>branch6</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>3</count> <item_version>0</item_version> <item>39</item> <item>40</item> <item>41</item> </node_objs> </item> <item class_id_reference="18" object_id="_76"> <Obj> <type>3</type> <id>46</id> <name>branch5</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>3</count> <item_version>0</item_version> <item>43</item> <item>44</item> <item>45</item> </node_objs> </item> <item class_id_reference="18" object_id="_77"> <Obj> <type>3</type> <id>50</id> <name>branch4</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>3</count> <item_version>0</item_version> <item>47</item> <item>48</item> <item>49</item> </node_objs> </item> <item class_id_reference="18" object_id="_78"> <Obj> <type>3</type> <id>54</id> <name>branch3</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>3</count> <item_version>0</item_version> <item>51</item> <item>52</item> <item>53</item> </node_objs> </item> <item class_id_reference="18" object_id="_79"> <Obj> <type>3</type> <id>58</id> <name>branch2</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>3</count> <item_version>0</item_version> <item>55</item> <item>56</item> <item>57</item> </node_objs> </item> <item class_id_reference="18" object_id="_80"> <Obj> <type>3</type> <id>62</id> <name>branch1</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>3</count> <item_version>0</item_version> <item>59</item> <item>60</item> <item>61</item> </node_objs> </item> <item class_id_reference="18" object_id="_81"> <Obj> <type>3</type> <id>66</id> <name>branch0</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>3</count> <item_version>0</item_version> <item>63</item> <item>64</item> <item>65</item> </node_objs> </item> <item class_id_reference="18" object_id="_82"> <Obj> <type>3</type> <id>70</id> <name>branch7</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>3</count> <item_version>0</item_version> <item>67</item> <item>68</item> <item>69</item> </node_objs> </item> <item class_id_reference="18" object_id="_83"> <Obj> <type>3</type> <id>74</id> <name>ifBlock</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>2</count> <item_version>0</item_version> <item>72</item> <item>73</item> </node_objs> </item> <item class_id_reference="18" object_id="_84"> <Obj> <type>3</type> <id>76</id> <name></name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>1</count> <item_version>0</item_version> <item>75</item> </node_objs> </item> </blocks> <edges class_id="19" tracking_level="0" version="0"> <count>130</count> <item_version>0</item_version> <item class_id="20" tracking_level="1" version="0" object_id="_85"> <id>77</id> <edge_type>2</edge_type> <source_obj>18</source_obj> <sink_obj>10</sink_obj> </item> <item class_id_reference="20" object_id="_86"> <id>79</id> <edge_type>1</edge_type> <source_obj>78</source_obj> <sink_obj>12</sink_obj> </item> <item class_id_reference="20" object_id="_87"> <id>80</id> <edge_type>2</edge_type> <source_obj>11</source_obj> <sink_obj>12</sink_obj> </item> <item class_id_reference="20" object_id="_88"> <id>81</id> <edge_type>1</edge_type> <source_obj>16</source_obj> <sink_obj>12</sink_obj> </item> <item class_id_reference="20" object_id="_89"> <id>82</id> <edge_type>2</edge_type> <source_obj>74</source_obj> <sink_obj>12</sink_obj> </item> <item class_id_reference="20" object_id="_90"> <id>84</id> <edge_type>1</edge_type> <source_obj>83</source_obj> <sink_obj>13</sink_obj> </item> <item class_id_reference="20" object_id="_91"> <id>85</id> <edge_type>2</edge_type> <source_obj>11</source_obj> <sink_obj>13</sink_obj> </item> <item class_id_reference="20" object_id="_92"> <id>86</id> <edge_type>1</edge_type> <source_obj>24</source_obj> <sink_obj>13</sink_obj> </item> <item class_id_reference="20" object_id="_93"> <id>87</id> <edge_type>2</edge_type> <source_obj>74</source_obj> <sink_obj>13</sink_obj> </item> <item class_id_reference="20" object_id="_94"> <id>88</id> <edge_type>1</edge_type> <source_obj>83</source_obj> <sink_obj>14</sink_obj> </item> <item class_id_reference="20" object_id="_95"> <id>89</id> <edge_type>2</edge_type> <source_obj>11</source_obj> <sink_obj>14</sink_obj> </item> <item class_id_reference="20" object_id="_96"> <id>90</id> <edge_type>1</edge_type> <source_obj>72</source_obj> <sink_obj>14</sink_obj> </item> <item class_id_reference="20" object_id="_97"> <id>91</id> <edge_type>2</edge_type> <source_obj>74</source_obj> <sink_obj>14</sink_obj> </item> <item class_id_reference="20" object_id="_98"> <id>92</id> <edge_type>1</edge_type> <source_obj>12</source_obj> <sink_obj>15</sink_obj> </item> <item class_id_reference="20" object_id="_99"> <id>94</id> <edge_type>1</edge_type> <source_obj>93</source_obj> <sink_obj>15</sink_obj> </item> <item class_id_reference="20" object_id="_100"> <id>95</id> <edge_type>1</edge_type> <source_obj>12</source_obj> <sink_obj>16</sink_obj> </item> <item class_id_reference="20" object_id="_101"> <id>97</id> <edge_type>1</edge_type> <source_obj>96</source_obj> <sink_obj>16</sink_obj> </item> <item class_id_reference="20" object_id="_102"> <id>98</id> <edge_type>1</edge_type> <source_obj>15</source_obj> <sink_obj>17</sink_obj> </item> <item class_id_reference="20" object_id="_103"> <id>99</id> <edge_type>2</edge_type> <source_obj>38</source_obj> <sink_obj>17</sink_obj> </item> <item class_id_reference="20" object_id="_104"> <id>100</id> <edge_type>2</edge_type> <source_obj>76</source_obj> <sink_obj>17</sink_obj> </item> <item class_id_reference="20" object_id="_105"> <id>101</id> <edge_type>1</edge_type> <source_obj>22</source_obj> <sink_obj>72</sink_obj> </item> <item class_id_reference="20" object_id="_106"> <id>103</id> <edge_type>1</edge_type> <source_obj>102</source_obj> <sink_obj>72</sink_obj> </item> <item class_id_reference="20" object_id="_107"> <id>104</id> <edge_type>2</edge_type> <source_obj>18</source_obj> <sink_obj>73</sink_obj> </item> <item class_id_reference="20" object_id="_108"> <id>105</id> <edge_type>1</edge_type> <source_obj>14</source_obj> <sink_obj>21</sink_obj> </item> <item class_id_reference="20" object_id="_109"> <id>107</id> <edge_type>1</edge_type> <source_obj>106</source_obj> <sink_obj>21</sink_obj> </item> <item class_id_reference="20" object_id="_110"> <id>108</id> <edge_type>1</edge_type> <source_obj>21</source_obj> <sink_obj>22</sink_obj> </item> <item class_id_reference="20" object_id="_111"> <id>109</id> <edge_type>1</edge_type> <source_obj>83</source_obj> <sink_obj>22</sink_obj> </item> <item class_id_reference="20" object_id="_112"> <id>110</id> <edge_type>1</edge_type> <source_obj>14</source_obj> <sink_obj>22</sink_obj> </item> <item class_id_reference="20" object_id="_113"> <id>111</id> <edge_type>1</edge_type> <source_obj>102</source_obj> <sink_obj>23</sink_obj> </item> <item class_id_reference="20" object_id="_114"> <id>112</id> <edge_type>1</edge_type> <source_obj>13</source_obj> <sink_obj>23</sink_obj> </item> <item class_id_reference="20" object_id="_115"> <id>113</id> <edge_type>1</edge_type> <source_obj>21</source_obj> <sink_obj>24</sink_obj> </item> <item class_id_reference="20" object_id="_116"> <id>114</id> <edge_type>1</edge_type> <source_obj>23</source_obj> <sink_obj>24</sink_obj> </item> <item class_id_reference="20" object_id="_117"> <id>115</id> <edge_type>1</edge_type> <source_obj>13</source_obj> <sink_obj>24</sink_obj> </item> <item class_id_reference="20" object_id="_118"> <id>116</id> <edge_type>1</edge_type> <source_obj>24</source_obj> <sink_obj>25</sink_obj> </item> <item class_id_reference="20" object_id="_119"> <id>119</id> <edge_type>1</edge_type> <source_obj>25</source_obj> <sink_obj>26</sink_obj> </item> <item class_id_reference="20" object_id="_120"> <id>121</id> <edge_type>1</edge_type> <source_obj>120</source_obj> <sink_obj>26</sink_obj> </item> <item class_id_reference="20" object_id="_121"> <id>122</id> <edge_type>1</edge_type> <source_obj>24</source_obj> <sink_obj>27</sink_obj> </item> <item class_id_reference="20" object_id="_122"> <id>123</id> <edge_type>1</edge_type> <source_obj>22</source_obj> <sink_obj>28</sink_obj> </item> <item class_id_reference="20" object_id="_123"> <id>124</id> <edge_type>1</edge_type> <source_obj>28</source_obj> <sink_obj>32</sink_obj> </item> <item class_id_reference="20" object_id="_124"> <id>125</id> <edge_type>1</edge_type> <source_obj>26</source_obj> <sink_obj>32</sink_obj> </item> <item class_id_reference="20" object_id="_125"> <id>126</id> <edge_type>1</edge_type> <source_obj>32</source_obj> <sink_obj>33</sink_obj> </item> <item class_id_reference="20" object_id="_126"> <id>127</id> <edge_type>1</edge_type> <source_obj>1</source_obj> <sink_obj>34</sink_obj> </item> <item class_id_reference="20" object_id="_127"> <id>129</id> <edge_type>1</edge_type> <source_obj>128</source_obj> <sink_obj>34</sink_obj> </item> <item class_id_reference="20" object_id="_128"> <id>130</id> <edge_type>1</edge_type> <source_obj>33</source_obj> <sink_obj>34</sink_obj> </item> <item class_id_reference="20" object_id="_129"> <id>131</id> <edge_type>1</edge_type> <source_obj>34</source_obj> <sink_obj>35</sink_obj> </item> <item class_id_reference="20" object_id="_130"> <id>132</id> <edge_type>1</edge_type> <source_obj>22</source_obj> <sink_obj>36</sink_obj> </item> <item class_id_reference="20" object_id="_131"> <id>133</id> <edge_type>1</edge_type> <source_obj>36</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_132"> <id>134</id> <edge_type>2</edge_type> <source_obj>70</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_133"> <id>135</id> <edge_type>1</edge_type> <source_obj>120</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_134"> <id>136</id> <edge_type>2</edge_type> <source_obj>66</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_135"> <id>138</id> <edge_type>1</edge_type> <source_obj>137</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_136"> <id>139</id> <edge_type>2</edge_type> <source_obj>62</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_137"> <id>141</id> <edge_type>1</edge_type> <source_obj>140</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_138"> <id>142</id> <edge_type>2</edge_type> <source_obj>58</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_139"> <id>144</id> <edge_type>1</edge_type> <source_obj>143</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_140"> <id>145</id> <edge_type>2</edge_type> <source_obj>54</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_141"> <id>147</id> <edge_type>1</edge_type> <source_obj>146</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_142"> <id>148</id> <edge_type>2</edge_type> <source_obj>50</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_143"> <id>150</id> <edge_type>1</edge_type> <source_obj>149</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_144"> <id>151</id> <edge_type>2</edge_type> <source_obj>46</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_145"> <id>153</id> <edge_type>1</edge_type> <source_obj>152</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_146"> <id>154</id> <edge_type>2</edge_type> <source_obj>42</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_147"> <id>155</id> <edge_type>1</edge_type> <source_obj>2</source_obj> <sink_obj>63</sink_obj> </item> <item class_id_reference="20" object_id="_148"> <id>156</id> <edge_type>1</edge_type> <source_obj>128</source_obj> <sink_obj>63</sink_obj> </item> <item class_id_reference="20" object_id="_149"> <id>157</id> <edge_type>1</edge_type> <source_obj>27</source_obj> <sink_obj>63</sink_obj> </item> <item class_id_reference="20" object_id="_150"> <id>158</id> <edge_type>1</edge_type> <source_obj>35</source_obj> <sink_obj>64</sink_obj> </item> <item class_id_reference="20" object_id="_151"> <id>159</id> <edge_type>1</edge_type> <source_obj>63</source_obj> <sink_obj>64</sink_obj> </item> <item class_id_reference="20" object_id="_152"> <id>160</id> <edge_type>2</edge_type> <source_obj>74</source_obj> <sink_obj>65</sink_obj> </item> <item class_id_reference="20" object_id="_153"> <id>161</id> <edge_type>1</edge_type> <source_obj>3</source_obj> <sink_obj>59</sink_obj> </item> <item class_id_reference="20" object_id="_154"> <id>162</id> <edge_type>1</edge_type> <source_obj>128</source_obj> <sink_obj>59</sink_obj> </item> <item class_id_reference="20" object_id="_155"> <id>163</id> <edge_type>1</edge_type> <source_obj>27</source_obj> <sink_obj>59</sink_obj> </item> <item class_id_reference="20" object_id="_156"> <id>164</id> <edge_type>1</edge_type> <source_obj>35</source_obj> <sink_obj>60</sink_obj> </item> <item class_id_reference="20" object_id="_157"> <id>165</id> <edge_type>1</edge_type> <source_obj>59</source_obj> <sink_obj>60</sink_obj> </item> <item class_id_reference="20" object_id="_158"> <id>166</id> <edge_type>2</edge_type> <source_obj>74</source_obj> <sink_obj>61</sink_obj> </item> <item class_id_reference="20" object_id="_159"> <id>167</id> <edge_type>1</edge_type> <source_obj>4</source_obj> <sink_obj>55</sink_obj> </item> <item class_id_reference="20" object_id="_160"> <id>168</id> <edge_type>1</edge_type> <source_obj>128</source_obj> <sink_obj>55</sink_obj> </item> <item class_id_reference="20" object_id="_161"> <id>169</id> <edge_type>1</edge_type> <source_obj>27</source_obj> <sink_obj>55</sink_obj> </item> <item class_id_reference="20" object_id="_162"> <id>170</id> <edge_type>1</edge_type> <source_obj>35</source_obj> <sink_obj>56</sink_obj> </item> <item class_id_reference="20" object_id="_163"> <id>171</id> <edge_type>1</edge_type> <source_obj>55</source_obj> <sink_obj>56</sink_obj> </item> <item class_id_reference="20" object_id="_164"> <id>172</id> <edge_type>2</edge_type> <source_obj>74</source_obj> <sink_obj>57</sink_obj> </item> <item class_id_reference="20" object_id="_165"> <id>173</id> <edge_type>1</edge_type> <source_obj>5</source_obj> <sink_obj>51</sink_obj> </item> <item class_id_reference="20" object_id="_166"> <id>174</id> <edge_type>1</edge_type> <source_obj>128</source_obj> <sink_obj>51</sink_obj> </item> <item class_id_reference="20" object_id="_167"> <id>175</id> <edge_type>1</edge_type> <source_obj>27</source_obj> <sink_obj>51</sink_obj> </item> <item class_id_reference="20" object_id="_168"> <id>176</id> <edge_type>1</edge_type> <source_obj>35</source_obj> <sink_obj>52</sink_obj> </item> <item class_id_reference="20" object_id="_169"> <id>177</id> <edge_type>1</edge_type> <source_obj>51</source_obj> <sink_obj>52</sink_obj> </item> <item class_id_reference="20" object_id="_170"> <id>178</id> <edge_type>2</edge_type> <source_obj>74</source_obj> <sink_obj>53</sink_obj> </item> <item class_id_reference="20" object_id="_171"> <id>179</id> <edge_type>1</edge_type> <source_obj>6</source_obj> <sink_obj>47</sink_obj> </item> <item class_id_reference="20" object_id="_172"> <id>180</id> <edge_type>1</edge_type> <source_obj>128</source_obj> <sink_obj>47</sink_obj> </item> <item class_id_reference="20" object_id="_173"> <id>181</id> <edge_type>1</edge_type> <source_obj>27</source_obj> <sink_obj>47</sink_obj> </item> <item class_id_reference="20" object_id="_174"> <id>182</id> <edge_type>1</edge_type> <source_obj>35</source_obj> <sink_obj>48</sink_obj> </item> <item class_id_reference="20" object_id="_175"> <id>183</id> <edge_type>1</edge_type> <source_obj>47</source_obj> <sink_obj>48</sink_obj> </item> <item class_id_reference="20" object_id="_176"> <id>184</id> <edge_type>2</edge_type> <source_obj>74</source_obj> <sink_obj>49</sink_obj> </item> <item class_id_reference="20" object_id="_177"> <id>185</id> <edge_type>1</edge_type> <source_obj>7</source_obj> <sink_obj>43</sink_obj> </item> <item class_id_reference="20" object_id="_178"> <id>186</id> <edge_type>1</edge_type> <source_obj>128</source_obj> <sink_obj>43</sink_obj> </item> <item class_id_reference="20" object_id="_179"> <id>187</id> <edge_type>1</edge_type> <source_obj>27</source_obj> <sink_obj>43</sink_obj> </item> <item class_id_reference="20" object_id="_180"> <id>188</id> <edge_type>1</edge_type> <source_obj>35</source_obj> <sink_obj>44</sink_obj> </item> <item class_id_reference="20" object_id="_181"> <id>189</id> <edge_type>1</edge_type> <source_obj>43</source_obj> <sink_obj>44</sink_obj> </item> <item class_id_reference="20" object_id="_182"> <id>190</id> <edge_type>2</edge_type> <source_obj>74</source_obj> <sink_obj>45</sink_obj> </item> <item class_id_reference="20" object_id="_183"> <id>191</id> <edge_type>1</edge_type> <source_obj>8</source_obj> <sink_obj>39</sink_obj> </item> <item class_id_reference="20" object_id="_184"> <id>192</id> <edge_type>1</edge_type> <source_obj>128</source_obj> <sink_obj>39</sink_obj> </item> <item class_id_reference="20" object_id="_185"> <id>193</id> <edge_type>1</edge_type> <source_obj>27</source_obj> <sink_obj>39</sink_obj> </item> <item class_id_reference="20" object_id="_186"> <id>194</id> <edge_type>1</edge_type> <source_obj>35</source_obj> <sink_obj>40</sink_obj> </item> <item class_id_reference="20" object_id="_187"> <id>195</id> <edge_type>1</edge_type> <source_obj>39</source_obj> <sink_obj>40</sink_obj> </item> <item class_id_reference="20" object_id="_188"> <id>196</id> <edge_type>2</edge_type> <source_obj>74</source_obj> <sink_obj>41</sink_obj> </item> <item class_id_reference="20" object_id="_189"> <id>197</id> <edge_type>1</edge_type> <source_obj>9</source_obj> <sink_obj>67</sink_obj> </item> <item class_id_reference="20" object_id="_190"> <id>198</id> <edge_type>1</edge_type> <source_obj>128</source_obj> <sink_obj>67</sink_obj> </item> <item class_id_reference="20" object_id="_191"> <id>199</id> <edge_type>1</edge_type> <source_obj>27</source_obj> <sink_obj>67</sink_obj> </item> <item class_id_reference="20" object_id="_192"> <id>200</id> <edge_type>1</edge_type> <source_obj>35</source_obj> <sink_obj>68</sink_obj> </item> <item class_id_reference="20" object_id="_193"> <id>201</id> <edge_type>1</edge_type> <source_obj>67</source_obj> <sink_obj>68</sink_obj> </item> <item class_id_reference="20" object_id="_194"> <id>202</id> <edge_type>2</edge_type> <source_obj>74</source_obj> <sink_obj>69</sink_obj> </item> <item class_id_reference="20" object_id="_195"> <id>233</id> <edge_type>2</edge_type> <source_obj>11</source_obj> <sink_obj>18</sink_obj> </item> <item class_id_reference="20" object_id="_196"> <id>234</id> <edge_type>2</edge_type> <source_obj>18</source_obj> <sink_obj>76</sink_obj> </item> <item class_id_reference="20" object_id="_197"> <id>235</id> <edge_type>2</edge_type> <source_obj>18</source_obj> <sink_obj>38</sink_obj> </item> <item class_id_reference="20" object_id="_198"> <id>236</id> <edge_type>2</edge_type> <source_obj>38</source_obj> <sink_obj>70</sink_obj> </item> <item class_id_reference="20" object_id="_199"> <id>237</id> <edge_type>2</edge_type> <source_obj>38</source_obj> <sink_obj>66</sink_obj> </item> <item class_id_reference="20" object_id="_200"> <id>238</id> <edge_type>2</edge_type> <source_obj>38</source_obj> <sink_obj>62</sink_obj> </item> <item class_id_reference="20" object_id="_201"> <id>239</id> <edge_type>2</edge_type> <source_obj>38</source_obj> <sink_obj>58</sink_obj> </item> <item class_id_reference="20" object_id="_202"> <id>240</id> <edge_type>2</edge_type> <source_obj>38</source_obj> <sink_obj>54</sink_obj> </item> <item class_id_reference="20" object_id="_203"> <id>241</id> <edge_type>2</edge_type> <source_obj>38</source_obj> <sink_obj>50</sink_obj> </item> <item class_id_reference="20" object_id="_204"> <id>242</id> <edge_type>2</edge_type> <source_obj>38</source_obj> <sink_obj>46</sink_obj> </item> <item class_id_reference="20" object_id="_205"> <id>243</id> <edge_type>2</edge_type> <source_obj>38</source_obj> <sink_obj>42</sink_obj> </item> <item class_id_reference="20" object_id="_206"> <id>244</id> <edge_type>2</edge_type> <source_obj>42</source_obj> <sink_obj>74</sink_obj> </item> <item class_id_reference="20" object_id="_207"> <id>245</id> <edge_type>2</edge_type> <source_obj>46</source_obj> <sink_obj>74</sink_obj> </item> <item class_id_reference="20" object_id="_208"> <id>246</id> <edge_type>2</edge_type> <source_obj>50</source_obj> <sink_obj>74</sink_obj> </item> <item class_id_reference="20" object_id="_209"> <id>247</id> <edge_type>2</edge_type> <source_obj>54</source_obj> <sink_obj>74</sink_obj> </item> <item class_id_reference="20" object_id="_210"> <id>248</id> <edge_type>2</edge_type> <source_obj>58</source_obj> <sink_obj>74</sink_obj> </item> <item class_id_reference="20" object_id="_211"> <id>249</id> <edge_type>2</edge_type> <source_obj>62</source_obj> <sink_obj>74</sink_obj> </item> <item class_id_reference="20" object_id="_212"> <id>250</id> <edge_type>2</edge_type> <source_obj>66</source_obj> <sink_obj>74</sink_obj> </item> <item class_id_reference="20" object_id="_213"> <id>251</id> <edge_type>2</edge_type> <source_obj>70</source_obj> <sink_obj>74</sink_obj> </item> <item class_id_reference="20" object_id="_214"> <id>252</id> <edge_type>2</edge_type> <source_obj>74</source_obj> <sink_obj>18</sink_obj> </item> </edges> </cdfg> <cdfg_regions class_id="21" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="22" tracking_level="1" version="0" object_id="_215"> <mId>1</mId> <mTag>dct_read_data</mTag> <mType>0</mType> <sub_regions> <count>3</count> <item_version>0</item_version> <item>2</item> <item>3</item> <item>4</item> </sub_regions> <basic_blocks> <count>0</count> <item_version>0</item_version> </basic_blocks> <mII>-1</mII> <mDepth>-1</mDepth> <mMinTripCount>-1</mMinTripCount> <mMaxTripCount>-1</mMaxTripCount> <mMinLatency>66</mMinLatency> <mMaxLatency>-1</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"></mDfPipe> </item> <item class_id_reference="22" object_id="_216"> <mId>2</mId> <mTag>Entry</mTag> <mType>0</mType> <sub_regions> <count>0</count> <item_version>0</item_version> </sub_regions> <basic_blocks> <count>1</count> <item_version>0</item_version> <item>11</item> </basic_blocks> <mII>-1</mII> <mDepth>-1</mDepth> <mMinTripCount>-1</mMinTripCount> <mMaxTripCount>-1</mMaxTripCount> <mMinLatency>0</mMinLatency> <mMaxLatency>-1</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"></mDfPipe> </item> <item class_id_reference="22" object_id="_217"> <mId>3</mId> <mTag>RD_Loop_Row_RD_Loop_Col</mTag> <mType>1</mType> <sub_regions> <count>0</count> <item_version>0</item_version> </sub_regions> <basic_blocks> <count>11</count> <item_version>0</item_version> <item>18</item> <item>38</item> <item>42</item> <item>46</item> <item>50</item> <item>54</item> <item>58</item> <item>62</item> <item>66</item> <item>70</item> <item>74</item> </basic_blocks> <mII>1</mII> <mDepth>2</mDepth> <mMinTripCount>64</mMinTripCount> <mMaxTripCount>64</mMaxTripCount> <mMinLatency>64</mMinLatency> <mMaxLatency>-1</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"></mDfPipe> </item> <item class_id_reference="22" object_id="_218"> <mId>4</mId> <mTag>Return</mTag> <mType>0</mType> <sub_regions> <count>0</count> <item_version>0</item_version> </sub_regions> <basic_blocks> <count>1</count> <item_version>0</item_version> <item>76</item> </basic_blocks> <mII>-1</mII> <mDepth>-1</mDepth> <mMinTripCount>-1</mMinTripCount> <mMaxTripCount>-1</mMaxTripCount> <mMinLatency>0</mMinLatency> <mMaxLatency>-1</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"></mDfPipe> </item> </cdfg_regions> <fsm class_id="24" tracking_level="1" version="0" object_id="_219"> <states class_id="25" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="26" tracking_level="1" version="0" object_id="_220"> <id>1</id> <operations class_id="27" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="28" tracking_level="1" version="0" object_id="_221"> <id>10</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_222"> <id>2</id> <operations> <count>20</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_223"> <id>12</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_224"> <id>13</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_225"> <id>14</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_226"> <id>15</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_227"> <id>16</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_228"> <id>17</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_229"> <id>21</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_230"> <id>22</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_231"> <id>23</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_232"> <id>24</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_233"> <id>25</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_234"> <id>26</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_235"> <id>28</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_236"> <id>32</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_237"> <id>33</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_238"> <id>34</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_239"> <id>35</id> <stage>2</stage> <latency>2</latency> </item> <item class_id_reference="28" object_id="_240"> <id>36</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_241"> <id>37</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_242"> <id>72</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_243"> <id>3</id> <operations> <count>33</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_244"> <id>19</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_245"> <id>20</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_246"> <id>27</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_247"> <id>29</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_248"> <id>30</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_249"> <id>31</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_250"> <id>35</id> <stage>1</stage> <latency>2</latency> </item> <item class_id_reference="28" object_id="_251"> <id>39</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_252"> <id>40</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_253"> <id>41</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_254"> <id>43</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_255"> <id>44</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_256"> <id>45</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_257"> <id>47</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_258"> <id>48</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_259"> <id>49</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_260"> <id>51</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_261"> <id>52</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_262"> <id>53</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_263"> <id>55</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_264"> <id>56</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_265"> <id>57</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_266"> <id>59</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_267"> <id>60</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_268"> <id>61</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_269"> <id>63</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_270"> <id>64</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_271"> <id>65</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_272"> <id>67</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_273"> <id>68</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_274"> <id>69</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_275"> <id>71</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_276"> <id>73</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_277"> <id>4</id> <operations> <count>1</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_278"> <id>75</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> </states> <transitions class_id="29" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="30" tracking_level="1" version="0" object_id="_279"> <inState>1</inState> <outState>2</outState> <condition class_id="31" tracking_level="0" version="0"> <id>76</id> <sop class_id="32" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="33" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_280"> <inState>3</inState> <outState>2</outState> <condition> <id>85</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_281"> <inState>2</inState> <outState>4</outState> <condition> <id>84</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>1</count> <item_version>0</item_version> <item class_id="34" tracking_level="0" version="0"> <first class_id="35" tracking_level="0" version="0"> <first>15</first> <second>0</second> </first> <second>0</second> </item> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_282"> <inState>2</inState> <outState>3</outState> <condition> <id>86</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>1</count> <item_version>0</item_version> <item> <first> <first>15</first> <second>0</second> </first> <second>1</second> </item> </item> </sop> </condition> </item> </transitions> </fsm> <res class_id="36" tracking_level="1" version="0" object_id="_283"> <dp_component_resource class_id="37" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </dp_component_resource> <dp_expression_resource> <count>0</count> <item_version>0</item_version> </dp_expression_resource> <dp_fifo_resource> <count>0</count> <item_version>0</item_version> </dp_fifo_resource> <dp_memory_resource> <count>0</count> <item_version>0</item_version> </dp_memory_resource> <dp_multiplexer_resource> <count>0</count> <item_version>0</item_version> </dp_multiplexer_resource> <dp_register_resource> <count>0</count> <item_version>0</item_version> </dp_register_resource> <dp_component_map class_id="38" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </dp_component_map> <dp_expression_map> <count>0</count> <item_version>0</item_version> </dp_expression_map> <dp_fifo_map> <count>0</count> <item_version>0</item_version> </dp_fifo_map> <dp_memory_map> <count>0</count> <item_version>0</item_version> </dp_memory_map> </res> <node_label_latency class_id="39" tracking_level="0" version="0"> <count>48</count> <item_version>0</item_version> <item class_id="40" tracking_level="0" version="0"> <first>10</first> <second class_id="41" tracking_level="0" version="0"> <first>0</first> <second>0</second> </second> </item> <item> <first>12</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>13</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>14</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>15</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>16</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>17</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>21</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>22</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>23</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>24</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>25</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>26</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>27</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>28</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>32</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>33</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>34</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>35</first> <second> <first>1</first> <second>1</second> </second> </item> <item> <first>36</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>37</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>39</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>40</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>41</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>43</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>44</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>45</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>47</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>48</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>49</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>51</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>52</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>53</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>55</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>56</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>57</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>59</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>60</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>61</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>63</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>64</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>65</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>67</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>68</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>69</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>72</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>73</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>75</first> <second> <first>2</first> <second>0</second> </second> </item> </node_label_latency> <bblk_ent_exit class_id="42" tracking_level="0" version="0"> <count>13</count> <item_version>0</item_version> <item class_id="43" tracking_level="0" version="0"> <first>11</first> <second class_id="44" tracking_level="0" version="0"> <first>0</first> <second>0</second> </second> </item> <item> <first>18</first> <second> <first>1</first> <second>1</second> </second> </item> <item> <first>38</first> <second> <first>1</first> <second>2</second> </second> </item> <item> <first>42</first> <second> <first>2</first> <second>2</second> </second> </item> <item> <first>46</first> <second> <first>2</first> <second>2</second> </second> </item> <item> <first>50</first> <second> <first>2</first> <second>2</second> </second> </item> <item> <first>54</first> <second> <first>2</first> <second>2</second> </second> </item> <item> <first>58</first> <second> <first>2</first> <second>2</second> </second> </item> <item> <first>62</first> <second> <first>2</first> <second>2</second> </second> </item> <item> <first>66</first> <second> <first>2</first> <second>2</second> </second> </item> <item> <first>70</first> <second> <first>2</first> <second>2</second> </second> </item> <item> <first>74</first> <second> <first>1</first> <second>2</second> </second> </item> <item> <first>76</first> <second> <first>2</first> <second>2</second> </second> </item> </bblk_ent_exit> <regions class_id="45" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="46" tracking_level="1" version="0" object_id="_284"> <region_name>RD_Loop_Row_RD_Loop_Col</region_name> <basic_blocks> <count>11</count> <item_version>0</item_version> <item>18</item> <item>38</item> <item>42</item> <item>46</item> <item>50</item> <item>54</item> <item>58</item> <item>62</item> <item>66</item> <item>70</item> <item>74</item> </basic_blocks> <nodes> <count>0</count> <item_version>0</item_version> </nodes> <anchor_node>-1</anchor_node> <region_type>8</region_type> <interval>1</interval> <pipe_depth>2</pipe_depth> </item> </regions> <dp_fu_nodes class_id="47" tracking_level="0" version="0"> <count>35</count> <item_version>0</item_version> <item class_id="48" tracking_level="0" version="0"> <first>70</first> <second> <count>1</count> <item_version>0</item_version> <item>34</item> </second> </item> <item> <first>77</first> <second> <count>2</count> <item_version>0</item_version> <item>35</item> <item>35</item> </second> </item> <item> <first>82</first> <second> <count>1</count> <item_version>0</item_version> <item>39</item> </second> </item> <item> <first>89</first> <second> <count>1</count> <item_version>0</item_version> <item>40</item> </second> </item> <item> <first>95</first> <second> <count>1</count> <item_version>0</item_version> <item>43</item> </second> </item> <item> <first>102</first> <second> <count>1</count> <item_version>0</item_version> <item>44</item> </second> </item> <item> <first>108</first> <second> <count>1</count> <item_version>0</item_version> <item>47</item> </second> </item> <item> <first>115</first> <second> <count>1</count> <item_version>0</item_version> <item>48</item> </second> </item> <item> <first>121</first> <second> <count>1</count> <item_version>0</item_version> <item>51</item> </second> </item> <item> <first>128</first> <second> <count>1</count> <item_version>0</item_version> <item>52</item> </second> </item> <item> <first>134</first> <second> <count>1</count> <item_version>0</item_version> <item>55</item> </second> </item> <item> <first>141</first> <second> <count>1</count> <item_version>0</item_version> <item>56</item> </second> </item> <item> <first>147</first> <second> <count>1</count> <item_version>0</item_version> <item>59</item> </second> </item> <item> <first>154</first> <second> <count>1</count> <item_version>0</item_version> <item>60</item> </second> </item> <item> <first>160</first> <second> <count>1</count> <item_version>0</item_version> <item>63</item> </second> </item> <item> <first>167</first> <second> <count>1</count> <item_version>0</item_version> <item>64</item> </second> </item> <item> <first>173</first> <second> <count>1</count> <item_version>0</item_version> <item>67</item> </second> </item> <item> <first>180</first> <second> <count>1</count> <item_version>0</item_version> <item>68</item> </second> </item> <item> <first>190</first> <second> <count>1</count> <item_version>0</item_version> <item>12</item> </second> </item> <item> <first>201</first> <second> <count>1</count> <item_version>0</item_version> <item>13</item> </second> </item> <item> <first>212</first> <second> <count>1</count> <item_version>0</item_version> <item>14</item> </second> </item> <item> <first>219</first> <second> <count>1</count> <item_version>0</item_version> <item>15</item> </second> </item> <item> <first>225</first> <second> <count>1</count> <item_version>0</item_version> <item>16</item> </second> </item> <item> <first>231</first> <second> <count>1</count> <item_version>0</item_version> <item>21</item> </second> </item> <item> <first>237</first> <second> <count>1</count> <item_version>0</item_version> <item>22</item> </second> </item> <item> <first>245</first> <second> <count>1</count> <item_version>0</item_version> <item>23</item> </second> </item> <item> <first>251</first> <second> <count>1</count> <item_version>0</item_version> <item>24</item> </second> </item> <item> <first>259</first> <second> <count>1</count> <item_version>0</item_version> <item>25</item> </second> </item> <item> <first>263</first> <second> <count>1</count> <item_version>0</item_version> <item>26</item> </second> </item> <item> <first>271</first> <second> <count>1</count> <item_version>0</item_version> <item>28</item> </second> </item> <item> <first>275</first> <second> <count>1</count> <item_version>0</item_version> <item>32</item> </second> </item> <item> <first>281</first> <second> <count>1</count> <item_version>0</item_version> <item>33</item> </second> </item> <item> <first>286</first> <second> <count>1</count> <item_version>0</item_version> <item>36</item> </second> </item> <item> <first>290</first> <second> <count>1</count> <item_version>0</item_version> <item>72</item> </second> </item> <item> <first>296</first> <second> <count>1</count> <item_version>0</item_version> <item>27</item> </second> </item> </dp_fu_nodes> <dp_fu_nodes_expression class_id="50" tracking_level="0" version="0"> <count>26</count> <item_version>0</item_version> <item class_id="51" tracking_level="0" version="0"> <first>buf_0_addr_gep_fu_160</first> <second> <count>1</count> <item_version>0</item_version> <item>63</item> </second> </item> <item> <first>buf_1_addr_gep_fu_147</first> <second> <count>1</count> <item_version>0</item_version> <item>59</item> </second> </item> <item> <first>buf_2_addr_gep_fu_134</first> <second> <count>1</count> <item_version>0</item_version> <item>55</item> </second> </item> <item> <first>buf_3_addr_gep_fu_121</first> <second> <count>1</count> <item_version>0</item_version> <item>51</item> </second> </item> <item> <first>buf_4_addr_gep_fu_108</first> <second> <count>1</count> <item_version>0</item_version> <item>47</item> </second> </item> <item> <first>buf_5_addr_gep_fu_95</first> <second> <count>1</count> <item_version>0</item_version> <item>43</item> </second> </item> <item> <first>buf_6_addr_gep_fu_82</first> <second> <count>1</count> <item_version>0</item_version> <item>39</item> </second> </item> <item> <first>buf_7_addr_gep_fu_173</first> <second> <count>1</count> <item_version>0</item_version> <item>67</item> </second> </item> <item> <first>c_1_fu_290</first> <second> <count>1</count> <item_version>0</item_version> <item>72</item> </second> </item> <item> <first>c_cast2_fu_271</first> <second> <count>1</count> <item_version>0</item_version> <item>28</item> </second> </item> <item> <first>c_mid2_fu_237</first> <second> <count>1</count> <item_version>0</item_version> <item>22</item> </second> </item> <item> <first>c_phi_fu_212</first> <second> <count>1</count> <item_version>0</item_version> <item>14</item> </second> </item> <item> <first>exitcond_flatten_fu_219</first> <second> <count>1</count> <item_version>0</item_version> <item>15</item> </second> </item> <item> <first>exitcond_fu_231</first> <second> <count>1</count> <item_version>0</item_version> <item>21</item> </second> </item> <item> <first>indvar_flatten_next_fu_225</first> <second> <count>1</count> <item_version>0</item_version> <item>16</item> </second> </item> <item> <first>indvar_flatten_phi_fu_190</first> <second> <count>1</count> <item_version>0</item_version> <item>12</item> </second> </item> <item> <first>input_addr_gep_fu_70</first> <second> <count>1</count> <item_version>0</item_version> <item>34</item> </second> </item> <item> <first>r_mid2_fu_251</first> <second> <count>1</count> <item_version>0</item_version> <item>24</item> </second> </item> <item> <first>r_phi_fu_201</first> <second> <count>1</count> <item_version>0</item_version> <item>13</item> </second> </item> <item> <first>r_s_fu_245</first> <second> <count>1</count> <item_version>0</item_version> <item>23</item> </second> </item> <item> <first>tmp_2_fu_259</first> <second> <count>1</count> <item_version>0</item_version> <item>25</item> </second> </item> <item> <first>tmp_3_fu_286</first> <second> <count>1</count> <item_version>0</item_version> <item>36</item> </second> </item> <item> <first>tmp_5_fu_275</first> <second> <count>1</count> <item_version>0</item_version> <item>32</item> </second> </item> <item> <first>tmp_6_fu_281</first> <second> <count>1</count> <item_version>0</item_version> <item>33</item> </second> </item> <item> <first>tmp_fu_263</first> <second> <count>1</count> <item_version>0</item_version> <item>26</item> </second> </item> <item> <first>tmp_s_fu_296</first> <second> <count>1</count> <item_version>0</item_version> <item>27</item> </second> </item> </dp_fu_nodes_expression> <dp_fu_nodes_module> <count>0</count> <item_version>0</item_version> </dp_fu_nodes_module> <dp_fu_nodes_io> <count>0</count> <item_version>0</item_version> </dp_fu_nodes_io> <return_ports> <count>0</count> <item_version>0</item_version> </return_ports> <dp_mem_port_nodes class_id="52" tracking_level="0" version="0"> <count>9</count> <item_version>0</item_version> <item class_id="53" tracking_level="0" version="0"> <first class_id="54" tracking_level="0" version="0"> <first>buf_0</first> <second>0</second> </first> <second> <count>1</count> <item_version>0</item_version> <item>64</item> </second> </item> <item> <first> <first>buf_1</first> <second>0</second> </first> <second> <count>1</count> <item_version>0</item_version> <item>60</item> </second> </item> <item> <first> <first>buf_2</first> <second>0</second> </first> <second> <count>1</count> <item_version>0</item_version> <item>56</item> </second> </item> <item> <first> <first>buf_3</first> <second>0</second> </first> <second> <count>1</count> <item_version>0</item_version> <item>52</item> </second> </item> <item> <first> <first>buf_4</first> <second>0</second> </first> <second> <count>1</count> <item_version>0</item_version> <item>48</item> </second> </item> <item> <first> <first>buf_5</first> <second>0</second> </first> <second> <count>1</count> <item_version>0</item_version> <item>44</item> </second> </item> <item> <first> <first>buf_6</first> <second>0</second> </first> <second> <count>1</count> <item_version>0</item_version> <item>40</item> </second> </item> <item> <first> <first>buf_7</first> <second>0</second> </first> <second> <count>1</count> <item_version>0</item_version> <item>68</item> </second> </item> <item> <first> <first>input_r</first> <second>0</second> </first> <second> <count>2</count> <item_version>0</item_version> <item>35</item> <item>35</item> </second> </item> </dp_mem_port_nodes> <dp_reg_nodes> <count>9</count> <item_version>0</item_version> <item> <first>186</first> <second> <count>1</count> <item_version>0</item_version> <item>12</item> </second> </item> <item> <first>197</first> <second> <count>1</count> <item_version>0</item_version> <item>13</item> </second> </item> <item> <first>208</first> <second> <count>1</count> <item_version>0</item_version> <item>14</item> </second> </item> <item> <first>307</first> <second> <count>1</count> <item_version>0</item_version> <item>15</item> </second> </item> <item> <first>311</first> <second> <count>1</count> <item_version>0</item_version> <item>16</item> </second> </item> <item> <first>316</first> <second> <count>1</count> <item_version>0</item_version> <item>24</item> </second> </item> <item> <first>322</first> <second> <count>1</count> <item_version>0</item_version> <item>34</item> </second> </item> <item> <first>327</first> <second> <count>1</count> <item_version>0</item_version> <item>36</item> </second> </item> <item> <first>331</first> <second> <count>1</count> <item_version>0</item_version> <item>72</item> </second> </item> </dp_reg_nodes> <dp_regname_nodes> <count>9</count> <item_version>0</item_version> <item> <first>c_1_reg_331</first> <second> <count>1</count> <item_version>0</item_version> <item>72</item> </second> </item> <item> <first>c_reg_208</first> <second> <count>1</count> <item_version>0</item_version> <item>14</item> </second> </item> <item> <first>exitcond_flatten_reg_307</first> <second> <count>1</count> <item_version>0</item_version> <item>15</item> </second> </item> <item> <first>indvar_flatten_next_reg_311</first> <second> <count>1</count> <item_version>0</item_version> <item>16</item> </second> </item> <item> <first>indvar_flatten_reg_186</first> <second> <count>1</count> <item_version>0</item_version> <item>12</item> </second> </item> <item> <first>input_addr_reg_322</first> <second> <count>1</count> <item_version>0</item_version> <item>34</item> </second> </item> <item> <first>r_mid2_reg_316</first> <second> <count>1</count> <item_version>0</item_version> <item>24</item> </second> </item> <item> <first>r_reg_197</first> <second> <count>1</count> <item_version>0</item_version> <item>13</item> </second> </item> <item> <first>tmp_3_reg_327</first> <second> <count>1</count> <item_version>0</item_version> <item>36</item> </second> </item> </dp_regname_nodes> <dp_reg_phi> <count>3</count> <item_version>0</item_version> <item> <first>186</first> <second> <count>1</count> <item_version>0</item_version> <item>12</item> </second> </item> <item> <first>197</first> <second> <count>1</count> <item_version>0</item_version> <item>13</item> </second> </item> <item> <first>208</first> <second> <count>1</count> <item_version>0</item_version> <item>14</item> </second> </item> </dp_reg_phi> <dp_regname_phi> <count>3</count> <item_version>0</item_version> <item> <first>c_reg_208</first> <second> <count>1</count> <item_version>0</item_version> <item>14</item> </second> </item> <item> <first>indvar_flatten_reg_186</first> <second> <count>1</count> <item_version>0</item_version> <item>12</item> </second> </item> <item> <first>r_reg_197</first> <second> <count>1</count> <item_version>0</item_version> <item>13</item> </second> </item> </dp_regname_phi> <dp_port_io_nodes class_id="55" tracking_level="0" version="0"> <count>9</count> <item_version>0</item_version> <item class_id="56" tracking_level="0" version="0"> <first>buf_0(p0)</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>store</first> <second> <count>1</count> <item_version>0</item_version> <item>64</item> </second> </item> </second> </item> <item> <first>buf_1(p0)</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>store</first> <second> <count>1</count> <item_version>0</item_version> <item>60</item> </second> </item> </second> </item> <item> <first>buf_2(p0)</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>store</first> <second> <count>1</count> <item_version>0</item_version> <item>56</item> </second> </item> </second> </item> <item> <first>buf_3(p0)</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>store</first> <second> <count>1</count> <item_version>0</item_version> <item>52</item> </second> </item> </second> </item> <item> <first>buf_4(p0)</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>store</first> <second> <count>1</count> <item_version>0</item_version> <item>48</item> </second> </item> </second> </item> <item> <first>buf_5(p0)</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>store</first> <second> <count>1</count> <item_version>0</item_version> <item>44</item> </second> </item> </second> </item> <item> <first>buf_6(p0)</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>store</first> <second> <count>1</count> <item_version>0</item_version> <item>40</item> </second> </item> </second> </item> <item> <first>buf_7(p0)</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>store</first> <second> <count>1</count> <item_version>0</item_version> <item>68</item> </second> </item> </second> </item> <item> <first>input_r(p0)</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>load</first> <second> <count>2</count> <item_version>0</item_version> <item>35</item> <item>35</item> </second> </item> </second> </item> </dp_port_io_nodes> <port2core class_id="57" tracking_level="0" version="0"> <count>9</count> <item_version>0</item_version> <item class_id="58" tracking_level="0" version="0"> <first>1</first> <second>RAM</second> </item> <item> <first>2</first> <second>RAM</second> </item> <item> <first>3</first> <second>RAM</second> </item> <item> <first>4</first> <second>RAM</second> </item> <item> <first>5</first> <second>RAM</second> </item> <item> <first>6</first> <second>RAM</second> </item> <item> <first>7</first> <second>RAM</second> </item> <item> <first>8</first> <second>RAM</second> </item> <item> <first>9</first> <second>RAM</second> </item> </port2core> <node2core> <count>0</count> <item_version>0</item_version> </node2core> </syndb> </boost_serialization>
25.008286
98
0.585568
1ed4c5027c633a1a6ccb0064e5565875917f5fad
3,765
ads
Ada
source/nodes/program-nodes-defining_character_literals.ads
optikos/oasis
9f64d46d26d964790d69f9db681c874cfb3bf96d
[ "MIT" ]
null
null
null
source/nodes/program-nodes-defining_character_literals.ads
optikos/oasis
9f64d46d26d964790d69f9db681c874cfb3bf96d
[ "MIT" ]
null
null
null
source/nodes/program-nodes-defining_character_literals.ads
optikos/oasis
9f64d46d26d964790d69f9db681c874cfb3bf96d
[ "MIT" ]
2
2019-09-14T23:18:50.000Z
2019-10-02T10:11:40.000Z
-- Copyright (c) 2019 Maxim Reznik <[email protected]> -- -- SPDX-License-Identifier: MIT -- License-Filename: LICENSE ------------------------------------------------------------- with Program.Lexical_Elements; with Program.Elements.Defining_Character_Literals; with Program.Element_Visitors; package Program.Nodes.Defining_Character_Literals is pragma Preelaborate; type Defining_Character_Literal is new Program.Nodes.Node and Program.Elements.Defining_Character_Literals .Defining_Character_Literal and Program.Elements.Defining_Character_Literals .Defining_Character_Literal_Text with private; function Create (Character_Literal_Token : not null Program.Lexical_Elements .Lexical_Element_Access) return Defining_Character_Literal; type Implicit_Defining_Character_Literal is new Program.Nodes.Node and Program.Elements.Defining_Character_Literals .Defining_Character_Literal with private; function Create (Is_Part_Of_Implicit : Boolean := False; Is_Part_Of_Inherited : Boolean := False; Is_Part_Of_Instance : Boolean := False) return Implicit_Defining_Character_Literal with Pre => Is_Part_Of_Implicit or Is_Part_Of_Inherited or Is_Part_Of_Instance; private type Base_Defining_Character_Literal is abstract new Program.Nodes.Node and Program.Elements.Defining_Character_Literals .Defining_Character_Literal with null record; procedure Initialize (Self : aliased in out Base_Defining_Character_Literal'Class); overriding procedure Visit (Self : not null access Base_Defining_Character_Literal; Visitor : in out Program.Element_Visitors.Element_Visitor'Class); overriding function Is_Defining_Character_Literal_Element (Self : Base_Defining_Character_Literal) return Boolean; overriding function Is_Defining_Name_Element (Self : Base_Defining_Character_Literal) return Boolean; type Defining_Character_Literal is new Base_Defining_Character_Literal and Program.Elements.Defining_Character_Literals .Defining_Character_Literal_Text with record Character_Literal_Token : not null Program.Lexical_Elements .Lexical_Element_Access; end record; overriding function To_Defining_Character_Literal_Text (Self : aliased in out Defining_Character_Literal) return Program.Elements.Defining_Character_Literals .Defining_Character_Literal_Text_Access; overriding function Character_Literal_Token (Self : Defining_Character_Literal) return not null Program.Lexical_Elements.Lexical_Element_Access; overriding function Image (Self : Defining_Character_Literal) return Text; type Implicit_Defining_Character_Literal is new Base_Defining_Character_Literal with record Is_Part_Of_Implicit : Boolean; Is_Part_Of_Inherited : Boolean; Is_Part_Of_Instance : Boolean; end record; overriding function To_Defining_Character_Literal_Text (Self : aliased in out Implicit_Defining_Character_Literal) return Program.Elements.Defining_Character_Literals .Defining_Character_Literal_Text_Access; overriding function Is_Part_Of_Implicit (Self : Implicit_Defining_Character_Literal) return Boolean; overriding function Is_Part_Of_Inherited (Self : Implicit_Defining_Character_Literal) return Boolean; overriding function Is_Part_Of_Instance (Self : Implicit_Defining_Character_Literal) return Boolean; overriding function Image (Self : Implicit_Defining_Character_Literal) return Text; end Program.Nodes.Defining_Character_Literals;
33.026316
77
0.754847
13613a56677243724d49998ce5754527f0bc7f43
5,210
adb
Ada
source/web/tools/a2js/properties-statements-if_statement.adb
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
24
2016-11-29T06:59:41.000Z
2021-08-30T11:55:16.000Z
source/web/tools/a2js/properties-statements-if_statement.adb
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
2
2019-01-16T05:15:20.000Z
2019-02-03T10:03:32.000Z
source/web/tools/a2js/properties-statements-if_statement.adb
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
4
2017-07-18T07:11:05.000Z
2020-06-21T03:02:25.000Z
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Web Framework -- -- -- -- Tools Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2015, Vadim Godunko <[email protected]> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ with Asis.Elements; with Asis.Statements; with Properties.Tools; package body Properties.Statements.If_Statement is ---------- -- Code -- ---------- function Code (Engine : access Engines.Contexts.Context; Element : Asis.Expression; Name : Engines.Text_Property) return League.Strings.Universal_String is List : constant Asis.Path_List := Asis.Statements.Statement_Paths (Element); Text : League.Strings.Universal_String; Down : League.Strings.Universal_String; begin for J in List'Range loop case Asis.Elements.Path_Kind (List (J)) is when Asis.An_If_Path => Text.Append ("if ("); Down := Engine.Text.Get_Property (Asis.Statements.Condition_Expression (List (J)), Name); Text.Append (Down); Text.Append (") {"); when Asis.An_Elsif_Path => Text.Append ("} else if ("); Down := Engine.Text.Get_Property (Asis.Statements.Condition_Expression (List (J)), Name); Text.Append (Down); Text.Append (") {"); when Asis.An_Else_Path => Text.Append ("} else {"); when others => raise Program_Error; end case; declare Nested : constant Asis.Statement_List := Asis.Statements.Sequence_Of_Statements (List (J)); begin Down := Engine.Text.Get_Property (List => Nested, Name => Name, Empty => League.Strings.Empty_Universal_String, Sum => Properties.Tools.Join'Access); Text.Append (Down); end; end loop; Text.Append ("};"); return Text; end Code; end Properties.Statements.If_Statement;
47.798165
78
0.440691
ada7acaf413d8b03c1755c292ba0a52e1a97bcfd
423
ads
Ada
examples/bootloader/flash.ads
ekoeppen/STM32_Generic_Ada_Drivers
4ff29c3026c4b24280baf22a5b81ea9969375466
[ "MIT" ]
1
2021-04-06T07:57:56.000Z
2021-04-06T07:57:56.000Z
examples/bootloader/flash.ads
ekoeppen/STM32_Generic_Ada_Drivers
4ff29c3026c4b24280baf22a5b81ea9969375466
[ "MIT" ]
null
null
null
examples/bootloader/flash.ads
ekoeppen/STM32_Generic_Ada_Drivers
4ff29c3026c4b24280baf22a5b81ea9969375466
[ "MIT" ]
2
2018-05-29T13:59:31.000Z
2019-02-03T19:48:08.000Z
with Interfaces; use Interfaces; package Flash is pragma Preelaborate; procedure Init ; procedure Unlock ; procedure Lock ; procedure Enable_Write ; procedure Write (Addr : Unsigned_32; Value : Unsigned_16) ; function Read (Addr : Unsigned_32) return Unsigned_16 ; procedure Erase (Addr : Unsigned_32) ; procedure Wait_Until_Ready ; end Flash;
16.92
60
0.643026
8bbb71decd4295bc5b4b354ef8db0f4a5ed48430
7,703
ads
Ada
src/asis/a4g-decl_sem.ads
jquorning/dynamo
10d68571476c270b8e45a9c5ef585fa9139b0d05
[ "Apache-2.0" ]
15
2015-01-18T23:04:19.000Z
2022-03-01T20:27:08.000Z
src/asis/a4g-decl_sem.ads
jquorning/dynamo
10d68571476c270b8e45a9c5ef585fa9139b0d05
[ "Apache-2.0" ]
16
2018-06-10T07:09:30.000Z
2022-03-26T18:28:40.000Z
src/asis/a4g-decl_sem.ads
jquorning/dynamo
10d68571476c270b8e45a9c5ef585fa9139b0d05
[ "Apache-2.0" ]
3
2015-11-11T18:00:14.000Z
2022-01-30T23:08:45.000Z
------------------------------------------------------------------------------ -- -- -- ASIS-for-GNAT IMPLEMENTATION COMPONENTS -- -- -- -- A 4 G . D E C L _ S E M -- -- -- -- S p e c -- -- -- -- Copyright (C) 1995-2012, Free Software Foundation, Inc. -- -- -- -- ASIS-for-GNAT is free software; you can redistribute it and/or modify it -- -- under terms of the GNU General Public License as published by the Free -- -- Software Foundation; either version 2, or (at your option) any later -- -- version. ASIS-for-GNAT is distributed in the hope that it will be use- -- -- ful, but WITHOUT ANY WARRANTY; without even the implied warranty of MER- -- -- CHANTABILITY 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 distributed with ASIS-for-GNAT; see file -- -- COPYING. If not, write to the Free Software Foundation, 59 Temple Place -- -- - Suite 330, Boston, MA 02111-1307, USA. -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- ASIS-for-GNAT was originally developed by the ASIS-for-GNAT team at the -- -- Software Engineering Laboratory of the Swiss Federal Institute of -- -- Technology (LGL-EPFL) in Lausanne, Switzerland, in cooperation with the -- -- Scientific Research Computer Center of Moscow State University (SRCC -- -- MSU), Russia, with funding partially provided by grants from the Swiss -- -- National Science Foundation and the Swiss Academy of Engineering -- -- Sciences. ASIS-for-GNAT is now maintained by Ada Core Technologies Inc -- -- (http://www.gnat.com). -- -- -- ------------------------------------------------------------------------------ -- This package contains routines needed for semantic queries from -- the Asis.Declarations package with Asis; use Asis; with Types; use Types; package A4G.Decl_Sem is -- All the routines defined in this package do not check their -- arguments - a caller is responcible for the proper use of these -- routines ------------------------------------------------- -- Routines for Corresponding_Type_Definition -- ------------------------------------------------- function Serach_First_View (Type_Entity : Entity_Id) return Entity_Id; -- taking the node representing the type entity, this function looks -- for the first occurence of this name in the corresponding declarative -- region. The idea is to find the declaration of the private or incomplete -- type for which this type defines the full view. If there is no private -- or incomplete view, the function returns its argument as a result. -- -- Note, that Type_Entity should not represent an implicit type created -- by the compiler. -- -- The reason why we need this function is that some functions from Sinfo -- and Einfo needed for semantic queries from Asis.Declarations do not -- correspond to their documentation or/and have irregular behaviour. If -- and when the corresponding problems in Einfo and Sinfo are fixed, it -- would be very nice to get rid of this function, which in fact is no -- more than ad hoc solution. --------------------------------------------- -- Routines for Corresponding_Declaration -- --------------------------------------------- function Get_Expanded_Spec (Instance_Node : Node_Id) return Node_Id; -- For Instance_Node, which should represent a generic instantiation, -- this function returns the node representing the expanded generic -- specification. This function never returns an Empty node. -- -- Note, that in case of subprogram instantiation GNAT creates an -- artificial package enclosing the resulted subprogram declaration -- -- This is an error to call this function for argument which does not -- represent an instantiation, or for a node representing a library -- unit declaration function Corresponding_Decl_Node (Body_Node : Node_Id) return Node_Id; -- For Body_Node representing a body, renaming-as-body or a body stub, this -- function returns the node representing the corresponding declaration. -- -- It is an error to call this function in case when no explicit separate -- declaration exists (that is, in case of renaming-as-declaration or -- a subprogram body (stub) for which no explicit separate declaration is -- presented. -- -- It is also an error to call this function for a node representing a -- library unit declaration or for a node representing generic -- instantiation. -------------------------------------- -- Routines for Corresponding_Body -- -------------------------------------- function Corresponding_Body_Node (Decl_Node : Node_Id) return Node_Id; -- For Decl_Node representing a declaration of a program unit, -- this function returns the node representing the corresponding -- body or renaming-as-body. In is an error to call this function, -- if a completion of the declaration represented by the argument is -- located in another compilation unit, and the tree being accessed -- does not contain this unit (this is the case for subprograms declared -- immediately within a library package/library generic package). function Get_Renaming_As_Body (Node : Node_Id; Spec_Only : Boolean := False) return Node_Id; -- This function tries to find for Node (which should be of -- N_Subprogram_Declaration kind, otherwise this is an error to call -- this function) the node representing renaming-as-body which is -- the completion of this subprogram declaration. The Spec_Only -- flag should be set to limit the search by a package spec only ------------------------------------------------- -- Routines for Corresponding_Generic_Element -- ------------------------------------------------- function Get_Corresponding_Generic_Element (Gen_Unit : Asis.Declaration; Def_Name : Asis.Element) return Asis.Element; -- This function traverses the declaration of a generic package -- Gen_Unit (by applying an instance of Traverce_Element) in order -- to find A_Defining_Name Element which represents the corresponding -- generic element for Def_Name; Def_Name should represent -- A_Defining_Name element which Is_Part_Of_Instance end A4G.Decl_Sem;
55.021429
79
0.54667
8bd2faac86f091a600bdfe587e70989498617216
214
adb
Ada
Pruebas/pruebaFunciones.adb
Arles96/PCompiladores
e435b9f5169589badf289b44a62f76d03438fa6e
[ "MIT" ]
null
null
null
Pruebas/pruebaFunciones.adb
Arles96/PCompiladores
e435b9f5169589badf289b44a62f76d03438fa6e
[ "MIT" ]
null
null
null
Pruebas/pruebaFunciones.adb
Arles96/PCompiladores
e435b9f5169589badf289b44a62f76d03438fa6e
[ "MIT" ]
1
2021-03-28T22:41:49.000Z
2021-03-28T22:41:49.000Z
procedure prueba is function Minimo2 (a, b: Integer) return Integer is X : Integer := 0; begin if a < b then return a; else return b; end if; end Minimo2; begin put(Minimo2(1, 2)); end prueba;
19.454545
52
0.640187
1e6b623dbf352475142c692b0f38c6161341ce9b
53,624
adb
Ada
src/asis/a4g-contt-dp.adb
jquorning/dynamo
10d68571476c270b8e45a9c5ef585fa9139b0d05
[ "Apache-2.0" ]
15
2015-01-18T23:04:19.000Z
2022-03-01T20:27:08.000Z
src/asis/a4g-contt-dp.adb
jquorning/dynamo
10d68571476c270b8e45a9c5ef585fa9139b0d05
[ "Apache-2.0" ]
16
2018-06-10T07:09:30.000Z
2022-03-26T18:28:40.000Z
src/asis/a4g-contt-dp.adb
jquorning/dynamo
10d68571476c270b8e45a9c5ef585fa9139b0d05
[ "Apache-2.0" ]
3
2015-11-11T18:00:14.000Z
2022-01-30T23:08:45.000Z
------------------------------------------------------------------------------ -- -- -- ASIS-for-GNAT IMPLEMENTATION COMPONENTS -- -- -- -- A 4 G . C O N T T . D P -- -- -- -- B o d y -- -- -- -- Copyright (C) 1995-2012, Free Software Foundation, Inc. -- -- -- -- ASIS-for-GNAT is free software; you can redistribute it and/or modify it -- -- under terms of the GNU General Public License as published by the Free -- -- Software Foundation; either version 2, or (at your option) any later -- -- version. ASIS-for-GNAT is distributed in the hope that it will be use- -- -- ful, but WITHOUT ANY WARRANTY; without even the implied warranty of MER- -- -- CHANTABILITY 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 distributed with ASIS-for-GNAT; see file -- -- COPYING. If not, write to the Free Software Foundation, 51 Franklin -- -- Street, Fifth Floor, Boston, MA 02110-1301, USA. -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- ASIS-for-GNAT was originally developed by the ASIS-for-GNAT team at the -- -- Software Engineering Laboratory of the Swiss Federal Institute of -- -- Technology (LGL-EPFL) in Lausanne, Switzerland, in cooperation with the -- -- Scientific Research Computer Center of Moscow State University (SRCC -- -- MSU), Russia, with funding partially provided by grants from the Swiss -- -- National Science Foundation and the Swiss Academy of Engineering -- -- Sciences. ASIS-for-GNAT is now maintained by AdaCore -- -- (http://www.adacore.com). -- -- -- ------------------------------------------------------------------------------ pragma Ada_2005; with Ada.Containers.Ordered_Sets; with Ada.Unchecked_Deallocation; with Asis.Set_Get; use Asis.Set_Get; with A4G.Contt.UT; use A4G.Contt.UT; with A4G.Get_Unit; use A4G.Get_Unit; with Atree; use Atree; with Nlists; use Nlists; with Namet; use Namet; with Sinfo; use Sinfo; with Lib; use Lib; package body A4G.Contt.Dp is ----------------------- -- Local Subprograms -- ----------------------- function Get_First_Stub (Body_Node : Node_Id) return Node_Id; function Get_Next_Stub (Stub_Node : Node_Id) return Node_Id; -- these two functions implement the iterator through the body stubs -- contained in the given compilation unit. The iterator should -- be started from calling Get_First_Stub for the node pointed to -- the body (that is, for the node of ..._Body kind). The Empty node -- is returned if there is no first/next body stub node procedure Set_All_Unit_Dependencies (U : Unit_Id); -- Computes the full lists of supporters and dependents of U in the current -- Context from the list of direct supporters of U and sets these lists as -- values of Supporters and Dependents lists in the Unit Table procedure Add_Unit_Supporters (U : Unit_Id; L : in out Elist_Id); -- Add all the supporters of U, excluding U itself to L. This procedure -- traverses all the transitive semantic dependencies. procedure Fix_Direct_Supporters (Unit : Unit_Id); -- This procedure adds missed direct dependencies to the unit. It is -- supposed that before the call the list of direct supporters contains -- only units extracted from the unit context clause. So, if U is a body, -- this procedure adds the spec to the list of direct supporters, if it is -- a subunit - the parent body is added, if it is a child unit - the -- parent spec is added etc. The procedure adds these supporters in a -- transitive manner - that is, in case of a subunit, it adds the parent -- body, its spec (if any), its parent (if any) etc. -- This function supposes that Current Context is correctly set before -- the call. function In_List (U : Unit_Id; L : Unit_Id_List; Up_To : Natural) return Boolean; -- Checks if U is a member of the first Up_To components of L. (If -- Up_To is 0, False is returned procedure CU_To_Unit_Id_List (CU_List : Compilation_Unit_List; Result_Unit_Id_List : in out Unit_Id_List; Result_List_Len : out Natural); -- Converts the ASIS Compilation Unit list into the list of Unit Ids and -- places this list into Result_Unit_Id_List. (Probably, we should replace -- this routine with a function...) -- For each ASIS Compilation Unit from CU_List the Result_Unit_Id_List -- contains exactly one Id for the corresponding unit. Result_List_Len is -- set to represent the index of the last Unit Id in Result_List_Len (0 -- in case if Result_List_Len is empty). This routine expects that -- Result_Unit_Id_List'Length >= CU_List'Length -------------------------------------- -- Dynamic Unit_Id list abstraction -- -------------------------------------- -- All the subprograms implementing Unit_Id list abstraction do not -- reset Context -- Is this package body the right place for defining this abstraction? -- May be, we should move it into A4G.A_Types??? type Unit_Id_List_Access is access Unit_Id_List; Tmp_Unit_Id_List_Access : Unit_Id_List_Access; procedure Free is new Ada.Unchecked_Deallocation (Unit_Id_List, Unit_Id_List_Access); function In_Unit_Id_List (U : Unit_Id; L : Unit_Id_List_Access) return Boolean; -- Checks if U is a member of L. procedure Append_Unit_To_List (U : Unit_Id; L : in out Unit_Id_List_Access); -- (Unconditionally) appends U to L. procedure Add_To_Unit_Id_List (U : Unit_Id; L : in out Unit_Id_List_Access); -- If not In_Unit_Id_List (U, L), U is appended to L (if L is null, -- new Unit_Id_List value is created) procedure Reorder_Sem_Dependencies (Units : Unit_Id_List_Access); -- This procedure takes the unit list with is supposed to be the result of -- one of the Set_All_<Relation> functions above (that is, its parameter -- is not supposed to be null and it contains only existing units). It -- reorders it in the way required by -- Asis.Compilation_Units.Relations.Semantic_Dependence_Order - that is, -- with no forward semantic dependencies. ------------------- -- Add_To_Parent -- ------------------- procedure Add_To_Parent (C : Context_Id; U : Unit_Id) is Parent_Id : Unit_Id; Unit_Kind : constant Unit_Kinds := Kind (C, U); begin if U = Standard_Id then return; end if; Reset_Context (C); -- ??? Get_Name_String (U, Norm_Ada_Name); if Not_Root then Form_Parent_Name; if Unit_Kind in A_Subunit then A_Name_Buffer (A_Name_Len) := 'b'; end if; Parent_Id := Name_Find (C); -- Parent_Id cannot be Nil_Unit here Append_Elmt (Unit => U, To => Unit_Table.Table (Parent_Id).Subunits_Or_Childs); else Append_Elmt (Unit => U, To => Unit_Table.Table (Standard_Id).Subunits_Or_Childs); end if; end Add_To_Parent; ------------------------- -- Add_Unit_Supporters -- ------------------------- procedure Add_Unit_Supporters (U : Unit_Id; L : in out Elist_Id) is Supporters : Elist_Id renames Unit_Table.Table (U).Supporters; Direct_Supporters : Elist_Id renames Unit_Table.Table (U).Direct_Supporters; Next_Support_Elmt : Elmt_Id; Next_Support_Unit : Unit_Id; begin if Is_Empty_Elmt_List (Direct_Supporters) then -- end of the recursion return; elsif not Is_Empty_Elmt_List (Supporters) then -- no need to traverse indirect dependencies Next_Support_Elmt := First_Elmt (Supporters); while Present (Next_Support_Elmt) loop Next_Support_Unit := Unit (Next_Support_Elmt); Add_To_Elmt_List (Unit => Next_Support_Unit, List => L); Next_Support_Elmt := Next_Elmt (Next_Support_Elmt); end loop; else -- And here we have to traverse the recursive dependencies: Next_Support_Elmt := First_Elmt (Direct_Supporters); while Present (Next_Support_Elmt) loop Next_Support_Unit := Unit (Next_Support_Elmt); -- The old code currently commented out caused a huge delay -- when opening one tree context (8326-002). We will keep it -- till the new code is tested for queries from -- Asis.Compilation_Units.Relations -- ???Old code start -- Here we can not be sure, that if Next_Support_Unit already -- is in the list, all its supporters also are in the list -- Add_To_Elmt_List -- (Unit => Next_Support_Unit, -- List => L); -- Add_Unit_Supporters (Next_Support_Unit, L); -- ???Old code end -- ???New code start if not In_Elmt_List (Next_Support_Unit, L) then Append_Elmt (Unit => Next_Support_Unit, To => L); Add_Unit_Supporters (Next_Support_Unit, L); end if; -- ???New code end Next_Support_Elmt := Next_Elmt (Next_Support_Elmt); end loop; end if; end Add_Unit_Supporters; ------------------------- -- Append_Subunit_Name -- ------------------------- procedure Append_Subunit_Name (Def_S_Name : Node_Id) is begin -- Here we need unqualified name, because the name -- which comes from the stub is qualified by parent body -- name Get_Unqualified_Decoded_Name_String (Chars (Def_S_Name)); A_Name_Buffer (A_Name_Len - 1) := '.'; A_Name_Buffer (A_Name_Len .. A_Name_Len + Name_Len - 1) := Name_Buffer (1 .. Name_Len); A_Name_Len := A_Name_Len + Name_Len + 1; A_Name_Buffer (A_Name_Len - 1) := '%'; A_Name_Buffer (A_Name_Len) := 'b'; end Append_Subunit_Name; ------------------------ -- CU_To_Unit_Id_List -- ------------------------ procedure CU_To_Unit_Id_List (CU_List : Compilation_Unit_List; Result_Unit_Id_List : in out Unit_Id_List; Result_List_Len : out Natural) is Next_Unit : Unit_Id; begin Result_List_Len := 0; for I in CU_List'Range loop Next_Unit := Get_Unit_Id (CU_List (I)); if not In_List (Next_Unit, Result_Unit_Id_List, Result_List_Len) then Result_List_Len := Result_List_Len + 1; Result_Unit_Id_List (Result_List_Len) := Next_Unit; end if; end loop; end CU_To_Unit_Id_List; --------------------------- -- Fix_Direct_Supporters -- --------------------------- procedure Fix_Direct_Supporters (Unit : Unit_Id) is function Next_Supporter (U : Unit_Id) return Unit_Id; -- Computes the next supporter to be added (from subunit to the parent -- body, from body to the spec, from child to the parent etc). Ends up -- with Standard and then with Nil_Unit as its parent Next_Supporter_Id : Unit_Id; function Next_Supporter (U : Unit_Id) return Unit_Id is C : constant Context_Id := Current_Context; Arg_Unit_Kind : constant Unit_Kinds := Kind (C, U); Result_Id : Unit_Id := Nil_Unit; begin case Arg_Unit_Kind is when A_Procedure | A_Function | A_Package | A_Generic_Procedure | A_Generic_Function | A_Generic_Package | A_Procedure_Instance | A_Function_Instance | A_Package_Instance | A_Procedure_Renaming | A_Function_Renaming | A_Package_Renaming | A_Generic_Procedure_Renaming | A_Generic_Function_Renaming | A_Generic_Package_Renaming => Result_Id := Get_Parent_Unit (C, U); when A_Procedure_Body | A_Function_Body => if Class (C, U) = A_Public_Declaration_And_Body then Result_Id := Get_Parent_Unit (C, U); else Result_Id := Get_Declaration (C, U); end if; when A_Package_Body => Result_Id := Get_Declaration (C, U); when A_Procedure_Body_Subunit | A_Function_Body_Subunit | A_Package_Body_Subunit | A_Task_Body_Subunit | A_Protected_Body_Subunit => Result_Id := Get_Subunit_Parent_Body (C, U); when others => pragma Assert (False); null; end case; return Result_Id; end Next_Supporter; begin Next_Supporter_Id := Next_Supporter (Unit); while Present (Next_Supporter_Id) loop Append_Elmt (Unit => Next_Supporter_Id, To => Unit_Table.Table (Unit).Direct_Supporters); Next_Supporter_Id := Next_Supporter (Next_Supporter_Id); end loop; end Fix_Direct_Supporters; -------------------- -- Get_First_Stub -- -------------------- function Get_First_Stub (Body_Node : Node_Id) return Node_Id is Decls : List_Id; Decl : Node_Id; begin Decls := Declarations (Body_Node); if No (Decls) then return Empty; else Decl := Nlists.First (Decls); while Present (Decl) loop if Nkind (Decl) in N_Body_Stub then return Decl; end if; Decl := Next (Decl); end loop; return Empty; end if; end Get_First_Stub; ------------------- -- Get_Next_Stub -- ------------------- function Get_Next_Stub (Stub_Node : Node_Id) return Node_Id is Next_Decl : Node_Id; begin Next_Decl := Next (Stub_Node); while Present (Next_Decl) loop if Nkind (Next_Decl) in N_Body_Stub then return Next_Decl; end if; Next_Decl := Next (Next_Decl); end loop; return Empty; end Get_Next_Stub; ------------- -- In_List -- ------------- function In_List (U : Unit_Id; L : Unit_Id_List; Up_To : Natural) return Boolean is Len : constant Natural := Natural'Min (Up_To, L'Length); Result : Boolean := False; begin for I in 1 .. Len loop if L (I) = U then Result := True; exit; end if; end loop; return Result; end In_List; ------------------ -- Process_Stub -- ------------------ procedure Process_Stub (C : Context_Id; U : Unit_Id; Stub : Node_Id) is Def_S_Name : Node_Id; Subunit_Id : Unit_Id; begin -- We should save (and then restore) the content of A_Name_Buffer in -- case when more than one stub is to be processed. (A_Name_Buffer -- contains the Ada name of the parent body) NB_Save; if Nkind (Stub) = N_Subprogram_Body_Stub then Def_S_Name := Defining_Unit_Name (Specification (Stub)); else Def_S_Name := Defining_Identifier (Stub); end if; Append_Subunit_Name (Def_S_Name); Subunit_Id := Name_Find (C); if No (Subunit_Id) then Subunit_Id := Allocate_Nonexistent_Unit_Entry (C); Append_Elmt (Unit => Subunit_Id, To => Unit_Table.Table (U).Subunits_Or_Childs); end if; NB_Restore; end Process_Stub; ------------------------------ -- Reorder_Sem_Dependencies -- ------------------------------ procedure Reorder_Sem_Dependencies (Units : Unit_Id_List_Access) is More_Inversion : Boolean := True; Tmp_Unit : Unit_Id; begin if Units'Length = 0 then return; end if; -- The idea is simple: for all the units in Units list we have the -- lists of all the unit's supporters already computed. If we order -- units so that the lengths of supporter lists will increase we will -- get the order in which there will be no forward semantic -- dependencies: if unit A depends on unit B, then A also depends on -- all the supporters of B, so it has the list of supporters longer -- then B has while More_Inversion loop More_Inversion := False; for J in Units'First .. Units'Last - 1 loop if List_Length (Unit_Table.Table (Units (J)).Supporters) > List_Length (Unit_Table.Table (Units (J + 1)).Supporters) then Tmp_Unit := Units (J + 1); Units (J + 1) := Units (J); Units (J) := Tmp_Unit; More_Inversion := True; end if; end loop; end loop; end Reorder_Sem_Dependencies; -------------------------- -- Set_All_Dependencies -- -------------------------- procedure Set_All_Dependencies (Use_First_New_Unit : Boolean := False) is Starting_Unit : Unit_Id; begin if Use_First_New_Unit then Starting_Unit := First_New_Unit; if No (Starting_Unit) then -- This may happen, when, for the incremental Context, we -- process the tree which is the main tree for some body unit, -- and this body unit has been already included in the Context -- (See Lib (spec, (h)) return; end if; else Starting_Unit := Config_Comp_Id + 1; -- Config_Comp_Id corresponds to last predefined unit set in the -- unit table end if; for U in Starting_Unit .. Last_Unit loop Set_All_Unit_Dependencies (U); end loop; end Set_All_Dependencies; ------------------------------- -- Set_All_Unit_Dependencies -- ------------------------------- procedure Set_All_Unit_Dependencies (U : Unit_Id) is Supporters : Elist_Id renames Unit_Table.Table (U).Supporters; Direct_Supporters : Elist_Id renames Unit_Table.Table (U).Direct_Supporters; Next_Support_Elmt : Elmt_Id; Next_Support_Unit : Unit_Id; begin Fix_Direct_Supporters (U); -- Setting all the unit supporters Next_Support_Elmt := First_Elmt (Direct_Supporters); while Present (Next_Support_Elmt) loop Next_Support_Unit := Unit (Next_Support_Elmt); -- If Next_Support_Unit already is in Supporters list, -- all its supporters also are already included in Supporters. if not In_Elmt_List (Next_Support_Unit, Supporters) then Append_Elmt (Unit => Next_Support_Unit, To => Supporters); Add_Unit_Supporters (Next_Support_Unit, Supporters); end if; Next_Support_Elmt := Next_Elmt (Next_Support_Elmt); end loop; -- And now - adding U as depended unit to the list of Dependents for -- all its supporters Next_Support_Elmt := First_Elmt (Supporters); while Present (Next_Support_Elmt) loop Next_Support_Unit := Unit (Next_Support_Elmt); Append_Elmt (Unit => U, To => Unit_Table.Table (Next_Support_Unit).Dependents); Next_Support_Elmt := Next_Elmt (Next_Support_Elmt); end loop; end Set_All_Unit_Dependencies; --------------------------- -- Set_Direct_Dependents -- --------------------------- procedure Set_Direct_Dependents (U : Unit_Id) is Next_Support_Elmt : Elmt_Id; Next_Support_Unit : Unit_Id; begin Next_Support_Elmt := First_Elmt (Unit_Table.Table (U).Direct_Supporters); while Present (Next_Support_Elmt) loop Next_Support_Unit := Unit (Next_Support_Elmt); Append_Elmt (Unit => U, To => Unit_Table.Table (Next_Support_Unit).Direct_Dependents); Next_Support_Elmt := Next_Elmt (Next_Support_Elmt); end loop; end Set_Direct_Dependents; ----------------------- -- Set_All_Ancestors -- ----------------------- procedure Set_All_Ancestors (Compilation_Units : Asis.Compilation_Unit_List; Result : in out Compilation_Unit_List_Access) is Cont : constant Context_Id := Current_Context; Arg_List : Unit_Id_List (1 .. Compilation_Units'Length) := (others => Nil_Unit); Arg_List_Len : Natural := 0; Result_List : Unit_Id_List_Access := null; Next_Ancestor_Unit : Unit_Id; begin -- For the current version, we are supposing, that we have only one -- Context opened at a time CU_To_Unit_Id_List (Compilation_Units, Arg_List, Arg_List_Len); -- Standard is an ancestor of any unit, and if we are here, -- Compilation_Units can not be Nil_Compilation_Unit_List. So we set -- it as the first element of the result list: Append_Unit_To_List (Standard_Id, Result_List); for I in 1 .. Arg_List_Len loop Next_Ancestor_Unit := Arg_List (I); if Next_Ancestor_Unit /= Standard_Id then while Kind (Cont, Next_Ancestor_Unit) in A_Subunit loop Next_Ancestor_Unit := Get_Subunit_Parent_Body (Cont, Next_Ancestor_Unit); end loop; if Class (Cont, Next_Ancestor_Unit) = A_Public_Body or else Class (Cont, Next_Ancestor_Unit) = A_Private_Body then Next_Ancestor_Unit := Get_Declaration (Cont, Next_Ancestor_Unit); end if; while Next_Ancestor_Unit /= Standard_Id loop if not In_Unit_Id_List (Next_Ancestor_Unit, Result_List) then Append_Unit_To_List (Next_Ancestor_Unit, Result_List); Next_Ancestor_Unit := Get_Parent_Unit (Cont, Next_Ancestor_Unit); else exit; end if; end loop; end if; end loop; -- And here we have to order Result_List to eliminate forward -- semantic dependencies -- Result_List can not be null - it contains at least Standard_Id Reorder_Sem_Dependencies (Result_List); Result := new Compilation_Unit_List' (Get_Comp_Unit_List (Result_List.all, Cont)); Free (Result_List); end Set_All_Ancestors; ------------------------ -- Set_All_Dependents -- ------------------------ procedure Set_All_Dependents (Compilation_Units : Asis.Compilation_Unit_List; Dependent_Units : Asis.Compilation_Unit_List; Result : in out Compilation_Unit_List_Access) is Cont : constant Context_Id := Current_Context; Arg_List : Unit_Id_List (1 .. Compilation_Units'Length) := (others => Nil_Unit); Arg_List_Len : Natural := 0; Dep_List : Unit_Id_List (1 .. Dependent_Units'Length) := (others => Nil_Unit); Dep_List_Len : Natural := 0; Result_List : Unit_Id_List_Access := null; Next_Dependent_Elmt : Elmt_Id; Next_Dependent_Unit : Unit_Id; begin -- For the current version, we are supposing, that we have only one -- Context opened at a time CU_To_Unit_Id_List (Compilation_Units, Arg_List, Arg_List_Len); CU_To_Unit_Id_List (Dependent_Units, Dep_List, Dep_List_Len); -- Now, collecting all the dependents for Compilation_Units for I in 1 .. Arg_List_Len loop Next_Dependent_Elmt := First_Elmt (Unit_Table.Table (Arg_List (I)).Dependents); while Present (Next_Dependent_Elmt) loop Next_Dependent_Unit := Unit (Next_Dependent_Elmt); if Dep_List_Len = 0 or else In_List (Next_Dependent_Unit, Dep_List, Dep_List_Len) then Add_To_Unit_Id_List (Next_Dependent_Unit, Result_List); end if; Next_Dependent_Elmt := Next_Elmt (Next_Dependent_Elmt); end loop; end loop; -- And here we have to order Result_List to eliminate forward -- semantic dependencies if Result_List /= null then Reorder_Sem_Dependencies (Result_List); Result := new Compilation_Unit_List' (Get_Comp_Unit_List (Result_List.all, Cont)); Free (Result_List); else Result := new Compilation_Unit_List (1 .. 0); end if; end Set_All_Dependents; ------------------------- -- Set_All_Descendants -- ------------------------- procedure Set_All_Descendants (Compilation_Units : Asis.Compilation_Unit_List; Result : in out Compilation_Unit_List_Access) is Cont : constant Context_Id := Current_Context; Arg_List : Unit_Id_List (1 .. Compilation_Units'Length) := (others => Nil_Unit); Arg_List_Len : Natural := 0; Result_List : Unit_Id_List_Access := null; Next_Descendant_Elmt : Elmt_Id; Next_Unit : Unit_Id; procedure Add_All_Descendants (Desc_Unit : Unit_Id; Result_List : in out Unit_Id_List_Access); -- If Desc_Unit is not in Result_List, this procedure adds it and -- (recursively) all its descendants which are not in Result_List to -- the list. procedure Add_All_Descendants (Desc_Unit : Unit_Id; Result_List : in out Unit_Id_List_Access) is Child_Elmt : Elmt_Id; Child_Unit : Unit_Id; begin if not In_Unit_Id_List (Desc_Unit, Result_List) then Append_Unit_To_List (Desc_Unit, Result_List); if Kind (Cont, Desc_Unit) = A_Package or else Kind (Cont, Desc_Unit) = A_Generic_Package or else Kind (Cont, Desc_Unit) = A_Package_Renaming or else Kind (Cont, Desc_Unit) = A_Generic_Package_Renaming then Child_Elmt := First_Elmt (Unit_Table.Table (Desc_Unit).Subunits_Or_Childs); while Present (Child_Elmt) loop Child_Unit := Unit (Child_Elmt); Add_All_Descendants (Child_Unit, Result_List); Child_Elmt := Next_Elmt (Child_Elmt); end loop; end if; end if; end Add_All_Descendants; begin -- We can not use CU_To_Unit_Id_List routine, because we have to -- filter out subunits, nonexistent units (?) and bodies for which the -- Context does not contain a spec - such units can not have -- descendants. For bodies, only the corresponding specs contain the -- lists of descendants. for I in Compilation_Units'Range loop Next_Unit := Get_Unit_Id (Compilation_Units (I)); if Kind (Cont, Next_Unit) not in A_Procedure_Body_Subunit .. A_Nonexistent_Body then if Kind (Cont, Next_Unit) in A_Library_Unit_Body then Next_Unit := Get_Declaration (Cont, Next_Unit); end if; if Present (Next_Unit) and then (not In_List (Next_Unit, Arg_List, Arg_List_Len)) then Arg_List_Len := Arg_List_Len + 1; Arg_List (Arg_List_Len) := Next_Unit; end if; end if; end loop; for J in 1 .. Arg_List_Len loop Next_Descendant_Elmt := First_Elmt (Unit_Table.Table (Arg_List (J)).Subunits_Or_Childs); while Present (Next_Descendant_Elmt) loop Next_Unit := Unit (Next_Descendant_Elmt); Add_All_Descendants (Next_Unit, Result_List); Next_Descendant_Elmt := Next_Elmt (Next_Descendant_Elmt); end loop; end loop; if Result_List /= null then Reorder_Sem_Dependencies (Result_List); Result := new Compilation_Unit_List' (Get_Comp_Unit_List (Result_List.all, Cont)); Free (Result_List); else Result := new Compilation_Unit_List (1 .. 0); end if; end Set_All_Descendants; ---------------------- -- Set_All_Families -- ---------------------- procedure Set_All_Families (Compilation_Units : Asis.Compilation_Unit_List; Result : in out Compilation_Unit_List_Access) is Cont : constant Context_Id := Current_Context; Arg_List : Unit_Id_List (1 .. Compilation_Units'Length) := (others => Nil_Unit); Arg_List_Len : Natural := 0; Result_List : Unit_Id_List_Access := null; procedure Collect_Spec_Family (Spec_Unit : Unit_Id; Result_List : in out Unit_Id_List_Access); -- If Spec_Unit is not in Result_List, this procedure adds it and -- (recursively) all members of its family which are not in Result_List -- to the list. In case of a spec, the corresponding body's family is -- also added procedure Collect_Body_Family (Body_Unit : Unit_Id; Result_List : in out Unit_Id_List_Access); -- If Body_Unit is not in Result_List, this procedure adds it and -- (recursively) all members of its family which are not in Result_List -- to the list. In case of a body, only the subunit tree rooted by this -- body may be added procedure Collect_Spec_Family (Spec_Unit : Unit_Id; Result_List : in out Unit_Id_List_Access) is Child_Elmt : Elmt_Id; Child_Unit : Unit_Id; begin if not In_Unit_Id_List (Spec_Unit, Result_List) then Append_Unit_To_List (Spec_Unit, Result_List); -- We have to add all descendants (if any) and their families if Kind (Cont, Spec_Unit) = A_Package or else Kind (Cont, Spec_Unit) = A_Generic_Package or else Kind (Cont, Spec_Unit) = A_Package_Renaming or else Kind (Cont, Spec_Unit) = A_Generic_Package_Renaming then Child_Elmt := First_Elmt (Unit_Table.Table (Spec_Unit).Subunits_Or_Childs); while Present (Child_Elmt) loop Child_Unit := Unit (Child_Elmt); if Kind (Cont, Child_Unit) in A_Procedure .. A_Generic_Package_Renaming then Collect_Spec_Family (Child_Unit, Result_List); elsif Kind (Cont, Child_Unit) in A_Procedure_Body .. A_Protected_Body_Subunit then Collect_Body_Family (Child_Unit, Result_List); end if; Child_Elmt := Next_Elmt (Child_Elmt); end loop; end if; end if; end Collect_Spec_Family; procedure Collect_Body_Family (Body_Unit : Unit_Id; Result_List : in out Unit_Id_List_Access) is Child_Elmt : Elmt_Id; Child_Unit : Unit_Id; begin if not In_Unit_Id_List (Body_Unit, Result_List) then Append_Unit_To_List (Body_Unit, Result_List); -- We have to add all descendants (if any) and their families if Kind (Cont, Body_Unit) in A_Procedure_Body .. A_Protected_Body_Subunit then Child_Elmt := First_Elmt (Unit_Table.Table (Body_Unit).Subunits_Or_Childs); while Present (Child_Elmt) loop Child_Unit := Unit (Child_Elmt); Collect_Body_Family (Child_Unit, Result_List); Child_Elmt := Next_Elmt (Child_Elmt); end loop; end if; end if; end Collect_Body_Family; begin CU_To_Unit_Id_List (Compilation_Units, Arg_List, Arg_List_Len); for J in 1 .. Arg_List_Len loop case Class (Cont, Arg_List (J)) is when A_Public_Declaration | A_Private_Declaration => Collect_Spec_Family (Arg_List (J), Result_List); when Not_A_Class => -- This should never happen, so just in case we -- raise an exception null; pragma Assert (False); when others => -- Here we can have only a body or a separate body Collect_Body_Family (Arg_List (J), Result_List); end case; end loop; -- And here we have to order Result_List to eliminate forward -- semantic dependencies if Result_List /= null then Reorder_Sem_Dependencies (Result_List); Result := new Compilation_Unit_List' (Get_Comp_Unit_List (Result_List.all, Cont)); Free (Result_List); else Result := new Compilation_Unit_List (1 .. 0); end if; end Set_All_Families; ------------------------ -- Set_All_Supporters -- ------------------------ package Unit_Container is new Ada.Containers.Ordered_Sets (Element_Type => Unit_Id); procedure Unit_List_To_Set (Unit_List : Elist_Id; Unit_Set : in out Unit_Container.Set); -- Assuming that Unit_List does not contain repeating elements, creates -- Unit_Set as the set containing Unit IDs from Unit_List. If Unit_Set is -- non-empty before the call, the old content of the set is lost. function Unit_Set_To_List (Unit_Set : Unit_Container.Set) return Unit_Id_List; -- Converts the unit id set into array Result_Set : Unit_Container.Set; New_Set : Unit_Container.Set; Newer_Set : Unit_Container.Set; Next_Direct_Supporter : Unit_Container.Cursor; procedure Unit_List_To_Set (Unit_List : Elist_Id; Unit_Set : in out Unit_Container.Set) is Next_El : Elmt_Id; begin Unit_Container.Clear (Unit_Set); Next_El := First_Elmt (Unit_List); while Present (Next_El) loop Unit_Container.Insert (Unit_Set, Unit (Next_El)); Next_El := Next_Elmt (Next_El); end loop; end Unit_List_To_Set; function Unit_Set_To_List (Unit_Set : Unit_Container.Set) return Unit_Id_List is Next_Unit : Unit_Container.Cursor; Result : Unit_Id_List (1 .. Natural (Unit_Container.Length (Unit_Set))); Next_Idx : Natural := Result'First; begin Next_Unit := Unit_Container.First (Unit_Set); while Unit_Container.Has_Element (Next_Unit) loop Result (Next_Idx) := Unit_Container.Element (Next_Unit); Next_Idx := Next_Idx + 1; Next_Unit := Unit_Container.Next (Next_Unit); end loop; return Result; end Unit_Set_To_List; procedure Set_All_Supporters (Compilation_Units : Asis.Compilation_Unit_List; Result : in out Compilation_Unit_List_Access) is Cont : constant Context_Id := Current_Context; Arg_List : Unit_Id_List (1 .. Compilation_Units'Length) := (others => Nil_Unit); Result_List : Unit_Id_List_Access := null; Arg_List_Len : Natural := 0; pragma Unreferenced (Arg_List_Len); procedure Collect_Supporters (U : Unit_Id); -- If U is not presented in Result, adds (recursively) all its -- supporters to Result_List -- Uses workpile algorithm to avoid cycling (cycling is possible because -- of limited with) procedure Collect_Supporters (U : Unit_Id) is Next_Supporter : Elmt_Id; begin Unit_Container.Clear (New_Set); Unit_Container.Clear (Newer_Set); Unit_List_To_Set (Unit_List => Unit_Table.Table (U).Supporters, Unit_Set => New_Set); Unit_Container.Union (Target => Result_Set, Source => New_Set); while not Unit_Container.Is_Empty (New_Set) loop Next_Direct_Supporter := Unit_Container.First (New_Set); Next_Supporter := First_Elmt (Unit_Table.Table (Unit_Container.Element (Next_Direct_Supporter)).Supporters); while Present (Next_Supporter) loop if not Unit_Container.Contains (Result_Set, Unit (Next_Supporter)) then Unit_Container.Insert (Newer_Set, Unit (Next_Supporter)); end if; Next_Supporter := Next_Elmt (Next_Supporter); end loop; Unit_Container.Delete_First (New_Set); if not Unit_Container.Is_Empty (Newer_Set) then Unit_Container.Union (Result_Set, Newer_Set); Unit_Container.Union (New_Set, Newer_Set); Unit_Container.Clear (Newer_Set); end if; end loop; end Collect_Supporters; begin Unit_Container.Clear (Result_Set); Unit_Container.Insert (Result_Set, Standard_Id); -- For the current version, we are supposing, that we have only one -- Context opened at a time CU_To_Unit_Id_List (Compilation_Units, Arg_List, Arg_List_Len); -- Now, collecting all the supporters for Compilation_Units -- Standard is a supporter of any unit, and if we are here, -- Compilation_Units can not be Nil_Compilation_Unit_List. So we set -- it as the first element of the result list: for J in Compilation_Units'Range loop Collect_Supporters (Get_Unit_Id (Compilation_Units (J))); end loop; Result_List := new Unit_Id_List'(Unit_Set_To_List (Result_Set)); -- And here we have to order Result_List to eliminate forward -- semantic dependencies -- Result_List can not be null - it contains at least Standard_Id Reorder_Sem_Dependencies (Result_List); Result := new Compilation_Unit_List' (Get_Comp_Unit_List (Result_List.all, Cont)); Free (Result_List); end Set_All_Supporters; -------------------------- -- Set_All_Needed_Units -- -------------------------- procedure Set_All_Needed_Units (Compilation_Units : Asis.Compilation_Unit_List; Result : in out Compilation_Unit_List_Access; Missed : in out Compilation_Unit_List_Access) is Cont : constant Context_Id := Current_Context; Cont_Tree_Mode : constant Tree_Mode := Tree_Processing_Mode (Cont); Arg_List : Unit_Id_List (1 .. Compilation_Units'Length) := (others => Nil_Unit); Arg_List_Len : Natural := 0; Result_List : Unit_Id_List_Access := null; Missed_List : Unit_Id_List_Access := null; procedure Set_One_Unit (U : Unit_Id); -- Provided that U is an (existing) unit which is not in the -- Result_List, this procedure adds this unit and all the units -- needed by it to result lists. procedure Add_Needed_By_Spec (Spec_Unit : Unit_Id); -- Provided that Spec_Unit denotes an (existing) spec, this procedure -- adds to the result lists units which are needed by this unit only, -- that is, excluding this unit (it is supposed to be already added at -- the moment of the call), its body and units needed by the body (if -- any, they are processed separately) procedure Add_Needed_By_Body (Body_Unit : Unit_Id); -- Provided that Body_Unit denotes an (existing) body, this procedure -- adds to the result lists units which are needed by this unit, -- excluding the unit itself (it is supposed to be already added at -- the moment of the call). That is, the spec of this unit and units -- which are needed by the spec (if any) are also needed, if they have -- not been added before ------------------------ -- Add_Needed_By_Body -- ------------------------ procedure Add_Needed_By_Body (Body_Unit : Unit_Id) is Spec_Unit : Unit_Id; Subunit_List : constant Unit_Id_List := Subunits (Cont, Body_Unit); Next_Support_Elmt : Elmt_Id; Next_Support_Unit : Unit_Id; begin -- First, check if there is a separate spec then it has to be -- processed if Class (Cont, Body_Unit) /= A_Public_Declaration_And_Body then Spec_Unit := Body_Unit; while Class (Cont, Spec_Unit) = A_Separate_Body loop Spec_Unit := Get_Subunit_Parent_Body (Cont, Spec_Unit); end loop; Spec_Unit := Get_Declaration (Cont, Spec_Unit); -- We can not get Nil or nonexistent unit here if not In_Unit_Id_List (Spec_Unit, Result_List) then Add_Needed_By_Spec (Spec_Unit); end if; end if; -- Now process body's supporters: Next_Support_Elmt := First_Elmt (Unit_Table.Table (Body_Unit).Supporters); while Present (Next_Support_Elmt) loop Next_Support_Unit := Unit (Next_Support_Elmt); if not In_Unit_Id_List (Next_Support_Unit, Result_List) then Set_One_Unit (Next_Support_Unit); end if; Next_Support_Elmt := Next_Elmt (Next_Support_Elmt); end loop; -- And, finally, subunits: for J in Subunit_List'Range loop if Kind (Cont, Subunit_List (J)) = A_Nonexistent_Body then Append_Unit_To_List (Subunit_List (J), Missed_List); elsif not In_Unit_Id_List (Subunit_List (J), Result_List) then Append_Unit_To_List (Subunit_List (J), Result_List); Add_Needed_By_Body (Subunit_List (J)); end if; end loop; end Add_Needed_By_Body; ------------------------ -- Add_Needed_By_Spec -- ------------------------ procedure Add_Needed_By_Spec (Spec_Unit : Unit_Id) is Next_Support_Elmt : Elmt_Id; Next_Support_Unit : Unit_Id; begin Next_Support_Elmt := First_Elmt (Unit_Table.Table (Spec_Unit).Supporters); while Present (Next_Support_Elmt) loop Next_Support_Unit := Unit (Next_Support_Elmt); if not In_Unit_Id_List (Next_Support_Unit, Result_List) then Set_One_Unit (Next_Support_Unit); end if; Next_Support_Elmt := Next_Elmt (Next_Support_Elmt); end loop; end Add_Needed_By_Spec; ------------------ -- Set_One_Unit -- ------------------ procedure Set_One_Unit (U : Unit_Id) is U_Body : Unit_Id; begin Append_Unit_To_List (U, Result_List); case Class (Cont, U) is when A_Public_Declaration | A_Private_Declaration => Add_Needed_By_Spec (U); if Is_Body_Required (Cont, U) then U_Body := Get_Body (Cont, U); if No (U_Body) and then (Cont_Tree_Mode = On_The_Fly or else Cont_Tree_Mode = Mixed) then -- Is it a correct thing to compile something on the fly -- Inside the query from Relations??? U_Body := Get_One_Unit (Name => To_Program_Text (Unit_Name (Get_Comp_Unit (U, Cont))), Context => Cont, Spec => False); end if; if Present (U_Body) then if Kind (Cont, U_Body) in A_Nonexistent_Declaration .. A_Nonexistent_Body then Add_To_Unit_Id_List (U_Body, Missed_List); elsif not In_Unit_Id_List (U_Body, Result_List) then Append_Unit_To_List (U_Body, Result_List); Add_Needed_By_Body (U_Body); end if; else U_Body := Get_Nonexistent_Unit (Cont); Append_Unit_To_List (U_Body, Missed_List); end if; end if; when Not_A_Class => -- This should never happen, so just in case we -- raise an exception null; pragma Assert (False); when others => Add_Needed_By_Body (U); end case; end Set_One_Unit; begin -- Set_All_Needed_Units CU_To_Unit_Id_List (Compilation_Units, Arg_List, Arg_List_Len); -- Standard is a supporter of any unit, and if we are here, -- Compilation_Units can not be Nil_Compilation_Unit_List. So we set -- it as the first element of the result list: Append_Unit_To_List (Standard_Id, Result_List); for J in 1 .. Arg_List_Len loop if not In_Unit_Id_List (Arg_List (J), Result_List) then Set_One_Unit (Arg_List (J)); end if; end loop; -- Result_List can not be null - it contains at least Standard_Id Reorder_Sem_Dependencies (Result_List); Result := new Compilation_Unit_List' (Get_Comp_Unit_List (Result_List.all, Cont)); Free (Result_List); if Missed_List /= null then Missed := new Compilation_Unit_List' (Get_Comp_Unit_List (Missed_List.all, Cont)); Free (Missed_List); else Missed := new Compilation_Unit_List (1 .. 0); end if; end Set_All_Needed_Units; ------------------ -- Set_Subunits -- ------------------ procedure Set_Subunits (C : Context_Id; U : Unit_Id; Top : Node_Id) is Body_Node : Node_Id; Stub_Node : Node_Id; begin Get_Name_String (U, Norm_Ada_Name); Body_Node := Unit (Top); if Nkind (Body_Node) = N_Subunit then Body_Node := Proper_Body (Body_Node); end if; Stub_Node := Get_First_Stub (Body_Node); if No (Stub_Node) then return; end if; while Present (Stub_Node) loop Process_Stub (C, U, Stub_Node); Stub_Node := Get_Next_Stub (Stub_Node); end loop; Unit_Table.Table (U).Subunits_Computed := True; end Set_Subunits; -------------------- -- Set_Supporters -- -------------------- procedure Set_Supporters (C : Context_Id; U : Unit_Id; Top : Node_Id) is begin Set_Withed_Units (C, U, Top); Set_Direct_Dependents (U); end Set_Supporters; ---------------------- -- Set_Withed_Units -- ---------------------- procedure Set_Withed_Units (C : Context_Id; U : Unit_Id; Top : Node_Id) is With_Clause_Node : Node_Id; Cunit_Node : Node_Id; Cunit_Number : Unit_Number_Type; Current_Supporter : Unit_Id; Tmp : Unit_Id; Include_Unit : Boolean := False; begin -- the maim control structure - cycle through the with clauses -- in the tree if No (Context_Items (Top)) then return; end if; With_Clause_Node := First_Non_Pragma (Context_Items (Top)); while Present (With_Clause_Node) loop -- here we simply get the name of the next supporting unit from -- the GNAT Units Table (defined in Lib) Cunit_Node := Library_Unit (With_Clause_Node); Cunit_Number := Get_Cunit_Unit_Number (Cunit_Node); Get_Decoded_Name_String (Unit_Name (Cunit_Number)); Set_Norm_Ada_Name_String_With_Check (Cunit_Number, Include_Unit); if Include_Unit then Current_Supporter := Name_Find (C); if A_Name_Buffer (A_Name_Len) = 'b' then A_Name_Buffer (A_Name_Len) := 's'; Tmp := Name_Find (C); if Present (Tmp) then -- OPEN PROBLEM: is this the best solution for this problem? -- -- Here we are in the potentially hard-to-report-about and -- definitely involving inconsistent unit set situation. -- The last version of U depends on subprogram body at least -- in one of the consistent trees, but the Context contains -- a spec (that is, a library_unit_declaration or a -- library_unit_renaming_declaration) for the same full -- expanded Ada name. The current working decision is -- to set this dependency as if U depends on the spec. -- -- Another (crazy!) problem: in one consistent tree -- U depends on the package P (and P does not require a -- body), and in another consistent tree U depends on -- the procedure P which is presented by its body only. -- It may be quite possible, if these trees were created -- with different search paths. Is our decision reasonable -- for this crazy situation :-[ ??!!?? Current_Supporter := Tmp; end if; end if; -- and now we store this dependency - we have to use -- Add_To_Elmt_List instead of Append_Elmt - some units -- may be mentioned several times in the context clause: if Implicit_With (With_Clause_Node) then Add_To_Elmt_List (Unit => Current_Supporter, List => Unit_Table.Table (U).Implicit_Supporters); else Add_To_Elmt_List (Unit => Current_Supporter, List => Unit_Table.Table (U).Direct_Supporters); end if; end if; With_Clause_Node := Next_Non_Pragma (With_Clause_Node); while Present (With_Clause_Node) and then Nkind (With_Clause_Node) /= N_With_Clause loop With_Clause_Node := Next_Non_Pragma (With_Clause_Node); end loop; end loop; end Set_Withed_Units; ------------------------------------------------------- -- Dynamic Unit_Id list abstraction (implementation) -- ------------------------------------------------------- ---------------------- -- In_Unit_Id_List -- ---------------------- function In_Unit_Id_List (U : Unit_Id; L : Unit_Id_List_Access) return Boolean is begin if L /= null then for I in L'Range loop if U = L (I) then return True; end if; end loop; end if; return False; end In_Unit_Id_List; -------------------------- -- Add_To_Unit_Id_List -- -------------------------- procedure Add_To_Unit_Id_List (U : Unit_Id; L : in out Unit_Id_List_Access) is begin if not In_Unit_Id_List (U, L) then Append_Unit_To_List (U, L); end if; end Add_To_Unit_Id_List; ------------------------- -- Append_Unit_To_List -- ------------------------- procedure Append_Unit_To_List (U : Unit_Id; L : in out Unit_Id_List_Access) is begin if L = null then L := new Unit_Id_List'(1 => U); else Free (Tmp_Unit_Id_List_Access); Tmp_Unit_Id_List_Access := new Unit_Id_List'(L.all & U); Free (L); L := new Unit_Id_List'(Tmp_Unit_Id_List_Access.all); end if; end Append_Unit_To_List; end A4G.Contt.Dp;
32.757483
79
0.567694
9a01384b6abadb47d8a4dc0c1947a3897bce3c9c
6,347
ads
Ada
gcc-gcc-7_3_0-release/gcc/ada/switch.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/ada/switch.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/ada/switch.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- S W I T C H -- -- -- -- S p e c -- -- -- -- Copyright (C) 1992-2012, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT 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 distributed with GNAT; see file COPYING3. If not, go to -- -- http://www.gnu.org/licenses for a complete copy of the license. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This package together with a child package appropriate to the client tool -- scans switches. Note that the body of the appropriate Usage package must be -- coordinated with the switches that are recognized by this package. These -- Usage packages also act as the official documentation for the switches -- that are recognized. In addition, package Debug documents the otherwise -- undocumented debug switches that are also recognized. with Gnatvsn; with Types; use Types; ------------ -- Switch -- ------------ package Switch is -- Common switches for GNU tools Version_Switch : constant String := "--version"; Help_Switch : constant String := "--help"; ----------------- -- Subprograms -- ----------------- generic with procedure Usage; -- Print tool-specific part of --help message procedure Check_Version_And_Help_G (Tool_Name : String; Initial_Year : String; Version_String : String := Gnatvsn.Gnat_Version_String); -- Check if switches --version or --help is used. If one of this switch is -- used, issue the proper messages and end the process. procedure Display_Version (Tool_Name : String; Initial_Year : String; Version_String : String := Gnatvsn.Gnat_Version_String); -- Display version of a tool when switch --version is used procedure Display_Usage_Version_And_Help; -- Output the two lines of usage for switches --version and --help function Is_Switch (Switch_Chars : String) return Boolean; -- Returns True iff Switch_Chars is at least two characters long, and the -- first character is an hyphen ('-'). function Is_Front_End_Switch (Switch_Chars : String) return Boolean; -- Returns True iff Switch_Chars represents a front-end switch, i.e. it -- starts with -I, -gnat or -?RTS. function Is_Internal_GCC_Switch (Switch_Chars : String) return Boolean; -- Returns True iff Switch_Chars represents an internal GCC switch to be -- followed by a single argument, such as -dumpbase, --param or -auxbase. -- Even though passed by the "gcc" driver, these need not be stored in ALI -- files and may safely be ignored by non GCC back-ends. function Switch_Last (Switch_Chars : String) return Natural; -- Index in Switch_Chars of the last relevant character for later string -- comparison purposes. This is typically 'Last, minus one if there is a -- terminating ASCII.NUL. private -- This section contains some common routines used by the tool dependent -- child packages (there is one such child package for each tool that uses -- Switches to scan switches - Compiler/gnatbind/gnatmake/. Switch_Max_Value : constant := 999_999; -- Maximum value permitted in switches that take a value function Nat_Present (Switch_Chars : String; Max : Integer; Ptr : Integer) return Boolean; -- Returns True if an integer is at the current scan location or an equal -- sign. This is used as a guard for calling Scan_Nat. Switch_Chars is the -- string containing the switch, and Ptr points just past the switch -- character. Max is the maximum allowed value of Ptr. procedure Scan_Nat (Switch_Chars : String; Max : Integer; Ptr : in out Integer; Result : out Nat; Switch : Character); -- Scan natural integer parameter for switch. On entry, Ptr points just -- past the switch character, on exit it points past the last digit of the -- integer value. Max is the maximum allowed value of Ptr, so the scan is -- restricted to Switch_Chars (Ptr .. Max). It is possible for Ptr to be -- one greater than Max on return if the entire string is digits. Scan_Nat -- will skip an optional equal sign if it is present. Nat_Present must be -- True, or an error will be signalled. procedure Scan_Pos (Switch_Chars : String; Max : Integer; Ptr : in out Integer; Result : out Pos; Switch : Character); -- Scan positive integer parameter for switch. Identical to Scan_Nat with -- same parameters except that zero is considered out of range. procedure Bad_Switch (Switch : Character); procedure Bad_Switch (Switch : String); pragma No_Return (Bad_Switch); -- Fail with an appropriate message when a switch is not recognized end Switch;
47.014815
79
0.588152
13452474b100239cbe1098af228a8145f98a70e3
7,312
adb
Ada
regtests/util-streams-buffered-lzma-tests.adb
yrashk/ada-util
2aaa1d87e92a7137e1c63dce90f0722c549dfafd
[ "Apache-2.0" ]
null
null
null
regtests/util-streams-buffered-lzma-tests.adb
yrashk/ada-util
2aaa1d87e92a7137e1c63dce90f0722c549dfafd
[ "Apache-2.0" ]
null
null
null
regtests/util-streams-buffered-lzma-tests.adb
yrashk/ada-util
2aaa1d87e92a7137e1c63dce90f0722c549dfafd
[ "Apache-2.0" ]
null
null
null
----------------------------------------------------------------------- -- util-streams-buffered-lzma-tests -- Unit tests for encoding buffered streams -- Copyright (C) 2018, 2019, 2021 Stephane Carrez -- Written by Stephane Carrez ([email protected]) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Util.Test_Caller; with Util.Streams.Files; with Util.Streams.Texts; with Util.Streams.AES; with Util.Encoders.AES; with Ada.Streams.Stream_IO; package body Util.Streams.Buffered.Lzma.Tests is use Util.Streams.Files; use Ada.Streams.Stream_IO; procedure Test_Stream_File (T : in out Test; Item : in String; Count : in Positive; Encrypt : in Boolean; Mode : in Util.Encoders.AES.AES_Mode; Label : in String); package Caller is new Util.Test_Caller (Test, "Streams.Buffered.Lzma"); procedure Add_Tests (Suite : in Util.Tests.Access_Test_Suite) is begin Caller.Add_Test (Suite, "Test Util.Streams.Buffered.Lzma.Write", Test_Compress_Stream'Access); Caller.Add_Test (Suite, "Test Util.Streams.Buffered.Lzma.Write (2)", Test_Compress_File_Stream'Access); Caller.Add_Test (Suite, "Test Util.Streams.Buffered.Lzma.Read+Write", Test_Compress_Decompress_Stream'Access); Caller.Add_Test (Suite, "Test Util.Streams.Buffered.Lzma.Read+Write+AES-CBC", Test_Compress_Encrypt_Decompress_Decrypt_Stream'Access); end Add_Tests; procedure Test_Compress_Stream (T : in out Test) is Stream : aliased File_Stream; Buffer : aliased Util.Streams.Buffered.Lzma.Compress_Stream; Print : Util.Streams.Texts.Print_Stream; Path : constant String := Util.Tests.Get_Test_Path ("test-stream.lzma"); Expect : constant String := Util.Tests.Get_Path ("regtests/expect/test-stream.lzma"); begin Stream.Create (Mode => Out_File, Name => Path); Buffer.Initialize (Output => Stream'Access, Size => 1024); Print.Initialize (Output => Buffer'Access, Size => 5); for I in 1 .. 32 loop Print.Write ("abcd"); Print.Write (" fghij"); Print.Write (ASCII.LF); end loop; Print.Flush; Stream.Close; Util.Tests.Assert_Equal_Files (T => T, Expect => Expect, Test => Path, Message => "LZMA stream"); end Test_Compress_Stream; procedure Test_Compress_File_Stream (T : in out Test) is Stream : aliased File_Stream; In_Stream : aliased File_Stream; Buffer : aliased Util.Streams.Buffered.Lzma.Compress_Stream; Path : constant String := Util.Tests.Get_Test_Path ("test-big-stream.lzma"); Expect : constant String := Util.Tests.Get_Path ("regtests/expect/test-big-stream.lzma"); begin In_Stream.Open (Ada.Streams.Stream_IO.In_File, Util.Tests.Get_Path ("regtests/files/test-big-stream.bin")); Stream.Create (Mode => Out_File, Name => Path); Buffer.Initialize (Output => Stream'Access, Size => 32768); Util.Streams.Copy (From => In_Stream, Into => Buffer); Buffer.Flush; Buffer.Close; Util.Tests.Assert_Equal_Files (T => T, Expect => Expect, Test => Path, Message => "LZMA stream"); end Test_Compress_File_Stream; procedure Test_Stream_File (T : in out Test; Item : in String; Count : in Positive; Encrypt : in Boolean; Mode : in Util.Encoders.AES.AES_Mode; Label : in String) is use Ada.Strings.Unbounded; Path : constant String := Util.Tests.Get_Test_Path ("stream-lzma-aes-" & Label & ".aes"); Key : constant Util.Encoders.Secret_Key := Util.Encoders.Create ("0123456789abcdef0123456789abcdef"); File : aliased File_Stream; Decipher : aliased Util.Streams.AES.Decoding_Stream; Cipher : aliased Util.Streams.AES.Encoding_Stream; Compress : aliased Util.Streams.Buffered.Lzma.Compress_Stream; Decompress : aliased Util.Streams.Buffered.Lzma.Decompress_Stream; Print : Util.Streams.Texts.Print_Stream; Reader : Util.Streams.Texts.Reader_Stream; begin -- Print -> Compress -> Cipher -> File File.Create (Mode => Out_File, Name => Path); if Encrypt then Cipher.Produces (File'Access, 64); Cipher.Set_Key (Key, Mode); Compress.Initialize (Cipher'Access, 1024); else Compress.Initialize (File'Access, 1024); end if; Print.Initialize (Compress'Access); for I in 1 .. Count loop Print.Write (Item & ASCII.LF); end loop; Print.Close; -- File -> Decipher -> Decompress -> Reader File.Open (Mode => In_File, Name => Path); if Encrypt then Decipher.Consumes (File'Access, 128); Decipher.Set_Key (Key, Mode); Decompress.Initialize (Decipher'Access, 1024); else Decompress.Initialize (File'Access, 1024); end if; Reader.Initialize (From => Decompress'Access); declare Line_Count : Natural := 0; begin while not Reader.Is_Eof loop declare Line : Unbounded_String; begin Reader.Read_Line (Line); exit when Length (Line) = 0; if Item & ASCII.LF /= Line then Util.Tests.Assert_Equals (T, Item & ASCII.LF, To_String (Line)); end if; Line_Count := Line_Count + 1; end; end loop; File.Close; Util.Tests.Assert_Equals (T, Count, Line_Count); end; end Test_Stream_File; procedure Test_Compress_Decompress_Stream (T : in out Test) is begin Test_Stream_File (T, "abcdefgh", 1000, False, Util.Encoders.AES.CBC, "NONE"); end Test_Compress_Decompress_Stream; procedure Test_Compress_Encrypt_Decompress_Decrypt_Stream (T : in out Test) is begin Test_Stream_File (T, "abcdefgh", 1000, True, Util.Encoders.AES.CBC, "AES-CBC"); end Test_Compress_Encrypt_Decompress_Decrypt_Stream; end Util.Streams.Buffered.Lzma.Tests;
42.022989
92
0.583425
04349eaeab188bbb6258a5bf8492b5994d7b7698
4,226
ads
Ada
ada-numerics-generic_real_arrays.ads
mgrojo/adalib
dc1355a5b65c2843e702ac76252addb2caf3c56b
[ "BSD-3-Clause" ]
15
2018-07-08T07:09:19.000Z
2021-11-21T09:58:55.000Z
ada-numerics-generic_real_arrays.ads
mgrojo/adalib
dc1355a5b65c2843e702ac76252addb2caf3c56b
[ "BSD-3-Clause" ]
4
2019-11-17T20:04:33.000Z
2021-08-29T21:24:55.000Z
ada-numerics-generic_real_arrays.ads
mgrojo/adalib
dc1355a5b65c2843e702ac76252addb2caf3c56b
[ "BSD-3-Clause" ]
3
2020-04-23T11:17:11.000Z
2021-08-29T19:31:09.000Z
-- Standard Ada library specification -- Copyright (c) 2003-2018 Maxim Reznik <[email protected]> -- Copyright (c) 2004-2016 AXE Consultants -- Copyright (c) 2004, 2005, 2006 Ada-Europe -- Copyright (c) 2000 The MITRE Corporation, Inc. -- Copyright (c) 1992, 1993, 1994, 1995 Intermetrics, Inc. -- SPDX-License-Identifier: BSD-3-Clause and LicenseRef-AdaReferenceManual --------------------------------------------------------------------------- generic type Real is digits <>; package Ada.Numerics.Generic_Real_Arrays is pragma Pure (Generic_Real_Arrays); -- Types type Real_Vector is array (Integer range <>) of Real'Base; type Real_Matrix is array (Integer range <>, Integer range <>) of Real'Base; -- Subprograms for Real_Vector types -- Real_Vector arithmetic operations function "+" (Right : in Real_Vector) return Real_Vector; function "-" (Right : in Real_Vector) return Real_Vector; function "abs" (Right : in Real_Vector) return Real_Vector; function "+" (Left : in Real_Vector; Right : Real_Vector) return Real_Vector; function "-" (Left : in Real_Vector; Right : Real_Vector) return Real_Vector; function "*" (Left : in Real_Vector; Right : Real_Vector) return Real'Base; function "abs" (Right : in Real_Vector) return Real'Base; -- Real_Vector scaling operations function "*" (Left : in Real'Base; Right : in Real_Vector) return Real_Vector; function "*" (Left : in Real_Vector; Right : in Real'Base) return Real_Vector; function "/" (Left : in Real_Vector; Right : in Real'Base) return Real_Vector; -- Other Real_Vector operations function Unit_Vector (Index : in Integer; Order : in Positive; First : in Integer := 1) return Real_Vector; -- Subprograms for Real_Matrix types -- Real_Matrix arithmetic operations function "+" (Right : in Real_Matrix) return Real_Matrix; function "-" (Right : in Real_Matrix) return Real_Matrix; function "abs" (Right : in Real_Matrix) return Real_Matrix; function Transpose (X : in Real_Matrix) return Real_Matrix; function "+" (Left : in Real_Matrix; Right : in Real_Matrix) return Real_Matrix; function "-" (Left : in Real_Matrix; Right : in Real_Matrix) return Real_Matrix; function "*" (Left : in Real_Matrix; Right : in Real_Matrix) return Real_Matrix; function "*" (Left : in Real_Matrix; Right : in Real_Vector) return Real_Matrix; function "*" (Left : in Real_Vector; Right : in Real_Matrix) return Real_Vector; function "*" (Left : in Real_Matrix; Right : in Real_Vector) return Real_Vector; -- Real_Matrix scaling operations function "*" (Left : in Real'Base; Right : in Real_Matrix) return Real_Matrix; function "*" (Left : in Real_Matrix; Right : in Real'Base) return Real_Matrix; function "/" (Left : in Real_Matrix; Right : in Real'Base) return Real_Matrix; -- Real_Matrix inversion and related operations function Solve (A : in Real_Matrix; X : in Real_Vector) return Real_Vector; function Solve (A : in Real_Matrix; X : in Real_Matrix) return Real_Matrix; function Inverse (A : in Real_Matrix) return Real_Matrix; function Determinant (A : in Real_Matrix) return Real'Base; -- Eigenvalues and vectors of a real symmetric matrix function Eigenvalues (A : in Real_Matrix) return Real_Vector; procedure Eigensystem (A : in Real_Matrix; Values : out Real_Vector; Vectors : out Real_Matrix); -- Other Real_Matrix operations function Unit_Matrix (Order : Positive; First_1 : Integer := 1; First_2 : Integer := 1) return Real_Matrix; end Ada.Numerics.Generic_Real_Arrays;
28.554054
79
0.601278
137f34b8aedc13d847035b0bdce191659eb52a86
5,437
ads
Ada
gcc-gcc-7_3_0-release/gcc/ada/s-taspri-hpux-dce.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/ada/s-taspri-hpux-dce.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/ada/s-taspri-hpux-dce.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS -- -- -- -- S Y S T E M . T A S K _ P R I M I T I V E S -- -- -- -- S p e c -- -- -- -- Copyright (C) 1991-2014, Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNARL was developed by the GNARL team at Florida State University. -- -- Extensive contributions were provided by Ada Core Technologies, Inc. -- -- -- ------------------------------------------------------------------------------ -- This is a HP-UX version of this package -- This package provides low-level support for most tasking features pragma Polling (Off); -- Turn off polling, we do not want ATC polling to take place during tasking -- operations. It causes infinite loops and other problems. with System.OS_Interface; package System.Task_Primitives is pragma Preelaborate; type Lock is limited private; -- Should be used for implementation of protected objects type RTS_Lock is limited private; -- Should be used inside the runtime system. The difference between Lock -- and the RTS_Lock is that the later one serves only as a semaphore so -- that do not check for ceiling violations. type Suspension_Object is limited private; -- Should be used for the implementation of Ada.Synchronous_Task_Control type Task_Body_Access is access procedure; -- Pointer to the task body's entry point (or possibly a wrapper -- declared local to the GNARL). type Private_Data is limited private; -- Any information that the GNULLI needs maintained on a per-task basis. -- A component of this type is guaranteed to be included in the -- Ada_Task_Control_Block. subtype Task_Address is System.Address; Task_Address_Size : constant := Standard'Address_Size; -- Type used for task addresses and its size Alternate_Stack_Size : constant := 0; -- No alternate signal stack is used on this platform private type Lock is record L : aliased System.OS_Interface.pthread_mutex_t; Priority : Integer; Owner_Priority : Integer; end record; type RTS_Lock is new System.OS_Interface.pthread_mutex_t; type Suspension_Object is record State : Boolean; pragma Atomic (State); -- Boolean that indicates whether the object is open. This field is -- marked Atomic to ensure that we can read its value without locking -- the access to the Suspension_Object. Waiting : Boolean; -- Flag showing if there is a task already suspended on this object L : aliased System.OS_Interface.pthread_mutex_t; -- Protection for ensuring mutual exclusion on the Suspension_Object CV : aliased System.OS_Interface.pthread_cond_t; -- Condition variable used to queue threads until condition is signaled end record; type Private_Data is record Thread : aliased System.OS_Interface.pthread_t; -- pragma Atomic (Thread); -- Unfortunately, the above fails because Thread is 64 bits. -- Thread field may be updated by two different threads of control. -- (See, Enter_Task and Create_Task in s-taprop.adb). They put the -- same value (thr_self value). We do not want to use lock on those -- operations and the only thing we have to make sure is that they -- are updated in atomic fashion. CV : aliased System.OS_Interface.pthread_cond_t; L : aliased RTS_Lock; -- Protection for all components is lock L end record; end System.Task_Primitives;
46.87069
78
0.564282
a056820141bd87acd386bbc70d69a3b8024ed8dd
8,937
adb
Ada
source/shell-commands-safe.adb
charlie5/aShell
f1a54d99db759314b7a62c84167f797d71f645ae
[ "ISC" ]
11
2016-11-03T10:33:19.000Z
2022-02-22T09:57:26.000Z
source/shell-commands-safe.adb
charlie5/aShell
f1a54d99db759314b7a62c84167f797d71f645ae
[ "ISC" ]
2
2016-12-14T05:21:52.000Z
2017-02-02T07:04:35.000Z
source/shell-commands-safe.adb
charlie5/aShell
f1a54d99db759314b7a62c84167f797d71f645ae
[ "ISC" ]
1
2016-11-21T17:51:25.000Z
2016-11-21T17:51:25.000Z
with Ada.Unchecked_Conversion, Ada.Containers.Hashed_Maps, Ada.Text_IO, Ada.Exceptions; package body Shell.Commands.Safe is ---------------------- --- Safe_Client_Output -- protected type Safe_Client_Outputs is procedure Add_Outputs (Output : in Shell.Data; Errors : in Shell.Data); entry Get_Outputs (Output : out Data_Vector; Errors : out Data_Vector; Normal_Exit : out Boolean); procedure Set_Done (Normal_Exit : in Boolean); private All_Output : Data_Vector; All_Errors : Data_Vector; Exit_Is_Normal : Boolean; Done : Boolean := False; end Safe_Client_Outputs; protected body Safe_Client_Outputs is procedure Add_Outputs (Output : in Shell.Data; Errors : in Shell.Data) is begin if Output'Length /= 0 then All_Output.Append (Output); end if; if Errors'Length /= 0 then All_Errors.Append (Errors); end if; end Add_Outputs; entry Get_Outputs (Output : out Data_Vector; Errors : out Data_Vector; Normal_Exit : out Boolean) when Done is begin Output := All_Output; Errors := All_Errors; Normal_Exit := Exit_Is_Normal; end Get_Outputs; procedure Set_Done (Normal_Exit : in Boolean) is begin Exit_Is_Normal := Normal_Exit; Done := True; end Set_Done; end Safe_Client_Outputs; type Safe_Client_Outputs_Access is access all Safe_Client_Outputs; ---------------- --- Spawn_Client -- task Spawn_Client is entry Add (The_Command : in Command; Input : in Data := No_Data; Outputs : in Safe_Client_Outputs_Access); entry Stop; end Spawn_Client; task body Spawn_Client is use Ada.Strings.Unbounded; package Id_Maps_of_Command_Outputs is new Ada.Containers.Hashed_Maps (Key_Type => Command_Id, Element_Type => Safe_Client_Outputs_Access, Hash => Hash, Equivalent_Keys => "="); Command_Outputs_Map : Id_Maps_of_Command_Outputs.Map; Server_In_Pipe : constant Shell.Pipe := To_Pipe; Server_Out_Pipe : constant Shell.Pipe := To_Pipe (Blocking => False); Server_Err_Pipe : constant Shell.Pipe := To_Pipe; Command_Line : Unbounded_String; Have_New_Command : Boolean := False; Command_Input : Data_Holder; Server_Input_Stream : aliased Pipe_Stream := Stream (Server_In_Pipe); Server_Output_Stream : aliased Pipe_Stream := Stream (Server_Out_Pipe); Next_Id : Command_Id := 1; Stopping : Boolean := False; Server_Is_Done : Boolean := False; Spawn_Server : Shell.Process with Unreferenced; begin Spawn_Server := Start (Program => "ashell_spawn_server", Input => Server_In_Pipe, Output => Server_Out_Pipe, Errors => Server_Err_Pipe); Close (Server_In_Pipe, Only_Read_End => True); Close (Server_Out_Pipe, Only_Write_End => True); Close (Server_Err_Pipe); log ("Starting Spawn_Client"); loop select accept Add (The_Command : in Command; Input : in Data := No_Data; Outputs : in Safe_Client_Outputs_Access) do Log (""); Log ("Client: Accepting new command."); Have_New_Command := True; Set_Unbounded_String (Command_Line, Name (The_Command) & " " & Arguments (The_Command)); Command_Input.Replace_Element (Input); Command_Outputs_Map.Insert (Next_Id, Outputs); end Add; or accept Stop do Log ("Client: Stopping."); Stopping := True; end Stop; or delay 0.01; end select; if Stopping then Log ("Client is stopping."); Server_Action'Output (Server_Input_Stream'Access, (Stop, Null_Id)); Log ("Client asks server to stop."); Stopping := False; elsif Have_New_Command then Log ("New Command:" & Next_Id'Image & " '" & (+Command_Line) & "'"); Server_Action'Output (Server_Input_Stream'Access, (New_Command, Next_Id, Command_Line, Command_Input)); Have_New_Command := False; Next_Id := Next_Id + 1; end if; if not Is_Empty (Server_Out_Pipe, Timeout => 0.06) then delay 0.01; declare Action : constant Client_Action := Client_Action'Input (Server_Output_Stream'Access); Command_Outputs : Safe_Client_Outputs_Access; begin case Action.Kind is when New_Outputs => Log ("New Outputs for Command:" & Action.Id'Image); Command_Outputs := Command_Outputs_Map.Element (Action.Id); Command_Outputs.Add_Outputs (Action.Output.Element, Action.Errors.Element); when Command_Done => Log ("Command Done:" & Action.Id'Image); Command_Outputs := Command_Outputs_Map.Element (Action.Id); Command_Outputs.Set_Done (Normal_Exit => Action.Normal_Exit); Command_Outputs_Map.Delete (Action.Id); when Server_Done => Log ("Server is done."); Server_Is_Done := True; end case; end; end if; exit when Server_Is_Done and Command_Outputs_Map.Is_Empty; end loop; Close (Server_In_Pipe, Only_Write_End => True); Close (Server_Out_Pipe, Only_Read_End => True); Log ("Client is done."); exception when Process_Error => Ada.Text_IO.New_Line (2); Ada.Text_IO.Put_Line ("__________________________________________________________________"); Ada.Text_IO.Put_Line ("Program 'ashell_spawn_server' not found on PATH. Please install it."); Ada.Text_IO.Put_Line ("Spawn client is shutting down."); Ada.Text_IO.Put_Line ("__________________________________________________________________"); Ada.Text_IO.New_Line (2); when E : others => Log ("Unhandled error in Spawn_Client."); Log (Ada.Exceptions.Exception_Information (E)); end Spawn_Client; procedure Run (The_Command : in out Command; Input : in Data := No_Data; Raise_Error : in Boolean := False) is Outputs : aliased Safe_Client_Outputs; Output : Data_Vector; Errors : Data_Vector; Normal_Exit : Boolean; begin Spawn_Client.Add (The_Command, Input, Outputs'Unchecked_Access); Outputs.Get_Outputs (Output, Errors, Normal_Exit); The_Command.Output := Output; The_Command.Errors := Errors; if Raise_Error and not Normal_Exit then raise Command_Error with "Command '" & (+The_Command.Name) & "' failed."; end if; exception when Tasking_Error => raise Command_Error with "Cannot run '" & (+The_Command.Name) & "'. The Spawn client has shut down."; end Run; function Run (The_Command : in out Command; Input : in Data := No_Data; Raise_Error : in Boolean := False) return Command_Results is begin Run (The_Command, Input, Raise_Error); return Results_Of (The_Command); end Run; procedure Stop_Spawn_Client is begin Spawn_Client.Stop; end Stop_Spawn_Client; end Shell.Commands.Safe;
31.357895
122
0.515609
1ee49489a364964d1093ad39f754d51f473df17e
145
adb
Ada
tests/nonsmoke/functional/CompileTests/experimental_ada_tests/tests/very_large_value.adb
LaudateCorpus1/rose-1
5fe906d2a01253130c5de465aded6a917a8476a0
[ "BSD-3-Clause" ]
488
2015-01-09T08:54:48.000Z
2022-03-30T07:15:46.000Z
tests/nonsmoke/functional/CompileTests/experimental_ada_tests/tests/very_large_value.adb
LaudateCorpus1/rose-1
5fe906d2a01253130c5de465aded6a917a8476a0
[ "BSD-3-Clause" ]
174
2015-01-28T18:41:32.000Z
2022-03-31T16:51:05.000Z
tests/nonsmoke/functional/CompileTests/experimental_ada_tests/tests/very_large_value.adb
LaudateCorpus1/rose-1
5fe906d2a01253130c5de465aded6a917a8476a0
[ "BSD-3-Clause" ]
146
2015-04-27T02:48:34.000Z
2022-03-04T07:32:53.000Z
procedure Very_Large_Value is begin if 16#2B.20000000000000000000000000000000000000000#E1 > 0.1 then null; end if; end Very_Large_Value;
20.714286
66
0.793103
38d745cf9726915db16ac0944e61c3108bb553e4
10,620
ads
Ada
src/gen-artifacts-docs.ads
jquorning/dynamo
10d68571476c270b8e45a9c5ef585fa9139b0d05
[ "Apache-2.0" ]
15
2015-01-18T23:04:19.000Z
2022-03-01T20:27:08.000Z
src/gen-artifacts-docs.ads
jquorning/dynamo
10d68571476c270b8e45a9c5ef585fa9139b0d05
[ "Apache-2.0" ]
16
2018-06-10T07:09:30.000Z
2022-03-26T18:28:40.000Z
src/gen-artifacts-docs.ads
jquorning/dynamo
10d68571476c270b8e45a9c5ef585fa9139b0d05
[ "Apache-2.0" ]
3
2015-11-11T18:00:14.000Z
2022-01-30T23:08:45.000Z
----------------------------------------------------------------------- -- gen-artifacts-docs -- Artifact for documentation -- Copyright (C) 2012, 2015, 2017, 2018, 2019, 2020, 2021 Stephane Carrez -- Written by Stephane Carrez ([email protected]) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Ada.Containers.Indefinite_Vectors; with Ada.Containers.Indefinite_Hashed_Maps; with Ada.Strings.Hash; with Ada.Text_IO; with Gen.Model.Packages; private with Util.Strings.Maps; -- with Asis; -- with Asis.Text; -- with Asis.Elements; -- with Asis.Exceptions; -- with Asis.Errors; -- with Asis.Implementation; -- with Asis.Elements; -- with Asis.Declarations; -- The <b>Gen.Artifacts.Docs</b> package is an artifact for the generation of -- application documentation. Its purpose is to scan the project source files -- and extract some interesting information for a developer's guide. The artifact -- scans the Ada source files, the XML configuration files, the XHTML files. -- -- The generated documentation is intended to be published on a web site. -- The Google Wiki style is generated by default. -- -- 1/ In the first step, the project files are scanned and the useful -- documentation is extracted. -- -- 2/ In the second step, the documentation is merged and reconciled. Links to -- documentation pages and references are setup and the final pages are generated. -- -- Ada -- --- -- The documentation starts at the first '== TITLE ==' marker and finishes before the -- package specification. -- -- XHTML -- ----- -- Same as Ada. -- -- XML Files -- ---------- -- The documentation is part of the XML and the <b>documentation</b> or <b>description</b> -- tags are extracted. package Gen.Artifacts.Docs is -- Tag marker (same as Java). TAG_CHAR : constant Character := '@'; -- Specific tags recognized when analyzing the documentation. TAG_AUTHOR : constant String := "author"; TAG_TITLE : constant String := "title"; TAG_INCLUDE : constant String := "include"; TAG_INCLUDE_CONFIG : constant String := "include-config"; TAG_INCLUDE_BEAN : constant String := "include-bean"; TAG_INCLUDE_QUERY : constant String := "include-query"; TAG_INCLUDE_PERM : constant String := "include-permission"; TAG_INCLUDE_DOC : constant String := "include-doc"; TAG_SEE : constant String := "see"; Unknown_Tag : exception; type Doc_Format is (DOC_MARKDOWN, DOC_WIKI_GOOGLE); -- ------------------------------ -- Documentation artifact -- ------------------------------ type Artifact is new Gen.Artifacts.Artifact with private; -- Prepare the model after all the configuration files have been read and before -- actually invoking the generation. overriding procedure Prepare (Handler : in out Artifact; Model : in out Gen.Model.Packages.Model_Definition'Class; Project : in out Gen.Model.Projects.Project_Definition'Class; Context : in out Generator'Class); procedure Generate (Handler : in out Artifact; Context : in out Generator'Class); -- Set the output document format to generate. procedure Set_Format (Handler : in out Artifact; Format : in Doc_Format; Footer : in Boolean); -- Load from the file a list of link definitions which can be injected in the generated doc. -- This allows to avoid polluting the Ada code with external links. procedure Read_Links (Handler : in out Artifact; Path : in String); private type Line_Kind is (L_TEXT, L_LIST, L_LIST_ITEM, L_SEE, L_INCLUDE, L_INCLUDE_CONFIG, L_INCLUDE_BEAN, L_INCLUDE_PERMISSION, L_INCLUDE_QUERY, L_INCLUDE_DOC, L_START_CODE, L_END_CODE, L_HEADER_1, L_HEADER_2, L_HEADER_3, L_HEADER_4); subtype Line_Include_Kind is Line_Kind range L_INCLUDE .. L_INCLUDE_DOC; type Line_Type (Len : Natural) is record Kind : Line_Kind := L_TEXT; Content : String (1 .. Len); end record; package Line_Vectors is new Ada.Containers.Indefinite_Vectors (Index_Type => Positive, Element_Type => Line_Type); type Line_Group_Vector is array (Line_Include_Kind) of Line_Vectors.Vector; type Doc_State is (IN_PARA, IN_SEPARATOR, IN_CODE, IN_CODE_SEPARATOR, IN_LIST); type Document_Formatter is abstract tagged record Links : Util.Strings.Maps.Map; end record; type Document_Formatter_Access is access all Document_Formatter'Class; type File_Document is record Name : UString; Title : UString; State : Doc_State := IN_PARA; Line_Number : Natural := 0; Lines : Line_Group_Vector; Was_Included : Boolean := False; Print_Footer : Boolean := True; Formatter : Document_Formatter_Access; end record; -- Get the document name from the file document (ex: <name>.wiki or <name>.md). function Get_Document_Name (Formatter : in Document_Formatter; Document : in File_Document) return String is abstract; -- Start a new document. procedure Start_Document (Formatter : in out Document_Formatter; Document : in File_Document; File : in Ada.Text_IO.File_Type) is abstract; -- Write a line in the target document formatting the line if necessary. procedure Write_Line (Formatter : in out Document_Formatter; File : in Ada.Text_IO.File_Type; Line : in Line_Type) is abstract; -- Finish the document. procedure Finish_Document (Formatter : in out Document_Formatter; Document : in File_Document; File : in Ada.Text_IO.File_Type; Source : in String) is abstract; package Doc_Maps is new Ada.Containers.Indefinite_Hashed_Maps (Key_Type => String, Element_Type => File_Document, Hash => Ada.Strings.Hash, Equivalent_Keys => "="); -- Include the document extract represented by <b>Name</b> into the document <b>Into</b>. -- The included document is marked so that it will not be generated. procedure Include (Docs : in out Doc_Maps.Map; Source : in String; Into : in out File_Document; Name : in String; Mode : in Line_Include_Kind; Position : in Natural); -- Generate the project documentation that was collected in <b>Docs</b>. -- The documentation is merged so that the @include tags are replaced by the matching -- document extracts. procedure Generate (Handler : in out Artifact; Docs : in out Doc_Maps.Map; Dir : in String); -- Returns True if the line indicates a bullet or numbered list. function Is_List (Line : in String) return Boolean; -- Returns True if the line indicates a code sample. function Is_Code (Line : in String) return Boolean; -- Append a raw text line to the document. procedure Append_Line (Doc : in out File_Document; Line : in String); -- Look and analyze the tag defined on the line. procedure Append_Tag (Doc : in out File_Document; Tag : in String); -- Analyse the documentation line and collect the documentation text. procedure Append (Doc : in out File_Document; Line : in String); -- After having collected the documentation, terminate the document by making sure -- the opened elements are closed. procedure Finish (Doc : in out File_Document); -- Set the name associated with the document extract. procedure Set_Name (Doc : in out File_Document; Name : in String); -- Set the title associated with the document extract. procedure Set_Title (Doc : in out File_Document; Title : in String); -- Scan the files in the directory refered to by <b>Path</b> and collect the documentation -- in the <b>Docs</b> hashed map. procedure Scan_Files (Handler : in out Artifact; Path : in String; Docs : in out Doc_Maps.Map); -- Read the Ada specification/body file and collect the useful documentation. -- To keep the implementation simple, we don't use the ASIS packages to scan and extract -- the documentation. We don't need to look at the Ada specification itself. Instead, -- we assume that the Ada source follows some Ada style guidelines. procedure Read_Ada_File (Handler : in out Artifact; File : in String; Result : in out File_Document); procedure Read_Xml_File (Handler : in out Artifact; File : in String; Result : in out File_Document); -- Read some general purpose documentation files. The documentation file -- can be integrated and merged by using the @include-doc tags and it may -- contain various @ tags. procedure Read_Doc_File (Handler : in out Artifact; File : in String; Result : in out File_Document); type Artifact is new Gen.Artifacts.Artifact with record Xslt_Command : UString; Format : Doc_Format := DOC_WIKI_GOOGLE; Print_Footer : Boolean := True; Formatter : Document_Formatter_Access; end record; end Gen.Artifacts.Docs;
42.310757
96
0.61629
38f17a40745decbf9e372db1632e5331e7983a44
2,467
adb
Ada
software/hal/boards/pixracer_v1/hil/hil-buzzer.adb
TUM-EI-RCS/StratoX
5fdd04e01a25efef6052376f43ce85b5bc973392
[ "BSD-3-Clause" ]
12
2017-06-08T14:19:57.000Z
2022-03-09T02:48:59.000Z
software/hal/boards/pixracer_v1/hil/hil-buzzer.adb
TUM-EI-RCS/StratoX
5fdd04e01a25efef6052376f43ce85b5bc973392
[ "BSD-3-Clause" ]
6
2017-06-08T13:13:50.000Z
2020-05-15T09:32:43.000Z
software/hal/boards/pixracer_v1/hil/hil-buzzer.adb
TUM-EI-RCS/StratoX
5fdd04e01a25efef6052376f43ce85b5bc973392
[ "BSD-3-Clause" ]
3
2017-06-30T14:05:06.000Z
2022-02-17T12:20:45.000Z
-- Institution: Technische Universitaet Muenchen -- Department: Realtime Computer Systems (RCS) -- Project: StratoX -- -- Authors: Martin Becker ([email protected]> with HIL.Config; with HIL.Timers; with HIL.Devices.Timers; -- @summary -- Target-independent specification for simple HIL of Piezo Buzzer package body HIL.Buzzer is procedure Initialize is begin case HIL.Config.BUZZER_PORT is when HIL.Config.BUZZER_USE_AUX5 => HIL.Timers.Initialize (HIL.Devices.Timers.Timer_Buzzer_Aux); when HIL.Config.BUZZER_USE_PORT => HIL.Timers.Initialize (HIL.Devices.Timers.Timer_Buzzer_Port); end case; end Initialize; procedure Enable is begin case HIL.Config.BUZZER_PORT is when HIL.Config.BUZZER_USE_AUX5 => HIL.Timers.Enable (t => HIL.Devices.Timers.Timer_Buzzer_Aux, ch => HIL.Devices.Timers.Timerchannel_Buzzer_Aux); when HIL.Config.BUZZER_USE_PORT => HIL.Timers.Enable (t => HIL.Devices.Timers.Timer_Buzzer_Port, ch => HIL.Devices.Timers.Timerchannel_Buzzer_Port); end case; end Enable; procedure Disable is begin case HIL.Config.BUZZER_PORT is when HIL.Config.BUZZER_USE_AUX5 => HIL.Timers.Disable (t => HIL.Devices.Timers.Timer_Buzzer_Aux, ch => HIL.Devices.Timers.Timerchannel_Buzzer_Aux); when HIL.Config.BUZZER_USE_PORT => HIL.Timers.Disable (t => HIL.Devices.Timers.Timer_Buzzer_Port, ch => HIL.Devices.Timers.Timerchannel_Buzzer_Port); end case; end Disable; procedure Set_Frequency (Frequency : Units.Frequency_Type) is begin case HIL.Config.BUZZER_PORT is when HIL.Config.BUZZER_USE_AUX5 => HIL.Timers.Configure_OC_Toggle (This => HIL.Devices.Timers.Timer_Buzzer_Aux, Channel => HIL.Devices.Timers.Timerchannel_Buzzer_Aux, Frequency => Frequency); when HIL.Config.BUZZER_USE_PORT => HIL.Timers.Configure_OC_Toggle (This => HIL.Devices.Timers.Timer_Buzzer_Port, Channel => HIL.Devices.Timers.Timerchannel_Buzzer_Port, Frequency => Frequency); end case; end Set_Frequency; end HIL.Buzzer;
36.279412
99
0.617349
ad57f51e04dbbedd14d09232e61cfe32519b14fa
3,229
adb
Ada
Sources/Globe_3d/objects/globe_3d-sprite.adb
ForYouEyesOnly/Space-Convoy
be4904f6a02695f7c4c5c3c965f4871cd3250003
[ "MIT" ]
1
2019-09-21T09:40:34.000Z
2019-09-21T09:40:34.000Z
Sources/Globe_3d/objects/globe_3d-sprite.adb
ForYouEyesOnly/Space-Convoy
be4904f6a02695f7c4c5c3c965f4871cd3250003
[ "MIT" ]
null
null
null
Sources/Globe_3d/objects/globe_3d-sprite.adb
ForYouEyesOnly/Space-Convoy
be4904f6a02695f7c4c5c3c965f4871cd3250003
[ "MIT" ]
1
2019-09-25T12:29:27.000Z
2019-09-25T12:29:27.000Z
pragma Warnings (Off); pragma Style_Checks (Off); with GLOBE_3D.Textures, GLOBE_3D.Math; package body GLOBE_3D.Sprite is package G3DT renames GLOBE_3D.Textures; package G3DM renames GLOBE_3D.Math; function skinned_Geometrys (o : in Sprite) return GL.skinned_geometry.skinned_Geometrys is begin return o.skinned_Geometrys (1 .. o.skinned_geometry_Count); end; procedure add (o : in out Sprite; Geometry : access GL.geometry.Geometry_t'Class; Skin : access GL.skins.Skin'Class) is new_skinned_Geometry : access GL.skinned_Geometry.Skinned_Geometry_t := new GL.skinned_Geometry.Skinned_Geometry_t; begin o.skinned_geometry_Count := o.skinned_geometry_Count + 1; o.skinned_Geometrys (o.skinned_geometry_Count) := (geometry => Geometry.all'Access, skin => Skin.all'Access, veneer => Skin.new_Veneer (for_geometry => Geometry.all)); end; procedure Pre_calculate (o : in out Sprite) is use GL, GL.Geometry, G3DM; begin --vertex_cache_optimise (o); -- tbd : doesn't seem to help !! . .. : ( -- at least with terrain . .. (terrain dataset may already naturally be in optimal order ?) -- so need to test with other dataset o.Bounds := null_Bounds; o.face_Count := 0; for Each in 1 .. o.skinned_geometry_Count loop o.Bounds := max (o.Bounds, o.skinned_Geometrys (Each).geometry.Bounds); o.face_Count := o.face_Count + o.skinned_Geometrys (Each).geometry.face_Count; end loop; -- setup bounding_sphere (for debug) -- -- declare -- use GLU; -- begin -- if o.bounding_sphere_Quadric /= null then -- glu.quadricDrawStyle (o.bounding_sphere_Quadric, glu.glu_LINE); -- end if; -- end; -- Ooof. Now we can certify: --o.pre_calculated := True; end Pre_calculate; procedure destroy (o : in out Sprite) is begin null; end; function face_Count (o : in Sprite) return Natural is begin return o.face_Count; end; function Bounds (o : in Sprite) return GL.geometry.Bounds_record is begin return o.Bounds; end; procedure Display (o : in out Sprite; clip : in Clipping_data) is begin null; -- actual display is done by the renderer (ie glut.Windows), which requests all skinned Geometry's -- and then applies 'gl state' sorting for performance, before drawing. end Display; procedure set_Alpha (o : in out Sprite; Alpha : in GL.Double) is begin null; -- tbd end; function is_Transparent (o : in Sprite) return Boolean is begin return o.is_Transparent; -- tbd : ensure this is updated when new primitives (with possible transparent appearance' are added. end; end GLOBE_3D.Sprite;
32.616162
134
0.577888
1eb8286af02a8319e052121010cfbfa5f6b5c4fd
2,811
ads
Ada
tools-src/gnu/gcc/gcc/ada/impunit.ads
modern-tomato/tomato
96f09fab4929c6ddde5c9113f1b2476ad37133c4
[ "FSFAP" ]
80
2015-01-02T10:14:04.000Z
2021-06-07T06:29:49.000Z
tools-src/gnu/gcc/gcc/ada/impunit.ads
modern-tomato/tomato
96f09fab4929c6ddde5c9113f1b2476ad37133c4
[ "FSFAP" ]
9
2015-05-14T11:03:12.000Z
2018-01-04T07:12:58.000Z
tools-src/gnu/gcc/gcc/ada/impunit.ads
modern-tomato/tomato
96f09fab4929c6ddde5c9113f1b2476ad37133c4
[ "FSFAP" ]
69
2015-01-02T10:45:56.000Z
2021-09-06T07:52:13.000Z
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- I M P U N I T -- -- -- -- S p e c -- -- -- -- $Revision$ -- -- -- Copyright (C) 2000 Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT 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 distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, -- -- MA 02111-1307, USA. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This package contains data and functions used to determine if a given -- unit is an internal unit intended only for use by the implementation -- and which should not be directly WITH'ed by user code. with Types; use Types; package Impunit is function Implementation_Unit (U : Unit_Number_Type) return Boolean; -- Given the unit number of a unit, this function determines if it is a -- unit that is intended to be used only internally by the implementation. -- This is used for posting warnings for improper WITH's of such units -- (such WITH's are allowed without warnings only in GNAT_Mode set by -- the use of -gnatg). True is returned if a warning should be posted. end Impunit;
62.466667
78
0.443259
4bb75ac615602d2bed6bfb70ff7ff3245f65c6df
12,353
adb
Ada
testsuite/league/grapheme_cluster_cursor_test.adb
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
24
2016-11-29T06:59:41.000Z
2021-08-30T11:55:16.000Z
testsuite/league/grapheme_cluster_cursor_test.adb
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
2
2019-01-16T05:15:20.000Z
2019-02-03T10:03:32.000Z
testsuite/league/grapheme_cluster_cursor_test.adb
svn2github/matreshka
9d222b3ad9da508855fb1f5adbe5e8a4fad4c530
[ "BSD-3-Clause" ]
4
2017-07-18T07:11:05.000Z
2020-06-21T03:02:25.000Z
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Localization, Internationalization, Globalization for Ada -- -- -- -- Testsuite Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2010-2012, Vadim Godunko <[email protected]> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ with Ada.Command_Line; with Ada.Unchecked_Deallocation; with Ada.Wide_Wide_Text_IO; with League.Application; with League.Characters; with League.Strings.Cursors.Grapheme_Clusters; procedure Grapheme_Cluster_Cursor_Test is use League.Strings; use League.Strings.Cursors.Grapheme_Clusters; Break_Character : constant Wide_Wide_Character := '÷'; No_Break_Character : constant Wide_Wide_Character := '×'; type Wide_Wide_String_Access is access all Wide_Wide_String; type Test_Data is array (Positive range <>) of Wide_Wide_String_Access; type Test_Data_Access is access all Test_Data; procedure Free is new Ada.Unchecked_Deallocation (Wide_Wide_String, Wide_Wide_String_Access); procedure Free is new Ada.Unchecked_Deallocation (Test_Data, Test_Data_Access); procedure Read_Test_Data (File_Name : String; Process : not null access procedure (Item : in out Universal_String; Data : Test_Data)); procedure Deep_Free (X : in out Test_Data_Access); procedure Do_Test (Item : in out Universal_String; Data : Test_Data); --------------- -- Deep_Free -- --------------- procedure Deep_Free (X : in out Test_Data_Access) is begin for J in X'Range loop Free (X (J)); end loop; Free (X); end Deep_Free; ------------- -- Do_Test -- ------------- procedure Do_Test (Item : in out Universal_String; Data : Test_Data) is J : Grapheme_Cluster_Cursor; N : Natural := 1; begin -- Test forward-backward iterator J.First (Item); while J.Has_Element loop if J.Element.To_Wide_Wide_String /= Data (N).all then raise Program_Error; end if; J.Next; N := N + 1; end loop; J.Previous; N := N - 1; while J.Has_Element loop if J.Element.To_Wide_Wide_String /= Data (N).all then raise Program_Error; end if; J.Previous; N := N - 1; end loop; -- Test backward-forward iterator J.Last (Item); N := Data'Last; while J.Has_Element loop if J.Element.To_Wide_Wide_String /= Data (N).all then raise Program_Error; end if; J.Previous; N := N - 1; end loop; J.Next; N := N + 1; while J.Has_Element loop if J.Element.To_Wide_Wide_String /= Data (N).all then raise Program_Error; end if; J.Next; N := N + 1; end loop; end Do_Test; -------------------- -- Read_Test_Data -- -------------------- procedure Read_Test_Data (File_Name : String; Process : not null access procedure (Item : in out Universal_String; Data : Test_Data)) is File : Ada.Wide_Wide_Text_IO.File_Type; Line : Wide_Wide_String (1 .. 1_024); Last : Natural; begin Ada.Wide_Wide_Text_IO.Open (File, Ada.Wide_Wide_Text_IO.In_File, File_Name, "wcem=8"); while not Ada.Wide_Wide_Text_IO.End_Of_File (File) loop Ada.Wide_Wide_Text_IO.Get_Line (File, Line, Last); -- Remove comment for J in 1 .. Last loop if Line (J) = '#' then Last := J - 1; exit; end if; end loop; -- Remove trailing spaces for J in reverse 1 .. Last loop if Line (J) /= ' ' then Last := J - 1; exit; end if; end loop; if Last /= 0 then declare Token_First : Positive := 1; Item : Wide_Wide_String_Access; Data : Test_Data_Access; Source : Wide_Wide_String_Access; X : Universal_String; procedure Skip_Spaces; procedure Parse_Break_Indicator; procedure Parse_Code_Point; --------------------------- -- Parse_Break_Indicator -- --------------------------- procedure Parse_Break_Indicator is Aux : Test_Data_Access := Data; begin Skip_Spaces; case Line (Token_First) is when Break_Character => if Item /= null then if Data = null then Data := new Test_Data (1 .. 1); else Data := new Test_Data (1 .. Aux'Last + 1); Data (Aux'Range) := Aux.all; Free (Aux); end if; Data (Data'Last) := Item; Item := null; end if; when No_Break_Character => null; when others => raise Constraint_Error with "Wrong format of the file"; end case; Token_First := Token_First + 1; end Parse_Break_Indicator; ---------------------- -- Parse_Code_Point -- ---------------------- procedure Parse_Code_Point is Token_Last : Positive; Aux : Wide_Wide_String_Access := Item; begin Skip_Spaces; Token_Last := Token_First; while Token_Last <= Last loop case Line (Token_Last) is when '0' .. '9' | 'A' .. 'F' => null; when ' ' => Token_Last := Token_Last - 1; exit; when others => raise Constraint_Error with "Wrong format of the file"; end case; Token_Last := Token_Last + 1; end loop; if Item = null then Item := new Wide_Wide_String (1 .. 1); else Item := new Wide_Wide_String (1 .. Aux'Last + 1); Item (Aux'Range) := Aux.all; Free (Aux); end if; Item (Item'Last) := Wide_Wide_Character'Val (Integer'Wide_Wide_Value ("16#" & Line (Token_First .. Token_Last) & '#')); if Source = null then Source := new Wide_Wide_String (1 .. 1); else Aux := Source; Source := new Wide_Wide_String (1 .. Aux'Last + 1); Source (Aux'Range) := Aux.all; Free (Aux); end if; Source (Source'Last) := Wide_Wide_Character'Val (Integer'Wide_Wide_Value ("16#" & Line (Token_First .. Token_Last) & '#')); Token_First := Token_Last + 1; end Parse_Code_Point; ----------------- -- Skip_Spaces -- ----------------- procedure Skip_Spaces is begin for J in Token_First .. Last loop if Line (J) /= ' ' then Token_First := J; exit; end if; end loop; end Skip_Spaces; OK : Boolean := True; begin Parse_Break_Indicator; while Token_First <= Last loop Parse_Code_Point; Parse_Break_Indicator; end loop; -- Check whether all source characters are valid Unicode -- characters. Unicode 6.1.0 introduce use of surrogate code -- points in test data, these tests can't be used to check -- Matreshka, because such data is invalid. for J in Source'Range loop if not League.Characters.To_Universal_Character (Source (J)).Is_Valid then OK := False; exit; end if; end loop; if OK then X := To_Universal_String (Source.all); Process (X, Data.all); end if; Deep_Free (Data); Free (Source); end; end if; end loop; Ada.Wide_Wide_Text_IO.Close (File); end Read_Test_Data; begin Read_Test_Data (Ada.Command_Line.Argument (1) & '/' & "auxiliary/GraphemeBreakTest.txt", Do_Test'Access); end Grapheme_Cluster_Cursor_Test;
33.751366
79
0.443212
1e37ca8cefd1b438e0ec78d40dd7f417a6938042
6,688
adb
Ada
src/drivers/eic_u2254/sam-eic.adb
Fabien-Chouteau/samd51-hal
54d4b29df100502d8b3e3b4680a198640faa5f4d
[ "BSD-3-Clause" ]
1
2020-02-24T23:19:03.000Z
2020-02-24T23:19:03.000Z
src/drivers/eic_u2254/sam-eic.adb
Fabien-Chouteau/samd51-hal
54d4b29df100502d8b3e3b4680a198640faa5f4d
[ "BSD-3-Clause" ]
null
null
null
src/drivers/eic_u2254/sam-eic.adb
Fabien-Chouteau/samd51-hal
54d4b29df100502d8b3e3b4680a198640faa5f4d
[ "BSD-3-Clause" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- Copyright (C) 2020, AdaCore -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions are -- -- met: -- -- 1. Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- 2. Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in -- -- the documentation and/or other materials provided with the -- -- distribution. -- -- 3. Neither the name of the copyright holder nor the names of its -- -- contributors may be used to endorse or promote products derived -- -- from this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -- -- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -- -- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -- -- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -- -- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -- -- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ with HAL; use HAL; with SAM_SVD.EIC; use SAM_SVD.EIC; package body SAM.EIC is ----------------- -- EIC_Enabled -- ----------------- function EIC_Enabled return Boolean is (EIC_Periph.CTRLA.ENABLE); ---------------- -- Enable_EIC -- ---------------- procedure Enable_EIC (Clock : EIC_Clock) is begin EIC_Periph.CTRLA.CKSEL := CTRLA_CKSELSelect'Enum_Val (if Clock = CLK_ULP32K then 1 else 0); EIC_Periph.CTRLA.ENABLE := True; while EIC_Periph.SYNCBUSY.ENABLE loop null; end loop; end Enable_EIC; --------------- -- Configure -- --------------- procedure Configure (Pin : EXTINT_Pin; Sense : Sense_Kind; Enable_Interrupt : Boolean; Debouncer : Boolean; Event_Output : Boolean := False) is CFG_Reg : constant Natural := (if Pin < 8 then 0 else 1); CFG_Index : constant Natural := Natural (Pin) mod 8; Pin_Mask : constant UInt16 := UInt16 (2 ** Natural (Pin)); begin case CFG_Index is when 0 => EIC_Periph.CONFIG (CFG_Reg).SENSE0 := CONFIG_SENSE0Select'Enum_Val (Sense_Kind'Enum_Rep (Sense)); when 1 => EIC_Periph.CONFIG (CFG_Reg).SENSE1 := CONFIG_SENSE1Select'Enum_Val (Sense_Kind'Enum_Rep (Sense)); when 2 => EIC_Periph.CONFIG (CFG_Reg).SENSE2 := CONFIG_SENSE2Select'Enum_Val (Sense_Kind'Enum_Rep (Sense)); when 3 => EIC_Periph.CONFIG (CFG_Reg).SENSE3 := CONFIG_SENSE3Select'Enum_Val (Sense_Kind'Enum_Rep (Sense)); when 4 => EIC_Periph.CONFIG (CFG_Reg).SENSE4 := CONFIG_SENSE4Select'Enum_Val (Sense_Kind'Enum_Rep (Sense)); when 5 => EIC_Periph.CONFIG (CFG_Reg).SENSE5 := CONFIG_SENSE5Select'Enum_Val (Sense_Kind'Enum_Rep (Sense)); when 6 => EIC_Periph.CONFIG (CFG_Reg).SENSE6 := CONFIG_SENSE6Select'Enum_Val (Sense_Kind'Enum_Rep (Sense)); when others => EIC_Periph.CONFIG (CFG_Reg).SENSE7 := CONFIG_SENSE7Select'Enum_Val (Sense_Kind'Enum_Rep (Sense)); end case; if Enable_Interrupt then EIC_Periph.INTENSET.EXTINT := Pin_Mask; else EIC_Periph.INTENCLR.EXTINT := Pin_Mask; end if; if Debouncer then EIC_Periph.DEBOUNCEN.DEBOUNCEN := EIC_Periph.DEBOUNCEN.DEBOUNCEN or Pin_Mask; else EIC_Periph.DEBOUNCEN.DEBOUNCEN := EIC_Periph.DEBOUNCEN.DEBOUNCEN and (not Pin_Mask); end if; if Event_Output then EIC_Periph.EVCTRL.EXTINTEO := EIC_Periph.EVCTRL.EXTINTEO or Pin_Mask; else EIC_Periph.EVCTRL.EXTINTEO := EIC_Periph.EVCTRL.EXTINTEO and (not Pin_Mask); end if; end Configure; --------------- -- Pin_State -- --------------- function Pin_State (Pin : EXTINT_Pin) return Boolean is Pin_Mask : constant UInt16 := UInt16 (2 ** Natural (Pin)); begin return (EIC_Periph.PINSTATE.PINSTATE and Pin_Mask) /= 0; end Pin_State; ---------------------- -- Enable_Interrupt -- ---------------------- procedure Enable_Interrupt (Pin : EXTINT_Pin) is Pin_Mask : constant UInt16 := UInt16 (2 ** Natural (Pin)); begin EIC_Periph.INTENSET.EXTINT := Pin_Mask; end Enable_Interrupt; ----------------------- -- Disable_Interrupt -- ----------------------- procedure Disable_Interrupt (Pin : EXTINT_Pin) is Pin_Mask : constant UInt16 := UInt16 (2 ** Natural (Pin)); begin EIC_Periph.INTENCLR.EXTINT := Pin_Mask; end Disable_Interrupt; --------------------- -- Clear_Interrupt -- --------------------- procedure Clear_Interrupt (Pin : EXTINT_Pin) is Pin_Mask : constant UInt16 := UInt16 (2 ** Natural (Pin)); begin EIC_Periph.INTFLAG.EXTINT := Pin_Mask; end Clear_Interrupt; --------------------- -- Interrupt_State -- --------------------- function Interrupt_State (Pin : EXTINT_Pin) return Boolean is Pin_Mask : constant UInt16 := UInt16 (2 ** Natural (Pin)); begin return (EIC_Periph.INTFLAG.EXTINT and Pin_Mask) /= 0; end Interrupt_State; end SAM.EIC;
38
78
0.5468
9ada8595723faeb59e5dde7ccd9b6bfe1376ca14
13,546
ads
Ada
src/other/ext/tcl/compat/zlib/contrib/ada/zlib.ads
starkaiser/brlcad
5f2487db0ccafc0fea7a342c7955541ce382f6ed
[ "BSD-4-Clause", "BSD-3-Clause" ]
83
2021-03-10T05:54:52.000Z
2022-03-31T16:33:46.000Z
src/other/ext/tcl/compat/zlib/contrib/ada/zlib.ads
starkaiser/brlcad
5f2487db0ccafc0fea7a342c7955541ce382f6ed
[ "BSD-4-Clause", "BSD-3-Clause" ]
13
2021-06-24T17:07:48.000Z
2022-03-31T15:31:33.000Z
src/other/ext/tcl/compat/zlib/contrib/ada/zlib.ads
starkaiser/brlcad
5f2487db0ccafc0fea7a342c7955541ce382f6ed
[ "BSD-4-Clause", "BSD-3-Clause" ]
54
2021-03-10T07:57:06.000Z
2022-03-28T23:20:37.000Z
------------------------------------------------------------------------------ -- ZLib for Ada thick binding. -- -- -- -- Copyright (C) 2002-2004 Dmitriy Anisimkov -- -- -- -- This library 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 library 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 library; if not, write to the Free Software Foundation, -- -- Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -- -- -- -- As a special exception, if other files instantiate generics from this -- -- unit, or you link this unit with other files to produce an executable, -- -- this unit does not by itself cause the resulting executable to be -- -- covered by the GNU General Public License. This exception does not -- -- however invalidate any other reasons why the executable file might be -- -- covered by the GNU Public License. -- ------------------------------------------------------------------------------ -- $Id$ with Ada.Streams; with Interfaces; package ZLib is ZLib_Error : exception; Status_Error : exception; type Compression_Level is new Integer range -1 .. 9; type Flush_Mode is private; type Compression_Method is private; type Window_Bits_Type is new Integer range 8 .. 15; type Memory_Level_Type is new Integer range 1 .. 9; type Unsigned_32 is new Interfaces.Unsigned_32; type Strategy_Type is private; type Header_Type is (None, Auto, Default, GZip); -- Header type usage have a some limitation for inflate. -- See comment for Inflate_Init. subtype Count is Ada.Streams.Stream_Element_Count; Default_Memory_Level : constant Memory_Level_Type := 8; Default_Window_Bits : constant Window_Bits_Type := 15; ---------------------------------- -- Compression method constants -- ---------------------------------- Deflated : constant Compression_Method; -- Only one method allowed in this ZLib version --------------------------------- -- Compression level constants -- --------------------------------- No_Compression : constant Compression_Level := 0; Best_Speed : constant Compression_Level := 1; Best_Compression : constant Compression_Level := 9; Default_Compression : constant Compression_Level := -1; -------------------------- -- Flush mode constants -- -------------------------- No_Flush : constant Flush_Mode; -- Regular way for compression, no flush Partial_Flush : constant Flush_Mode; -- Will be removed, use Z_SYNC_FLUSH instead Sync_Flush : constant Flush_Mode; -- All pending output is flushed to the output buffer and the output -- is aligned on a byte boundary, so that the decompressor can get all -- input data available so far. (In particular avail_in is zero after the -- call if enough output space has been provided before the call.) -- Flushing may degrade compression for some compression algorithms and so -- it should be used only when necessary. Block_Flush : constant Flush_Mode; -- Z_BLOCK requests that inflate() stop -- if and when it get to the next deflate block boundary. When decoding the -- zlib or gzip format, this will cause inflate() to return immediately -- after the header and before the first block. When doing a raw inflate, -- inflate() will go ahead and process the first block, and will return -- when it gets to the end of that block, or when it runs out of data. Full_Flush : constant Flush_Mode; -- All output is flushed as with SYNC_FLUSH, and the compression state -- is reset so that decompression can restart from this point if previous -- compressed data has been damaged or if random access is desired. Using -- Full_Flush too often can seriously degrade the compression. Finish : constant Flush_Mode; -- Just for tell the compressor that input data is complete. ------------------------------------ -- Compression strategy constants -- ------------------------------------ -- RLE stategy could be used only in version 1.2.0 and later. Filtered : constant Strategy_Type; Huffman_Only : constant Strategy_Type; RLE : constant Strategy_Type; Default_Strategy : constant Strategy_Type; Default_Buffer_Size : constant := 4096; type Filter_Type is tagged limited private; -- The filter is for compression and for decompression. -- The usage of the type is depend of its initialization. function Version return String; pragma Inline (Version); -- Return string representation of the ZLib version. procedure Deflate_Init (Filter : in out Filter_Type; Level : in Compression_Level := Default_Compression; Strategy : in Strategy_Type := Default_Strategy; Method : in Compression_Method := Deflated; Window_Bits : in Window_Bits_Type := Default_Window_Bits; Memory_Level : in Memory_Level_Type := Default_Memory_Level; Header : in Header_Type := Default); -- Compressor initialization. -- When Header parameter is Auto or Default, then default zlib header -- would be provided for compressed data. -- When Header is GZip, then gzip header would be set instead of -- default header. -- When Header is None, no header would be set for compressed data. procedure Inflate_Init (Filter : in out Filter_Type; Window_Bits : in Window_Bits_Type := Default_Window_Bits; Header : in Header_Type := Default); -- Decompressor initialization. -- Default header type mean that ZLib default header is expecting in the -- input compressed stream. -- Header type None mean that no header is expecting in the input stream. -- GZip header type mean that GZip header is expecting in the -- input compressed stream. -- Auto header type mean that header type (GZip or Native) would be -- detected automatically in the input stream. -- Note that header types parameter values None, GZip and Auto are -- supported for inflate routine only in ZLib versions 1.2.0.2 and later. -- Deflate_Init is supporting all header types. function Is_Open (Filter : in Filter_Type) return Boolean; pragma Inline (Is_Open); -- Is the filter opened for compression or decompression. procedure Close (Filter : in out Filter_Type; Ignore_Error : in Boolean := False); -- Closing the compression or decompressor. -- If stream is closing before the complete and Ignore_Error is False, -- The exception would be raised. generic with procedure Data_In (Item : out Ada.Streams.Stream_Element_Array; Last : out Ada.Streams.Stream_Element_Offset); with procedure Data_Out (Item : in Ada.Streams.Stream_Element_Array); procedure Generic_Translate (Filter : in out Filter_Type; In_Buffer_Size : in Integer := Default_Buffer_Size; Out_Buffer_Size : in Integer := Default_Buffer_Size); -- Compress/decompress data fetch from Data_In routine and pass the result -- to the Data_Out routine. User should provide Data_In and Data_Out -- for compression/decompression data flow. -- Compression or decompression depend on Filter initialization. function Total_In (Filter : in Filter_Type) return Count; pragma Inline (Total_In); -- Returns total number of input bytes read so far function Total_Out (Filter : in Filter_Type) return Count; pragma Inline (Total_Out); -- Returns total number of bytes output so far function CRC32 (CRC : in Unsigned_32; Data : in Ada.Streams.Stream_Element_Array) return Unsigned_32; pragma Inline (CRC32); -- Compute CRC32, it could be necessary for make gzip format procedure CRC32 (CRC : in out Unsigned_32; Data : in Ada.Streams.Stream_Element_Array); pragma Inline (CRC32); -- Compute CRC32, it could be necessary for make gzip format ------------------------------------------------- -- Below is more complex low level routines. -- ------------------------------------------------- procedure Translate (Filter : in out Filter_Type; In_Data : in Ada.Streams.Stream_Element_Array; In_Last : out Ada.Streams.Stream_Element_Offset; Out_Data : out Ada.Streams.Stream_Element_Array; Out_Last : out Ada.Streams.Stream_Element_Offset; Flush : in Flush_Mode); -- Compress/decompress the In_Data buffer and place the result into -- Out_Data. In_Last is the index of last element from In_Data accepted by -- the Filter. Out_Last is the last element of the received data from -- Filter. To tell the filter that incoming data are complete put the -- Flush parameter to Finish. function Stream_End (Filter : in Filter_Type) return Boolean; pragma Inline (Stream_End); -- Return the true when the stream is complete. procedure Flush (Filter : in out Filter_Type; Out_Data : out Ada.Streams.Stream_Element_Array; Out_Last : out Ada.Streams.Stream_Element_Offset; Flush : in Flush_Mode); pragma Inline (Flush); -- Flushing the data from the compressor. generic with procedure Write (Item : in Ada.Streams.Stream_Element_Array); -- User should provide this routine for accept -- compressed/decompressed data. Buffer_Size : in Ada.Streams.Stream_Element_Offset := Default_Buffer_Size; -- Buffer size for Write user routine. procedure Write (Filter : in out Filter_Type; Item : in Ada.Streams.Stream_Element_Array; Flush : in Flush_Mode := No_Flush); -- Compress/Decompress data from Item to the generic parameter procedure -- Write. Output buffer size could be set in Buffer_Size generic parameter. generic with procedure Read (Item : out Ada.Streams.Stream_Element_Array; Last : out Ada.Streams.Stream_Element_Offset); -- User should provide data for compression/decompression -- thru this routine. Buffer : in out Ada.Streams.Stream_Element_Array; -- Buffer for keep remaining data from the previous -- back read. Rest_First, Rest_Last : in out Ada.Streams.Stream_Element_Offset; -- Rest_First have to be initialized to Buffer'Last + 1 -- Rest_Last have to be initialized to Buffer'Last -- before usage. Allow_Read_Some : in Boolean := False; -- Is it allowed to return Last < Item'Last before end of data. procedure Read (Filter : in out Filter_Type; Item : out Ada.Streams.Stream_Element_Array; Last : out Ada.Streams.Stream_Element_Offset; Flush : in Flush_Mode := No_Flush); -- Compress/Decompress data from generic parameter procedure Read to the -- Item. User should provide Buffer and initialized Rest_First, Rest_Last -- indicators. If Allow_Read_Some is True, Read routines could return -- Last < Item'Last only at end of stream. private use Ada.Streams; pragma Assert (Ada.Streams.Stream_Element'Size = 8); pragma Assert (Ada.Streams.Stream_Element'Modulus = 2**8); type Flush_Mode is new Integer range 0 .. 5; type Compression_Method is new Integer range 8 .. 8; type Strategy_Type is new Integer range 0 .. 3; No_Flush : constant Flush_Mode := 0; Partial_Flush : constant Flush_Mode := 1; Sync_Flush : constant Flush_Mode := 2; Full_Flush : constant Flush_Mode := 3; Finish : constant Flush_Mode := 4; Block_Flush : constant Flush_Mode := 5; Filtered : constant Strategy_Type := 1; Huffman_Only : constant Strategy_Type := 2; RLE : constant Strategy_Type := 3; Default_Strategy : constant Strategy_Type := 0; Deflated : constant Compression_Method := 8; type Z_Stream; type Z_Stream_Access is access all Z_Stream; type Filter_Type is tagged limited record Strm : Z_Stream_Access; Compression : Boolean; Stream_End : Boolean; Header : Header_Type; CRC : Unsigned_32; Offset : Stream_Element_Offset; -- Offset for gzip header/footer output. end record; end ZLib;
41.173252
79
0.629337
1e6bb2e7eabf81bc7a522f46f0fd28965a628b8a
5,925
adb
Ada
llvm-gcc-4.2-2.9/gcc/ada/a-swuwti.adb
vidkidz/crossbridge
ba0bf94aee0ce6cf7eb5be882382e52bc57ba396
[ "MIT" ]
1
2016-04-09T02:58:13.000Z
2016-04-09T02:58:13.000Z
llvm-gcc-4.2-2.9/gcc/ada/a-swuwti.adb
vidkidz/crossbridge
ba0bf94aee0ce6cf7eb5be882382e52bc57ba396
[ "MIT" ]
null
null
null
llvm-gcc-4.2-2.9/gcc/ada/a-swuwti.adb
vidkidz/crossbridge
ba0bf94aee0ce6cf7eb5be882382e52bc57ba396
[ "MIT" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- ADA.STRINGS.WIDE_UNBOUNDED.WIDE_TEXT_IO -- -- -- -- B o d y -- -- -- -- Copyright (C) 1997-2005, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT 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 distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, -- -- Boston, MA 02110-1301, USA. -- -- -- -- As a special exception, if other files instantiate generics from this -- -- unit, or you link this unit with other files to produce an executable, -- -- this unit does not by itself cause the resulting executable to be -- -- covered by the GNU General Public License. This exception does not -- -- however invalidate any other reasons why the executable file might be -- -- covered by the GNU Public License. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with Ada.Wide_Text_IO; use Ada.Wide_Text_IO; package body Ada.Strings.Wide_Unbounded.Wide_Text_IO is -------------- -- Get_Line -- -------------- function Get_Line return Unbounded_Wide_String is Buffer : Wide_String (1 .. 1000); Last : Natural; Str1 : Wide_String_Access; Str2 : Wide_String_Access; Result : Unbounded_Wide_String; begin Get_Line (Buffer, Last); Str1 := new Wide_String'(Buffer (1 .. Last)); while Last = Buffer'Last loop Get_Line (Buffer, Last); Str2 := new Wide_String'(Str1.all & Buffer (1 .. Last)); Free (Str1); Str1 := Str2; end loop; Result.Reference := Str1; Result.Last := Str1'Length; return Result; end Get_Line; function Get_Line (File : Ada.Wide_Text_IO.File_Type) return Unbounded_Wide_String is Buffer : Wide_String (1 .. 1000); Last : Natural; Str1 : Wide_String_Access; Str2 : Wide_String_Access; Result : Unbounded_Wide_String; begin Get_Line (File, Buffer, Last); Str1 := new Wide_String'(Buffer (1 .. Last)); while Last = Buffer'Last loop Get_Line (File, Buffer, Last); Str2 := new Wide_String'(Str1.all & Buffer (1 .. Last)); Free (Str1); Str1 := Str2; end loop; Result.Reference := Str1; Result.Last := Str1'Length; return Result; end Get_Line; procedure Get_Line (Item : out Unbounded_Wide_String) is begin Get_Line (Current_Input, Item); end Get_Line; procedure Get_Line (File : Ada.Wide_Text_IO.File_Type; Item : out Unbounded_Wide_String) is begin -- We are going to read into the string that is already there and -- allocated. Hopefully it is big enough now, if not, we will extend -- it in the usual manner using Realloc_For_Chunk. -- Make sure we start with at least 80 characters if Item.Reference'Last < 80 then Realloc_For_Chunk (Item, 80); end if; -- Loop to read data, filling current string as far as possible. -- Item.Last holds the number of characters read so far. Item.Last := 0; loop Get_Line (File, Item.Reference (Item.Last + 1 .. Item.Reference'Last), Item.Last); -- If we hit the end of the line before the end of the buffer, then -- we are all done, and the result length is properly set. if Item.Last < Item.Reference'Last then return; end if; -- If not enough room, double it and keep reading Realloc_For_Chunk (Item, Item.Last); end loop; end Get_Line; --------- -- Put -- --------- procedure Put (U : Unbounded_Wide_String) is begin Put (U.Reference (1 .. U.Last)); end Put; procedure Put (File : File_Type; U : Unbounded_Wide_String) is begin Put (File, U.Reference (1 .. U.Last)); end Put; -------------- -- Put_Line -- -------------- procedure Put_Line (U : Unbounded_Wide_String) is begin Put_Line (U.Reference (1 .. U.Last)); end Put_Line; procedure Put_Line (File : File_Type; U : Unbounded_Wide_String) is begin Put_Line (File, U.Reference (1 .. U.Last)); end Put_Line; end Ada.Strings.Wide_Unbounded.Wide_Text_IO;
37.03125
78
0.518143
3d141f9f3e81b13aef146a6b77e9c10fd02a31a2
3,417
ads
Ada
gcc-gcc-7_3_0-release/gcc/ada/s-imgint.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
70
2015-01-03T01:44:38.000Z
2022-03-20T14:24:24.000Z
gcc-gcc-7_3_0-release/gcc/ada/s-imgint.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/ada/s-imgint.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
12
2015-07-13T04:36:54.000Z
2020-06-21T02:55:04.000Z
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- S Y S T E M . I M G _ I N T -- -- -- -- S p e c -- -- -- -- Copyright (C) 1992-2009, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This package contains the routines for supporting the Image attribute for -- signed integer types up to Size Integer'Size, and also for conversion -- operations required in Text_IO.Integer_IO for such types. package System.Img_Int is pragma Pure; procedure Image_Integer (V : Integer; S : in out String; P : out Natural); -- Computes Integer'Image (V) and stores the result in S (1 .. P) -- setting the resulting value of P. The caller guarantees that S -- is long enough to hold the result, and that S'First is 1. procedure Set_Image_Integer (V : Integer; S : in out String; P : in out Natural); -- Stores the image of V in S starting at S (P + 1), P is updated to point -- to the last character stored. The value stored is identical to the value -- of Integer'Image (V) except that no leading space is stored when V is -- non-negative. The caller guarantees that S is long enough to hold the -- result. S need not have a lower bound of 1. end System.Img_Int;
58.913793
79
0.462979
a05ddf5d6541f6fe5069adde07a6c9513c271a0a
4,883
ads
Ada
Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnarl/s-tasinf.ads
djamal2727/Main-Bearing-Analytical-Model
2f00c2219c71be0175c6f4f8f1d4cca231d97096
[ "Apache-2.0" ]
null
null
null
Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnarl/s-tasinf.ads
djamal2727/Main-Bearing-Analytical-Model
2f00c2219c71be0175c6f4f8f1d4cca231d97096
[ "Apache-2.0" ]
null
null
null
Validation/pyFrame3DD-master/gcc-master/gcc/ada/libgnarl/s-tasinf.ads
djamal2727/Main-Bearing-Analytical-Model
2f00c2219c71be0175c6f4f8f1d4cca231d97096
[ "Apache-2.0" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- S Y S T E M . T A S K _ I N F O -- -- -- -- S p e c -- -- -- -- Copyright (C) 1992-2020, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This package contains the definitions and routines associated with the -- implementation and use of the Task_Info pragma. It is specialized -- appropriately for targets that make use of this pragma. -- Note: the compiler generates direct calls to this interface, via Rtsfind. -- Any changes to this interface may require corresponding compiler changes. -- The functionality in this unit is now provided by the predefined package -- System.Multiprocessors and the CPU aspect. This package is obsolescent. package System.Task_Info is pragma Obsolescent (Task_Info, "use System.Multiprocessors and CPU aspect"); pragma Preelaborate; pragma Elaborate_Body; -- To ensure that a body is allowed ----------------------------------------- -- Implementation of Task_Info Feature -- ----------------------------------------- -- The Task_Info pragma: -- pragma Task_Info (EXPRESSION); -- allows the specification on a task by task basis of a value of type -- System.Task_Info.Task_Info_Type to be passed to a task when it is -- created. The specification of this type, and the effect on the task -- that is created is target dependent. -- The Task_Info pragma appears within a task definition (compare the -- definition and implementation of pragma Priority). If no such pragma -- appears, then the value Unspecified_Task_Info is passed. If a pragma -- is present, then it supplies an alternative value. If the argument of -- the pragma is a discriminant reference, then the value can be set on -- a task by task basis by supplying the appropriate discriminant value. -- Note that this means that the type used for Task_Info_Type must be -- suitable for use as a discriminant (i.e. a scalar or access type). ------------------ -- Declarations -- ------------------ type Scope_Type is (Process_Scope, -- Contend only with threads in same process System_Scope, -- Contend with all threads on same CPU Default_Scope); type Task_Info_Type is new Scope_Type; -- Type used for passing information to task create call, using the -- Task_Info pragma. This type may be specialized for individual -- implementations, but it must be a type that can be used as a -- discriminant (i.e. a scalar or access type). Unspecified_Task_Info : constant Task_Info_Type := Default_Scope; -- Value passed to task in the absence of a Task_Info pragma end System.Task_Info;
51.946809
79
0.533279
8b4b8205f2fe2ec2e2f5d4c498c8e00faa540afa
410
adb
Ada
examples/nrf24/peripherals.adb
ekoeppen/STM32_Generic_Ada_Drivers
4ff29c3026c4b24280baf22a5b81ea9969375466
[ "MIT" ]
1
2021-04-06T07:57:56.000Z
2021-04-06T07:57:56.000Z
examples/nrf24/peripherals.adb
ekoeppen/STM32_Generic_Ada_Drivers
4ff29c3026c4b24280baf22a5b81ea9969375466
[ "MIT" ]
null
null
null
examples/nrf24/peripherals.adb
ekoeppen/STM32_Generic_Ada_Drivers
4ff29c3026c4b24280baf22a5b81ea9969375466
[ "MIT" ]
2
2018-05-29T13:59:31.000Z
2019-02-03T19:48:08.000Z
with STM32_SVD; use STM32_SVD; with STM32_SVD.RCC; use STM32_SVD.RCC; with STM32GD.Board; use STM32GD.Board; package body Peripherals is procedure Init is begin RCC_Periph.APB2ENR.SPI1EN := 1; CE.Init; CSN.Init; CSN.Set; SCLK.Init; MISO.Init; MOSI.Init; IRQ.Init; SPI.Init; Timer.Init; Radio.Init; end Init; end Peripherals;
17.826087
39
0.612195
38d57cd41813db5e48091d6c99c98c53eb48b1ba
4,421
adb
Ada
src/latin_utils/latin_utils-dictionary_package-numeral_entry_io.adb
Alex-Vasile/whitakers-words
9fa16606d97842746fea0379839f40c959c53d56
[ "FTL" ]
204
2015-06-12T21:22:55.000Z
2022-03-28T10:50:16.000Z
src/latin_utils/latin_utils-dictionary_package-numeral_entry_io.adb
Alex-Vasile/whitakers-words
9fa16606d97842746fea0379839f40c959c53d56
[ "FTL" ]
98
2015-06-15T22:17:04.000Z
2021-10-01T18:17:55.000Z
src/latin_utils/latin_utils-dictionary_package-numeral_entry_io.adb
Alex-Vasile/whitakers-words
9fa16606d97842746fea0379839f40c959c53d56
[ "FTL" ]
50
2015-06-16T22:42:24.000Z
2021-12-29T16:53:08.000Z
-- WORDS, a Latin dictionary, by Colonel William Whitaker (USAF, Retired) -- -- Copyright William A. Whitaker (1936–2010) -- -- This is a free program, which means it is proper to copy it and pass -- it on to your friends. Consider it a developmental item for which -- there is no charge. However, just for form, it is Copyrighted -- (c). Permission is hereby freely given for any and all use of program -- and data. You can sell it as your own, but at least tell me. -- -- This version is distributed without obligation, but the developer -- would appreciate comments and suggestions. -- -- All parts of the WORDS system, source code and data files, are made freely -- available to anyone who wishes to use them, for whatever purpose. separate (Latin_Utils.Dictionary_Package) package body Numeral_Entry_IO is --------------------------------------------------------------------------- -- FIXME: Why is this one set here? Num_Out_Size : constant := 5; -- NOTE: Maybe set this in spec? --------------------------------------------------------------------------- procedure Get (File : in Ada.Text_IO.File_Type; Item : out Numeral_Entry) is Spacer : Character := ' '; pragma Unreferenced (Spacer); begin Decn_Record_IO.Get (File, Item.Decl); Ada.Text_IO.Get (File, Spacer); Numeral_Sort_Type_IO.Get (File, Item.Sort); Ada.Text_IO.Get (File, Spacer); Inflections_Package.Integer_IO.Get (File, Item.Value); end Get; --------------------------------------------------------------------------- procedure Get (Item : out Numeral_Entry) is Spacer : Character := ' '; pragma Unreferenced (Spacer); begin Decn_Record_IO.Get (Item.Decl); Ada.Text_IO.Get (Spacer); Numeral_Sort_Type_IO.Get (Item.Sort); Ada.Text_IO.Get (Spacer); Inflections_Package.Integer_IO.Get (Item.Value); end Get; --------------------------------------------------------------------------- procedure Put (File : in Ada.Text_IO.File_Type; Item : in Numeral_Entry) is begin Decn_Record_IO.Put (File, Item.Decl); Ada.Text_IO.Put (File, ' '); Numeral_Sort_Type_IO.Put (File, Item.Sort); Ada.Text_IO.Put (File, ' '); Inflections_Package.Integer_IO.Put (File, Item.Value, Num_Out_Size); end Put; --------------------------------------------------------------------------- procedure Put (Item : in Numeral_Entry) is begin Decn_Record_IO.Put (Item.Decl); Ada.Text_IO.Put (' '); Numeral_Sort_Type_IO.Put (Item.Sort); Ada.Text_IO.Put (' '); Inflections_Package.Integer_IO.Put (Item.Value, Num_Out_Size); end Put; --------------------------------------------------------------------------- procedure Get (Source : in String; Target : out Numeral_Entry; Last : out Integer ) is -- Used for computing lower bound of substring Low : Integer := Source'First - 1; begin Decn_Record_IO.Get (Source (Low + 1 .. Source'Last), Target.Decl, Low); Low := Low + 1; Numeral_Sort_Type_IO.Get (Source (Low + 1 .. Source'Last), Target.Sort, Low); Low := Low + 1; Inflections_Package.Integer_IO.Get (Source (Low + 1 .. Source'Last), Target.Value, Last); end Get; --------------------------------------------------------------------------- procedure Put (Target : out String; Item : in Numeral_Entry) is -- These variables are used for computing bounds of substrings Low : Integer := Target'First - 1; High : Integer := 0; begin -- Put Decn_Record High := Low + Decn_Record_IO.Default_Width; Decn_Record_IO.Put (Target (Low + 1 .. High), Item.Decl); Low := High + 1; Target (Low) := ' '; -- Put Numeral_Sort_Type High := Low + Numeral_Sort_Type_IO.Default_Width; Numeral_Sort_Type_IO.Put (Target (Low + 1 .. High), Item.Sort); Low := High + 1; Target (Low) := ' '; -- Put Integer -- High := Low + Numeral_Value_Type_IO.Default_Width; High := Low + Num_Out_Size; Inflections_Package.Integer_IO.Put (Target (Low + 1 .. High), Item.Value); -- Fill remainder of string Target (High + 1 .. Target'Last) := (others => ' '); end Put; --------------------------------------------------------------------------- end Numeral_Entry_IO;
35.087302
80
0.553721
a0e9ff4176fd4e45fe9f514d07dcb9309a38a95c
6,096
ads
Ada
bsp-examples/evb1000/stm32-nvic.ads
SALLYPEMDAS/DW1000
ce2906596e479c83ce64673e8e7cf03856c45523
[ "MIT" ]
9
2016-07-06T21:26:41.000Z
2020-11-22T11:21:58.000Z
bsp-examples/evb1000/stm32-nvic.ads
hao122065175/DW1000
ce2906596e479c83ce64673e8e7cf03856c45523
[ "MIT" ]
1
2018-06-19T15:20:41.000Z
2018-06-19T21:14:31.000Z
bsp-examples/evb1000/stm32-nvic.ads
hao122065175/DW1000
ce2906596e479c83ce64673e8e7cf03856c45523
[ "MIT" ]
4
2018-07-18T03:35:25.000Z
2020-11-22T11:21:59.000Z
-- This spec has been automatically generated from STM32F105xx.svd pragma Restrictions (No_Elaboration_Code); pragma Ada_2012; with System; package STM32.NVIC is pragma Preelaborate; --------------- -- Registers -- --------------- ------------------- -- ICTR_Register -- ------------------- subtype ICTR_INTLINESNUM_Field is STM32.UInt4; -- Interrupt Controller Type Register type ICTR_Register is record -- Read-only. Total number of interrupt lines in groups INTLINESNUM : ICTR_INTLINESNUM_Field; -- unspecified Reserved_4_31 : STM32.UInt28; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for ICTR_Register use record INTLINESNUM at 0 range 0 .. 3; Reserved_4_31 at 0 range 4 .. 31; end record; ------------------ -- IPR_Register -- ------------------ -- IPR0_IPR_N array element subtype IPR0_IPR_N_Element is STM32.Byte; -- IPR0_IPR_N array type IPR0_IPR_N_Field_Array is array (0 .. 3) of IPR0_IPR_N_Element with Component_Size => 8, Size => 32; -- Interrupt Priority Register type IPR_Register (As_Array : Boolean := False) is record case As_Array is when False => -- IPR_N as a value Val : STM32.Word; when True => -- IPR_N as an array Arr : IPR0_IPR_N_Field_Array; end case; end record with Unchecked_Union, Size => 32, Volatile_Full_Access, Bit_Order => System.Low_Order_First; for IPR_Register use record Val at 0 range 0 .. 31; Arr at 0 range 0 .. 31; end record; ------------------- -- STIR_Register -- ------------------- subtype STIR_INTID_Field is STM32.UInt9; -- Software Triggered Interrupt Register type STIR_Register is record -- Write-only. interrupt to be triggered INTID : STIR_INTID_Field := 16#0#; -- unspecified Reserved_9_31 : STM32.UInt23 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for STIR_Register use record INTID at 0 range 0 .. 8; Reserved_9_31 at 0 range 9 .. 31; end record; ----------------- -- Peripherals -- ----------------- -- Nested Vectored Interrupt Controller type NVIC_Peripheral is record -- Interrupt Controller Type Register ICTR : ICTR_Register; -- Interrupt Set-Enable Register ISER0 : STM32.Word; -- Interrupt Set-Enable Register ISER1 : STM32.Word; -- Interrupt Set-Enable Register ISER2 : STM32.Word; -- Interrupt Clear-Enable Register ICER0 : STM32.Word; -- Interrupt Clear-Enable Register ICER1 : STM32.Word; -- Interrupt Clear-Enable Register ICER2 : STM32.Word; -- Interrupt Set-Pending Register ISPR0 : STM32.Word; -- Interrupt Set-Pending Register ISPR1 : STM32.Word; -- Interrupt Set-Pending Register ISPR2 : STM32.Word; -- Interrupt Clear-Pending Register ICPR0 : STM32.Word; -- Interrupt Clear-Pending Register ICPR1 : STM32.Word; -- Interrupt Clear-Pending Register ICPR2 : STM32.Word; -- Interrupt Active Bit Register IABR0 : STM32.Word; -- Interrupt Active Bit Register IABR1 : STM32.Word; -- Interrupt Active Bit Register IABR2 : STM32.Word; -- Interrupt Priority Register IPR0 : IPR_Register; -- Interrupt Priority Register IPR1 : IPR_Register; -- Interrupt Priority Register IPR2 : IPR_Register; -- Interrupt Priority Register IPR3 : IPR_Register; -- Interrupt Priority Register IPR4 : IPR_Register; -- Interrupt Priority Register IPR5 : IPR_Register; -- Interrupt Priority Register IPR6 : IPR_Register; -- Interrupt Priority Register IPR7 : IPR_Register; -- Interrupt Priority Register IPR8 : IPR_Register; -- Interrupt Priority Register IPR9 : IPR_Register; -- Interrupt Priority Register IPR10 : IPR_Register; -- Interrupt Priority Register IPR11 : IPR_Register; -- Interrupt Priority Register IPR12 : IPR_Register; -- Interrupt Priority Register IPR13 : IPR_Register; -- Interrupt Priority Register IPR14 : IPR_Register; -- Interrupt Priority Register IPR15 : IPR_Register; -- Interrupt Priority Register IPR16 : IPR_Register; -- Software Triggered Interrupt Register STIR : STIR_Register; end record with Volatile; for NVIC_Peripheral use record ICTR at 4 range 0 .. 31; ISER0 at 256 range 0 .. 31; ISER1 at 260 range 0 .. 31; ISER2 at 264 range 0 .. 31; ICER0 at 384 range 0 .. 31; ICER1 at 388 range 0 .. 31; ICER2 at 392 range 0 .. 31; ISPR0 at 512 range 0 .. 31; ISPR1 at 516 range 0 .. 31; ISPR2 at 520 range 0 .. 31; ICPR0 at 640 range 0 .. 31; ICPR1 at 644 range 0 .. 31; ICPR2 at 648 range 0 .. 31; IABR0 at 768 range 0 .. 31; IABR1 at 772 range 0 .. 31; IABR2 at 776 range 0 .. 31; IPR0 at 1024 range 0 .. 31; IPR1 at 1028 range 0 .. 31; IPR2 at 1032 range 0 .. 31; IPR3 at 1036 range 0 .. 31; IPR4 at 1040 range 0 .. 31; IPR5 at 1044 range 0 .. 31; IPR6 at 1048 range 0 .. 31; IPR7 at 1052 range 0 .. 31; IPR8 at 1056 range 0 .. 31; IPR9 at 1060 range 0 .. 31; IPR10 at 1064 range 0 .. 31; IPR11 at 1068 range 0 .. 31; IPR12 at 1072 range 0 .. 31; IPR13 at 1076 range 0 .. 31; IPR14 at 1080 range 0 .. 31; IPR15 at 1084 range 0 .. 31; IPR16 at 1088 range 0 .. 31; STIR at 3840 range 0 .. 31; end record; -- Nested Vectored Interrupt Controller NVIC_Periph : aliased NVIC_Peripheral with Import, Address => NVIC_Base; end STM32.NVIC;
29.307692
70
0.59416
4b6e71b76c1179736c314e793fff706c9594a4cf
105
ads
Ada
config/rp2040_zfp_config.ads
hgrodriguez/rp2040_zfp
1ec0fccd6e97fb6e445814e41d0839771e72b214
[ "BSD-3-Clause" ]
null
null
null
config/rp2040_zfp_config.ads
hgrodriguez/rp2040_zfp
1ec0fccd6e97fb6e445814e41d0839771e72b214
[ "BSD-3-Clause" ]
null
null
null
config/rp2040_zfp_config.ads
hgrodriguez/rp2040_zfp
1ec0fccd6e97fb6e445814e41d0839771e72b214
[ "BSD-3-Clause" ]
null
null
null
-- Configuration for rp2040_zfp generated by Alire package rp2040_zfp_Config is end rp2040_zfp_Config;
21
51
0.838095
9a37c9a2d8d0e42a138d9c43d247c554ab143afe
551
adb
Ada
euler12.adb
kimtg/euler-ada
9b12d59aefbb1e0da2d9b7308de463c8fc579294
[ "Unlicense" ]
7
2016-07-10T02:27:59.000Z
2019-02-09T22:24:33.000Z
euler12.adb
kimtg/euler-ada
9b12d59aefbb1e0da2d9b7308de463c8fc579294
[ "Unlicense" ]
null
null
null
euler12.adb
kimtg/euler-ada
9b12d59aefbb1e0da2d9b7308de463c8fc579294
[ "Unlicense" ]
null
null
null
with Ada.Text_IO; procedure Euler12 is Triangle_Num : Positive := 1; I : Positive := 1; J : Positive; Num_Divisors : Natural; begin loop Num_Divisors := 0; J := 1; while J * J <= Triangle_Num loop if Triangle_Num mod J = 0 then Num_Divisors := Num_Divisors + 2; end if; J := J + 1; end loop; Ada.Text_IO.Put_Line(Positive'Image(Triangle_Num) & Natural'Image(Num_Divisors)); exit when Num_Divisors > 500; I := I + 1; Triangle_Num := Triangle_Num + I; end loop; end Euler12;
22.958333
87
0.6098
8be2b91490378b342aa2fa088db0547682e70c1c
1,352
ads
Ada
source/s-runcon.ads
ytomino/drake
4e4bdcd8b8e23a11a29b31d3a8861fdf60090ea2
[ "MIT" ]
33
2015-04-04T09:19:36.000Z
2021-11-10T05:33:34.000Z
source/s-runcon.ads
ytomino/drake
4e4bdcd8b8e23a11a29b31d3a8861fdf60090ea2
[ "MIT" ]
8
2017-11-14T13:05:07.000Z
2018-08-09T15:28:49.000Z
source/s-runcon.ads
ytomino/drake
4e4bdcd8b8e23a11a29b31d3a8861fdf60090ea2
[ "MIT" ]
9
2015-02-03T17:09:53.000Z
2021-11-12T01:16:05.000Z
pragma License (Unrestricted); -- runtime unit with System.Unwind.Representation; package System.Runtime_Context is pragma Preelaborate; -- equivalent to TSD (s-soflin.ads) type Task_Local_Storage is record Secondary_Stack : aliased Address; Overlaid_Allocation : Address; -- for System.Storage_Pools.Overlaps SEH : Address; -- Win32 only Machine_Occurrence : Unwind.Representation.Machine_Occurrence_Access; Secondary_Occurrence : aliased Unwind.Representation.Machine_Occurrence; Triggered_By_Abort : Boolean; No_Discrete_Value_Failure_Propagation : Boolean; Discrete_Value_Failure : Boolean; end record; pragma Suppress_Initialization (Task_Local_Storage); type Task_Local_Storage_Access is access all Task_Local_Storage; for Task_Local_Storage_Access'Storage_Size use 0; function Get_Environment_Task_Local_Storage return not null Task_Local_Storage_Access; type Get_Task_Local_Storage_Handler is access function return not null Task_Local_Storage_Access; pragma Favor_Top_Level (Get_Task_Local_Storage_Handler); Get_Task_Local_Storage_Hook : not null Get_Task_Local_Storage_Handler := Get_Environment_Task_Local_Storage'Access; function Get_Task_Local_Storage return not null Task_Local_Storage_Access; end System.Runtime_Context;
37.555556
78
0.792899
1e53b4080c98cf53c92675437545e69232e6d667
2,086
adb
Ada
src/ada-core/src/linted-tagged_accessors.adb
mstewartgallus/linted
4d4cf9390353ea045b95671474ab278456793a35
[ "Apache-2.0" ]
null
null
null
src/ada-core/src/linted-tagged_accessors.adb
mstewartgallus/linted
4d4cf9390353ea045b95671474ab278456793a35
[ "Apache-2.0" ]
null
null
null
src/ada-core/src/linted-tagged_accessors.adb
mstewartgallus/linted
4d4cf9390353ea045b95671474ab278456793a35
[ "Apache-2.0" ]
null
null
null
-- Copyright 2017 Steven Stewart-Gallus -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or -- implied. See the License for the specific language governing -- permissions and limitations under the License. with Ada.Unchecked_Conversion; with Interfaces; package body Linted.Tagged_Accessors is use type Interfaces.Unsigned_64; -- Warnings are off because of a spurious warning about strict -- aliasing pragma Warnings (Off); function Convert is new Ada.Unchecked_Conversion (Source => Access_T, Target => Interfaces.Unsigned_64); function Convert is new Ada.Unchecked_Conversion (Source => Interfaces.Unsigned_64, Target => Access_T); pragma Warnings (On); function To (Ptr : Access_T) return Tagged_Access is begin return To (Ptr, 0); end To; function To (Ptr : Access_T; Tag : Tag_Bits) return Tagged_Access is Converted : Interfaces.Unsigned_64; begin Converted := Convert (Ptr); pragma Assert (Interfaces.Shift_Right (Interfaces.Unsigned_64 (Converted), 48) = 0); return Tagged_Access (Interfaces.Shift_Right (Converted, 6) or Interfaces.Shift_Left (Interfaces.Unsigned_64 (Tag), 42)); end To; function From (Ptr : Tagged_Access) return Access_T is begin return Convert (Interfaces.Shift_Left (Interfaces.Unsigned_64 (Ptr) and 2#11_11111111_11111111_11111111_11111111_11111111#, 6)); end From; function Tag (Ptr : Tagged_Access) return Tag_Bits is begin return Tag_Bits (Interfaces.Shift_Right (Interfaces.Unsigned_64 (Ptr), 42)); end Tag; end Linted.Tagged_Accessors;
33.111111
78
0.697987
a001862bc47726701df58b7aff174078ddbbfee9
3,252
ads
Ada
bb-runtimes/examples/stm32f4-discovery/leds-containers/src/stm32f4-sysconfig_control.ads
JCGobbi/Nucleo-STM32F334R8
2a0b1b4b2664c92773703ac5e95dcb71979d051c
[ "BSD-3-Clause" ]
null
null
null
bb-runtimes/examples/stm32f4-discovery/leds-containers/src/stm32f4-sysconfig_control.ads
JCGobbi/Nucleo-STM32F334R8
2a0b1b4b2664c92773703ac5e95dcb71979d051c
[ "BSD-3-Clause" ]
null
null
null
bb-runtimes/examples/stm32f4-discovery/leds-containers/src/stm32f4-sysconfig_control.ads
JCGobbi/Nucleo-STM32F334R8
2a0b1b4b2664c92773703ac5e95dcb71979d051c
[ "BSD-3-Clause" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- GNAT EXAMPLE -- -- -- -- Copyright (C) 2015, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This file provides register definitions for the STM32F4 (ARM Cortex M4F) -- microcontrollers from ST Microelectronics. pragma Restrictions (No_Elaboration_Code); package STM32F4.SYSCONFIG_Control is type EXTI_Register is record IMR : Bits_32x1; EMR : Bits_32x1; RTSR : Bits_32x1; FTSR : Bits_32x1; SWIER : Bits_32x1; PR : Bits_32x1; end record; for EXTI_Register use record IMR at 0 range 0 .. 31; EMR at 4 range 0 .. 31; RTSR at 8 range 0 .. 31; FTSR at 12 range 0 .. 31; SWIER at 16 range 0 .. 31; PR at 20 range 0 .. 31; end record; type SYSCFG_Register is record MEMRM : Word; PMC : Word; EXTICR1 : Bits_8x4; EXTICR2 : Bits_8x4; EXTICR3 : Bits_8x4; EXTICR4 : Bits_8x4; CMPCR : Word; end record; for SYSCFG_Register use record MEMRM at 0 range 0 .. 31; PMC at 4 range 0 .. 31; EXTICR1 at 8 range 0 .. 31; EXTICR2 at 12 range 0 .. 31; EXTICR3 at 16 range 0 .. 31; EXTICR4 at 20 range 0 .. 31; CMPCR at 24 range 0 .. 31; end record; end STM32F4.SYSCONFIG_Control;
43.945946
78
0.473555
381a5ca6b821038d736e5f2a27be37779ec90564
42,169
adb
Ada
hls_video_block/solution1/.autopilot/db/gry2rgb.bind.adb
parker-xilinx/HLS_2d_filter
25c85715167623c07bd5f06a8747961cdafee616
[ "Unlicense" ]
1
2019-12-22T12:22:36.000Z
2019-12-22T12:22:36.000Z
hls_video_block/solution1/.autopilot/db/gry2rgb.bind.adb
parker-xilinx/HLS_2d_filter
25c85715167623c07bd5f06a8747961cdafee616
[ "Unlicense" ]
null
null
null
hls_video_block/solution1/.autopilot/db/gry2rgb.bind.adb
parker-xilinx/HLS_2d_filter
25c85715167623c07bd5f06a8747961cdafee616
[ "Unlicense" ]
2
2019-12-22T12:22:38.000Z
2021-04-30T00:59:20.000Z
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> <!DOCTYPE boost_serialization> <boost_serialization signature="serialization::archive" version="15"> <syndb class_id="0" tracking_level="0" version="0"> <userIPLatency>-1</userIPLatency> <userIPName></userIPName> <cdfg class_id="1" tracking_level="1" version="0" object_id="_0"> <name>gry2rgb</name> <ret_bitwidth>0</ret_bitwidth> <ports class_id="2" tracking_level="0" version="0"> <count>2</count> <item_version>0</item_version> <item class_id="3" tracking_level="1" version="0" object_id="_1"> <Value class_id="4" tracking_level="0" version="0"> <Obj class_id="5" tracking_level="0" version="0"> <type>1</type> <id>1</id> <name>input_mat_data_V</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo class_id="6" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>input_mat.data.V</originalName> <rtlName></rtlName> <coreName>FIFO_SRL</coreName> </Obj> <bitwidth>1</bitwidth> </Value> <direction>0</direction> <if_type>3</if_type> <array_size>0</array_size> <bit_vecs class_id="7" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_2"> <Value> <Obj> <type>1</type> <id>2</id> <name>output_mat_data_V</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>output_mat.data.V</originalName> <rtlName></rtlName> <coreName>FIFO_SRL</coreName> </Obj> <bitwidth>17</bitwidth> </Value> <direction>1</direction> <if_type>3</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> </ports> <nodes class_id="8" tracking_level="0" version="0"> <count>11</count> <item_version>0</item_version> <item class_id="9" tracking_level="1" version="0" object_id="_3"> <Value> <Obj> <type>0</type> <id>5</id> <name></name> <fileName>hls_video_block.cpp</fileName> <fileDirectory>C:\Users\parkerh\Documents\2d_filter_xfopencv</fileDirectory> <lineNumber>145</lineNumber> <contextFuncName>gry2rgb</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item class_id="10" tracking_level="0" version="0"> <first>C:\Users\parkerh\Documents\2d_filter_xfopencv</first> <second class_id="11" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="12" tracking_level="0" version="0"> <first class_id="13" tracking_level="0" version="0"> <first>hls_video_block.cpp</first> <second>gry2rgb</second> </first> <second>145</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>23</item> </oprand_edges> <opcode>br</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.65</m_delay> <m_topoIndex>1</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_4"> <Value> <Obj> <type>0</type> <id>7</id> <name>indvar_flatten</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>20</bitwidth> </Value> <oprand_edges> <count>4</count> <item_version>0</item_version> <item>25</item> <item>26</item> <item>27</item> <item>28</item> </oprand_edges> <opcode>phi</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>2</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_5"> <Value> <Obj> <type>0</type> <id>8</id> <name>exitcond_flatten</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>1</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>29</item> <item>31</item> </oprand_edges> <opcode>icmp</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>1.07</m_delay> <m_topoIndex>3</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_6"> <Value> <Obj> <type>0</type> <id>9</id> <name>indvar_flatten_next</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>20</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>32</item> <item>34</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.89</m_delay> <m_topoIndex>4</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_7"> <Value> <Obj> <type>0</type> <id>10</id> <name></name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>35</item> <item>36</item> <item>37</item> </oprand_edges> <opcode>br</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>5</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_8"> <Value> <Obj> <type>0</type> <id>14</id> <name>input_mat_data_V_rea</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>1</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>39</item> <item>40</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>1.83</m_delay> <m_topoIndex>6</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_9"> <Value> <Obj> <type>0</type> <id>15</id> <name>input_pixel_V</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>input_pixel.V</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>41</item> <item>43</item> <item>45</item> </oprand_edges> <opcode>select</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.17</m_delay> <m_topoIndex>7</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_10"> <Value> <Obj> <type>0</type> <id>16</id> <name>tmp</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>17</bitwidth> </Value> <oprand_edges> <count>4</count> <item_version>0</item_version> <item>47</item> <item>48</item> <item>49</item> <item>50</item> </oprand_edges> <opcode>bitconcatenate</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>8</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_11"> <Value> <Obj> <type>0</type> <id>17</id> <name></name> <fileName>hls_video_block.cpp</fileName> <fileDirectory>C:\Users\parkerh\Documents\2d_filter_xfopencv</fileDirectory> <lineNumber>152</lineNumber> <contextFuncName>gry2rgb</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>C:\Users\parkerh\Documents\2d_filter_xfopencv</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>hls_video_block.cpp</first> <second>gry2rgb</second> </first> <second>152</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>52</item> <item>53</item> <item>54</item> </oprand_edges> <opcode>write</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>1.83</m_delay> <m_topoIndex>9</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_12"> <Value> <Obj> <type>0</type> <id>19</id> <name></name> <fileName>hls_video_block.cpp</fileName> <fileDirectory>C:\Users\parkerh\Documents\2d_filter_xfopencv</fileDirectory> <lineNumber>146</lineNumber> <contextFuncName>gry2rgb</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>C:\Users\parkerh\Documents\2d_filter_xfopencv</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>hls_video_block.cpp</first> <second>gry2rgb</second> </first> <second>146</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>55</item> </oprand_edges> <opcode>br</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>10</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_13"> <Value> <Obj> <type>0</type> <id>21</id> <name></name> <fileName>hls_video_block.cpp</fileName> <fileDirectory>C:\Users\parkerh\Documents\2d_filter_xfopencv</fileDirectory> <lineNumber>155</lineNumber> <contextFuncName>gry2rgb</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>C:\Users\parkerh\Documents\2d_filter_xfopencv</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>hls_video_block.cpp</first> <second>gry2rgb</second> </first> <second>155</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>0</count> <item_version>0</item_version> </oprand_edges> <opcode>ret</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>11</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> </nodes> <consts class_id="15" tracking_level="0" version="0"> <count>5</count> <item_version>0</item_version> <item class_id="16" tracking_level="1" version="0" object_id="_14"> <Value> <Obj> <type>2</type> <id>24</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>20</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_15"> <Value> <Obj> <type>2</type> <id>30</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>20</bitwidth> </Value> <const_type>0</const_type> <content>921600</content> </item> <item class_id_reference="16" object_id="_16"> <Value> <Obj> <type>2</type> <id>33</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>20</bitwidth> </Value> <const_type>0</const_type> <content>1</content> </item> <item class_id_reference="16" object_id="_17"> <Value> <Obj> <type>2</type> <id>42</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>8</bitwidth> </Value> <const_type>0</const_type> <content>255</content> </item> <item class_id_reference="16" object_id="_18"> <Value> <Obj> <type>2</type> <id>44</id> <name>empty</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>8</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> </consts> <blocks class_id="17" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="18" tracking_level="1" version="0" object_id="_19"> <Obj> <type>3</type> <id>6</id> <name></name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>1</count> <item_version>0</item_version> <item>5</item> </node_objs> </item> <item class_id_reference="18" object_id="_20"> <Obj> <type>3</type> <id>11</id> <name>.preheader</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>4</count> <item_version>0</item_version> <item>7</item> <item>8</item> <item>9</item> <item>10</item> </node_objs> </item> <item class_id_reference="18" object_id="_21"> <Obj> <type>3</type> <id>20</id> <name>.preheader.preheader</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>5</count> <item_version>0</item_version> <item>14</item> <item>15</item> <item>16</item> <item>17</item> <item>19</item> </node_objs> </item> <item class_id_reference="18" object_id="_22"> <Obj> <type>3</type> <id>22</id> <name></name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>1</count> <item_version>0</item_version> <item>21</item> </node_objs> </item> </blocks> <edges class_id="19" tracking_level="0" version="0"> <count>26</count> <item_version>0</item_version> <item class_id="20" tracking_level="1" version="0" object_id="_23"> <id>23</id> <edge_type>2</edge_type> <source_obj>11</source_obj> <sink_obj>5</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_24"> <id>25</id> <edge_type>1</edge_type> <source_obj>24</source_obj> <sink_obj>7</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_25"> <id>26</id> <edge_type>2</edge_type> <source_obj>6</source_obj> <sink_obj>7</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_26"> <id>27</id> <edge_type>1</edge_type> <source_obj>9</source_obj> <sink_obj>7</sink_obj> <is_back_edge>1</is_back_edge> </item> <item class_id_reference="20" object_id="_27"> <id>28</id> <edge_type>2</edge_type> <source_obj>20</source_obj> <sink_obj>7</sink_obj> <is_back_edge>1</is_back_edge> </item> <item class_id_reference="20" object_id="_28"> <id>29</id> <edge_type>1</edge_type> <source_obj>7</source_obj> <sink_obj>8</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_29"> <id>31</id> <edge_type>1</edge_type> <source_obj>30</source_obj> <sink_obj>8</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_30"> <id>32</id> <edge_type>1</edge_type> <source_obj>7</source_obj> <sink_obj>9</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_31"> <id>34</id> <edge_type>1</edge_type> <source_obj>33</source_obj> <sink_obj>9</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_32"> <id>35</id> <edge_type>1</edge_type> <source_obj>8</source_obj> <sink_obj>10</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_33"> <id>36</id> <edge_type>2</edge_type> <source_obj>20</source_obj> <sink_obj>10</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_34"> <id>37</id> <edge_type>2</edge_type> <source_obj>22</source_obj> <sink_obj>10</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_35"> <id>40</id> <edge_type>1</edge_type> <source_obj>1</source_obj> <sink_obj>14</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_36"> <id>41</id> <edge_type>1</edge_type> <source_obj>14</source_obj> <sink_obj>15</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_37"> <id>43</id> <edge_type>1</edge_type> <source_obj>42</source_obj> <sink_obj>15</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_38"> <id>45</id> <edge_type>1</edge_type> <source_obj>44</source_obj> <sink_obj>15</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_39"> <id>48</id> <edge_type>1</edge_type> <source_obj>14</source_obj> <sink_obj>16</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_40"> <id>49</id> <edge_type>1</edge_type> <source_obj>15</source_obj> <sink_obj>16</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_41"> <id>50</id> <edge_type>1</edge_type> <source_obj>15</source_obj> <sink_obj>16</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_42"> <id>53</id> <edge_type>1</edge_type> <source_obj>2</source_obj> <sink_obj>17</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_43"> <id>54</id> <edge_type>1</edge_type> <source_obj>16</source_obj> <sink_obj>17</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_44"> <id>55</id> <edge_type>2</edge_type> <source_obj>11</source_obj> <sink_obj>19</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_45"> <id>113</id> <edge_type>2</edge_type> <source_obj>6</source_obj> <sink_obj>11</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_46"> <id>114</id> <edge_type>2</edge_type> <source_obj>11</source_obj> <sink_obj>22</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_47"> <id>115</id> <edge_type>2</edge_type> <source_obj>11</source_obj> <sink_obj>20</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_48"> <id>116</id> <edge_type>2</edge_type> <source_obj>20</source_obj> <sink_obj>11</sink_obj> <is_back_edge>1</is_back_edge> </item> </edges> </cdfg> <cdfg_regions class_id="21" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="22" tracking_level="1" version="0" object_id="_49"> <mId>1</mId> <mTag>gry2rgb</mTag> <mType>0</mType> <sub_regions> <count>3</count> <item_version>0</item_version> <item>2</item> <item>3</item> <item>4</item> </sub_regions> <basic_blocks> <count>0</count> <item_version>0</item_version> </basic_blocks> <mII>-1</mII> <mDepth>-1</mDepth> <mMinTripCount>-1</mMinTripCount> <mMaxTripCount>-1</mMaxTripCount> <mMinLatency>921602</mMinLatency> <mMaxLatency>921602</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"></mDfPipe> </item> <item class_id_reference="22" object_id="_50"> <mId>2</mId> <mTag>Entry</mTag> <mType>0</mType> <sub_regions> <count>0</count> <item_version>0</item_version> </sub_regions> <basic_blocks> <count>1</count> <item_version>0</item_version> <item>6</item> </basic_blocks> <mII>-1</mII> <mDepth>-1</mDepth> <mMinTripCount>-1</mMinTripCount> <mMaxTripCount>-1</mMaxTripCount> <mMinLatency>0</mMinLatency> <mMaxLatency>0</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"></mDfPipe> </item> <item class_id_reference="22" object_id="_51"> <mId>3</mId> <mTag>Loop 1</mTag> <mType>1</mType> <sub_regions> <count>0</count> <item_version>0</item_version> </sub_regions> <basic_blocks> <count>2</count> <item_version>0</item_version> <item>11</item> <item>20</item> </basic_blocks> <mII>1</mII> <mDepth>2</mDepth> <mMinTripCount>921600</mMinTripCount> <mMaxTripCount>921600</mMaxTripCount> <mMinLatency>921600</mMinLatency> <mMaxLatency>921600</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"></mDfPipe> </item> <item class_id_reference="22" object_id="_52"> <mId>4</mId> <mTag>Return</mTag> <mType>0</mType> <sub_regions> <count>0</count> <item_version>0</item_version> </sub_regions> <basic_blocks> <count>1</count> <item_version>0</item_version> <item>22</item> </basic_blocks> <mII>-1</mII> <mDepth>-1</mDepth> <mMinTripCount>-1</mMinTripCount> <mMaxTripCount>-1</mMaxTripCount> <mMinLatency>0</mMinLatency> <mMaxLatency>0</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"></mDfPipe> </item> </cdfg_regions> <fsm class_id="24" tracking_level="1" version="0" object_id="_53"> <states class_id="25" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="26" tracking_level="1" version="0" object_id="_54"> <id>1</id> <operations class_id="27" tracking_level="0" version="0"> <count>3</count> <item_version>0</item_version> <item class_id="28" tracking_level="1" version="0" object_id="_55"> <id>3</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_56"> <id>4</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_57"> <id>5</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_58"> <id>2</id> <operations> <count>4</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_59"> <id>7</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_60"> <id>8</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_61"> <id>9</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_62"> <id>10</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_63"> <id>3</id> <operations> <count>8</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_64"> <id>12</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_65"> <id>13</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_66"> <id>14</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_67"> <id>15</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_68"> <id>16</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_69"> <id>17</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_70"> <id>18</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_71"> <id>19</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_72"> <id>4</id> <operations> <count>1</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_73"> <id>21</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> </states> <transitions class_id="29" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="30" tracking_level="1" version="0" object_id="_74"> <inState>1</inState> <outState>2</outState> <condition class_id="31" tracking_level="0" version="0"> <id>-1</id> <sop class_id="32" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="33" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_75"> <inState>3</inState> <outState>2</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_76"> <inState>2</inState> <outState>4</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>1</count> <item_version>0</item_version> <item class_id="34" tracking_level="0" version="0"> <first class_id="35" tracking_level="0" version="0"> <first>8</first> <second>0</second> </first> <second>0</second> </item> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_77"> <inState>2</inState> <outState>3</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>1</count> <item_version>0</item_version> <item> <first> <first>8</first> <second>0</second> </first> <second>1</second> </item> </item> </sop> </condition> </item> </transitions> </fsm> <res class_id="-1"></res> <node_label_latency class_id="37" tracking_level="0" version="0"> <count>11</count> <item_version>0</item_version> <item class_id="38" tracking_level="0" version="0"> <first>5</first> <second class_id="39" tracking_level="0" version="0"> <first>0</first> <second>0</second> </second> </item> <item> <first>7</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>8</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>9</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>10</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>14</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>15</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>16</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>17</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>19</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>21</first> <second> <first>3</first> <second>0</second> </second> </item> </node_label_latency> <bblk_ent_exit class_id="40" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="41" tracking_level="0" version="0"> <first>6</first> <second class_id="42" tracking_level="0" version="0"> <first>0</first> <second>0</second> </second> </item> <item> <first>11</first> <second> <first>1</first> <second>1</second> </second> </item> <item> <first>20</first> <second> <first>2</first> <second>2</second> </second> </item> <item> <first>22</first> <second> <first>2</first> <second>2</second> </second> </item> </bblk_ent_exit> <regions class_id="43" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="44" tracking_level="1" version="0" object_id="_78"> <region_name>Loop 1</region_name> <basic_blocks> <count>2</count> <item_version>0</item_version> <item>11</item> <item>20</item> </basic_blocks> <nodes> <count>0</count> <item_version>0</item_version> </nodes> <anchor_node>-1</anchor_node> <region_type>8</region_type> <interval>1</interval> <pipe_depth>2</pipe_depth> </item> </regions> <dp_fu_nodes class_id="45" tracking_level="0" version="0"> <count>7</count> <item_version>0</item_version> <item class_id="46" tracking_level="0" version="0"> <first>44</first> <second> <count>1</count> <item_version>0</item_version> <item>14</item> </second> </item> <item> <first>50</first> <second> <count>1</count> <item_version>0</item_version> <item>17</item> </second> </item> <item> <first>61</first> <second> <count>1</count> <item_version>0</item_version> <item>7</item> </second> </item> <item> <first>68</first> <second> <count>1</count> <item_version>0</item_version> <item>8</item> </second> </item> <item> <first>74</first> <second> <count>1</count> <item_version>0</item_version> <item>9</item> </second> </item> <item> <first>80</first> <second> <count>1</count> <item_version>0</item_version> <item>15</item> </second> </item> <item> <first>88</first> <second> <count>1</count> <item_version>0</item_version> <item>16</item> </second> </item> </dp_fu_nodes> <dp_fu_nodes_expression class_id="48" tracking_level="0" version="0"> <count>5</count> <item_version>0</item_version> <item class_id="49" tracking_level="0" version="0"> <first>exitcond_flatten_fu_68</first> <second> <count>1</count> <item_version>0</item_version> <item>8</item> </second> </item> <item> <first>indvar_flatten_next_fu_74</first> <second> <count>1</count> <item_version>0</item_version> <item>9</item> </second> </item> <item> <first>indvar_flatten_phi_fu_61</first> <second> <count>1</count> <item_version>0</item_version> <item>7</item> </second> </item> <item> <first>input_pixel_V_fu_80</first> <second> <count>1</count> <item_version>0</item_version> <item>15</item> </second> </item> <item> <first>tmp_fu_88</first> <second> <count>1</count> <item_version>0</item_version> <item>16</item> </second> </item> </dp_fu_nodes_expression> <dp_fu_nodes_module> <count>0</count> <item_version>0</item_version> </dp_fu_nodes_module> <dp_fu_nodes_io> <count>2</count> <item_version>0</item_version> <item> <first>StgValue_17_write_fu_50</first> <second> <count>1</count> <item_version>0</item_version> <item>17</item> </second> </item> <item> <first>input_mat_data_V_rea_read_fu_44</first> <second> <count>1</count> <item_version>0</item_version> <item>14</item> </second> </item> </dp_fu_nodes_io> <return_ports> <count>0</count> <item_version>0</item_version> </return_ports> <dp_mem_port_nodes class_id="50" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </dp_mem_port_nodes> <dp_reg_nodes> <count>3</count> <item_version>0</item_version> <item> <first>57</first> <second> <count>1</count> <item_version>0</item_version> <item>7</item> </second> </item> <item> <first>99</first> <second> <count>1</count> <item_version>0</item_version> <item>8</item> </second> </item> <item> <first>103</first> <second> <count>1</count> <item_version>0</item_version> <item>9</item> </second> </item> </dp_reg_nodes> <dp_regname_nodes> <count>3</count> <item_version>0</item_version> <item> <first>exitcond_flatten_reg_99</first> <second> <count>1</count> <item_version>0</item_version> <item>8</item> </second> </item> <item> <first>indvar_flatten_next_reg_103</first> <second> <count>1</count> <item_version>0</item_version> <item>9</item> </second> </item> <item> <first>indvar_flatten_reg_57</first> <second> <count>1</count> <item_version>0</item_version> <item>7</item> </second> </item> </dp_regname_nodes> <dp_reg_phi> <count>1</count> <item_version>0</item_version> <item> <first>57</first> <second> <count>1</count> <item_version>0</item_version> <item>7</item> </second> </item> </dp_reg_phi> <dp_regname_phi> <count>1</count> <item_version>0</item_version> <item> <first>indvar_flatten_reg_57</first> <second> <count>1</count> <item_version>0</item_version> <item>7</item> </second> </item> </dp_regname_phi> <dp_port_io_nodes class_id="51" tracking_level="0" version="0"> <count>2</count> <item_version>0</item_version> <item class_id="52" tracking_level="0" version="0"> <first>input_mat_data_V</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>14</item> </second> </item> </second> </item> <item> <first>output_mat_data_V</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>write</first> <second> <count>1</count> <item_version>0</item_version> <item>17</item> </second> </item> </second> </item> </dp_port_io_nodes> <port2core class_id="53" tracking_level="0" version="0"> <count>2</count> <item_version>0</item_version> <item class_id="54" tracking_level="0" version="0"> <first>1</first> <second>FIFO_SRL</second> </item> <item> <first>2</first> <second>FIFO_SRL</second> </item> </port2core> <node2core> <count>0</count> <item_version>0</item_version> </node2core> </syndb> </boost_serialization>
26.062423
82
0.609381
22b41a316be8ec9aac661f77a6db4cd21cf471cb
27,205
adb
Ada
runtime/ravenscar-sfp-stm32f427/common/s-fatgen.adb
TUM-EI-RCS/StratoX
5fdd04e01a25efef6052376f43ce85b5bc973392
[ "BSD-3-Clause" ]
12
2017-06-08T14:19:57.000Z
2022-03-09T02:48:59.000Z
runtime/ravenscar-sfp-stm32f427/common/s-fatgen.adb
TUM-EI-RCS/StratoX
5fdd04e01a25efef6052376f43ce85b5bc973392
[ "BSD-3-Clause" ]
6
2017-06-08T13:13:50.000Z
2020-05-15T09:32:43.000Z
runtime/ravenscar-sfp-stm32f427/common/s-fatgen.adb
TUM-EI-RCS/StratoX
5fdd04e01a25efef6052376f43ce85b5bc973392
[ "BSD-3-Clause" ]
3
2017-06-30T14:05:06.000Z
2022-02-17T12:20:45.000Z
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- S Y S T E M . F A T _ G E N -- -- -- -- B o d y -- -- -- -- Copyright (C) 1992-2015, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- -- -- -- -- -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- The implementation here is portable to any IEEE implementation. It does -- not handle nonbinary radix, and also assumes that model numbers and -- machine numbers are basically identical, which is not true of all possible -- floating-point implementations. On a non-IEEE machine, this body must be -- specialized appropriately, or better still, its generic instantiations -- should be replaced by efficient machine-specific code. with Ada.Unchecked_Conversion; with System; package body System.Fat_Gen is Float_Radix : constant T := T (T'Machine_Radix); Radix_To_M_Minus_1 : constant T := Float_Radix ** (T'Machine_Mantissa - 1); pragma Assert (T'Machine_Radix = 2); -- This version does not handle radix 16 -- Constants for Decompose and Scaling Rad : constant T := T (T'Machine_Radix); Invrad : constant T := 1.0 / Rad; subtype Expbits is Integer range 0 .. 6; -- 2 ** (2 ** 7) might overflow. How big can radix-16 exponents get? Log_Power : constant array (Expbits) of Integer := (1, 2, 4, 8, 16, 32, 64); R_Power : constant array (Expbits) of T := (Rad ** 1, Rad ** 2, Rad ** 4, Rad ** 8, Rad ** 16, Rad ** 32, Rad ** 64); R_Neg_Power : constant array (Expbits) of T := (Invrad ** 1, Invrad ** 2, Invrad ** 4, Invrad ** 8, Invrad ** 16, Invrad ** 32, Invrad ** 64); ----------------------- -- Local Subprograms -- ----------------------- procedure Decompose (XX : T; Frac : out T; Expo : out UI); -- Decomposes a floating-point number into fraction and exponent parts. -- Both results are signed, with Frac having the sign of XX, and UI has -- the sign of the exponent. The absolute value of Frac is in the range -- 0.0 <= Frac < 1.0. If Frac = 0.0 or -0.0, then Expo is always zero. function Gradual_Scaling (Adjustment : UI) return T; -- Like Scaling with a first argument of 1.0, but returns the smallest -- denormal rather than zero when the adjustment is smaller than -- Machine_Emin. Used for Succ and Pred. -------------- -- Adjacent -- -------------- function Adjacent (X, Towards : T) return T is begin if Towards = X then return X; elsif Towards > X then return Succ (X); else return Pred (X); end if; end Adjacent; ------------- -- Ceiling -- ------------- function Ceiling (X : T) return T is XT : constant T := Truncation (X); begin if X <= 0.0 then return XT; elsif X = XT then return X; else return XT + 1.0; end if; end Ceiling; ------------- -- Compose -- ------------- function Compose (Fraction : T; Exponent : UI) return T is Arg_Frac : T; Arg_Exp : UI; pragma Unreferenced (Arg_Exp); begin Decompose (Fraction, Arg_Frac, Arg_Exp); return Scaling (Arg_Frac, Exponent); end Compose; --------------- -- Copy_Sign -- --------------- function Copy_Sign (Value, Sign : T) return T is Result : T; function Is_Negative (V : T) return Boolean; pragma Import (Intrinsic, Is_Negative); begin Result := abs Value; if Is_Negative (Sign) then return -Result; else return Result; end if; end Copy_Sign; --------------- -- Decompose -- --------------- procedure Decompose (XX : T; Frac : out T; Expo : out UI) is X : constant T := T'Machine (XX); begin if X = 0.0 then -- The normalized exponent of zero is zero, see RM A.5.2(15) Frac := X; Expo := 0; -- Check for infinities, transfinites, whatnot elsif X > T'Safe_Last then Frac := Invrad; Expo := T'Machine_Emax + 1; elsif X < T'Safe_First then Frac := -Invrad; Expo := T'Machine_Emax + 2; -- how many extra negative values? else -- Case of nonzero finite x. Essentially, we just multiply -- by Rad ** (+-2**N) to reduce the range. declare Ax : T := abs X; Ex : UI := 0; -- Ax * Rad ** Ex is invariant begin if Ax >= 1.0 then while Ax >= R_Power (Expbits'Last) loop Ax := Ax * R_Neg_Power (Expbits'Last); Ex := Ex + Log_Power (Expbits'Last); end loop; -- Ax < Rad ** 64 for N in reverse Expbits'First .. Expbits'Last - 1 loop if Ax >= R_Power (N) then Ax := Ax * R_Neg_Power (N); Ex := Ex + Log_Power (N); end if; -- Ax < R_Power (N) end loop; -- 1 <= Ax < Rad Ax := Ax * Invrad; Ex := Ex + 1; else -- 0 < ax < 1 while Ax < R_Neg_Power (Expbits'Last) loop Ax := Ax * R_Power (Expbits'Last); Ex := Ex - Log_Power (Expbits'Last); end loop; -- Rad ** -64 <= Ax < 1 for N in reverse Expbits'First .. Expbits'Last - 1 loop if Ax < R_Neg_Power (N) then Ax := Ax * R_Power (N); Ex := Ex - Log_Power (N); end if; -- R_Neg_Power (N) <= Ax < 1 end loop; end if; Frac := (if X > 0.0 then Ax else -Ax); Expo := Ex; end; end if; end Decompose; -------------- -- Exponent -- -------------- function Exponent (X : T) return UI is X_Frac : T; X_Exp : UI; pragma Unreferenced (X_Frac); begin Decompose (X, X_Frac, X_Exp); return X_Exp; end Exponent; ----------- -- Floor -- ----------- function Floor (X : T) return T is XT : constant T := Truncation (X); begin if X >= 0.0 then return XT; elsif XT = X then return X; else return XT - 1.0; end if; end Floor; -------------- -- Fraction -- -------------- function Fraction (X : T) return T is X_Frac : T; X_Exp : UI; pragma Unreferenced (X_Exp); begin Decompose (X, X_Frac, X_Exp); return X_Frac; end Fraction; --------------------- -- Gradual_Scaling -- --------------------- function Gradual_Scaling (Adjustment : UI) return T is Y : T; Y1 : T; Ex : UI := Adjustment; begin if Adjustment < T'Machine_Emin - 1 then Y := 2.0 ** T'Machine_Emin; Y1 := Y; Ex := Ex - T'Machine_Emin; while Ex < 0 loop Y := T'Machine (Y / 2.0); if Y = 0.0 then return Y1; end if; Ex := Ex + 1; Y1 := Y; end loop; return Y1; else return Scaling (1.0, Adjustment); end if; end Gradual_Scaling; ------------------ -- Leading_Part -- ------------------ function Leading_Part (X : T; Radix_Digits : UI) return T is L : UI; Y, Z : T; begin if Radix_Digits >= T'Machine_Mantissa then return X; elsif Radix_Digits <= 0 then raise Constraint_Error; else L := Exponent (X) - Radix_Digits; Y := Truncation (Scaling (X, -L)); Z := Scaling (Y, L); return Z; end if; end Leading_Part; ------------- -- Machine -- ------------- -- The trick with Machine is to force the compiler to store the result -- in memory so that we do not have extra precision used. The compiler -- is clever, so we have to outwit its possible optimizations. We do -- this by using an intermediate pragma Volatile location. function Machine (X : T) return T is Temp : T; pragma Volatile (Temp); begin Temp := X; return Temp; end Machine; ---------------------- -- Machine_Rounding -- ---------------------- -- For now, the implementation is identical to that of Rounding, which is -- a permissible behavior, but is not the most efficient possible approach. function Machine_Rounding (X : T) return T is Result : T; Tail : T; begin Result := Truncation (abs X); Tail := abs X - Result; if Tail >= 0.5 then Result := Result + 1.0; end if; if X > 0.0 then return Result; elsif X < 0.0 then return -Result; -- For zero case, make sure sign of zero is preserved else return X; end if; end Machine_Rounding; ----------- -- Model -- ----------- -- We treat Model as identical to Machine. This is true of IEEE and other -- nice floating-point systems, but not necessarily true of all systems. function Model (X : T) return T is begin return Machine (X); end Model; ---------- -- Pred -- ---------- function Pred (X : T) return T is X_Frac : T; X_Exp : UI; begin -- Zero has to be treated specially, since its exponent is zero if X = 0.0 then return -Succ (X); -- Special treatment for most negative number elsif X = T'First then -- If not generating infinities, we raise a constraint error if T'Machine_Overflows then raise Constraint_Error with "Pred of largest negative number"; -- Otherwise generate a negative infinity else return X / (X - X); end if; -- For infinities, return unchanged elsif X < T'First or else X > T'Last then return X; -- Subtract from the given number a number equivalent to the value -- of its least significant bit. Given that the most significant bit -- represents a value of 1.0 * radix ** (exp - 1), the value we want -- is obtained by shifting this by (mantissa-1) bits to the right, -- i.e. decreasing the exponent by that amount. else Decompose (X, X_Frac, X_Exp); -- A special case, if the number we had was a positive power of -- two, then we want to subtract half of what we would otherwise -- subtract, since the exponent is going to be reduced. -- Note that X_Frac has the same sign as X, so if X_Frac is 0.5, -- then we know that we have a positive number (and hence a -- positive power of 2). if X_Frac = 0.5 then return X - Gradual_Scaling (X_Exp - T'Machine_Mantissa - 1); -- Otherwise the exponent is unchanged else return X - Gradual_Scaling (X_Exp - T'Machine_Mantissa); end if; end if; end Pred; --------------- -- Remainder -- --------------- function Remainder (X, Y : T) return T is A : T; B : T; Arg : T; P : T; P_Frac : T; Sign_X : T; IEEE_Rem : T; Arg_Exp : UI; P_Exp : UI; K : UI; P_Even : Boolean; Arg_Frac : T; pragma Unreferenced (Arg_Frac); begin if Y = 0.0 then raise Constraint_Error; end if; if X > 0.0 then Sign_X := 1.0; Arg := X; else Sign_X := -1.0; Arg := -X; end if; P := abs Y; if Arg < P then P_Even := True; IEEE_Rem := Arg; P_Exp := Exponent (P); else Decompose (Arg, Arg_Frac, Arg_Exp); Decompose (P, P_Frac, P_Exp); P := Compose (P_Frac, Arg_Exp); K := Arg_Exp - P_Exp; P_Even := True; IEEE_Rem := Arg; for Cnt in reverse 0 .. K loop if IEEE_Rem >= P then P_Even := False; IEEE_Rem := IEEE_Rem - P; else P_Even := True; end if; P := P * 0.5; end loop; end if; -- That completes the calculation of modulus remainder. The final -- step is get the IEEE remainder. Here we need to compare Rem with -- (abs Y) / 2. We must be careful of unrepresentable Y/2 value -- caused by subnormal numbers if P_Exp >= 0 then A := IEEE_Rem; B := abs Y * 0.5; else A := IEEE_Rem * 2.0; B := abs Y; end if; if A > B or else (A = B and then not P_Even) then IEEE_Rem := IEEE_Rem - abs Y; end if; return Sign_X * IEEE_Rem; end Remainder; -------------- -- Rounding -- -------------- function Rounding (X : T) return T is Result : T; Tail : T; begin Result := Truncation (abs X); Tail := abs X - Result; if Tail >= 0.5 then Result := Result + 1.0; end if; if X > 0.0 then return Result; elsif X < 0.0 then return -Result; -- For zero case, make sure sign of zero is preserved else return X; end if; end Rounding; ------------- -- Scaling -- ------------- -- Return x * rad ** adjustment quickly, or quietly underflow to zero, -- or overflow naturally. function Scaling (X : T; Adjustment : UI) return T is begin if X = 0.0 or else Adjustment = 0 then return X; end if; -- Nonzero x essentially, just multiply repeatedly by Rad ** (+-2**n) declare Y : T := X; Ex : UI := Adjustment; -- Y * Rad ** Ex is invariant begin if Ex < 0 then while Ex <= -Log_Power (Expbits'Last) loop Y := Y * R_Neg_Power (Expbits'Last); Ex := Ex + Log_Power (Expbits'Last); end loop; -- -64 < Ex <= 0 for N in reverse Expbits'First .. Expbits'Last - 1 loop if Ex <= -Log_Power (N) then Y := Y * R_Neg_Power (N); Ex := Ex + Log_Power (N); end if; -- -Log_Power (N) < Ex <= 0 end loop; -- Ex = 0 else -- Ex >= 0 while Ex >= Log_Power (Expbits'Last) loop Y := Y * R_Power (Expbits'Last); Ex := Ex - Log_Power (Expbits'Last); end loop; -- 0 <= Ex < 64 for N in reverse Expbits'First .. Expbits'Last - 1 loop if Ex >= Log_Power (N) then Y := Y * R_Power (N); Ex := Ex - Log_Power (N); end if; -- 0 <= Ex < Log_Power (N) end loop; -- Ex = 0 end if; return Y; end; end Scaling; ---------- -- Succ -- ---------- function Succ (X : T) return T is X_Frac : T; X_Exp : UI; X1, X2 : T; begin -- Treat zero specially since it has a zero exponent if X = 0.0 then X1 := 2.0 ** T'Machine_Emin; -- Following loop generates smallest denormal loop X2 := T'Machine (X1 / 2.0); exit when X2 = 0.0; X1 := X2; end loop; return X1; -- Special treatment for largest positive number elsif X = T'Last then -- If not generating infinities, we raise a constraint error if T'Machine_Overflows then raise Constraint_Error with "Succ of largest negative number"; -- Otherwise generate a positive infinity else return X / (X - X); end if; -- For infinities, return unchanged elsif X < T'First or else X > T'Last then return X; -- Add to the given number a number equivalent to the value -- of its least significant bit. Given that the most significant bit -- represents a value of 1.0 * radix ** (exp - 1), the value we want -- is obtained by shifting this by (mantissa-1) bits to the right, -- i.e. decreasing the exponent by that amount. else Decompose (X, X_Frac, X_Exp); -- A special case, if the number we had was a negative power of two, -- then we want to add half of what we would otherwise add, since the -- exponent is going to be reduced. -- Note that X_Frac has the same sign as X, so if X_Frac is -0.5, -- then we know that we have a negative number (and hence a negative -- power of 2). if X_Frac = -0.5 then return X + Gradual_Scaling (X_Exp - T'Machine_Mantissa - 1); -- Otherwise the exponent is unchanged else return X + Gradual_Scaling (X_Exp - T'Machine_Mantissa); end if; end if; end Succ; ---------------- -- Truncation -- ---------------- -- The basic approach is to compute -- T'Machine (RM1 + N) - RM1 -- where N >= 0.0 and RM1 = radix ** (mantissa - 1) -- This works provided that the intermediate result (RM1 + N) does not -- have extra precision (which is why we call Machine). When we compute -- RM1 + N, the exponent of N will be normalized and the mantissa shifted -- shifted appropriately so the lower order bits, which cannot contribute -- to the integer part of N, fall off on the right. When we subtract RM1 -- again, the significant bits of N are shifted to the left, and what we -- have is an integer, because only the first e bits are different from -- zero (assuming binary radix here). function Truncation (X : T) return T is Result : T; begin Result := abs X; if Result >= Radix_To_M_Minus_1 then return Machine (X); else Result := Machine (Radix_To_M_Minus_1 + Result) - Radix_To_M_Minus_1; if Result > abs X then Result := Result - 1.0; end if; if X > 0.0 then return Result; elsif X < 0.0 then return -Result; -- For zero case, make sure sign of zero is preserved else return X; end if; end if; end Truncation; ----------------------- -- Unbiased_Rounding -- ----------------------- function Unbiased_Rounding (X : T) return T is Abs_X : constant T := abs X; Result : T; Tail : T; begin Result := Truncation (Abs_X); Tail := Abs_X - Result; if Tail > 0.5 then Result := Result + 1.0; elsif Tail = 0.5 then Result := 2.0 * Truncation ((Result / 2.0) + 0.5); end if; if X > 0.0 then return Result; elsif X < 0.0 then return -Result; -- For zero case, make sure sign of zero is preserved else return X; end if; end Unbiased_Rounding; ----------- -- Valid -- ----------- function Valid (X : not null access T) return Boolean is IEEE_Emin : constant Integer := T'Machine_Emin - 1; IEEE_Emax : constant Integer := T'Machine_Emax - 1; IEEE_Bias : constant Integer := -(IEEE_Emin - 1); subtype IEEE_Exponent_Range is Integer range IEEE_Emin - 1 .. IEEE_Emax + 1; -- The implementation of this floating point attribute uses a -- representation type Float_Rep that allows direct access to the -- exponent and mantissa parts of a floating point number. -- The Float_Rep type is an array of Float_Word elements. This -- representation is chosen to make it possible to size the type based -- on a generic parameter. Since the array size is known at compile -- time, efficient code can still be generated. The size of Float_Word -- elements should be large enough to allow accessing the exponent in -- one read, but small enough so that all floating point object sizes -- are a multiple of the Float_Word'Size. -- The following conditions must be met for all possible instantiations -- of the attributes package: -- - T'Size is an integral multiple of Float_Word'Size -- - The exponent and sign are completely contained in a single -- component of Float_Rep, named Most_Significant_Word (MSW). -- - The sign occupies the most significant bit of the MSW and the -- exponent is in the following bits. Unused bits (if any) are in -- the least significant part. type Float_Word is mod 2**Positive'Min (System.Word_Size, 32); type Rep_Index is range 0 .. 7; Rep_Words : constant Positive := (T'Size + Float_Word'Size - 1) / Float_Word'Size; Rep_Last : constant Rep_Index := Rep_Index'Min (Rep_Index (Rep_Words - 1), (T'Mantissa + 16) / Float_Word'Size); -- Determine the number of Float_Words needed for representing the -- entire floating-point value. Do not take into account excessive -- padding, as occurs on IA-64 where 80 bits floats get padded to 128 -- bits. In general, the exponent field cannot be larger than 15 bits, -- even for 128-bit floating-point types, so the final format size -- won't be larger than T'Mantissa + 16. type Float_Rep is array (Rep_Index range 0 .. Rep_Index (Rep_Words - 1)) of Float_Word; pragma Suppress_Initialization (Float_Rep); -- This pragma suppresses the generation of an initialization procedure -- for type Float_Rep when operating in Initialize/Normalize_Scalars -- mode. This is not just a matter of efficiency, but of functionality, -- since Valid has a pragma Inline_Always, which is not permitted if -- there are nested subprograms present. Most_Significant_Word : constant Rep_Index := Rep_Last * Standard'Default_Bit_Order; -- Finding the location of the Exponent_Word is a bit tricky. In general -- we assume Word_Order = Bit_Order. Exponent_Factor : constant Float_Word := 2**(Float_Word'Size - 1) / Float_Word (IEEE_Emax - IEEE_Emin + 3) * Boolean'Pos (Most_Significant_Word /= 2) + Boolean'Pos (Most_Significant_Word = 2); -- Factor that the extracted exponent needs to be divided by to be in -- range 0 .. IEEE_Emax - IEEE_Emin + 2. Special case: Exponent_Factor -- is 1 for x86/IA64 double extended (GCC adds unused bits to the type). Exponent_Mask : constant Float_Word := Float_Word (IEEE_Emax - IEEE_Emin + 2) * Exponent_Factor; -- Value needed to mask out the exponent field. This assumes that the -- range IEEE_Emin - 1 .. IEEE_Emax + contains 2**N values, for some N -- in Natural. function To_Float is new Ada.Unchecked_Conversion (Float_Rep, T); type Float_Access is access all T; function To_Address is new Ada.Unchecked_Conversion (Float_Access, System.Address); XA : constant System.Address := To_Address (Float_Access (X)); R : Float_Rep; pragma Import (Ada, R); for R'Address use XA; -- R is a view of the input floating-point parameter. Note that we -- must avoid copying the actual bits of this parameter in float -- form (since it may be a signalling NaN). E : constant IEEE_Exponent_Range := Integer ((R (Most_Significant_Word) and Exponent_Mask) / Exponent_Factor) - IEEE_Bias; -- Mask/Shift T to only get bits from the exponent. Then convert biased -- value to integer value. SR : Float_Rep; -- Float_Rep representation of significant of X.all begin if T'Denorm then -- All denormalized numbers are valid, so the only invalid numbers -- are overflows and NaNs, both with exponent = Emax + 1. return E /= IEEE_Emax + 1; end if; -- All denormalized numbers except 0.0 are invalid -- Set exponent of X to zero, so we end up with the significand, which -- definitely is a valid number and can be converted back to a float. SR := R; SR (Most_Significant_Word) := (SR (Most_Significant_Word) and not Exponent_Mask) + Float_Word (IEEE_Bias) * Exponent_Factor; return (E in IEEE_Emin .. IEEE_Emax) or else ((E = IEEE_Emin - 1) and then abs To_Float (SR) = 1.0); end Valid; end System.Fat_Gen;
29.189914
79
0.512553
1e55a687e3febb1d37bc4a72024afa986029d2f6
206
ads
Ada
1-base/math/source/generic/pure/geometry/trigonometry/any_math-any_fast_rotation.ads
charlie5/lace
e9b7dc751d500ff3f559617a6fc3089ace9dc134
[ "0BSD" ]
20
2015-11-04T09:23:59.000Z
2022-01-14T10:21:42.000Z
1-base/math/source/generic/pure/geometry/trigonometry/any_math-any_fast_rotation.ads
charlie5/lace-alire
9ace9682cf4daac7adb9f980c2868d6225b8111c
[ "0BSD" ]
2
2015-11-04T17:05:56.000Z
2015-12-08T03:16:13.000Z
1-base/math/source/generic/pure/geometry/trigonometry/any_math-any_fast_rotation.ads
charlie5/lace-alire
9ace9682cf4daac7adb9f980c2868d6225b8111c
[ "0BSD" ]
1
2015-12-07T12:53:52.000Z
2015-12-07T12:53:52.000Z
generic package any_Math.any_fast_Rotation is function to_Rotation (Angle : in Real) return access constant Matrix_2x2; private pragma Inline_Always (to_Rotation); end any_Math.any_fast_Rotation;
17.166667
76
0.805825
381415d70ca6f244cfbd4e43c6bac2ff41d4b530
4,790
ads
Ada
components/src/touch_panel/ft5336/ft5336.ads
shakram02/Ada_Drivers_Library
a407ca7ddbc2d9756647016c2f8fd8ef24a239ff
[ "BSD-3-Clause" ]
192
2016-06-01T18:32:04.000Z
2022-03-26T22:52:31.000Z
components/src/touch_panel/ft5336/ft5336.ads
morbos/Ada_Drivers_Library
a4ab26799be60997c38735f4056160c4af597ef7
[ "BSD-3-Clause" ]
239
2016-05-26T20:02:01.000Z
2022-03-31T09:46:56.000Z
components/src/touch_panel/ft5336/ft5336.ads
morbos/Ada_Drivers_Library
a4ab26799be60997c38735f4056160c4af597ef7
[ "BSD-3-Clause" ]
142
2016-06-05T08:12:20.000Z
2022-03-24T17:37:17.000Z
------------------------------------------------------------------------------ -- -- -- Copyright (C) 2015-2016, AdaCore -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions are -- -- met: -- -- 1. Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- 2. Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in -- -- the documentation and/or other materials provided with the -- -- distribution. -- -- 3. Neither the name of the copyright holder nor the names of its -- -- contributors may be used to endorse or promote products derived -- -- from this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -- -- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -- -- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -- -- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -- -- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -- -- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- Generic driver for the FT5336 touch panel with HAL; use HAL; with HAL.I2C; use HAL.I2C; with HAL.Touch_Panel; use HAL.Touch_Panel; package FT5336 is type FT5336_Device (Port : not null Any_I2C_Port; I2C_Addr : I2C_Address) is limited new Touch_Panel_Device with private; function Check_Id (This : in out FT5336_Device) return Boolean; -- Checks the ID of the touch panel controller, returns false if not found -- or invalid. procedure TP_Set_Use_Interrupts (This : in out FT5336_Device; Enabled : Boolean); -- Whether the data is retrieved upon interrupt or by polling by the -- software. overriding procedure Set_Bounds (This : in out FT5336_Device; Width : Natural; Height : Natural; Swap : HAL.Touch_Panel.Swap_State); -- Set screen bounds. Touch_State must should stay within screen bounds overriding function Active_Touch_Points (This : in out FT5336_Device) return HAL.Touch_Panel.Touch_Identifier; -- Retrieve the number of active touch points overriding function Get_Touch_Point (This : in out FT5336_Device; Touch_Id : HAL.Touch_Panel.Touch_Identifier) return HAL.Touch_Panel.TP_Touch_State; -- Retrieves the position and pressure information of the specified -- touch overriding function Get_All_Touch_Points (This : in out FT5336_Device) return HAL.Touch_Panel.TP_State; -- Retrieves the position and pressure information of every active touch -- points private type FT5336_Device (Port : not null Any_I2C_Port; I2C_Addr : I2C_Address) is limited new HAL.Touch_Panel.Touch_Panel_Device with record LCD_Natural_Width : Natural := 0; LCD_Natural_Height : Natural := 0; Swap : Swap_State := 0; end record; function I2C_Read (This : in out FT5336_Device; Reg : UInt8; Status : out Boolean) return UInt8; procedure I2C_Write (This : in out FT5336_Device; Reg : UInt8; Data : UInt8; Status : out Boolean); end FT5336;
47.9
78
0.551775
1edf4094d97d399d219f241e2b3257a317434a43
6,600
adb
Ada
3-mid/opengl/source/lean/model/opengl-model-sphere-lit_colored.adb
charlie5/lace-alire
9ace9682cf4daac7adb9f980c2868d6225b8111c
[ "0BSD" ]
1
2022-01-20T07:13:42.000Z
2022-01-20T07:13:42.000Z
3-mid/opengl/source/lean/model/opengl-model-sphere-lit_colored.adb
charlie5/lace-alire
9ace9682cf4daac7adb9f980c2868d6225b8111c
[ "0BSD" ]
null
null
null
3-mid/opengl/source/lean/model/opengl-model-sphere-lit_colored.adb
charlie5/lace-alire
9ace9682cf4daac7adb9f980c2868d6225b8111c
[ "0BSD" ]
null
null
null
with openGL.Geometry .lit_colored, openGL.Primitive.indexed; package body openGL.Model.sphere.lit_colored is --------- --- Forge -- function new_Sphere (Radius : in Real; lat_Count : in Positive := default_latitude_Count; long_Count : in Positive := default_longitude_Count; Color : in lucid_Color) return View is Self : constant View := new Item; begin Self.Color := Color; Self.lat_Count := lat_Count; Self.long_Count := long_Count; Self.define (Radius); return Self; end new_Sphere; -------------- --- Attributes -- -- NB: - An extra vertex is required at the end of each latitude ring. -- - This last vertex has the same site as the rings initial vertex. -- - The last vertex has 's' texture coord of 1.0, whereas -- the initial vertex has 's' texture coord of 0.0. -- overriding function to_GL_Geometries (Self : access Item; Textures : access Texture.name_Map_of_texture'Class; Fonts : in Font.font_id_Map_of_font) return Geometry.views is pragma unreferenced (Textures, Fonts); use Geometry, Geometry.lit_colored; lat_Count : Positive renames Self.lat_Count; long_Count : Positive renames Self.long_Count; Num_lat_strips : constant Positive := lat_Count - 1; lat_Spacing : constant Real := Degrees_180 / Real (lat_Count - 1); long_Spacing : constant Real := Degrees_360 / Real (long_Count); indices_Count : constant long_Index_t := long_Index_t (Num_lat_strips * (long_Count + 1) * 2); vertex_Count : constant Index_t := 1 + 1 -- North and south pole. + Index_t ((long_Count + 1) * (lat_Count - 2)); -- Each latitude ring. the_Vertices : aliased Geometry.lit_colored.Vertex_array := (1 .. vertex_Count => <>); the_Sites : aliased Sites := (1 .. vertex_Count => <>); the_Indices : aliased Indices := (1 .. indices_Count => <>); Color : constant rgba_Color := to_rgba_Color (Self.Color); the_Geometry : constant Geometry.lit_colored.view := Geometry.lit_colored.new_Geometry; begin set_Sites: declare use linear_Algebra, linear_Algebra_3D; north_Pole : constant Site := (0.0, 0.5, 0.0); south_Pole : constant Site := (0.0, -0.5, 0.0); the_Site : Site := north_Pole; vert_Id : Index_t := 1; -- Start at '1' (not '0') to account for the northpole. latitude_line_First : Site; a, b : Real := 0.0; -- Angular 'cursors' used to track lat/long for texture coords. begin the_Sites (the_Vertices'First) := north_Pole; the_Vertices (the_Vertices'First).Site := north_Pole; the_Vertices (the_Vertices'First).Normal := Normalised (north_Pole); the_Vertices (the_Vertices'First).Color := Color; the_Vertices (the_Vertices'First).Shine := 0.5; the_Sites (the_Vertices'Last) := south_Pole; the_Vertices (the_Vertices'Last).Site := south_Pole; the_Vertices (the_Vertices'Last).Normal := Normalised (south_Pole); the_Vertices (the_Vertices'Last).Color := Color; the_Vertices (the_Vertices'Last).Shine := 0.5; for lat_Id in 2 .. lat_Count - 1 loop a := 0.0; b := b + lat_Spacing; the_Site := the_Site * z_Rotation_from (lat_Spacing); latitude_line_First := the_Site; -- Store initial latitude lines 1st point. vert_Id := vert_Id + 1; the_Sites (vert_Id) := the_Site; -- Add 1st point on a line of latitude. the_Vertices (vert_Id).Site := the_Site; the_Vertices (vert_Id).Normal := Normalised (the_Site); the_Vertices (vert_Id).Color := Color; the_Vertices (vert_Id).Shine := 0.5; for long_Id in 1 .. long_Count loop a := a + long_Spacing; if long_Id /= long_Count then the_Site := the_Site * y_Rotation_from (-long_Spacing); else the_Site := latitude_line_First; -- Restore the_Vertex back to initial latitude lines 1st point. end if; vert_Id := vert_Id + 1; the_Sites (vert_Id) := the_Site; -- Add each succesive point on a line of latitude. the_Vertices (vert_Id).Site := the_Site; the_Vertices (vert_Id).Normal := Normalised (the_Site); the_Vertices (vert_Id).Color := Color; the_Vertices (vert_Id).Shine := 0.5; end loop; end loop; end set_Sites; for i in the_Vertices'Range loop the_Vertices (i).Site := the_Vertices (i).Site * Self.Radius * 2.0; end loop; set_Indices: declare strip_Id : long_Index_t := 0; Upper : Index_t; Lower : Index_t; begin upper := 1; lower := 2; for lat_Strip in 1 .. num_lat_Strips loop for Each in 1 .. long_Count + 1 loop strip_Id := strip_Id + 1; the_Indices (strip_Id) := Upper; strip_Id := strip_Id + 1; the_Indices (strip_Id) := Lower; if lat_Strip /= 1 then Upper := Upper + 1; end if; if lat_Strip /= num_lat_Strips then Lower := Lower + 1; end if; end loop; if lat_Strip = 1 then Upper := 2; end if; Lower := Upper + Index_t (long_Count) + 1; end loop; end set_Indices; the_Geometry.is_Transparent (False); the_Geometry.Vertices_are (the_Vertices); declare the_Primitive : constant Primitive.indexed.view := Primitive.indexed.new_Primitive (Primitive.triangle_Strip, the_Indices); begin the_Geometry.add (Primitive.view (the_Primitive)); end; return (1 => Geometry.view (the_Geometry)); end to_GL_Geometries; end openGL.Model.sphere.lit_colored;
34.736842
129
0.546212
8b1c550e17eefae75d632c2bb20fc1f96c873543
69,504
ads
Ada
arch/ARM/RP/svd/rp2040/rp_svd-io_qspi.ads
morbos/Ada_Drivers_Library
a4ab26799be60997c38735f4056160c4af597ef7
[ "BSD-3-Clause" ]
2
2018-05-16T03:56:39.000Z
2019-07-31T13:53:56.000Z
arch/ARM/RP/svd/rp2040/rp_svd-io_qspi.ads
morbos/Ada_Drivers_Library
a4ab26799be60997c38735f4056160c4af597ef7
[ "BSD-3-Clause" ]
null
null
null
arch/ARM/RP/svd/rp2040/rp_svd-io_qspi.ads
morbos/Ada_Drivers_Library
a4ab26799be60997c38735f4056160c4af597ef7
[ "BSD-3-Clause" ]
null
null
null
-- Copyright (c) 2020 Raspberry Pi (Trading) Ltd. -- -- SPDX-License-Identifier: BSD-3-Clause -- This spec has been automatically generated from rp2040.svd pragma Restrictions (No_Elaboration_Code); pragma Ada_2012; pragma Style_Checks (Off); with HAL; with System; package RP_SVD.IO_QSPI is pragma Preelaborate; --------------- -- Registers -- --------------- -- GPIO status type GPIO_QSPI_SCLK_STATUS_Register is record -- unspecified Reserved_0_7 : HAL.UInt8; -- Read-only. output signal from selected peripheral, before register -- override is applied OUTFROMPERI : Boolean; -- Read-only. output signal to pad after register override is applied OUTTOPAD : Boolean; -- unspecified Reserved_10_11 : HAL.UInt2; -- Read-only. output enable from selected peripheral, before register -- override is applied OEFROMPERI : Boolean; -- Read-only. output enable to pad after register override is applied OETOPAD : Boolean; -- unspecified Reserved_14_16 : HAL.UInt3; -- Read-only. input signal from pad, before override is applied INFROMPAD : Boolean; -- unspecified Reserved_18_18 : HAL.Bit; -- Read-only. input signal to peripheral, after override is applied INTOPERI : Boolean; -- unspecified Reserved_20_23 : HAL.UInt4; -- Read-only. interrupt from pad before override is applied IRQFROMPAD : Boolean; -- unspecified Reserved_25_25 : HAL.Bit; -- Read-only. interrupt to processors, after override is applied IRQTOPROC : Boolean; -- unspecified Reserved_27_31 : HAL.UInt5; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for GPIO_QSPI_SCLK_STATUS_Register use record Reserved_0_7 at 0 range 0 .. 7; OUTFROMPERI at 0 range 8 .. 8; OUTTOPAD at 0 range 9 .. 9; Reserved_10_11 at 0 range 10 .. 11; OEFROMPERI at 0 range 12 .. 12; OETOPAD at 0 range 13 .. 13; Reserved_14_16 at 0 range 14 .. 16; INFROMPAD at 0 range 17 .. 17; Reserved_18_18 at 0 range 18 .. 18; INTOPERI at 0 range 19 .. 19; Reserved_20_23 at 0 range 20 .. 23; IRQFROMPAD at 0 range 24 .. 24; Reserved_25_25 at 0 range 25 .. 25; IRQTOPROC at 0 range 26 .. 26; Reserved_27_31 at 0 range 27 .. 31; end record; -- 0-31 -> selects pin function according to the gpio table\n 31 == NULL type GPIO_QSPI_SCLK_CTRL_FUNCSEL_Field is (XIP_SCLK, SIO_30, NULL_k) with Size => 5; for GPIO_QSPI_SCLK_CTRL_FUNCSEL_Field use (XIP_SCLK => 0, SIO_30 => 5, NULL_k => 31); type GPIO_QSPI_SCLK_CTRL_OUTOVER_Field is (-- drive output from peripheral signal selected by funcsel Normal, -- drive output from inverse of peripheral signal selected by funcsel Invert, -- drive output low Low, -- drive output high High) with Size => 2; for GPIO_QSPI_SCLK_CTRL_OUTOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); type GPIO_QSPI_SCLK_CTRL_OEOVER_Field is (-- drive output enable from peripheral signal selected by funcsel Normal, -- drive output enable from inverse of peripheral signal selected by funcsel Invert, -- disable output Disable, -- enable output Enable) with Size => 2; for GPIO_QSPI_SCLK_CTRL_OEOVER_Field use (Normal => 0, Invert => 1, Disable => 2, Enable => 3); type GPIO_QSPI_SCLK_CTRL_INOVER_Field is (-- don't invert the peri input Normal, -- invert the peri input Invert, -- drive peri input low Low, -- drive peri input high High) with Size => 2; for GPIO_QSPI_SCLK_CTRL_INOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); type GPIO_QSPI_SCLK_CTRL_IRQOVER_Field is (-- don't invert the interrupt Normal, -- invert the interrupt Invert, -- drive interrupt low Low, -- drive interrupt high High) with Size => 2; for GPIO_QSPI_SCLK_CTRL_IRQOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); -- GPIO control including function select and overrides. type GPIO_QSPI_SCLK_CTRL_Register is record -- 0-31 -> selects pin function according to the gpio table\n 31 == NULL FUNCSEL : GPIO_QSPI_SCLK_CTRL_FUNCSEL_Field := RP_SVD.IO_QSPI.NULL_k; -- unspecified Reserved_5_7 : HAL.UInt3 := 16#0#; OUTOVER : GPIO_QSPI_SCLK_CTRL_OUTOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_10_11 : HAL.UInt2 := 16#0#; OEOVER : GPIO_QSPI_SCLK_CTRL_OEOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_14_15 : HAL.UInt2 := 16#0#; INOVER : GPIO_QSPI_SCLK_CTRL_INOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_18_27 : HAL.UInt10 := 16#0#; IRQOVER : GPIO_QSPI_SCLK_CTRL_IRQOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_30_31 : HAL.UInt2 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for GPIO_QSPI_SCLK_CTRL_Register use record FUNCSEL at 0 range 0 .. 4; Reserved_5_7 at 0 range 5 .. 7; OUTOVER at 0 range 8 .. 9; Reserved_10_11 at 0 range 10 .. 11; OEOVER at 0 range 12 .. 13; Reserved_14_15 at 0 range 14 .. 15; INOVER at 0 range 16 .. 17; Reserved_18_27 at 0 range 18 .. 27; IRQOVER at 0 range 28 .. 29; Reserved_30_31 at 0 range 30 .. 31; end record; -- GPIO status type GPIO_QSPI_SS_STATUS_Register is record -- unspecified Reserved_0_7 : HAL.UInt8; -- Read-only. output signal from selected peripheral, before register -- override is applied OUTFROMPERI : Boolean; -- Read-only. output signal to pad after register override is applied OUTTOPAD : Boolean; -- unspecified Reserved_10_11 : HAL.UInt2; -- Read-only. output enable from selected peripheral, before register -- override is applied OEFROMPERI : Boolean; -- Read-only. output enable to pad after register override is applied OETOPAD : Boolean; -- unspecified Reserved_14_16 : HAL.UInt3; -- Read-only. input signal from pad, before override is applied INFROMPAD : Boolean; -- unspecified Reserved_18_18 : HAL.Bit; -- Read-only. input signal to peripheral, after override is applied INTOPERI : Boolean; -- unspecified Reserved_20_23 : HAL.UInt4; -- Read-only. interrupt from pad before override is applied IRQFROMPAD : Boolean; -- unspecified Reserved_25_25 : HAL.Bit; -- Read-only. interrupt to processors, after override is applied IRQTOPROC : Boolean; -- unspecified Reserved_27_31 : HAL.UInt5; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for GPIO_QSPI_SS_STATUS_Register use record Reserved_0_7 at 0 range 0 .. 7; OUTFROMPERI at 0 range 8 .. 8; OUTTOPAD at 0 range 9 .. 9; Reserved_10_11 at 0 range 10 .. 11; OEFROMPERI at 0 range 12 .. 12; OETOPAD at 0 range 13 .. 13; Reserved_14_16 at 0 range 14 .. 16; INFROMPAD at 0 range 17 .. 17; Reserved_18_18 at 0 range 18 .. 18; INTOPERI at 0 range 19 .. 19; Reserved_20_23 at 0 range 20 .. 23; IRQFROMPAD at 0 range 24 .. 24; Reserved_25_25 at 0 range 25 .. 25; IRQTOPROC at 0 range 26 .. 26; Reserved_27_31 at 0 range 27 .. 31; end record; -- 0-31 -> selects pin function according to the gpio table\n 31 == NULL type GPIO_QSPI_SS_CTRL_FUNCSEL_Field is (XIP_SS_N, SIO_31, NULL_k) with Size => 5; for GPIO_QSPI_SS_CTRL_FUNCSEL_Field use (XIP_SS_N => 0, SIO_31 => 5, NULL_k => 31); type GPIO_QSPI_SS_CTRL_OUTOVER_Field is (-- drive output from peripheral signal selected by funcsel Normal, -- drive output from inverse of peripheral signal selected by funcsel Invert, -- drive output low Low, -- drive output high High) with Size => 2; for GPIO_QSPI_SS_CTRL_OUTOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); type GPIO_QSPI_SS_CTRL_OEOVER_Field is (-- drive output enable from peripheral signal selected by funcsel Normal, -- drive output enable from inverse of peripheral signal selected by funcsel Invert, -- disable output Disable, -- enable output Enable) with Size => 2; for GPIO_QSPI_SS_CTRL_OEOVER_Field use (Normal => 0, Invert => 1, Disable => 2, Enable => 3); type GPIO_QSPI_SS_CTRL_INOVER_Field is (-- don't invert the peri input Normal, -- invert the peri input Invert, -- drive peri input low Low, -- drive peri input high High) with Size => 2; for GPIO_QSPI_SS_CTRL_INOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); type GPIO_QSPI_SS_CTRL_IRQOVER_Field is (-- don't invert the interrupt Normal, -- invert the interrupt Invert, -- drive interrupt low Low, -- drive interrupt high High) with Size => 2; for GPIO_QSPI_SS_CTRL_IRQOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); -- GPIO control including function select and overrides. type GPIO_QSPI_SS_CTRL_Register is record -- 0-31 -> selects pin function according to the gpio table\n 31 == NULL FUNCSEL : GPIO_QSPI_SS_CTRL_FUNCSEL_Field := RP_SVD.IO_QSPI.NULL_k; -- unspecified Reserved_5_7 : HAL.UInt3 := 16#0#; OUTOVER : GPIO_QSPI_SS_CTRL_OUTOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_10_11 : HAL.UInt2 := 16#0#; OEOVER : GPIO_QSPI_SS_CTRL_OEOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_14_15 : HAL.UInt2 := 16#0#; INOVER : GPIO_QSPI_SS_CTRL_INOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_18_27 : HAL.UInt10 := 16#0#; IRQOVER : GPIO_QSPI_SS_CTRL_IRQOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_30_31 : HAL.UInt2 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for GPIO_QSPI_SS_CTRL_Register use record FUNCSEL at 0 range 0 .. 4; Reserved_5_7 at 0 range 5 .. 7; OUTOVER at 0 range 8 .. 9; Reserved_10_11 at 0 range 10 .. 11; OEOVER at 0 range 12 .. 13; Reserved_14_15 at 0 range 14 .. 15; INOVER at 0 range 16 .. 17; Reserved_18_27 at 0 range 18 .. 27; IRQOVER at 0 range 28 .. 29; Reserved_30_31 at 0 range 30 .. 31; end record; -- GPIO status type GPIO_QSPI_SD0_STATUS_Register is record -- unspecified Reserved_0_7 : HAL.UInt8; -- Read-only. output signal from selected peripheral, before register -- override is applied OUTFROMPERI : Boolean; -- Read-only. output signal to pad after register override is applied OUTTOPAD : Boolean; -- unspecified Reserved_10_11 : HAL.UInt2; -- Read-only. output enable from selected peripheral, before register -- override is applied OEFROMPERI : Boolean; -- Read-only. output enable to pad after register override is applied OETOPAD : Boolean; -- unspecified Reserved_14_16 : HAL.UInt3; -- Read-only. input signal from pad, before override is applied INFROMPAD : Boolean; -- unspecified Reserved_18_18 : HAL.Bit; -- Read-only. input signal to peripheral, after override is applied INTOPERI : Boolean; -- unspecified Reserved_20_23 : HAL.UInt4; -- Read-only. interrupt from pad before override is applied IRQFROMPAD : Boolean; -- unspecified Reserved_25_25 : HAL.Bit; -- Read-only. interrupt to processors, after override is applied IRQTOPROC : Boolean; -- unspecified Reserved_27_31 : HAL.UInt5; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for GPIO_QSPI_SD0_STATUS_Register use record Reserved_0_7 at 0 range 0 .. 7; OUTFROMPERI at 0 range 8 .. 8; OUTTOPAD at 0 range 9 .. 9; Reserved_10_11 at 0 range 10 .. 11; OEFROMPERI at 0 range 12 .. 12; OETOPAD at 0 range 13 .. 13; Reserved_14_16 at 0 range 14 .. 16; INFROMPAD at 0 range 17 .. 17; Reserved_18_18 at 0 range 18 .. 18; INTOPERI at 0 range 19 .. 19; Reserved_20_23 at 0 range 20 .. 23; IRQFROMPAD at 0 range 24 .. 24; Reserved_25_25 at 0 range 25 .. 25; IRQTOPROC at 0 range 26 .. 26; Reserved_27_31 at 0 range 27 .. 31; end record; -- 0-31 -> selects pin function according to the gpio table\n 31 == NULL type GPIO_QSPI_SD0_CTRL_FUNCSEL_Field is (XIP_SD0, SIO_32, NULL_k) with Size => 5; for GPIO_QSPI_SD0_CTRL_FUNCSEL_Field use (XIP_SD0 => 0, SIO_32 => 5, NULL_k => 31); type GPIO_QSPI_SD0_CTRL_OUTOVER_Field is (-- drive output from peripheral signal selected by funcsel Normal, -- drive output from inverse of peripheral signal selected by funcsel Invert, -- drive output low Low, -- drive output high High) with Size => 2; for GPIO_QSPI_SD0_CTRL_OUTOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); type GPIO_QSPI_SD0_CTRL_OEOVER_Field is (-- drive output enable from peripheral signal selected by funcsel Normal, -- drive output enable from inverse of peripheral signal selected by funcsel Invert, -- disable output Disable, -- enable output Enable) with Size => 2; for GPIO_QSPI_SD0_CTRL_OEOVER_Field use (Normal => 0, Invert => 1, Disable => 2, Enable => 3); type GPIO_QSPI_SD0_CTRL_INOVER_Field is (-- don't invert the peri input Normal, -- invert the peri input Invert, -- drive peri input low Low, -- drive peri input high High) with Size => 2; for GPIO_QSPI_SD0_CTRL_INOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); type GPIO_QSPI_SD0_CTRL_IRQOVER_Field is (-- don't invert the interrupt Normal, -- invert the interrupt Invert, -- drive interrupt low Low, -- drive interrupt high High) with Size => 2; for GPIO_QSPI_SD0_CTRL_IRQOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); -- GPIO control including function select and overrides. type GPIO_QSPI_SD0_CTRL_Register is record -- 0-31 -> selects pin function according to the gpio table\n 31 == NULL FUNCSEL : GPIO_QSPI_SD0_CTRL_FUNCSEL_Field := RP_SVD.IO_QSPI.NULL_k; -- unspecified Reserved_5_7 : HAL.UInt3 := 16#0#; OUTOVER : GPIO_QSPI_SD0_CTRL_OUTOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_10_11 : HAL.UInt2 := 16#0#; OEOVER : GPIO_QSPI_SD0_CTRL_OEOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_14_15 : HAL.UInt2 := 16#0#; INOVER : GPIO_QSPI_SD0_CTRL_INOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_18_27 : HAL.UInt10 := 16#0#; IRQOVER : GPIO_QSPI_SD0_CTRL_IRQOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_30_31 : HAL.UInt2 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for GPIO_QSPI_SD0_CTRL_Register use record FUNCSEL at 0 range 0 .. 4; Reserved_5_7 at 0 range 5 .. 7; OUTOVER at 0 range 8 .. 9; Reserved_10_11 at 0 range 10 .. 11; OEOVER at 0 range 12 .. 13; Reserved_14_15 at 0 range 14 .. 15; INOVER at 0 range 16 .. 17; Reserved_18_27 at 0 range 18 .. 27; IRQOVER at 0 range 28 .. 29; Reserved_30_31 at 0 range 30 .. 31; end record; -- GPIO status type GPIO_QSPI_SD1_STATUS_Register is record -- unspecified Reserved_0_7 : HAL.UInt8; -- Read-only. output signal from selected peripheral, before register -- override is applied OUTFROMPERI : Boolean; -- Read-only. output signal to pad after register override is applied OUTTOPAD : Boolean; -- unspecified Reserved_10_11 : HAL.UInt2; -- Read-only. output enable from selected peripheral, before register -- override is applied OEFROMPERI : Boolean; -- Read-only. output enable to pad after register override is applied OETOPAD : Boolean; -- unspecified Reserved_14_16 : HAL.UInt3; -- Read-only. input signal from pad, before override is applied INFROMPAD : Boolean; -- unspecified Reserved_18_18 : HAL.Bit; -- Read-only. input signal to peripheral, after override is applied INTOPERI : Boolean; -- unspecified Reserved_20_23 : HAL.UInt4; -- Read-only. interrupt from pad before override is applied IRQFROMPAD : Boolean; -- unspecified Reserved_25_25 : HAL.Bit; -- Read-only. interrupt to processors, after override is applied IRQTOPROC : Boolean; -- unspecified Reserved_27_31 : HAL.UInt5; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for GPIO_QSPI_SD1_STATUS_Register use record Reserved_0_7 at 0 range 0 .. 7; OUTFROMPERI at 0 range 8 .. 8; OUTTOPAD at 0 range 9 .. 9; Reserved_10_11 at 0 range 10 .. 11; OEFROMPERI at 0 range 12 .. 12; OETOPAD at 0 range 13 .. 13; Reserved_14_16 at 0 range 14 .. 16; INFROMPAD at 0 range 17 .. 17; Reserved_18_18 at 0 range 18 .. 18; INTOPERI at 0 range 19 .. 19; Reserved_20_23 at 0 range 20 .. 23; IRQFROMPAD at 0 range 24 .. 24; Reserved_25_25 at 0 range 25 .. 25; IRQTOPROC at 0 range 26 .. 26; Reserved_27_31 at 0 range 27 .. 31; end record; -- 0-31 -> selects pin function according to the gpio table\n 31 == NULL type GPIO_QSPI_SD1_CTRL_FUNCSEL_Field is (XIP_SD1, SIO_33, NULL_k) with Size => 5; for GPIO_QSPI_SD1_CTRL_FUNCSEL_Field use (XIP_SD1 => 0, SIO_33 => 5, NULL_k => 31); type GPIO_QSPI_SD1_CTRL_OUTOVER_Field is (-- drive output from peripheral signal selected by funcsel Normal, -- drive output from inverse of peripheral signal selected by funcsel Invert, -- drive output low Low, -- drive output high High) with Size => 2; for GPIO_QSPI_SD1_CTRL_OUTOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); type GPIO_QSPI_SD1_CTRL_OEOVER_Field is (-- drive output enable from peripheral signal selected by funcsel Normal, -- drive output enable from inverse of peripheral signal selected by funcsel Invert, -- disable output Disable, -- enable output Enable) with Size => 2; for GPIO_QSPI_SD1_CTRL_OEOVER_Field use (Normal => 0, Invert => 1, Disable => 2, Enable => 3); type GPIO_QSPI_SD1_CTRL_INOVER_Field is (-- don't invert the peri input Normal, -- invert the peri input Invert, -- drive peri input low Low, -- drive peri input high High) with Size => 2; for GPIO_QSPI_SD1_CTRL_INOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); type GPIO_QSPI_SD1_CTRL_IRQOVER_Field is (-- don't invert the interrupt Normal, -- invert the interrupt Invert, -- drive interrupt low Low, -- drive interrupt high High) with Size => 2; for GPIO_QSPI_SD1_CTRL_IRQOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); -- GPIO control including function select and overrides. type GPIO_QSPI_SD1_CTRL_Register is record -- 0-31 -> selects pin function according to the gpio table\n 31 == NULL FUNCSEL : GPIO_QSPI_SD1_CTRL_FUNCSEL_Field := RP_SVD.IO_QSPI.NULL_k; -- unspecified Reserved_5_7 : HAL.UInt3 := 16#0#; OUTOVER : GPIO_QSPI_SD1_CTRL_OUTOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_10_11 : HAL.UInt2 := 16#0#; OEOVER : GPIO_QSPI_SD1_CTRL_OEOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_14_15 : HAL.UInt2 := 16#0#; INOVER : GPIO_QSPI_SD1_CTRL_INOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_18_27 : HAL.UInt10 := 16#0#; IRQOVER : GPIO_QSPI_SD1_CTRL_IRQOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_30_31 : HAL.UInt2 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for GPIO_QSPI_SD1_CTRL_Register use record FUNCSEL at 0 range 0 .. 4; Reserved_5_7 at 0 range 5 .. 7; OUTOVER at 0 range 8 .. 9; Reserved_10_11 at 0 range 10 .. 11; OEOVER at 0 range 12 .. 13; Reserved_14_15 at 0 range 14 .. 15; INOVER at 0 range 16 .. 17; Reserved_18_27 at 0 range 18 .. 27; IRQOVER at 0 range 28 .. 29; Reserved_30_31 at 0 range 30 .. 31; end record; -- GPIO status type GPIO_QSPI_SD2_STATUS_Register is record -- unspecified Reserved_0_7 : HAL.UInt8; -- Read-only. output signal from selected peripheral, before register -- override is applied OUTFROMPERI : Boolean; -- Read-only. output signal to pad after register override is applied OUTTOPAD : Boolean; -- unspecified Reserved_10_11 : HAL.UInt2; -- Read-only. output enable from selected peripheral, before register -- override is applied OEFROMPERI : Boolean; -- Read-only. output enable to pad after register override is applied OETOPAD : Boolean; -- unspecified Reserved_14_16 : HAL.UInt3; -- Read-only. input signal from pad, before override is applied INFROMPAD : Boolean; -- unspecified Reserved_18_18 : HAL.Bit; -- Read-only. input signal to peripheral, after override is applied INTOPERI : Boolean; -- unspecified Reserved_20_23 : HAL.UInt4; -- Read-only. interrupt from pad before override is applied IRQFROMPAD : Boolean; -- unspecified Reserved_25_25 : HAL.Bit; -- Read-only. interrupt to processors, after override is applied IRQTOPROC : Boolean; -- unspecified Reserved_27_31 : HAL.UInt5; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for GPIO_QSPI_SD2_STATUS_Register use record Reserved_0_7 at 0 range 0 .. 7; OUTFROMPERI at 0 range 8 .. 8; OUTTOPAD at 0 range 9 .. 9; Reserved_10_11 at 0 range 10 .. 11; OEFROMPERI at 0 range 12 .. 12; OETOPAD at 0 range 13 .. 13; Reserved_14_16 at 0 range 14 .. 16; INFROMPAD at 0 range 17 .. 17; Reserved_18_18 at 0 range 18 .. 18; INTOPERI at 0 range 19 .. 19; Reserved_20_23 at 0 range 20 .. 23; IRQFROMPAD at 0 range 24 .. 24; Reserved_25_25 at 0 range 25 .. 25; IRQTOPROC at 0 range 26 .. 26; Reserved_27_31 at 0 range 27 .. 31; end record; -- 0-31 -> selects pin function according to the gpio table\n 31 == NULL type GPIO_QSPI_SD2_CTRL_FUNCSEL_Field is (XIP_SD2, SIO_34, NULL_k) with Size => 5; for GPIO_QSPI_SD2_CTRL_FUNCSEL_Field use (XIP_SD2 => 0, SIO_34 => 5, NULL_k => 31); type GPIO_QSPI_SD2_CTRL_OUTOVER_Field is (-- drive output from peripheral signal selected by funcsel Normal, -- drive output from inverse of peripheral signal selected by funcsel Invert, -- drive output low Low, -- drive output high High) with Size => 2; for GPIO_QSPI_SD2_CTRL_OUTOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); type GPIO_QSPI_SD2_CTRL_OEOVER_Field is (-- drive output enable from peripheral signal selected by funcsel Normal, -- drive output enable from inverse of peripheral signal selected by funcsel Invert, -- disable output Disable, -- enable output Enable) with Size => 2; for GPIO_QSPI_SD2_CTRL_OEOVER_Field use (Normal => 0, Invert => 1, Disable => 2, Enable => 3); type GPIO_QSPI_SD2_CTRL_INOVER_Field is (-- don't invert the peri input Normal, -- invert the peri input Invert, -- drive peri input low Low, -- drive peri input high High) with Size => 2; for GPIO_QSPI_SD2_CTRL_INOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); type GPIO_QSPI_SD2_CTRL_IRQOVER_Field is (-- don't invert the interrupt Normal, -- invert the interrupt Invert, -- drive interrupt low Low, -- drive interrupt high High) with Size => 2; for GPIO_QSPI_SD2_CTRL_IRQOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); -- GPIO control including function select and overrides. type GPIO_QSPI_SD2_CTRL_Register is record -- 0-31 -> selects pin function according to the gpio table\n 31 == NULL FUNCSEL : GPIO_QSPI_SD2_CTRL_FUNCSEL_Field := RP_SVD.IO_QSPI.NULL_k; -- unspecified Reserved_5_7 : HAL.UInt3 := 16#0#; OUTOVER : GPIO_QSPI_SD2_CTRL_OUTOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_10_11 : HAL.UInt2 := 16#0#; OEOVER : GPIO_QSPI_SD2_CTRL_OEOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_14_15 : HAL.UInt2 := 16#0#; INOVER : GPIO_QSPI_SD2_CTRL_INOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_18_27 : HAL.UInt10 := 16#0#; IRQOVER : GPIO_QSPI_SD2_CTRL_IRQOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_30_31 : HAL.UInt2 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for GPIO_QSPI_SD2_CTRL_Register use record FUNCSEL at 0 range 0 .. 4; Reserved_5_7 at 0 range 5 .. 7; OUTOVER at 0 range 8 .. 9; Reserved_10_11 at 0 range 10 .. 11; OEOVER at 0 range 12 .. 13; Reserved_14_15 at 0 range 14 .. 15; INOVER at 0 range 16 .. 17; Reserved_18_27 at 0 range 18 .. 27; IRQOVER at 0 range 28 .. 29; Reserved_30_31 at 0 range 30 .. 31; end record; -- GPIO status type GPIO_QSPI_SD3_STATUS_Register is record -- unspecified Reserved_0_7 : HAL.UInt8; -- Read-only. output signal from selected peripheral, before register -- override is applied OUTFROMPERI : Boolean; -- Read-only. output signal to pad after register override is applied OUTTOPAD : Boolean; -- unspecified Reserved_10_11 : HAL.UInt2; -- Read-only. output enable from selected peripheral, before register -- override is applied OEFROMPERI : Boolean; -- Read-only. output enable to pad after register override is applied OETOPAD : Boolean; -- unspecified Reserved_14_16 : HAL.UInt3; -- Read-only. input signal from pad, before override is applied INFROMPAD : Boolean; -- unspecified Reserved_18_18 : HAL.Bit; -- Read-only. input signal to peripheral, after override is applied INTOPERI : Boolean; -- unspecified Reserved_20_23 : HAL.UInt4; -- Read-only. interrupt from pad before override is applied IRQFROMPAD : Boolean; -- unspecified Reserved_25_25 : HAL.Bit; -- Read-only. interrupt to processors, after override is applied IRQTOPROC : Boolean; -- unspecified Reserved_27_31 : HAL.UInt5; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for GPIO_QSPI_SD3_STATUS_Register use record Reserved_0_7 at 0 range 0 .. 7; OUTFROMPERI at 0 range 8 .. 8; OUTTOPAD at 0 range 9 .. 9; Reserved_10_11 at 0 range 10 .. 11; OEFROMPERI at 0 range 12 .. 12; OETOPAD at 0 range 13 .. 13; Reserved_14_16 at 0 range 14 .. 16; INFROMPAD at 0 range 17 .. 17; Reserved_18_18 at 0 range 18 .. 18; INTOPERI at 0 range 19 .. 19; Reserved_20_23 at 0 range 20 .. 23; IRQFROMPAD at 0 range 24 .. 24; Reserved_25_25 at 0 range 25 .. 25; IRQTOPROC at 0 range 26 .. 26; Reserved_27_31 at 0 range 27 .. 31; end record; -- 0-31 -> selects pin function according to the gpio table\n 31 == NULL type GPIO_QSPI_SD3_CTRL_FUNCSEL_Field is (XIP_SD3, SIO_35, NULL_k) with Size => 5; for GPIO_QSPI_SD3_CTRL_FUNCSEL_Field use (XIP_SD3 => 0, SIO_35 => 5, NULL_k => 31); type GPIO_QSPI_SD3_CTRL_OUTOVER_Field is (-- drive output from peripheral signal selected by funcsel Normal, -- drive output from inverse of peripheral signal selected by funcsel Invert, -- drive output low Low, -- drive output high High) with Size => 2; for GPIO_QSPI_SD3_CTRL_OUTOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); type GPIO_QSPI_SD3_CTRL_OEOVER_Field is (-- drive output enable from peripheral signal selected by funcsel Normal, -- drive output enable from inverse of peripheral signal selected by funcsel Invert, -- disable output Disable, -- enable output Enable) with Size => 2; for GPIO_QSPI_SD3_CTRL_OEOVER_Field use (Normal => 0, Invert => 1, Disable => 2, Enable => 3); type GPIO_QSPI_SD3_CTRL_INOVER_Field is (-- don't invert the peri input Normal, -- invert the peri input Invert, -- drive peri input low Low, -- drive peri input high High) with Size => 2; for GPIO_QSPI_SD3_CTRL_INOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); type GPIO_QSPI_SD3_CTRL_IRQOVER_Field is (-- don't invert the interrupt Normal, -- invert the interrupt Invert, -- drive interrupt low Low, -- drive interrupt high High) with Size => 2; for GPIO_QSPI_SD3_CTRL_IRQOVER_Field use (Normal => 0, Invert => 1, Low => 2, High => 3); -- GPIO control including function select and overrides. type GPIO_QSPI_SD3_CTRL_Register is record -- 0-31 -> selects pin function according to the gpio table\n 31 == NULL FUNCSEL : GPIO_QSPI_SD3_CTRL_FUNCSEL_Field := RP_SVD.IO_QSPI.NULL_k; -- unspecified Reserved_5_7 : HAL.UInt3 := 16#0#; OUTOVER : GPIO_QSPI_SD3_CTRL_OUTOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_10_11 : HAL.UInt2 := 16#0#; OEOVER : GPIO_QSPI_SD3_CTRL_OEOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_14_15 : HAL.UInt2 := 16#0#; INOVER : GPIO_QSPI_SD3_CTRL_INOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_18_27 : HAL.UInt10 := 16#0#; IRQOVER : GPIO_QSPI_SD3_CTRL_IRQOVER_Field := RP_SVD.IO_QSPI.Normal; -- unspecified Reserved_30_31 : HAL.UInt2 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for GPIO_QSPI_SD3_CTRL_Register use record FUNCSEL at 0 range 0 .. 4; Reserved_5_7 at 0 range 5 .. 7; OUTOVER at 0 range 8 .. 9; Reserved_10_11 at 0 range 10 .. 11; OEOVER at 0 range 12 .. 13; Reserved_14_15 at 0 range 14 .. 15; INOVER at 0 range 16 .. 17; Reserved_18_27 at 0 range 18 .. 27; IRQOVER at 0 range 28 .. 29; Reserved_30_31 at 0 range 30 .. 31; end record; -- Raw Interrupts type INTR_Register is record -- Read-only. GPIO_QSPI_SCLK_LEVEL_LOW : Boolean := False; -- Read-only. GPIO_QSPI_SCLK_LEVEL_HIGH : Boolean := False; -- Write data bit of one shall clear (set to zero) the corresponding bit -- in the field. GPIO_QSPI_SCLK_EDGE_LOW : Boolean := False; -- Write data bit of one shall clear (set to zero) the corresponding bit -- in the field. GPIO_QSPI_SCLK_EDGE_HIGH : Boolean := False; -- Read-only. GPIO_QSPI_SS_LEVEL_LOW : Boolean := False; -- Read-only. GPIO_QSPI_SS_LEVEL_HIGH : Boolean := False; -- Write data bit of one shall clear (set to zero) the corresponding bit -- in the field. GPIO_QSPI_SS_EDGE_LOW : Boolean := False; -- Write data bit of one shall clear (set to zero) the corresponding bit -- in the field. GPIO_QSPI_SS_EDGE_HIGH : Boolean := False; -- Read-only. GPIO_QSPI_SD0_LEVEL_LOW : Boolean := False; -- Read-only. GPIO_QSPI_SD0_LEVEL_HIGH : Boolean := False; -- Write data bit of one shall clear (set to zero) the corresponding bit -- in the field. GPIO_QSPI_SD0_EDGE_LOW : Boolean := False; -- Write data bit of one shall clear (set to zero) the corresponding bit -- in the field. GPIO_QSPI_SD0_EDGE_HIGH : Boolean := False; -- Read-only. GPIO_QSPI_SD1_LEVEL_LOW : Boolean := False; -- Read-only. GPIO_QSPI_SD1_LEVEL_HIGH : Boolean := False; -- Write data bit of one shall clear (set to zero) the corresponding bit -- in the field. GPIO_QSPI_SD1_EDGE_LOW : Boolean := False; -- Write data bit of one shall clear (set to zero) the corresponding bit -- in the field. GPIO_QSPI_SD1_EDGE_HIGH : Boolean := False; -- Read-only. GPIO_QSPI_SD2_LEVEL_LOW : Boolean := False; -- Read-only. GPIO_QSPI_SD2_LEVEL_HIGH : Boolean := False; -- Write data bit of one shall clear (set to zero) the corresponding bit -- in the field. GPIO_QSPI_SD2_EDGE_LOW : Boolean := False; -- Write data bit of one shall clear (set to zero) the corresponding bit -- in the field. GPIO_QSPI_SD2_EDGE_HIGH : Boolean := False; -- Read-only. GPIO_QSPI_SD3_LEVEL_LOW : Boolean := False; -- Read-only. GPIO_QSPI_SD3_LEVEL_HIGH : Boolean := False; -- Write data bit of one shall clear (set to zero) the corresponding bit -- in the field. GPIO_QSPI_SD3_EDGE_LOW : Boolean := False; -- Write data bit of one shall clear (set to zero) the corresponding bit -- in the field. GPIO_QSPI_SD3_EDGE_HIGH : Boolean := False; -- unspecified Reserved_24_31 : HAL.UInt8 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for INTR_Register use record GPIO_QSPI_SCLK_LEVEL_LOW at 0 range 0 .. 0; GPIO_QSPI_SCLK_LEVEL_HIGH at 0 range 1 .. 1; GPIO_QSPI_SCLK_EDGE_LOW at 0 range 2 .. 2; GPIO_QSPI_SCLK_EDGE_HIGH at 0 range 3 .. 3; GPIO_QSPI_SS_LEVEL_LOW at 0 range 4 .. 4; GPIO_QSPI_SS_LEVEL_HIGH at 0 range 5 .. 5; GPIO_QSPI_SS_EDGE_LOW at 0 range 6 .. 6; GPIO_QSPI_SS_EDGE_HIGH at 0 range 7 .. 7; GPIO_QSPI_SD0_LEVEL_LOW at 0 range 8 .. 8; GPIO_QSPI_SD0_LEVEL_HIGH at 0 range 9 .. 9; GPIO_QSPI_SD0_EDGE_LOW at 0 range 10 .. 10; GPIO_QSPI_SD0_EDGE_HIGH at 0 range 11 .. 11; GPIO_QSPI_SD1_LEVEL_LOW at 0 range 12 .. 12; GPIO_QSPI_SD1_LEVEL_HIGH at 0 range 13 .. 13; GPIO_QSPI_SD1_EDGE_LOW at 0 range 14 .. 14; GPIO_QSPI_SD1_EDGE_HIGH at 0 range 15 .. 15; GPIO_QSPI_SD2_LEVEL_LOW at 0 range 16 .. 16; GPIO_QSPI_SD2_LEVEL_HIGH at 0 range 17 .. 17; GPIO_QSPI_SD2_EDGE_LOW at 0 range 18 .. 18; GPIO_QSPI_SD2_EDGE_HIGH at 0 range 19 .. 19; GPIO_QSPI_SD3_LEVEL_LOW at 0 range 20 .. 20; GPIO_QSPI_SD3_LEVEL_HIGH at 0 range 21 .. 21; GPIO_QSPI_SD3_EDGE_LOW at 0 range 22 .. 22; GPIO_QSPI_SD3_EDGE_HIGH at 0 range 23 .. 23; Reserved_24_31 at 0 range 24 .. 31; end record; -- Interrupt Enable for proc0 type PROC0_INTE_Register is record GPIO_QSPI_SCLK_LEVEL_LOW : Boolean := False; GPIO_QSPI_SCLK_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SCLK_EDGE_LOW : Boolean := False; GPIO_QSPI_SCLK_EDGE_HIGH : Boolean := False; GPIO_QSPI_SS_LEVEL_LOW : Boolean := False; GPIO_QSPI_SS_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SS_EDGE_LOW : Boolean := False; GPIO_QSPI_SS_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD0_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD0_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD0_EDGE_LOW : Boolean := False; GPIO_QSPI_SD0_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD1_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD1_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD1_EDGE_LOW : Boolean := False; GPIO_QSPI_SD1_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD2_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD2_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD2_EDGE_LOW : Boolean := False; GPIO_QSPI_SD2_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD3_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD3_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD3_EDGE_LOW : Boolean := False; GPIO_QSPI_SD3_EDGE_HIGH : Boolean := False; -- unspecified Reserved_24_31 : HAL.UInt8 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for PROC0_INTE_Register use record GPIO_QSPI_SCLK_LEVEL_LOW at 0 range 0 .. 0; GPIO_QSPI_SCLK_LEVEL_HIGH at 0 range 1 .. 1; GPIO_QSPI_SCLK_EDGE_LOW at 0 range 2 .. 2; GPIO_QSPI_SCLK_EDGE_HIGH at 0 range 3 .. 3; GPIO_QSPI_SS_LEVEL_LOW at 0 range 4 .. 4; GPIO_QSPI_SS_LEVEL_HIGH at 0 range 5 .. 5; GPIO_QSPI_SS_EDGE_LOW at 0 range 6 .. 6; GPIO_QSPI_SS_EDGE_HIGH at 0 range 7 .. 7; GPIO_QSPI_SD0_LEVEL_LOW at 0 range 8 .. 8; GPIO_QSPI_SD0_LEVEL_HIGH at 0 range 9 .. 9; GPIO_QSPI_SD0_EDGE_LOW at 0 range 10 .. 10; GPIO_QSPI_SD0_EDGE_HIGH at 0 range 11 .. 11; GPIO_QSPI_SD1_LEVEL_LOW at 0 range 12 .. 12; GPIO_QSPI_SD1_LEVEL_HIGH at 0 range 13 .. 13; GPIO_QSPI_SD1_EDGE_LOW at 0 range 14 .. 14; GPIO_QSPI_SD1_EDGE_HIGH at 0 range 15 .. 15; GPIO_QSPI_SD2_LEVEL_LOW at 0 range 16 .. 16; GPIO_QSPI_SD2_LEVEL_HIGH at 0 range 17 .. 17; GPIO_QSPI_SD2_EDGE_LOW at 0 range 18 .. 18; GPIO_QSPI_SD2_EDGE_HIGH at 0 range 19 .. 19; GPIO_QSPI_SD3_LEVEL_LOW at 0 range 20 .. 20; GPIO_QSPI_SD3_LEVEL_HIGH at 0 range 21 .. 21; GPIO_QSPI_SD3_EDGE_LOW at 0 range 22 .. 22; GPIO_QSPI_SD3_EDGE_HIGH at 0 range 23 .. 23; Reserved_24_31 at 0 range 24 .. 31; end record; -- Interrupt Force for proc0 type PROC0_INTF_Register is record GPIO_QSPI_SCLK_LEVEL_LOW : Boolean := False; GPIO_QSPI_SCLK_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SCLK_EDGE_LOW : Boolean := False; GPIO_QSPI_SCLK_EDGE_HIGH : Boolean := False; GPIO_QSPI_SS_LEVEL_LOW : Boolean := False; GPIO_QSPI_SS_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SS_EDGE_LOW : Boolean := False; GPIO_QSPI_SS_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD0_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD0_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD0_EDGE_LOW : Boolean := False; GPIO_QSPI_SD0_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD1_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD1_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD1_EDGE_LOW : Boolean := False; GPIO_QSPI_SD1_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD2_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD2_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD2_EDGE_LOW : Boolean := False; GPIO_QSPI_SD2_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD3_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD3_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD3_EDGE_LOW : Boolean := False; GPIO_QSPI_SD3_EDGE_HIGH : Boolean := False; -- unspecified Reserved_24_31 : HAL.UInt8 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for PROC0_INTF_Register use record GPIO_QSPI_SCLK_LEVEL_LOW at 0 range 0 .. 0; GPIO_QSPI_SCLK_LEVEL_HIGH at 0 range 1 .. 1; GPIO_QSPI_SCLK_EDGE_LOW at 0 range 2 .. 2; GPIO_QSPI_SCLK_EDGE_HIGH at 0 range 3 .. 3; GPIO_QSPI_SS_LEVEL_LOW at 0 range 4 .. 4; GPIO_QSPI_SS_LEVEL_HIGH at 0 range 5 .. 5; GPIO_QSPI_SS_EDGE_LOW at 0 range 6 .. 6; GPIO_QSPI_SS_EDGE_HIGH at 0 range 7 .. 7; GPIO_QSPI_SD0_LEVEL_LOW at 0 range 8 .. 8; GPIO_QSPI_SD0_LEVEL_HIGH at 0 range 9 .. 9; GPIO_QSPI_SD0_EDGE_LOW at 0 range 10 .. 10; GPIO_QSPI_SD0_EDGE_HIGH at 0 range 11 .. 11; GPIO_QSPI_SD1_LEVEL_LOW at 0 range 12 .. 12; GPIO_QSPI_SD1_LEVEL_HIGH at 0 range 13 .. 13; GPIO_QSPI_SD1_EDGE_LOW at 0 range 14 .. 14; GPIO_QSPI_SD1_EDGE_HIGH at 0 range 15 .. 15; GPIO_QSPI_SD2_LEVEL_LOW at 0 range 16 .. 16; GPIO_QSPI_SD2_LEVEL_HIGH at 0 range 17 .. 17; GPIO_QSPI_SD2_EDGE_LOW at 0 range 18 .. 18; GPIO_QSPI_SD2_EDGE_HIGH at 0 range 19 .. 19; GPIO_QSPI_SD3_LEVEL_LOW at 0 range 20 .. 20; GPIO_QSPI_SD3_LEVEL_HIGH at 0 range 21 .. 21; GPIO_QSPI_SD3_EDGE_LOW at 0 range 22 .. 22; GPIO_QSPI_SD3_EDGE_HIGH at 0 range 23 .. 23; Reserved_24_31 at 0 range 24 .. 31; end record; -- Interrupt status after masking & forcing for proc0 type PROC0_INTS_Register is record -- Read-only. GPIO_QSPI_SCLK_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SCLK_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SCLK_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SCLK_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SS_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SS_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SS_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SS_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD0_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SD0_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD0_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SD0_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD1_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SD1_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD1_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SD1_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD2_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SD2_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD2_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SD2_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD3_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SD3_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD3_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SD3_EDGE_HIGH : Boolean; -- unspecified Reserved_24_31 : HAL.UInt8; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for PROC0_INTS_Register use record GPIO_QSPI_SCLK_LEVEL_LOW at 0 range 0 .. 0; GPIO_QSPI_SCLK_LEVEL_HIGH at 0 range 1 .. 1; GPIO_QSPI_SCLK_EDGE_LOW at 0 range 2 .. 2; GPIO_QSPI_SCLK_EDGE_HIGH at 0 range 3 .. 3; GPIO_QSPI_SS_LEVEL_LOW at 0 range 4 .. 4; GPIO_QSPI_SS_LEVEL_HIGH at 0 range 5 .. 5; GPIO_QSPI_SS_EDGE_LOW at 0 range 6 .. 6; GPIO_QSPI_SS_EDGE_HIGH at 0 range 7 .. 7; GPIO_QSPI_SD0_LEVEL_LOW at 0 range 8 .. 8; GPIO_QSPI_SD0_LEVEL_HIGH at 0 range 9 .. 9; GPIO_QSPI_SD0_EDGE_LOW at 0 range 10 .. 10; GPIO_QSPI_SD0_EDGE_HIGH at 0 range 11 .. 11; GPIO_QSPI_SD1_LEVEL_LOW at 0 range 12 .. 12; GPIO_QSPI_SD1_LEVEL_HIGH at 0 range 13 .. 13; GPIO_QSPI_SD1_EDGE_LOW at 0 range 14 .. 14; GPIO_QSPI_SD1_EDGE_HIGH at 0 range 15 .. 15; GPIO_QSPI_SD2_LEVEL_LOW at 0 range 16 .. 16; GPIO_QSPI_SD2_LEVEL_HIGH at 0 range 17 .. 17; GPIO_QSPI_SD2_EDGE_LOW at 0 range 18 .. 18; GPIO_QSPI_SD2_EDGE_HIGH at 0 range 19 .. 19; GPIO_QSPI_SD3_LEVEL_LOW at 0 range 20 .. 20; GPIO_QSPI_SD3_LEVEL_HIGH at 0 range 21 .. 21; GPIO_QSPI_SD3_EDGE_LOW at 0 range 22 .. 22; GPIO_QSPI_SD3_EDGE_HIGH at 0 range 23 .. 23; Reserved_24_31 at 0 range 24 .. 31; end record; -- Interrupt Enable for proc1 type PROC1_INTE_Register is record GPIO_QSPI_SCLK_LEVEL_LOW : Boolean := False; GPIO_QSPI_SCLK_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SCLK_EDGE_LOW : Boolean := False; GPIO_QSPI_SCLK_EDGE_HIGH : Boolean := False; GPIO_QSPI_SS_LEVEL_LOW : Boolean := False; GPIO_QSPI_SS_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SS_EDGE_LOW : Boolean := False; GPIO_QSPI_SS_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD0_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD0_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD0_EDGE_LOW : Boolean := False; GPIO_QSPI_SD0_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD1_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD1_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD1_EDGE_LOW : Boolean := False; GPIO_QSPI_SD1_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD2_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD2_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD2_EDGE_LOW : Boolean := False; GPIO_QSPI_SD2_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD3_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD3_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD3_EDGE_LOW : Boolean := False; GPIO_QSPI_SD3_EDGE_HIGH : Boolean := False; -- unspecified Reserved_24_31 : HAL.UInt8 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for PROC1_INTE_Register use record GPIO_QSPI_SCLK_LEVEL_LOW at 0 range 0 .. 0; GPIO_QSPI_SCLK_LEVEL_HIGH at 0 range 1 .. 1; GPIO_QSPI_SCLK_EDGE_LOW at 0 range 2 .. 2; GPIO_QSPI_SCLK_EDGE_HIGH at 0 range 3 .. 3; GPIO_QSPI_SS_LEVEL_LOW at 0 range 4 .. 4; GPIO_QSPI_SS_LEVEL_HIGH at 0 range 5 .. 5; GPIO_QSPI_SS_EDGE_LOW at 0 range 6 .. 6; GPIO_QSPI_SS_EDGE_HIGH at 0 range 7 .. 7; GPIO_QSPI_SD0_LEVEL_LOW at 0 range 8 .. 8; GPIO_QSPI_SD0_LEVEL_HIGH at 0 range 9 .. 9; GPIO_QSPI_SD0_EDGE_LOW at 0 range 10 .. 10; GPIO_QSPI_SD0_EDGE_HIGH at 0 range 11 .. 11; GPIO_QSPI_SD1_LEVEL_LOW at 0 range 12 .. 12; GPIO_QSPI_SD1_LEVEL_HIGH at 0 range 13 .. 13; GPIO_QSPI_SD1_EDGE_LOW at 0 range 14 .. 14; GPIO_QSPI_SD1_EDGE_HIGH at 0 range 15 .. 15; GPIO_QSPI_SD2_LEVEL_LOW at 0 range 16 .. 16; GPIO_QSPI_SD2_LEVEL_HIGH at 0 range 17 .. 17; GPIO_QSPI_SD2_EDGE_LOW at 0 range 18 .. 18; GPIO_QSPI_SD2_EDGE_HIGH at 0 range 19 .. 19; GPIO_QSPI_SD3_LEVEL_LOW at 0 range 20 .. 20; GPIO_QSPI_SD3_LEVEL_HIGH at 0 range 21 .. 21; GPIO_QSPI_SD3_EDGE_LOW at 0 range 22 .. 22; GPIO_QSPI_SD3_EDGE_HIGH at 0 range 23 .. 23; Reserved_24_31 at 0 range 24 .. 31; end record; -- Interrupt Force for proc1 type PROC1_INTF_Register is record GPIO_QSPI_SCLK_LEVEL_LOW : Boolean := False; GPIO_QSPI_SCLK_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SCLK_EDGE_LOW : Boolean := False; GPIO_QSPI_SCLK_EDGE_HIGH : Boolean := False; GPIO_QSPI_SS_LEVEL_LOW : Boolean := False; GPIO_QSPI_SS_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SS_EDGE_LOW : Boolean := False; GPIO_QSPI_SS_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD0_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD0_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD0_EDGE_LOW : Boolean := False; GPIO_QSPI_SD0_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD1_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD1_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD1_EDGE_LOW : Boolean := False; GPIO_QSPI_SD1_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD2_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD2_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD2_EDGE_LOW : Boolean := False; GPIO_QSPI_SD2_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD3_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD3_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD3_EDGE_LOW : Boolean := False; GPIO_QSPI_SD3_EDGE_HIGH : Boolean := False; -- unspecified Reserved_24_31 : HAL.UInt8 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for PROC1_INTF_Register use record GPIO_QSPI_SCLK_LEVEL_LOW at 0 range 0 .. 0; GPIO_QSPI_SCLK_LEVEL_HIGH at 0 range 1 .. 1; GPIO_QSPI_SCLK_EDGE_LOW at 0 range 2 .. 2; GPIO_QSPI_SCLK_EDGE_HIGH at 0 range 3 .. 3; GPIO_QSPI_SS_LEVEL_LOW at 0 range 4 .. 4; GPIO_QSPI_SS_LEVEL_HIGH at 0 range 5 .. 5; GPIO_QSPI_SS_EDGE_LOW at 0 range 6 .. 6; GPIO_QSPI_SS_EDGE_HIGH at 0 range 7 .. 7; GPIO_QSPI_SD0_LEVEL_LOW at 0 range 8 .. 8; GPIO_QSPI_SD0_LEVEL_HIGH at 0 range 9 .. 9; GPIO_QSPI_SD0_EDGE_LOW at 0 range 10 .. 10; GPIO_QSPI_SD0_EDGE_HIGH at 0 range 11 .. 11; GPIO_QSPI_SD1_LEVEL_LOW at 0 range 12 .. 12; GPIO_QSPI_SD1_LEVEL_HIGH at 0 range 13 .. 13; GPIO_QSPI_SD1_EDGE_LOW at 0 range 14 .. 14; GPIO_QSPI_SD1_EDGE_HIGH at 0 range 15 .. 15; GPIO_QSPI_SD2_LEVEL_LOW at 0 range 16 .. 16; GPIO_QSPI_SD2_LEVEL_HIGH at 0 range 17 .. 17; GPIO_QSPI_SD2_EDGE_LOW at 0 range 18 .. 18; GPIO_QSPI_SD2_EDGE_HIGH at 0 range 19 .. 19; GPIO_QSPI_SD3_LEVEL_LOW at 0 range 20 .. 20; GPIO_QSPI_SD3_LEVEL_HIGH at 0 range 21 .. 21; GPIO_QSPI_SD3_EDGE_LOW at 0 range 22 .. 22; GPIO_QSPI_SD3_EDGE_HIGH at 0 range 23 .. 23; Reserved_24_31 at 0 range 24 .. 31; end record; -- Interrupt status after masking & forcing for proc1 type PROC1_INTS_Register is record -- Read-only. GPIO_QSPI_SCLK_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SCLK_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SCLK_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SCLK_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SS_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SS_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SS_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SS_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD0_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SD0_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD0_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SD0_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD1_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SD1_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD1_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SD1_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD2_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SD2_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD2_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SD2_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD3_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SD3_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD3_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SD3_EDGE_HIGH : Boolean; -- unspecified Reserved_24_31 : HAL.UInt8; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for PROC1_INTS_Register use record GPIO_QSPI_SCLK_LEVEL_LOW at 0 range 0 .. 0; GPIO_QSPI_SCLK_LEVEL_HIGH at 0 range 1 .. 1; GPIO_QSPI_SCLK_EDGE_LOW at 0 range 2 .. 2; GPIO_QSPI_SCLK_EDGE_HIGH at 0 range 3 .. 3; GPIO_QSPI_SS_LEVEL_LOW at 0 range 4 .. 4; GPIO_QSPI_SS_LEVEL_HIGH at 0 range 5 .. 5; GPIO_QSPI_SS_EDGE_LOW at 0 range 6 .. 6; GPIO_QSPI_SS_EDGE_HIGH at 0 range 7 .. 7; GPIO_QSPI_SD0_LEVEL_LOW at 0 range 8 .. 8; GPIO_QSPI_SD0_LEVEL_HIGH at 0 range 9 .. 9; GPIO_QSPI_SD0_EDGE_LOW at 0 range 10 .. 10; GPIO_QSPI_SD0_EDGE_HIGH at 0 range 11 .. 11; GPIO_QSPI_SD1_LEVEL_LOW at 0 range 12 .. 12; GPIO_QSPI_SD1_LEVEL_HIGH at 0 range 13 .. 13; GPIO_QSPI_SD1_EDGE_LOW at 0 range 14 .. 14; GPIO_QSPI_SD1_EDGE_HIGH at 0 range 15 .. 15; GPIO_QSPI_SD2_LEVEL_LOW at 0 range 16 .. 16; GPIO_QSPI_SD2_LEVEL_HIGH at 0 range 17 .. 17; GPIO_QSPI_SD2_EDGE_LOW at 0 range 18 .. 18; GPIO_QSPI_SD2_EDGE_HIGH at 0 range 19 .. 19; GPIO_QSPI_SD3_LEVEL_LOW at 0 range 20 .. 20; GPIO_QSPI_SD3_LEVEL_HIGH at 0 range 21 .. 21; GPIO_QSPI_SD3_EDGE_LOW at 0 range 22 .. 22; GPIO_QSPI_SD3_EDGE_HIGH at 0 range 23 .. 23; Reserved_24_31 at 0 range 24 .. 31; end record; -- Interrupt Enable for dormant_wake type DORMANT_WAKE_INTE_Register is record GPIO_QSPI_SCLK_LEVEL_LOW : Boolean := False; GPIO_QSPI_SCLK_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SCLK_EDGE_LOW : Boolean := False; GPIO_QSPI_SCLK_EDGE_HIGH : Boolean := False; GPIO_QSPI_SS_LEVEL_LOW : Boolean := False; GPIO_QSPI_SS_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SS_EDGE_LOW : Boolean := False; GPIO_QSPI_SS_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD0_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD0_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD0_EDGE_LOW : Boolean := False; GPIO_QSPI_SD0_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD1_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD1_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD1_EDGE_LOW : Boolean := False; GPIO_QSPI_SD1_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD2_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD2_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD2_EDGE_LOW : Boolean := False; GPIO_QSPI_SD2_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD3_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD3_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD3_EDGE_LOW : Boolean := False; GPIO_QSPI_SD3_EDGE_HIGH : Boolean := False; -- unspecified Reserved_24_31 : HAL.UInt8 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for DORMANT_WAKE_INTE_Register use record GPIO_QSPI_SCLK_LEVEL_LOW at 0 range 0 .. 0; GPIO_QSPI_SCLK_LEVEL_HIGH at 0 range 1 .. 1; GPIO_QSPI_SCLK_EDGE_LOW at 0 range 2 .. 2; GPIO_QSPI_SCLK_EDGE_HIGH at 0 range 3 .. 3; GPIO_QSPI_SS_LEVEL_LOW at 0 range 4 .. 4; GPIO_QSPI_SS_LEVEL_HIGH at 0 range 5 .. 5; GPIO_QSPI_SS_EDGE_LOW at 0 range 6 .. 6; GPIO_QSPI_SS_EDGE_HIGH at 0 range 7 .. 7; GPIO_QSPI_SD0_LEVEL_LOW at 0 range 8 .. 8; GPIO_QSPI_SD0_LEVEL_HIGH at 0 range 9 .. 9; GPIO_QSPI_SD0_EDGE_LOW at 0 range 10 .. 10; GPIO_QSPI_SD0_EDGE_HIGH at 0 range 11 .. 11; GPIO_QSPI_SD1_LEVEL_LOW at 0 range 12 .. 12; GPIO_QSPI_SD1_LEVEL_HIGH at 0 range 13 .. 13; GPIO_QSPI_SD1_EDGE_LOW at 0 range 14 .. 14; GPIO_QSPI_SD1_EDGE_HIGH at 0 range 15 .. 15; GPIO_QSPI_SD2_LEVEL_LOW at 0 range 16 .. 16; GPIO_QSPI_SD2_LEVEL_HIGH at 0 range 17 .. 17; GPIO_QSPI_SD2_EDGE_LOW at 0 range 18 .. 18; GPIO_QSPI_SD2_EDGE_HIGH at 0 range 19 .. 19; GPIO_QSPI_SD3_LEVEL_LOW at 0 range 20 .. 20; GPIO_QSPI_SD3_LEVEL_HIGH at 0 range 21 .. 21; GPIO_QSPI_SD3_EDGE_LOW at 0 range 22 .. 22; GPIO_QSPI_SD3_EDGE_HIGH at 0 range 23 .. 23; Reserved_24_31 at 0 range 24 .. 31; end record; -- Interrupt Force for dormant_wake type DORMANT_WAKE_INTF_Register is record GPIO_QSPI_SCLK_LEVEL_LOW : Boolean := False; GPIO_QSPI_SCLK_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SCLK_EDGE_LOW : Boolean := False; GPIO_QSPI_SCLK_EDGE_HIGH : Boolean := False; GPIO_QSPI_SS_LEVEL_LOW : Boolean := False; GPIO_QSPI_SS_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SS_EDGE_LOW : Boolean := False; GPIO_QSPI_SS_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD0_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD0_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD0_EDGE_LOW : Boolean := False; GPIO_QSPI_SD0_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD1_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD1_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD1_EDGE_LOW : Boolean := False; GPIO_QSPI_SD1_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD2_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD2_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD2_EDGE_LOW : Boolean := False; GPIO_QSPI_SD2_EDGE_HIGH : Boolean := False; GPIO_QSPI_SD3_LEVEL_LOW : Boolean := False; GPIO_QSPI_SD3_LEVEL_HIGH : Boolean := False; GPIO_QSPI_SD3_EDGE_LOW : Boolean := False; GPIO_QSPI_SD3_EDGE_HIGH : Boolean := False; -- unspecified Reserved_24_31 : HAL.UInt8 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for DORMANT_WAKE_INTF_Register use record GPIO_QSPI_SCLK_LEVEL_LOW at 0 range 0 .. 0; GPIO_QSPI_SCLK_LEVEL_HIGH at 0 range 1 .. 1; GPIO_QSPI_SCLK_EDGE_LOW at 0 range 2 .. 2; GPIO_QSPI_SCLK_EDGE_HIGH at 0 range 3 .. 3; GPIO_QSPI_SS_LEVEL_LOW at 0 range 4 .. 4; GPIO_QSPI_SS_LEVEL_HIGH at 0 range 5 .. 5; GPIO_QSPI_SS_EDGE_LOW at 0 range 6 .. 6; GPIO_QSPI_SS_EDGE_HIGH at 0 range 7 .. 7; GPIO_QSPI_SD0_LEVEL_LOW at 0 range 8 .. 8; GPIO_QSPI_SD0_LEVEL_HIGH at 0 range 9 .. 9; GPIO_QSPI_SD0_EDGE_LOW at 0 range 10 .. 10; GPIO_QSPI_SD0_EDGE_HIGH at 0 range 11 .. 11; GPIO_QSPI_SD1_LEVEL_LOW at 0 range 12 .. 12; GPIO_QSPI_SD1_LEVEL_HIGH at 0 range 13 .. 13; GPIO_QSPI_SD1_EDGE_LOW at 0 range 14 .. 14; GPIO_QSPI_SD1_EDGE_HIGH at 0 range 15 .. 15; GPIO_QSPI_SD2_LEVEL_LOW at 0 range 16 .. 16; GPIO_QSPI_SD2_LEVEL_HIGH at 0 range 17 .. 17; GPIO_QSPI_SD2_EDGE_LOW at 0 range 18 .. 18; GPIO_QSPI_SD2_EDGE_HIGH at 0 range 19 .. 19; GPIO_QSPI_SD3_LEVEL_LOW at 0 range 20 .. 20; GPIO_QSPI_SD3_LEVEL_HIGH at 0 range 21 .. 21; GPIO_QSPI_SD3_EDGE_LOW at 0 range 22 .. 22; GPIO_QSPI_SD3_EDGE_HIGH at 0 range 23 .. 23; Reserved_24_31 at 0 range 24 .. 31; end record; -- Interrupt status after masking & forcing for dormant_wake type DORMANT_WAKE_INTS_Register is record -- Read-only. GPIO_QSPI_SCLK_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SCLK_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SCLK_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SCLK_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SS_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SS_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SS_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SS_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD0_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SD0_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD0_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SD0_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD1_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SD1_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD1_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SD1_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD2_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SD2_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD2_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SD2_EDGE_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD3_LEVEL_LOW : Boolean; -- Read-only. GPIO_QSPI_SD3_LEVEL_HIGH : Boolean; -- Read-only. GPIO_QSPI_SD3_EDGE_LOW : Boolean; -- Read-only. GPIO_QSPI_SD3_EDGE_HIGH : Boolean; -- unspecified Reserved_24_31 : HAL.UInt8; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for DORMANT_WAKE_INTS_Register use record GPIO_QSPI_SCLK_LEVEL_LOW at 0 range 0 .. 0; GPIO_QSPI_SCLK_LEVEL_HIGH at 0 range 1 .. 1; GPIO_QSPI_SCLK_EDGE_LOW at 0 range 2 .. 2; GPIO_QSPI_SCLK_EDGE_HIGH at 0 range 3 .. 3; GPIO_QSPI_SS_LEVEL_LOW at 0 range 4 .. 4; GPIO_QSPI_SS_LEVEL_HIGH at 0 range 5 .. 5; GPIO_QSPI_SS_EDGE_LOW at 0 range 6 .. 6; GPIO_QSPI_SS_EDGE_HIGH at 0 range 7 .. 7; GPIO_QSPI_SD0_LEVEL_LOW at 0 range 8 .. 8; GPIO_QSPI_SD0_LEVEL_HIGH at 0 range 9 .. 9; GPIO_QSPI_SD0_EDGE_LOW at 0 range 10 .. 10; GPIO_QSPI_SD0_EDGE_HIGH at 0 range 11 .. 11; GPIO_QSPI_SD1_LEVEL_LOW at 0 range 12 .. 12; GPIO_QSPI_SD1_LEVEL_HIGH at 0 range 13 .. 13; GPIO_QSPI_SD1_EDGE_LOW at 0 range 14 .. 14; GPIO_QSPI_SD1_EDGE_HIGH at 0 range 15 .. 15; GPIO_QSPI_SD2_LEVEL_LOW at 0 range 16 .. 16; GPIO_QSPI_SD2_LEVEL_HIGH at 0 range 17 .. 17; GPIO_QSPI_SD2_EDGE_LOW at 0 range 18 .. 18; GPIO_QSPI_SD2_EDGE_HIGH at 0 range 19 .. 19; GPIO_QSPI_SD3_LEVEL_LOW at 0 range 20 .. 20; GPIO_QSPI_SD3_LEVEL_HIGH at 0 range 21 .. 21; GPIO_QSPI_SD3_EDGE_LOW at 0 range 22 .. 22; GPIO_QSPI_SD3_EDGE_HIGH at 0 range 23 .. 23; Reserved_24_31 at 0 range 24 .. 31; end record; ----------------- -- Peripherals -- ----------------- type IO_QSPI_Peripheral is record -- GPIO status GPIO_QSPI_SCLK_STATUS : aliased GPIO_QSPI_SCLK_STATUS_Register; -- GPIO control including function select and overrides. GPIO_QSPI_SCLK_CTRL : aliased GPIO_QSPI_SCLK_CTRL_Register; -- GPIO status GPIO_QSPI_SS_STATUS : aliased GPIO_QSPI_SS_STATUS_Register; -- GPIO control including function select and overrides. GPIO_QSPI_SS_CTRL : aliased GPIO_QSPI_SS_CTRL_Register; -- GPIO status GPIO_QSPI_SD0_STATUS : aliased GPIO_QSPI_SD0_STATUS_Register; -- GPIO control including function select and overrides. GPIO_QSPI_SD0_CTRL : aliased GPIO_QSPI_SD0_CTRL_Register; -- GPIO status GPIO_QSPI_SD1_STATUS : aliased GPIO_QSPI_SD1_STATUS_Register; -- GPIO control including function select and overrides. GPIO_QSPI_SD1_CTRL : aliased GPIO_QSPI_SD1_CTRL_Register; -- GPIO status GPIO_QSPI_SD2_STATUS : aliased GPIO_QSPI_SD2_STATUS_Register; -- GPIO control including function select and overrides. GPIO_QSPI_SD2_CTRL : aliased GPIO_QSPI_SD2_CTRL_Register; -- GPIO status GPIO_QSPI_SD3_STATUS : aliased GPIO_QSPI_SD3_STATUS_Register; -- GPIO control including function select and overrides. GPIO_QSPI_SD3_CTRL : aliased GPIO_QSPI_SD3_CTRL_Register; -- Raw Interrupts INTR : aliased INTR_Register; -- Interrupt Enable for proc0 PROC0_INTE : aliased PROC0_INTE_Register; -- Interrupt Force for proc0 PROC0_INTF : aliased PROC0_INTF_Register; -- Interrupt status after masking & forcing for proc0 PROC0_INTS : aliased PROC0_INTS_Register; -- Interrupt Enable for proc1 PROC1_INTE : aliased PROC1_INTE_Register; -- Interrupt Force for proc1 PROC1_INTF : aliased PROC1_INTF_Register; -- Interrupt status after masking & forcing for proc1 PROC1_INTS : aliased PROC1_INTS_Register; -- Interrupt Enable for dormant_wake DORMANT_WAKE_INTE : aliased DORMANT_WAKE_INTE_Register; -- Interrupt Force for dormant_wake DORMANT_WAKE_INTF : aliased DORMANT_WAKE_INTF_Register; -- Interrupt status after masking & forcing for dormant_wake DORMANT_WAKE_INTS : aliased DORMANT_WAKE_INTS_Register; end record with Volatile; for IO_QSPI_Peripheral use record GPIO_QSPI_SCLK_STATUS at 16#0# range 0 .. 31; GPIO_QSPI_SCLK_CTRL at 16#4# range 0 .. 31; GPIO_QSPI_SS_STATUS at 16#8# range 0 .. 31; GPIO_QSPI_SS_CTRL at 16#C# range 0 .. 31; GPIO_QSPI_SD0_STATUS at 16#10# range 0 .. 31; GPIO_QSPI_SD0_CTRL at 16#14# range 0 .. 31; GPIO_QSPI_SD1_STATUS at 16#18# range 0 .. 31; GPIO_QSPI_SD1_CTRL at 16#1C# range 0 .. 31; GPIO_QSPI_SD2_STATUS at 16#20# range 0 .. 31; GPIO_QSPI_SD2_CTRL at 16#24# range 0 .. 31; GPIO_QSPI_SD3_STATUS at 16#28# range 0 .. 31; GPIO_QSPI_SD3_CTRL at 16#2C# range 0 .. 31; INTR at 16#30# range 0 .. 31; PROC0_INTE at 16#34# range 0 .. 31; PROC0_INTF at 16#38# range 0 .. 31; PROC0_INTS at 16#3C# range 0 .. 31; PROC1_INTE at 16#40# range 0 .. 31; PROC1_INTF at 16#44# range 0 .. 31; PROC1_INTS at 16#48# range 0 .. 31; DORMANT_WAKE_INTE at 16#4C# range 0 .. 31; DORMANT_WAKE_INTF at 16#50# range 0 .. 31; DORMANT_WAKE_INTS at 16#54# range 0 .. 31; end record; IO_QSPI_Periph : aliased IO_QSPI_Peripheral with Import, Address => IO_QSPI_Base; end RP_SVD.IO_QSPI;
37.856209
83
0.621331
8be2121dee1462588ac7da506b508ae1b4b2202e
16,231
ads
Ada
gcc-gcc-7_3_0-release/gcc/ada/a-coinve.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
7
2020-05-02T17:34:05.000Z
2021-10-17T10:15:18.000Z
gcc-gcc-7_3_0-release/gcc/ada/a-coinve.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
null
null
null
gcc-gcc-7_3_0-release/gcc/ada/a-coinve.ads
best08618/asylo
5a520a9f5c461ede0f32acc284017b737a43898c
[ "Apache-2.0" ]
2
2020-07-27T00:22:36.000Z
2021-04-01T09:41:02.000Z
------------------------------------------------------------------------------ -- -- -- GNAT LIBRARY COMPONENTS -- -- -- -- A D A . C O N T A I N E R S . I N D E F I N I T E _ V E C T O R S -- -- -- -- S p e c -- -- -- -- Copyright (C) 2004-2015, Free Software Foundation, Inc. -- -- -- -- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. The copyright notice above, and the license provisions that follow -- -- apply solely to the contents of the part following the private keyword. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- This unit was originally developed by Matthew J Heaney. -- ------------------------------------------------------------------------------ with Ada.Iterator_Interfaces; with Ada.Containers.Helpers; private with Ada.Finalization; private with Ada.Streams; generic type Index_Type is range <>; type Element_Type (<>) is private; with function "=" (Left, Right : Element_Type) return Boolean is <>; package Ada.Containers.Indefinite_Vectors is pragma Annotate (CodePeer, Skip_Analysis); pragma Preelaborate; pragma Remote_Types; subtype Extended_Index is Index_Type'Base range Index_Type'First - 1 .. Index_Type'Min (Index_Type'Base'Last - 1, Index_Type'Last) + 1; No_Index : constant Extended_Index := Extended_Index'First; type Vector is tagged private with Constant_Indexing => Constant_Reference, Variable_Indexing => Reference, Default_Iterator => Iterate, Iterator_Element => Element_Type; pragma Preelaborable_Initialization (Vector); type Cursor is private; pragma Preelaborable_Initialization (Cursor); Empty_Vector : constant Vector; No_Element : constant Cursor; function Has_Element (Position : Cursor) return Boolean; package Vector_Iterator_Interfaces is new Ada.Iterator_Interfaces (Cursor, Has_Element); overriding function "=" (Left, Right : Vector) return Boolean; function To_Vector (Length : Count_Type) return Vector; function To_Vector (New_Item : Element_Type; Length : Count_Type) return Vector; function "&" (Left, Right : Vector) return Vector; function "&" (Left : Vector; Right : Element_Type) return Vector; function "&" (Left : Element_Type; Right : Vector) return Vector; function "&" (Left, Right : Element_Type) return Vector; function Capacity (Container : Vector) return Count_Type; procedure Reserve_Capacity (Container : in out Vector; Capacity : Count_Type); function Length (Container : Vector) return Count_Type; procedure Set_Length (Container : in out Vector; Length : Count_Type); function Is_Empty (Container : Vector) return Boolean; procedure Clear (Container : in out Vector); type Constant_Reference_Type (Element : not null access constant Element_Type) is private with Implicit_Dereference => Element; type Reference_Type (Element : not null access Element_Type) is private with Implicit_Dereference => Element; function Constant_Reference (Container : aliased Vector; Position : Cursor) return Constant_Reference_Type; pragma Inline (Constant_Reference); function Reference (Container : aliased in out Vector; Position : Cursor) return Reference_Type; pragma Inline (Reference); function Constant_Reference (Container : aliased Vector; Index : Index_Type) return Constant_Reference_Type; pragma Inline (Constant_Reference); function Reference (Container : aliased in out Vector; Index : Index_Type) return Reference_Type; pragma Inline (Reference); function To_Cursor (Container : Vector; Index : Extended_Index) return Cursor; function To_Index (Position : Cursor) return Extended_Index; function Element (Container : Vector; Index : Index_Type) return Element_Type; function Element (Position : Cursor) return Element_Type; procedure Replace_Element (Container : in out Vector; Index : Index_Type; New_Item : Element_Type); procedure Replace_Element (Container : in out Vector; Position : Cursor; New_Item : Element_Type); procedure Query_Element (Container : Vector; Index : Index_Type; Process : not null access procedure (Element : Element_Type)); procedure Query_Element (Position : Cursor; Process : not null access procedure (Element : Element_Type)); procedure Update_Element (Container : in out Vector; Index : Index_Type; Process : not null access procedure (Element : in out Element_Type)); procedure Update_Element (Container : in out Vector; Position : Cursor; Process : not null access procedure (Element : in out Element_Type)); procedure Assign (Target : in out Vector; Source : Vector); function Copy (Source : Vector; Capacity : Count_Type := 0) return Vector; procedure Move (Target : in out Vector; Source : in out Vector); procedure Insert (Container : in out Vector; Before : Extended_Index; New_Item : Vector); procedure Insert (Container : in out Vector; Before : Cursor; New_Item : Vector); procedure Insert (Container : in out Vector; Before : Cursor; New_Item : Vector; Position : out Cursor); procedure Insert (Container : in out Vector; Before : Extended_Index; New_Item : Element_Type; Count : Count_Type := 1); procedure Insert (Container : in out Vector; Before : Cursor; New_Item : Element_Type; Count : Count_Type := 1); procedure Insert (Container : in out Vector; Before : Cursor; New_Item : Element_Type; Position : out Cursor; Count : Count_Type := 1); procedure Prepend (Container : in out Vector; New_Item : Vector); procedure Prepend (Container : in out Vector; New_Item : Element_Type; Count : Count_Type := 1); procedure Append (Container : in out Vector; New_Item : Vector); procedure Append (Container : in out Vector; New_Item : Element_Type; Count : Count_Type := 1); procedure Insert_Space (Container : in out Vector; Before : Extended_Index; Count : Count_Type := 1); procedure Insert_Space (Container : in out Vector; Before : Cursor; Position : out Cursor; Count : Count_Type := 1); procedure Delete (Container : in out Vector; Index : Extended_Index; Count : Count_Type := 1); procedure Delete (Container : in out Vector; Position : in out Cursor; Count : Count_Type := 1); procedure Delete_First (Container : in out Vector; Count : Count_Type := 1); procedure Delete_Last (Container : in out Vector; Count : Count_Type := 1); procedure Reverse_Elements (Container : in out Vector); procedure Swap (Container : in out Vector; I, J : Index_Type); procedure Swap (Container : in out Vector; I, J : Cursor); function First_Index (Container : Vector) return Index_Type; function First (Container : Vector) return Cursor; function First_Element (Container : Vector) return Element_Type; function Last_Index (Container : Vector) return Extended_Index; function Last (Container : Vector) return Cursor; function Last_Element (Container : Vector) return Element_Type; function Next (Position : Cursor) return Cursor; procedure Next (Position : in out Cursor); function Previous (Position : Cursor) return Cursor; procedure Previous (Position : in out Cursor); function Find_Index (Container : Vector; Item : Element_Type; Index : Index_Type := Index_Type'First) return Extended_Index; function Find (Container : Vector; Item : Element_Type; Position : Cursor := No_Element) return Cursor; function Reverse_Find_Index (Container : Vector; Item : Element_Type; Index : Index_Type := Index_Type'Last) return Extended_Index; function Reverse_Find (Container : Vector; Item : Element_Type; Position : Cursor := No_Element) return Cursor; function Contains (Container : Vector; Item : Element_Type) return Boolean; procedure Iterate (Container : Vector; Process : not null access procedure (Position : Cursor)); function Iterate (Container : Vector) return Vector_Iterator_Interfaces.Reversible_Iterator'class; function Iterate (Container : Vector; Start : Cursor) return Vector_Iterator_Interfaces.Reversible_Iterator'class; procedure Reverse_Iterate (Container : Vector; Process : not null access procedure (Position : Cursor)); generic with function "<" (Left, Right : Element_Type) return Boolean is <>; package Generic_Sorting is function Is_Sorted (Container : Vector) return Boolean; procedure Sort (Container : in out Vector); procedure Merge (Target : in out Vector; Source : in out Vector); end Generic_Sorting; private pragma Inline (Append); pragma Inline (First_Index); pragma Inline (Last_Index); pragma Inline (Element); pragma Inline (First_Element); pragma Inline (Last_Element); pragma Inline (Query_Element); pragma Inline (Update_Element); pragma Inline (Replace_Element); pragma Inline (Is_Empty); pragma Inline (Contains); pragma Inline (Next); pragma Inline (Previous); use Ada.Containers.Helpers; package Implementation is new Generic_Implementation; use Implementation; type Element_Access is access Element_Type; type Elements_Array is array (Index_Type range <>) of Element_Access; function "=" (L, R : Elements_Array) return Boolean is abstract; type Elements_Type (Last : Extended_Index) is limited record EA : Elements_Array (Index_Type'First .. Last); end record; type Elements_Access is access all Elements_Type; use Finalization; use Streams; type Vector is new Controlled with record Elements : Elements_Access := null; Last : Extended_Index := No_Index; TC : aliased Tamper_Counts; end record; overriding procedure Adjust (Container : in out Vector); overriding procedure Finalize (Container : in out Vector); procedure Write (Stream : not null access Root_Stream_Type'Class; Container : Vector); for Vector'Write use Write; procedure Read (Stream : not null access Root_Stream_Type'Class; Container : out Vector); for Vector'Read use Read; type Vector_Access is access all Vector; for Vector_Access'Storage_Size use 0; type Cursor is record Container : Vector_Access; Index : Index_Type := Index_Type'First; end record; procedure Read (Stream : not null access Root_Stream_Type'Class; Position : out Cursor); for Cursor'Read use Read; procedure Write (Stream : not null access Root_Stream_Type'Class; Position : Cursor); for Cursor'Write use Write; subtype Reference_Control_Type is Implementation.Reference_Control_Type; -- It is necessary to rename this here, so that the compiler can find it type Constant_Reference_Type (Element : not null access constant Element_Type) is record Control : Reference_Control_Type := raise Program_Error with "uninitialized reference"; -- The RM says, "The default initialization of an object of -- type Constant_Reference_Type or Reference_Type propagates -- Program_Error." end record; procedure Write (Stream : not null access Root_Stream_Type'Class; Item : Constant_Reference_Type); for Constant_Reference_Type'Write use Write; procedure Read (Stream : not null access Root_Stream_Type'Class; Item : out Constant_Reference_Type); for Constant_Reference_Type'Read use Read; type Reference_Type (Element : not null access Element_Type) is record Control : Reference_Control_Type := raise Program_Error with "uninitialized reference"; -- The RM says, "The default initialization of an object of -- type Constant_Reference_Type or Reference_Type propagates -- Program_Error." end record; procedure Write (Stream : not null access Root_Stream_Type'Class; Item : Reference_Type); for Reference_Type'Write use Write; procedure Read (Stream : not null access Root_Stream_Type'Class; Item : out Reference_Type); for Reference_Type'Read use Read; -- Three operations are used to optimize in the expansion of "for ... of" -- loops: the Next(Cursor) procedure in the visible part, and the following -- Pseudo_Reference and Get_Element_Access functions. See Exp_Ch5 for -- details. function Pseudo_Reference (Container : aliased Vector'Class) return Reference_Control_Type; pragma Inline (Pseudo_Reference); -- Creates an object of type Reference_Control_Type pointing to the -- container, and increments the Lock. Finalization of this object will -- decrement the Lock. function Get_Element_Access (Position : Cursor) return not null Element_Access; -- Returns a pointer to the element designated by Position. No_Element : constant Cursor := Cursor'(null, Index_Type'First); Empty_Vector : constant Vector := (Controlled with others => <>); type Iterator is new Limited_Controlled and Vector_Iterator_Interfaces.Reversible_Iterator with record Container : Vector_Access; Index : Index_Type'Base; end record with Disable_Controlled => not T_Check; overriding procedure Finalize (Object : in out Iterator); overriding function First (Object : Iterator) return Cursor; overriding function Last (Object : Iterator) return Cursor; overriding function Next (Object : Iterator; Position : Cursor) return Cursor; overriding function Previous (Object : Iterator; Position : Cursor) return Cursor; end Ada.Containers.Indefinite_Vectors;
31.82549
79
0.637114
ad8ae2e801b6f9002efad1f7b5d9823eac3037f8
1,171
ads
Ada
regtests/keystore-passwords-tests.ads
thierr26/ada-keystore
25099a9df3ce9b48a401148eb1b84442011759a0
[ "Apache-2.0" ]
null
null
null
regtests/keystore-passwords-tests.ads
thierr26/ada-keystore
25099a9df3ce9b48a401148eb1b84442011759a0
[ "Apache-2.0" ]
null
null
null
regtests/keystore-passwords-tests.ads
thierr26/ada-keystore
25099a9df3ce9b48a401148eb1b84442011759a0
[ "Apache-2.0" ]
null
null
null
----------------------------------------------------------------------- -- keystore-passwords-tests -- Tests for Keystore.Passwords -- Copyright (C) 2019 Stephane Carrez -- Written by Stephane Carrez ([email protected]) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Util.Tests; package Keystore.Passwords.Tests is procedure Add_Tests (Suite : in Util.Tests.Access_Test_Suite); type Test is new Util.Tests.Test with null record; -- Test the using the Passwords.Files procedure Test_File_Password (T : in out Test); end Keystore.Passwords.Tests;
39.033333
76
0.650726
c794b5936828b44b88de2315b9ad1f3ec3d1bd46
14,117
adb
Ada
bb-runtimes/runtimes/ravenscar-sfp-stm32f3x4/gnarl/s-bbthre.adb
JCGobbi/Nucleo-STM32F334R8
2a0b1b4b2664c92773703ac5e95dcb71979d051c
[ "BSD-3-Clause" ]
null
null
null
bb-runtimes/runtimes/ravenscar-sfp-stm32f3x4/gnarl/s-bbthre.adb
JCGobbi/Nucleo-STM32F334R8
2a0b1b4b2664c92773703ac5e95dcb71979d051c
[ "BSD-3-Clause" ]
null
null
null
bb-runtimes/runtimes/ravenscar-sfp-stm32f3x4/gnarl/s-bbthre.adb
JCGobbi/Nucleo-STM32F334R8
2a0b1b4b2664c92773703ac5e95dcb71979d051c
[ "BSD-3-Clause" ]
null
null
null
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS -- -- -- -- S Y S T E M . B B . T H R E A D S -- -- -- -- B o d y -- -- -- -- Copyright (C) 1999-2002 Universidad Politecnica de Madrid -- -- Copyright (C) 2003-2005 The European Space Agency -- -- Copyright (C) 2003-2021, AdaCore -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNARL is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- -- -- -- -- -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNARL was developed by the GNARL team at Florida State University. -- -- Extensive contributions were provided by Ada Core Technologies, Inc. -- -- -- -- The port of GNARL to bare board targets was initially developed by the -- -- Real-Time Systems Group at the Technical University of Madrid. -- -- -- ------------------------------------------------------------------------------ pragma Restrictions (No_Elaboration_Code); with System.Parameters; with System.BB.Interrupts; with System.BB.Protection; with System.BB.Threads.Queues; package body System.BB.Threads is use System.Multiprocessors; use System.BB.CPU_Primitives; use System.BB.Board_Support.Multiprocessors; use System.BB.Time; use Board_Support; use type System.Storage_Elements.Storage_Offset; procedure Initialize_Thread (Id : Thread_Id; Code : System.Address; Arg : System.Address; Priority : Integer; This_CPU : System.Multiprocessors.CPU_Range; Stack_Top : System.Address; Stack_Bottom : System.Address); -- Intialize the thread's kernel data structure and its context ----------------------- -- Stack information -- ----------------------- -- Boundaries of the stack for the environment task, defined by the linker -- script file. Top_Of_Environment_Stack : constant System.Address; pragma Import (Asm, Top_Of_Environment_Stack, "__stack_end"); -- Top of the stack to be used by the environment task Bottom_Of_Environment_Stack : constant System.Address; pragma Import (Asm, Bottom_Of_Environment_Stack, "__stack_start"); -- Bottom of the stack to be used by the environment task ------------------ -- Get_Affinity -- ------------------ function Get_Affinity (Thread : Thread_Id) return CPU_Range is begin return Thread.Base_CPU; end Get_Affinity; ------------- -- Get_CPU -- ------------- function Get_CPU (Thread : Thread_Id) return CPU is begin if Thread.Base_CPU = Not_A_Specific_CPU then -- Return the implementation specific default CPU return CPU'First; else return CPU (Thread.Base_CPU); end if; end Get_CPU; -------------- -- Get_ATCB -- -------------- function Get_ATCB return System.Address is begin -- This is not a light operation as there is a function call return Queues.Running_Thread.ATCB; end Get_ATCB; ------------------ -- Get_Priority -- ------------------ function Get_Priority (Id : Thread_Id) return Integer is begin -- This function does not need to be protected by Enter_Kernel and -- Leave_Kernel, because the Active_Priority value is only updated by -- Set_Priority (atomically). Moreover, Active_Priority is marked as -- Volatile. return Id.Active_Priority; end Get_Priority; ----------------------- -- Initialize_Thread -- ----------------------- procedure Initialize_Thread (Id : Thread_Id; Code : System.Address; Arg : System.Address; Priority : Integer; This_CPU : System.Multiprocessors.CPU_Range; Stack_Top : System.Address; Stack_Bottom : System.Address) is begin -- Initialize task kernel data structure Id.Base_CPU := This_CPU; -- The active priority is initially equal to the base priority Id.Base_Priority := Priority; Id.Active_Priority := Priority; -- Insert in the global list. Id.Global_List := Queues.Global_List; Queues.Global_List := Id; -- Insert task inside the ready list (as last within its priority) Queues.Insert (Id); -- Store stack information Id.Top_Of_Stack := Stack_Top; Id.Bottom_Of_Stack := Stack_Bottom; -- The initial state is Runnable Id.State := Runnable; -- Not currently in an interrupt handler Id.In_Interrupt := False; -- No wakeup has been yet signaled Id.Wakeup_Signaled := False; -- Initialize alarm status Id.Alarm_Time := System.BB.Time.Time'Last; Id.Next_Alarm := Null_Thread_Id; -- Reset execution time Id.Execution_Time := System.BB.Time.Initial_Composite_Execution_Time; -- Initialize the task's register context Initialize_Context (Buffer => Id.Context'Access, Program_Counter => Code, Argument => Arg, Stack_Pointer => (if System.Parameters.Stack_Grows_Down then Id.Top_Of_Stack else Id.Bottom_Of_Stack)); end Initialize_Thread; ---------------- -- Initialize -- ---------------- procedure Initialize (Environment_Thread : Thread_Id; Main_Priority : System.Any_Priority) is Main_CPU : constant System.Multiprocessors.CPU := Current_CPU; begin -- Perform some basic hardware initialization (clock, timer, and -- interrupt handlers). -- First initialize interrupt stacks Interrupts.Initialize_Interrupts; -- Then the CPU (which set interrupt stack pointer) Initialize_CPU; -- Then the devices Board_Support.Initialize_Board; Time.Initialize_Timers; -- Initialize internal queues and the environment task Protection.Enter_Kernel; -- The environment thread executes the main procedure of the program Initialize_Thread (Environment_Thread, Null_Address, Null_Address, Main_Priority, Main_CPU, Top_Of_Environment_Stack'Address, Bottom_Of_Environment_Stack'Address); Queues.Running_Thread_Table (Main_CPU) := Environment_Thread; -- The tasking executive is initialized Initialized := True; Protection.Leave_Kernel; end Initialize; ---------------------- -- Initialize_Slave -- ---------------------- procedure Initialize_Slave (Idle_Thread : Thread_Id; Idle_Priority : Integer; Stack_Address : System.Address; Stack_Size : System.Storage_Elements.Storage_Offset) is CPU_Id : constant System.Multiprocessors.CPU := Current_CPU; begin Initialize_Thread (Idle_Thread, Null_Address, Null_Address, Idle_Priority, CPU_Id, Stack_Address + Stack_Size, Stack_Address); Queues.Running_Thread_Table (CPU_Id) := Idle_Thread; end Initialize_Slave; -------------- -- Set_ATCB -- -------------- procedure Set_ATCB (Id : Thread_Id; ATCB : System.Address) is begin -- Set_ATCB is only called in the initialization of the task Id.ATCB := ATCB; end Set_ATCB; ------------------ -- Set_Priority -- ------------------ procedure Set_Priority (Priority : Integer) is begin Protection.Enter_Kernel; -- The Ravenscar profile does not allow dynamic priority changes. Tasks -- change their priority only when they inherit the ceiling priority of -- a PO (Ceiling Locking policy). Hence, the task must be running when -- changing the priority. It is not possible to change the priority of -- another thread within the Ravenscar profile, so that is why -- Running_Thread is used. -- Priority changes are only possible as a result of inheriting the -- ceiling priority of a protected object. Hence, it can never be set -- a priority which is lower than the base priority of the thread. pragma Assert (Queues.Running_Thread /= Null_Thread_Id and then Priority >= Queues.Running_Thread.Base_Priority); Queues.Change_Priority (Queues.Running_Thread, Priority); Protection.Leave_Kernel; end Set_Priority; ----------- -- Sleep -- ----------- procedure Sleep is Self_Id : constant Thread_Id := Queues.Running_Thread; begin Protection.Enter_Kernel; -- It can only suspend if it is executing pragma Assert (Self_Id /= Null_Thread_Id and then Self_Id.State = Runnable); if Self_Id.Wakeup_Signaled then -- Another thread has already executed a Wakeup on this thread so -- that we just consume the token and continue execution. It means -- that just before this call to Sleep the task has been preempted -- by the task that is awaking it. Hence the Sleep/Wakeup calls do -- not happen in the expected order, and we use the Wakeup_Signaled -- to flag this event so it is not lost. -- The situation is the following: -- 1) a task A is going to wait in an entry for a barrier -- 2) task A releases the lock associated to the protected object -- 3) task A calls Sleep to suspend itself -- 4) a task B opens the barrier and awakes task A (calls Wakeup) -- This is the expected sequence of events, but 4) may happen -- before 3) because task A decreases its priority in step 2) as a -- consequence of releasing the lock (Ceiling_Locking). Hence, task -- A may be preempted by task B in the window between releasing the -- protected object and actually suspending itself, and the Wakeup -- call by task B in 4) can happen before the Sleep call in 3). Self_Id.Wakeup_Signaled := False; else -- Update status Self_Id.State := Suspended; -- Extract from the list of ready threads Queues.Extract (Self_Id); -- The currently executing thread is now blocked, and it will leave -- the CPU when executing the Leave_Kernel procedure. end if; Protection.Leave_Kernel; -- Now the thread has been awaken again and it is executing end Sleep; ------------------- -- Thread_Create -- ------------------- procedure Thread_Create (Id : Thread_Id; Code : System.Address; Arg : System.Address; Priority : Integer; Base_CPU : System.Multiprocessors.CPU_Range; Stack_Address : System.Address; Stack_Size : System.Storage_Elements.Storage_Offset) is begin Protection.Enter_Kernel; Initialize_Thread (Id, Code, Arg, Priority, Base_CPU, ((Stack_Address + Stack_Size) / Standard'Maximum_Alignment) * Standard'Maximum_Alignment, Stack_Address); Protection.Leave_Kernel; end Thread_Create; ----------------- -- Thread_Self -- ----------------- function Thread_Self return Thread_Id is begin -- Return the thread that is currently executing return Queues.Running_Thread; end Thread_Self; ------------ -- Wakeup -- ------------ procedure Wakeup (Id : Thread_Id) is begin Protection.Enter_Kernel; if Id.State = Suspended then -- The thread is already waiting so that we awake it -- Update status Id.State := Runnable; -- Insert the thread at the tail of its active priority so that the -- thread will resume execution. Queues.Insert (Id); else -- The thread is not yet waiting so that we just signal that the -- Wakeup command has been executed. We are waking up a task that -- is going to wait in an entry for a barrier, but before calling -- Sleep it has been preempted by the task awaking it. Id.Wakeup_Signaled := True; end if; pragma Assert (Id.State = Runnable); Protection.Leave_Kernel; end Wakeup; end System.BB.Threads;
32.304348
78
0.560388
ad043232cf72a923b20cbadc7a740a1085feb330
2,382
adb
Ada
src/tom/library/sl/ada/abstractstrategybasicpackage.adb
rewriting/tom
2918e95c78006f08a2a0919ef440413fa5c2342a
[ "BSD-3-Clause" ]
36
2016-02-19T12:09:49.000Z
2022-02-03T13:13:21.000Z
src/tom/library/sl/ada/abstractstrategybasicpackage.adb
rewriting/tom
2918e95c78006f08a2a0919ef440413fa5c2342a
[ "BSD-3-Clause" ]
null
null
null
src/tom/library/sl/ada/abstractstrategybasicpackage.adb
rewriting/tom
2918e95c78006f08a2a0919ef440413fa5c2342a
[ "BSD-3-Clause" ]
6
2017-11-30T17:07:10.000Z
2022-03-12T14:46:21.000Z
with VisitFailurePackage, EnvironmentPackage; use VisitFailurePackage, EnvironmentPackage; with Ada.Text_IO; use Ada.Text_IO; package body AbstractStrategyBasicPackage is ---------------------------------------------------------------------------- -- Strategy implementation ---------------------------------------------------------------------------- overriding function visit(str: access AbstractStrategyBasic; i: access Introspector'Class) return Integer is obj: ObjectPtr := null; begin obj := visitLight(StrategyPtr(str) , getSubject(str.env.all), i); EnvironmentPackage.setSubject( str.env.all, obj); return EnvironmentPackage.SUCCESS; exception when VisitFailure => return EnvironmentPackage.FAILURE; end; ---------------------------------------------------------------------------- -- Visitable implementation ---------------------------------------------------------------------------- overriding function getChildCount(v : access AbstractStrategyBasic) return Integer is begin return 1; end; overriding function setChildren(v: access AbstractStrategyBasic ; children : ObjectPtrArrayPtr) return VisitablePtr is begin v.any := StrategyPtr(children(children'First)); return VisitablePtr(v); end; overriding function getChildren(v: access AbstractStrategyBasic) return ObjectPtrArrayPtr is begin return new ObjectPtrArray'( 0 => ObjectPtr(v.any) ); end; overriding function getChildAt(v: access AbstractStrategyBasic; i : Integer) return VisitablePtr is IndexOutOfBoundsException : exception; begin if i = 0 then return VisitablePtr(v.any); else raise IndexOutOfBoundsException; end if; end; overriding function setChildAt(v: access AbstractStrategyBasic; i: in Integer; child: in VisitablePtr) return VisitablePtr is IndexOutOfBoundsException : exception; begin if i = 0 then v.any := StrategyPtr(child); else raise IndexOutOfBoundsException; end if; return VisitablePtr(v); end; ---------------------------------------------------------------------------- procedure makeAbstractStrategyBasic(asb : in out AbstractStrategyBasic'Class; s: StrategyPtr) is begin if s = null then asb.any := null; else asb.any := s; end if; end; ---------------------------------------------------------------------------- end AbstractStrategyBasicPackage;
27.697674
115
0.609152
1e4ca2ad0761edcbaa4a5ec900b01b0944a106e8
9,477
ads
Ada
msp430x2/msp430g2553/svd/msp430_svd-adc10.ads
ekoeppen/MSP430_Generic_Ada_Drivers
12b8238ea22dbb0c0c6c63ca46bfa7e2cb80334a
[ "MIT" ]
null
null
null
msp430x2/msp430g2553/svd/msp430_svd-adc10.ads
ekoeppen/MSP430_Generic_Ada_Drivers
12b8238ea22dbb0c0c6c63ca46bfa7e2cb80334a
[ "MIT" ]
null
null
null
msp430x2/msp430g2553/svd/msp430_svd-adc10.ads
ekoeppen/MSP430_Generic_Ada_Drivers
12b8238ea22dbb0c0c6c63ca46bfa7e2cb80334a
[ "MIT" ]
null
null
null
-- This spec has been automatically generated from msp430g2553.svd pragma Restrictions (No_Elaboration_Code); pragma Ada_2012; pragma Style_Checks (Off); with System; -- ADC10 package MSP430_SVD.ADC10 is pragma Preelaborate; --------------- -- Registers -- --------------- -- ADC10 Data Transfer Control 0 type ADC10DTC0_Register is record -- This bit should normally be reset ADC10FETCH : MSP430_SVD.Bit := 16#0#; -- ADC10 block one ADC10B1 : MSP430_SVD.Bit := 16#0#; -- ADC10 continuous transfer ADC10CT : MSP430_SVD.Bit := 16#0#; -- ADC10 two-block mode ADC10TB : MSP430_SVD.Bit := 16#0#; -- unspecified Reserved_4_7 : MSP430_SVD.UInt4 := 16#0#; end record with Volatile_Full_Access, Object_Size => 8, Bit_Order => System.Low_Order_First; for ADC10DTC0_Register use record ADC10FETCH at 0 range 0 .. 0; ADC10B1 at 0 range 1 .. 1; ADC10CT at 0 range 2 .. 2; ADC10TB at 0 range 3 .. 3; Reserved_4_7 at 0 range 4 .. 7; end record; -- ADC10 Sample Hold Select Bit: 0 type ADC10CTL0_ADC10SHT_Field is (-- 4 x ADC10CLKs Adc10Sht_0, -- 8 x ADC10CLKs Adc10Sht_1, -- 16 x ADC10CLKs Adc10Sht_2, -- 64 x ADC10CLKs Adc10Sht_3) with Size => 2; for ADC10CTL0_ADC10SHT_Field use (Adc10Sht_0 => 0, Adc10Sht_1 => 1, Adc10Sht_2 => 2, Adc10Sht_3 => 3); -- ADC10 Reference Select Bit: 0 type ADC10CTL0_SREF_Field is (-- VR+ = AVCC and VR- = AVSS Sref_0, -- VR+ = VREF+ and VR- = AVSS Sref_1, -- VR+ = VEREF+ and VR- = AVSS Sref_2, -- VR+ = VEREF+ and VR- = AVSS Sref_3, -- VR+ = AVCC and VR- = VREF-/VEREF- Sref_4, -- VR+ = VREF+ and VR- = VREF-/VEREF- Sref_5, -- VR+ = VEREF+ and VR- = VREF-/VEREF- Sref_6, -- VR+ = VEREF+ and VR- = VREF-/VEREF- Sref_7) with Size => 3; for ADC10CTL0_SREF_Field use (Sref_0 => 0, Sref_1 => 1, Sref_2 => 2, Sref_3 => 3, Sref_4 => 4, Sref_5 => 5, Sref_6 => 6, Sref_7 => 7); -- ADC10 Control 0 type ADC10CTL0_Register is record -- ADC10 Start Conversion ADC10SC : MSP430_SVD.Bit := 16#0#; -- ADC10 Enable Conversion ENC : MSP430_SVD.Bit := 16#0#; -- ADC10 Interrupt Flag ADC10IFG : MSP430_SVD.Bit := 16#0#; -- ADC10 Interrupt Enalbe ADC10IE : MSP430_SVD.Bit := 16#0#; -- ADC10 On/Enable ADC10ON : MSP430_SVD.Bit := 16#0#; -- ADC10 Reference on REFON : MSP430_SVD.Bit := 16#0#; -- ADC10 Ref 0:1.5V / 1:2.5V REF2_5V : MSP430_SVD.Bit := 16#0#; -- ADC10 Multiple SampleConversion MSC : MSP430_SVD.Bit := 16#0#; -- ADC10 Reference Burst Mode REFBURST : MSP430_SVD.Bit := 16#0#; -- ADC10 Enalbe output of Ref. REFOUT : MSP430_SVD.Bit := 16#0#; -- ADC10 Sampling Rate 0:200ksps / 1:50ksps ADC10SR : MSP430_SVD.Bit := 16#0#; -- ADC10 Sample Hold Select Bit: 0 ADC10SHT : ADC10CTL0_ADC10SHT_Field := MSP430_SVD.ADC10.Adc10Sht_0; -- ADC10 Reference Select Bit: 0 SREF : ADC10CTL0_SREF_Field := MSP430_SVD.ADC10.Sref_0; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for ADC10CTL0_Register use record ADC10SC at 0 range 0 .. 0; ENC at 0 range 1 .. 1; ADC10IFG at 0 range 2 .. 2; ADC10IE at 0 range 3 .. 3; ADC10ON at 0 range 4 .. 4; REFON at 0 range 5 .. 5; REF2_5V at 0 range 6 .. 6; MSC at 0 range 7 .. 7; REFBURST at 0 range 8 .. 8; REFOUT at 0 range 9 .. 9; ADC10SR at 0 range 10 .. 10; ADC10SHT at 0 range 11 .. 12; SREF at 0 range 13 .. 15; end record; -- ADC10 Conversion Sequence Select 0 type ADC10CTL1_CONSEQ_Field is (-- Single channel single conversion Conseq_0, -- Sequence of channels Conseq_1, -- Repeat single channel Conseq_2, -- Repeat sequence of channels Conseq_3) with Size => 2; for ADC10CTL1_CONSEQ_Field use (Conseq_0 => 0, Conseq_1 => 1, Conseq_2 => 2, Conseq_3 => 3); -- ADC10 Clock Source Select Bit: 0 type ADC10CTL1_ADC10SSEL_Field is (-- ADC10OSC Adc10Ssel_0, -- ACLK Adc10Ssel_1, -- MCLK Adc10Ssel_2, -- SMCLK Adc10Ssel_3) with Size => 2; for ADC10CTL1_ADC10SSEL_Field use (Adc10Ssel_0 => 0, Adc10Ssel_1 => 1, Adc10Ssel_2 => 2, Adc10Ssel_3 => 3); -- ADC10 Clock Divider Select Bit: 0 type ADC10CTL1_ADC10DIV_Field is (-- ADC10 Clock Divider Select 0 Adc10Div_0, -- ADC10 Clock Divider Select 1 Adc10Div_1, -- ADC10 Clock Divider Select 2 Adc10Div_2, -- ADC10 Clock Divider Select 3 Adc10Div_3, -- ADC10 Clock Divider Select 4 Adc10Div_4, -- ADC10 Clock Divider Select 5 Adc10Div_5, -- ADC10 Clock Divider Select 6 Adc10Div_6, -- ADC10 Clock Divider Select 7 Adc10Div_7) with Size => 3; for ADC10CTL1_ADC10DIV_Field use (Adc10Div_0 => 0, Adc10Div_1 => 1, Adc10Div_2 => 2, Adc10Div_3 => 3, Adc10Div_4 => 4, Adc10Div_5 => 5, Adc10Div_6 => 6, Adc10Div_7 => 7); -- ADC10 Sample/Hold Source Bit: 0 type ADC10CTL1_SHS_Field is (-- ADC10SC Shs_0, -- TA3 OUT1 Shs_1, -- TA3 OUT0 Shs_2, -- TA3 OUT2 Shs_3) with Size => 2; for ADC10CTL1_SHS_Field use (Shs_0 => 0, Shs_1 => 1, Shs_2 => 2, Shs_3 => 3); -- ADC10 Input Channel Select Bit: 0 type ADC10CTL1_INCH_Field is (-- Selects Channel 0 Inch_0, -- Selects Channel 1 Inch_1, -- Selects Channel 2 Inch_2, -- Selects Channel 3 Inch_3, -- Selects Channel 4 Inch_4, -- Selects Channel 5 Inch_5, -- Selects Channel 6 Inch_6, -- Selects Channel 7 Inch_7, -- Selects Channel 8 Inch_8, -- Selects Channel 9 Inch_9, -- Selects Channel 10 Inch_10, -- Selects Channel 11 Inch_11, -- Selects Channel 12 Inch_12, -- Selects Channel 13 Inch_13, -- Selects Channel 14 Inch_14, -- Selects Channel 15 Inch_15) with Size => 4; for ADC10CTL1_INCH_Field use (Inch_0 => 0, Inch_1 => 1, Inch_2 => 2, Inch_3 => 3, Inch_4 => 4, Inch_5 => 5, Inch_6 => 6, Inch_7 => 7, Inch_8 => 8, Inch_9 => 9, Inch_10 => 10, Inch_11 => 11, Inch_12 => 12, Inch_13 => 13, Inch_14 => 14, Inch_15 => 15); -- ADC10 Control 1 type ADC10CTL1_Register is record -- ADC10 BUSY ADC10BUSY : MSP430_SVD.Bit := 16#0#; -- ADC10 Conversion Sequence Select 0 CONSEQ : ADC10CTL1_CONSEQ_Field := MSP430_SVD.ADC10.Conseq_0; -- ADC10 Clock Source Select Bit: 0 ADC10SSEL : ADC10CTL1_ADC10SSEL_Field := MSP430_SVD.ADC10.Adc10Ssel_0; -- ADC10 Clock Divider Select Bit: 0 ADC10DIV : ADC10CTL1_ADC10DIV_Field := MSP430_SVD.ADC10.Adc10Div_0; -- ADC10 Invert Sample Hold Signal ISSH : MSP430_SVD.Bit := 16#0#; -- ADC10 Data Format 0:binary 1:2's complement ADC10DF : MSP430_SVD.Bit := 16#0#; -- ADC10 Sample/Hold Source Bit: 0 SHS : ADC10CTL1_SHS_Field := MSP430_SVD.ADC10.Shs_0; -- ADC10 Input Channel Select Bit: 0 INCH : ADC10CTL1_INCH_Field := MSP430_SVD.ADC10.Inch_0; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for ADC10CTL1_Register use record ADC10BUSY at 0 range 0 .. 0; CONSEQ at 0 range 1 .. 2; ADC10SSEL at 0 range 3 .. 4; ADC10DIV at 0 range 5 .. 7; ISSH at 0 range 8 .. 8; ADC10DF at 0 range 9 .. 9; SHS at 0 range 10 .. 11; INCH at 0 range 12 .. 15; end record; ----------------- -- Peripherals -- ----------------- -- ADC10 type ADC10_Peripheral is record -- ADC10 Data Transfer Control 0 ADC10DTC0 : aliased ADC10DTC0_Register; -- ADC10 Data Transfer Control 1 ADC10DTC1 : aliased MSP430_SVD.Byte; -- ADC10 Analog Enable 0 ADC10AE0 : aliased MSP430_SVD.Byte; -- ADC10 Control 0 ADC10CTL0 : aliased ADC10CTL0_Register; -- ADC10 Control 1 ADC10CTL1 : aliased ADC10CTL1_Register; -- ADC10 Memory ADC10MEM : aliased MSP430_SVD.UInt16; -- ADC10 Data Transfer Start Address ADC10SA : aliased MSP430_SVD.UInt16; end record with Volatile; for ADC10_Peripheral use record ADC10DTC0 at 16#0# range 0 .. 7; ADC10DTC1 at 16#1# range 0 .. 7; ADC10AE0 at 16#2# range 0 .. 7; ADC10CTL0 at 16#168# range 0 .. 15; ADC10CTL1 at 16#16A# range 0 .. 15; ADC10MEM at 16#16C# range 0 .. 15; ADC10SA at 16#174# range 0 .. 15; end record; -- ADC10 ADC10_Periph : aliased ADC10_Peripheral with Import, Address => ADC10_Base; end MSP430_SVD.ADC10;
27.955752
76
0.567901
8b8c8f8d79f5a353094cd7323890a762c6d96283
3,359
ads
Ada
.emacs.d/elpa/wisi-3.1.3/wisitoken-productions.ads
caqg/linux-home
eed631aae6f5e59e4f46e14f1dff443abca5fa28
[ "Linux-OpenIB" ]
null
null
null
.emacs.d/elpa/wisi-3.1.3/wisitoken-productions.ads
caqg/linux-home
eed631aae6f5e59e4f46e14f1dff443abca5fa28
[ "Linux-OpenIB" ]
null
null
null
.emacs.d/elpa/wisi-3.1.3/wisitoken-productions.ads
caqg/linux-home
eed631aae6f5e59e4f46e14f1dff443abca5fa28
[ "Linux-OpenIB" ]
null
null
null
-- Abstract : -- -- Type and operations for building grammar productions. -- -- Copyright (C) 2018 - 2020 Free Software Foundation, Inc. -- -- This file is part of the WisiToken package. -- -- The WisiToken package is free software; you can redistribute it -- and/or modify it under terms of the GNU General Public License as -- published by the Free Software Foundation; either version 3, or -- (at your option) any later version. This library is distributed in -- the hope that it will be useful, but WITHOUT ANY WARRANTY; without -- even the implied warranty of MERCHAN- TABILITY or FITNESS FOR A -- PARTICULAR PURPOSE. -- -- As a special exception under Section 7 of GPL version 3, you are granted -- additional permissions described in the GCC Runtime Library Exception, -- version 3.1, as published by the Free Software Foundation. pragma License (Modified_GPL); with SAL.Gen_Unbounded_Definite_Vectors; with WisiToken.Semantic_Checks; with WisiToken.Syntax_Trees; package WisiToken.Productions is use all type Ada.Containers.Count_Type; package Recursion_Arrays is new SAL.Gen_Unbounded_Definite_Vectors (Positive, Recursion_Class, Default_Element => None); function Image (Item : in Recursion_Arrays.Vector) return String; -- For parse_table type Right_Hand_Side is record Tokens : Token_ID_Arrays.Vector; Recursion : Recursion_Arrays.Vector; -- Recursion for each token. There may be more than one recursion cycle for any token, -- but we don't track that. Action : WisiToken.Syntax_Trees.Semantic_Action; Check : WisiToken.Semantic_Checks.Semantic_Check; end record with Dynamic_Predicate => (Tokens.Length = 0 or Tokens.First_Index = 1) and (Recursion.Length = 0 or (Recursion.First_Index = Tokens.First_Index and Recursion.Last_Index = Tokens.Last_Index)); package RHS_Arrays is new SAL.Gen_Unbounded_Definite_Vectors (Natural, Right_Hand_Side, Default_Element => (others => <>)); type Instance is record LHS : Token_ID := Invalid_Token_ID; RHSs : RHS_Arrays.Vector; end record; package Prod_Arrays is new SAL.Gen_Unbounded_Definite_Vectors (Token_ID, Instance, Default_Element => (others => <>)); function Constant_Ref_RHS (Grammar : in Prod_Arrays.Vector; ID : in Production_ID) return RHS_Arrays.Constant_Reference_Type; function Image (LHS : in Token_ID; RHS_Index : in Natural; RHS : in Token_ID_Arrays.Vector; Descriptor : in WisiToken.Descriptor) return String; -- For comments in generated code, diagnostic messages. procedure Put (Grammar : Prod_Arrays.Vector; Descriptor : in WisiToken.Descriptor); -- Put Image of each production to Ada.Text_IO.Current_Output, for parse_table. package Line_Number_Arrays is new SAL.Gen_Unbounded_Definite_Vectors (Natural, Line_Number_Type, Default_Element => Invalid_Line_Number); type Prod_Source_Line_Map is record Line : Line_Number_Type := Invalid_Line_Number; RHS_Map : Line_Number_Arrays.Vector; end record; package Source_Line_Maps is new SAL.Gen_Unbounded_Definite_Vectors (Token_ID, Prod_Source_Line_Map, Default_Element => (others => <>)); -- For line numbers of productions in source files. end WisiToken.Productions;
37.741573
97
0.731468