diff options
author | Johannes Kanig <kanig@adacore.com> | 2011-08-29 09:36:59 +0000 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2011-08-29 11:36:59 +0200 |
commit | 4bcd6411417e4bd46d5f6416f72c71bf69cd577a (patch) | |
tree | ab3ea9abe2874400f41876854678114635a331a2 | |
parent | f0f88eb6da6cebf88ec1b3fc2d75b6b350c1bfba (diff) | |
download | gcc-4bcd6411417e4bd46d5f6416f72c71bf69cd577a.zip gcc-4bcd6411417e4bd46d5f6416f72c71bf69cd577a.tar.gz gcc-4bcd6411417e4bd46d5f6416f72c71bf69cd577a.tar.bz2 |
frontend.adb (Frontend): Exit after creating Standard package when -gnatd.H is present.
2011-08-29 Johannes Kanig <kanig@adacore.com>
* frontend.adb (Frontend): Exit after creating Standard package when
-gnatd.H is present.
* gnat1drv.adb (Gnat1drv): Call Backend right away when -gnatd.H is
present.
From-SVN: r178180
-rw-r--r-- | gcc/ada/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/ada/frontend.adb | 6 | ||||
-rw-r--r-- | gcc/ada/gnat1drv.adb | 17 |
3 files changed, 29 insertions, 1 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 04df953..f48eafe 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,10 @@ +2011-08-29 Johannes Kanig <kanig@adacore.com> + + * frontend.adb (Frontend): Exit after creating Standard package when + -gnatd.H is present. + * gnat1drv.adb (Gnat1drv): Call Backend right away when -gnatd.H is + present. + 2011-08-29 Robert Dewar <dewar@adacore.com> * exp_ch9.adb, mlib-prj.adb, prj.adb, prj.ads, ttypes.ads, sem_ch4.adb, diff --git a/gcc/ada/frontend.adb b/gcc/ada/frontend.adb index c6dd8cb..f849d31 100644 --- a/gcc/ada/frontend.adb +++ b/gcc/ada/frontend.adb @@ -98,6 +98,12 @@ begin CStand.Create_Standard; + -- If the -gnatd.H flag is present, we are only interested in the Standard + -- package, so the frontend has done its job here. + if Debug_Flag_Dot_HH then + return; + end if; + -- Check possible symbol definitions specified by -gnateD switches Prepcomp.Process_Command_Line_Symbol_Definitions; diff --git a/gcc/ada/gnat1drv.adb b/gcc/ada/gnat1drv.adb index febce1b..b494bd4 100644 --- a/gcc/ada/gnat1drv.adb +++ b/gcc/ada/gnat1drv.adb @@ -771,8 +771,23 @@ begin Frontend; -- Exit with errors if the main source could not be parsed - + -- Also, when -gnatd.H is present, the source file is not set. if Sinput.Main_Source_File = No_Source_File then + if Debug_Flag_Dot_HH then + -- We lock all the tables to keep the convention that the backend + -- needs to unlock the tables it wants to touch. + Atree.Lock; + Elists.Lock; + Fname.UF.Lock; + Inline.Lock; + Lib.Lock; + Nlists.Lock; + Sem.Lock; + Sinput.Lock; + Namet.Lock; + Stringt.Lock; + Back_End.Call_Back_End (Back_End.Generate_Object); + end if; Errout.Finalize (Last_Call => True); Errout.Output_Messages; Exit_Program (E_Errors); |