diff options
author | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-08-06 08:26:27 +0000 |
---|---|---|
committer | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-08-06 08:26:27 +0000 |
commit | fafc6b97000e420240e78934a1cad2b92a27dca8 (patch) | |
tree | 252d34fec92d6b22e8d4f8e3c7dedd6b4cf771ed /gcc/ada/gnat1drv.adb | |
parent | 825c35988f4318028a74bf0ce1710e9a3d3d822a (diff) | |
download | gcc-fafc6b97000e420240e78934a1cad2b92a27dca8.tar.gz |
2012-08-06 Robert Dewar <dewar@adacore.com>
* exp_util.adb, switch-c.adb, inline.ads, sem_ch10.adb, types.ads,
checks.adb, sem_prag.adb, sem.adb, sem.ads, sem_res.adb, sem_attr.adb,
gnat1drv.adb, exp_ch4.adb, exp_ch6.adb, opt.ads, osint.adb: Implement
extended overflow checks (step 1).
(Overflow_Check_Type, Suppress_Record, Suppress_All): New types.
(Suppress_Array): Extended to include switches to control extended
overflow checking (and renamed to Suppress_Record).
Update all uses of Suppress_Array.
2012-08-06 Thomas Quinot <quinot@adacore.com>
* makeutl.ads: Minor documentation fix.
2012-08-06 Thomas Quinot <quinot@adacore.com>
* exp_ch7.adb: Minor reformatting.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@190166 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/gnat1drv.adb')
-rw-r--r-- | gcc/ada/gnat1drv.adb | 30 |
1 files changed, 18 insertions, 12 deletions
diff --git a/gcc/ada/gnat1drv.adb b/gcc/ada/gnat1drv.adb index 4cc6a4937b2..b2f371f3973 100644 --- a/gcc/ada/gnat1drv.adb +++ b/gcc/ada/gnat1drv.adb @@ -193,13 +193,16 @@ procedure Gnat1drv is -- Enable all other language checks Suppress_Options := - (Access_Check => True, - Alignment_Check => True, - Division_Check => True, - Elaboration_Check => True, - Overflow_Check => True, - others => False); - Enable_Overflow_Checks := False; + (Suppress => (Access_Check => True, + Alignment_Check => True, + Division_Check => True, + Elaboration_Check => True, + Overflow_Check => True, + others => False), + Overflow_Checks_General => Suppress, + Overflow_Checks_Assertions => Suppress); + + Enable_Overflow_Checks := False; Dynamic_Elaboration_Checks := False; -- Kill debug of generated code, since it messes up sloc values @@ -339,9 +342,11 @@ procedure Gnat1drv is and Targparm.Backend_Overflow_Checks_On_Target)) then - Suppress_Options (Overflow_Check) := False; + Suppress_Options.Suppress (Overflow_Check) := False; else - Suppress_Options (Overflow_Check) := True; + Suppress_Options.Suppress (Overflow_Check) := True; + Suppress_Options.Overflow_Checks_General := Check_All; + Suppress_Options.Overflow_Checks_Assertions := Check_All; end if; -- Set default for atomic synchronization. As this synchronization @@ -349,7 +354,8 @@ procedure Gnat1drv is -- on some targets, an optional target parameter can turn the option -- off. Note Atomic Synchronization is implemented as check. - Suppress_Options (Atomic_Synchronization) := not Atomic_Sync_Default; + Suppress_Options.Suppress (Atomic_Synchronization) := + not Atomic_Sync_Default; -- Set switch indicating if we can use N_Expression_With_Actions @@ -426,12 +432,12 @@ procedure Gnat1drv is Restrict.Restrictions.Set (No_Initialize_Scalars) := True; -- Suppress all language checks since they are handled implicitly by - -- the formal verification backend. + -- the formal verification backend. -- Turn off dynamic elaboration checks. -- Turn off alignment checks. -- Turn off validity checking. - Suppress_Options := (others => True); + Suppress_Options := Suppress_All; Enable_Overflow_Checks := False; Dynamic_Elaboration_Checks := False; Reset_Validity_Check_Options; |