From d1915cb82c1319af3267e9617fd81ecbeef01a2c Mon Sep 17 00:00:00 2001 From: Arnaud Charlet Date: Thu, 12 Nov 2015 12:59:18 +0100 Subject: [PATCH] [multiple changes] 2015-11-12 Arnaud Charlet * back_end.adb, opt.ads (Debugger_Level): Update comment. (Scan_Back_End_Switches): Set Debugger_Level. 2015-11-12 Bob Duff * fmap.adb, debug.ads, checks.adb, exp_ch11.adb: Minor edits. 2015-11-12 Doug Rupp * s-stchop-vxworks.adb (Stack_Limit): Export vice Import. 2015-11-12 Gary Dismukes * sem_dim.adb: Minor reformatting. From-SVN: r230246 --- gcc/ada/ChangeLog | 17 +++++++++++++++++ gcc/ada/back_end.adb | 18 ++++++++++++++++++ gcc/ada/checks.adb | 2 +- gcc/ada/debug.ads | 4 ++-- gcc/ada/exp_ch11.adb | 2 +- gcc/ada/fmap.adb | 2 +- gcc/ada/opt.ads | 1 + gcc/ada/s-stchop-vxworks.adb | 7 ++++--- gcc/ada/sem_dim.adb | 4 ++-- 9 files changed, 47 insertions(+), 10 deletions(-) diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 5290312447c..582a6460b6f 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,20 @@ +2015-11-12 Arnaud Charlet + + * back_end.adb, opt.ads (Debugger_Level): Update comment. + (Scan_Back_End_Switches): Set Debugger_Level. + +2015-11-12 Bob Duff + + * fmap.adb, debug.ads, checks.adb, exp_ch11.adb: Minor edits. + +2015-11-12 Doug Rupp + + * s-stchop-vxworks.adb (Stack_Limit): Export vice Import. + +2015-11-12 Gary Dismukes + + * sem_dim.adb: Minor reformatting. + 2015-11-12 Gary Dismukes * gnat1drv.adb, opt.ads: Minor reformatting. diff --git a/gcc/ada/back_end.adb b/gcc/ada/back_end.adb index 7768687b269..b5d566971ce 100644 --- a/gcc/ada/back_end.adb +++ b/gcc/ada/back_end.adb @@ -272,6 +272,24 @@ package body Back_End is elsif Switch_Chars (First .. Last) = "fdump-scos" then Opt.Generate_SCO := True; Opt.Generate_SCO_Instance_Table := True; + + elsif Switch_Chars (First) = 'g' then + Debugger_Level := 2; + + if First < Last then + case Switch_Chars (First + 1) is + when '0' => + Debugger_Level := 0; + when '1' => + Debugger_Level := 1; + when '2' => + Debugger_Level := 2; + when '3' => + Debugger_Level := 3; + when others => + null; + end case; + end if; end if; end if; end Scan_Back_End_Switches; diff --git a/gcc/ada/checks.adb b/gcc/ada/checks.adb index f992aa2097a..05ec983dee7 100644 --- a/gcc/ada/checks.adb +++ b/gcc/ada/checks.adb @@ -169,7 +169,7 @@ package body Checks is end record; -- The following table keeps track of saved checks. Rather than use an - -- extensible table. We just use a table of fixed size, and we discard + -- extensible table, we just use a table of fixed size, and we discard -- any saved checks that do not fit. That's very unlikely to happen and -- this is only an optimization in any case. diff --git a/gcc/ada/debug.ads b/gcc/ada/debug.ads index 9ebaa52cfb0..3ed93268188 100644 --- a/gcc/ada/debug.ads +++ b/gcc/ada/debug.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2009, Free Software Foundation, Inc. -- +-- 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- -- @@ -40,7 +40,7 @@ package Debug is -- Dynamic Debug Flags -- ------------------------- - -- Flags that can be used to active various specialized debugging output + -- Flags that can be used to activate various specialized debugging output -- information. The flags are preset to False, which corresponds to the -- given output being suppressed. The individual flags can be turned on -- using the undocumented switch dxxx where xxx is a string of letters for diff --git a/gcc/ada/exp_ch11.adb b/gcc/ada/exp_ch11.adb index 814dfdd80fd..c41a95f4973 100644 --- a/gcc/ada/exp_ch11.adb +++ b/gcc/ada/exp_ch11.adb @@ -1995,7 +1995,7 @@ package body Exp_Ch11 is -- Get_Local_Raise_Call_Entity -- --------------------------------- - -- Note: this is primary provided for use by the back end in generating + -- Note: this is primarily provided for use by the back end in generating -- calls to Local_Raise. But it would be too late in the back end to call -- RTE if this actually caused a load/analyze of the unit. So what we do -- is to ensure there is a dummy call to this function during front end diff --git a/gcc/ada/fmap.adb b/gcc/ada/fmap.adb index 77fa6c0d78d..e618d3c7fce 100644 --- a/gcc/ada/fmap.adb +++ b/gcc/ada/fmap.adb @@ -50,7 +50,7 @@ package body Fmap is Max_Buffer : constant := 1_500; Buffer : String (1 .. Max_Buffer); - -- Used to bufferize output when writing to a new mapping file + -- Used to buffer output when writing to a new mapping file Buffer_Last : Natural := 0; -- Index of last valid character in Buffer diff --git a/gcc/ada/opt.ads b/gcc/ada/opt.ads index 9041a88929b..cacc6a04a55 100644 --- a/gcc/ada/opt.ads +++ b/gcc/ada/opt.ads @@ -421,6 +421,7 @@ package Opt is subtype Debug_Level_Value is Nat range 0 .. 3; Debugger_Level : Debug_Level_Value := 0; + -- GNAT, GNATBIND -- The value given to the -g parameter. The default value for -g with -- no value is 2. If no -g is specified, defaults to 0. -- Note that the generated code should never depend on this variable, diff --git a/gcc/ada/s-stchop-vxworks.adb b/gcc/ada/s-stchop-vxworks.adb index 06ec151ef39..106d4e6ed57 100644 --- a/gcc/ada/s-stchop-vxworks.adb +++ b/gcc/ada/s-stchop-vxworks.adb @@ -60,9 +60,10 @@ package body System.Stack_Checking.Operations is -- VxWorks MILS includes the necessary routine in taskLib, so nothing -- special needs to be done there. - Stack_Limit : Address; - - pragma Import (C, Stack_Limit, "__gnat_stack_limit"); + Stack_Limit : Address := + Boolean'Pos (Stack_Grows_Down) * Address'First + + Boolean'Pos (not Stack_Grows_Down) * Address'Last; + pragma Export (C, Stack_Limit, "__gnat_stack_limit"); -- Stack_Limit contains the limit of the stack. This variable is later made -- a task variable (by calling taskVarAdd) and then correctly set to the diff --git a/gcc/ada/sem_dim.adb b/gcc/ada/sem_dim.adb index 7a544b645ed..b859b14af74 100644 --- a/gcc/ada/sem_dim.adb +++ b/gcc/ada/sem_dim.adb @@ -255,7 +255,7 @@ package body Sem_Dim is procedure Analyze_Dimension_Number_Declaration (N : Node_Id); -- Procedure to analyze dimension of expression in a number declaration. - -- This allows a named number to have non-trivial dimensions, while by + -- This allows a named number to have nontrivial dimensions, while by -- default a named number is dimensionless. procedure Analyze_Dimension_Object_Declaration (N : Node_Id); @@ -1510,7 +1510,7 @@ package body Sem_Dim is end if; end if; - -- If expander is active, remove dimension information from each + -- If expander is active, remove dimension information from each -- operand, as only dimensions of result are relevant. if Expander_Active then -- 2.30.2