From 5a64837c6b14f97b066772abc1463aa8f2c962d5 Mon Sep 17 00:00:00 2001 From: Arnaud Charlet Date: Mon, 13 Jul 2009 10:30:44 +0000 Subject: gnat1drv.adb (Adjust_Global_Switches): No longer set Back_Annotate_Rep_Info in inspector mode. 2009-07-13 Arnaud Charlet * gnat1drv.adb (Adjust_Global_Switches): No longer set Back_Annotate_Rep_Info in inspector mode. (Gnat1Drv): Need to call the back-end in inspector mode to generate SCIL * opt.ads: Update comment. From-SVN: r149567 --- gcc/ada/ChangeLog | 8 ++++++++ gcc/ada/gnat1drv.adb | 17 +++++++++-------- gcc/ada/opt.ads | 6 +++--- 3 files changed, 20 insertions(+), 11 deletions(-) (limited to 'gcc/ada') diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index c71282e..8d276e8 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,11 @@ +2009-07-13 Arnaud Charlet + + * gnat1drv.adb (Adjust_Global_Switches): No longer set + Back_Annotate_Rep_Info in inspector mode. + (Gnat1Drv): Need to call the back-end in inspector mode to generate SCIL + + * opt.ads: Update comment. + 2009-07-13 Robert Dewar * lib.adb, prj-nmsc.adb, prj-proc.adb, prj-proc.ads, prj.adb, diff --git a/gcc/ada/gnat1drv.adb b/gcc/ada/gnat1drv.adb index b5a3354..f737e96 100644 --- a/gcc/ada/gnat1drv.adb +++ b/gcc/ada/gnat1drv.adb @@ -117,22 +117,23 @@ procedure Gnat1drv is -- Turn off inlining in ASIS mode, since ASIS cannot handle the extra -- information in the trees caused by inlining being active. - -- More specifically, the tree seems to malformed from the ASIS point - -- of view if -gnatc and -gnatn appear together ??? + -- More specifically, the tree seems to be malformed from the ASIS + -- point of view if -gnatc and -gnatn appear together??? Inline_Active := False; - -- Turn off inspector mode in ASIS mode. For reasons that need - -- clearer documentation, Inspector cannot function in this mode ??? + -- Turn off Inspector mode in ASIS mode, since Inspector requires + -- front-end expansion. Inspector_Mode := False; end if; - -- Inspeector mode requires back-end rep info and also needs to disable - -- front-end inlining (but -gnatn does not need to be disabled). + -- Inspector mode needs to disable front-end inlining since the + -- generated trees (in particular order and consistency between specs + -- compiled as part of a main unit or as part of a with-clause) are + -- causing troubles. if Inspector_Mode then - Back_Annotate_Rep_Info := True; Front_End_Inlining := False; end if; @@ -751,7 +752,7 @@ begin -- a VM, since representations are largely symbolic there. if Back_End_Mode = Declarations_Only - and then (not Back_Annotate_Rep_Info + and then (not (Back_Annotate_Rep_Info or else Inspector_Mode) or else Main_Kind = N_Subunit or else Targparm.Frontend_Layout_On_Target or else Targparm.VM_Target /= No_VM) diff --git a/gcc/ada/opt.ads b/gcc/ada/opt.ads index 1ae4482..1da5f80 100644 --- a/gcc/ada/opt.ads +++ b/gcc/ada/opt.ads @@ -639,8 +639,8 @@ package Opt is Inspector_Mode : Boolean renames Debug.Debug_Flag_Dot_II; -- GNAT - -- True if compiling in inspector mode (-gnatd.I switch). - -- Enable inspector mode, in particular SCIL generation. + -- Set True to activate Inspector mode (-gnatd.I switch). In particular + -- this enables SCIL generation. -- When VM_Target /= None, the compiler will also attempt to -- generate code even in case of unsupported construct instead of -- displaying an error. @@ -651,7 +651,7 @@ package Opt is Follow_Links_For_Files : Boolean := False; -- PROJECT MANAGER - -- Set to True (-eL) to process the project files in trusted mode + -- Set to True (-eL) to process the project files in trusted mode. -- If Follow_Links is False, it is assumed that the project doesn't contain -- any file duplicated through symbolic links (although the latter are -- still valid if they point to a file which is outside of the project), -- cgit v1.1