summaryrefslogtreecommitdiff
path: root/gcc/ada/frontend.adb
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2008-03-26 07:36:02 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2008-03-26 07:36:02 +0000
commit2253aba6069113bf4d0356a00a1eb828be807d23 (patch)
tree70dbf93da9aba2214e551ac66d758a30077cf351 /gcc/ada/frontend.adb
parent1722baf3c2afd28012e3b87df33d12b4865d8129 (diff)
downloadgcc-2253aba6069113bf4d0356a00a1eb828be807d23.tar.gz
2008-03-26 Robert Dewar <dewar@adacore.com>
* ali.ads, ali.adb (Optimize_Alignment_Setting): New field in ALI record * bcheck.adb (Check_Consistent_Optimize_Alignment): New procedure * debug.adb: Add debug flags d.r and d.v Add debug flag .T (Optimize_Alignment (Time)) Add debug flag .S (Optimize_Alignment (Space)) * freeze.adb (Freeze_Record_Type): Set OK_To_Reorder_Components depending on setting of relevant debug flags. Replace use of Warnings_Off by Has_Warnings_Off (Freeze_Entity): In circuit for warning on suspicious convention actuals, do not give warning if subprogram has same entity as formal type, or if subprogram does not come from source. (Freeze_Entity): Don't reset Is_Packed for fully rep speced record if Optimize_Alignment set to Space. * frontend.adb: Add call to Sem_Warn.Initialize Add call to Sem_Warn.Output_Unused_Warnings_Off_Warnings Reset Optimize_Alignment mode from debug switches .S and .T * layout.adb (Layout_Composite_Object): Rewritten for Optimize_Aligment pragma. * lib-writ.ads, lib-writ.adb: New Ox parameter for Optimize_Alignment mode. * opt.ads, opt.adb: (Optimize_Alignment): New global switch * par-prag.adb (N_Pragma): Chars field removed, use Chars (Pragma_Identifier (.. instead, adjustments throughout to accomodate this change. Add entry for pragma Optimize_Alignment * sem_prag.adb (N_Pragma): Chars field removed, use Chars (Pragma_Identifier (.. instead, adjustments throughout to accomodate this change. (Process_Compile_Time_Warning_Or_Error): Use !! for generated msg (Favor_Top_Level): Use new function Is_Access_Subprogram_Type Add implementation of pragma Optimize_Alignment git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@133549 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/frontend.adb')
-rw-r--r--gcc/ada/frontend.adb16
1 files changed, 13 insertions, 3 deletions
diff --git a/gcc/ada/frontend.adb b/gcc/ada/frontend.adb
index dc1d469f0c2..6d01843fb22 100644
--- a/gcc/ada/frontend.adb
+++ b/gcc/ada/frontend.adb
@@ -6,7 +6,7 @@
-- --
-- B o d y --
-- --
--- Copyright (C) 1992-2007, Free Software Foundation, Inc. --
+-- Copyright (C) 1992-2008, 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- --
@@ -59,8 +59,8 @@ with Tbuild; use Tbuild;
with Types; use Types;
procedure Frontend is
- Config_Pragmas : List_Id;
- -- Gather configuration pragmas
+ Config_Pragmas : List_Id;
+ -- Gather configuration pragmas
begin
-- Carry out package initializations. These are initializations which
@@ -78,6 +78,7 @@ begin
Sem_Ch8.Initialize;
Fname.UF.Initialize;
Checks.Initialize;
+ Sem_Warn.Initialize;
-- Create package Standard
@@ -207,6 +208,14 @@ begin
Fmap.Initialize (Mapping_File_Name.all);
end if;
+ -- Adjust Optimize_Alignment mode from debug switches if necessary
+
+ if Debug_Flag_Dot_SS then
+ Optimize_Alignment := 'S';
+ elsif Debug_Flag_Dot_TT then
+ Optimize_Alignment := 'T';
+ end if;
+
-- We have now processed the command line switches, and the gnat.adc
-- file, so this is the point at which we want to capture the values
-- of the configuration switches (see Opt for further details).
@@ -326,6 +335,7 @@ begin
Sem_Warn.Output_Non_Modifed_In_Out_Warnings;
Sem_Warn.Output_Unreferenced_Messages;
Sem_Warn.Check_Unused_Withs;
+ Sem_Warn.Output_Unused_Warnings_Off_Warnings;
end if;
end if;