|
|
DataMuseum.dkPresents historical artifacts from the history of: Rational R1000/400 Tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Rational R1000/400 Tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: B T
Length: 4802 (0x12c2)
Types: TextFile
Names: »B«
└─⟦180fe333a⟧ Bits:30000405 8mm tape, Rational 1000, SW CATALOG, 10_20_0
└─⟦180fe333a⟧ Bits:30000537 8mm tape, Rational 1000, SW Catalog 10_20_0
└─⟦5cb1d1d7f⟧ »DATA«
└─⟦3b1ee7bd8⟧
└─⟦this⟧
with Log;
with Common;
with Profile;
with Calendar;
with Compilation;
with Report_Times;
with String_Utilities;
with System_Utilities;
procedure Batch_Benchmark
(Context : in String := ">> LIBRARY CONTAINING SOURCE <<";
Main_Unit : in String := ">> MAIN PROGRAM SPEC <<";
Response : in String := "<PROFILE>") is
--
Old_Response_Profile : Profile.Response_Profile := Profile.Get;
New_Response_Profile : Profile.Response_Profile := Profile.Value (Response);
--
Context_Name : constant String := String_Utilities.Upper_Case (Context);
Main_Unit_Name : constant String := String_Utilities.Upper_Case (Main_Unit);
Skin_Unit_Name : constant String := Main_Unit_Name & "_SKIN";
--
Starting_Wall_Clock_Time : Calendar.Time;
Ending_Wall_Clock_Time : Calendar.Time;
Starting_Cpu_Time : Duration;
Ending_Cpu_Time : Duration;
--
begin
--
Profile.Set (New_Response_Profile);
Log.Put_Line ("[Batch_Benchmark (Context => """ &
Context_Name & """, Main_Unit => """ &
Main_Unit_Name & """, Response => """ &
Profile.Image (New_Response_Profile) & """);]",
Profile.Auxiliary_Msg);
--
Log.Put_Line ("Demoting all units to source state");
Compilation.Demote (Unit => Context & ".??'C(ADA)",
Goal => Compilation.Source,
Limit => "<WORLDS>",
Effort_Only => False,
Response => Response);
Log.Put_Line ("Demoted units to source state", Profile.Positive_Msg);
--
Log.Put_Line ("Batch compiling " & Main_Unit_Name & " to coded state");
Starting_Wall_Clock_Time := Calendar.Clock;
Starting_Cpu_Time := System_Utilities.Cpu;
Compilation.Make (Unit => Context_Name & "." & Main_Unit_Name & "'SPEC",
Scope => Compilation.All_Parts,
Goal => Compilation.Coded,
Limit => "<WORLDS>",
Effort_Only => False,
Response => Response);
Ending_Cpu_Time := System_Utilities.Cpu;
Ending_Wall_Clock_Time := Calendar.Clock;
Log.Put_Line ("Batch compiled " & Main_Unit_Name & " to coded state",
Profile.Positive_Msg);
--
Report_Times ("BATCH COMPILATION TIMES FOR """ & Main_Unit_Name & """:",
Starting_Wall_Clock_Time,
Ending_Wall_Clock_Time,
Starting_Cpu_Time,
Ending_Cpu_Time);
--
Log.Put_Line ("Linking " & Main_Unit_Name);
--
-- First, promote the skin unit to coded, then put its body back
-- into the installed state.
--
Compilation.Make (Unit => Context_Name & "." & Skin_Unit_Name & "'SPEC",
Scope => Compilation.All_Parts,
Goal => Compilation.Coded,
Limit => "<WORLDS>",
Effort_Only => False,
Response => Response);
Compilation.Demote (Unit => Context_Name & "." & Skin_Unit_Name & "'BODY",
Goal => Compilation.Installed,
Limit => "<WORLDS>",
Effort_Only => False,
Response => Response);
--
-- Now calculate the time it takes to bring the skin unit's body
-- to the coded state. Since the skin unit contains a "Pragma Main",
-- it will be linked during this process. Since the skin unit is a very
-- small piece of code relative to the size of the unit(s) upon
-- which it depends, this effectively measures the link time for
-- the unit(s).
--
Common.Definition (Context_Name & "." & Skin_Unit_Name & "'BODY",
Visible => False);
Starting_Wall_Clock_Time := Calendar.Clock;
Starting_Cpu_Time := System_Utilities.Cpu;
Common.Promote;
Ending_Cpu_Time := System_Utilities.Cpu;
Ending_Wall_Clock_Time := Calendar.Clock;
--
Log.Put_Line ("Done linking " & Main_Unit_Name, Profile.Positive_Msg);
--
Report_Times ("LINK TIMES FOR """ & Main_Unit_Name & """:",
Starting_Wall_Clock_Time,
Ending_Wall_Clock_Time,
Starting_Cpu_Time,
Ending_Cpu_Time);
--
Log.Put_Line ("[end of Batch_Benchmark command - no error(s) detected]",
Profile.Auxiliary_Msg);
Profile.Set (Old_Response_Profile);
--
exception
when others =>
Log.Put_Line ("[end of Batch_Benchmark command - error(s) detected]",
Profile.Auxiliary_Msg);
Profile.Set (Old_Response_Profile);
--
end Batch_Benchmark;