public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r12-2163] [Ada] Duplicated D lines in ali files
@ 2021-07-08 13:37 Pierre-Marie de Rodat
  0 siblings, 0 replies; only message in thread
From: Pierre-Marie de Rodat @ 2021-07-08 13:37 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:d75dde1a7234c4ff556bd9e6ab55ca95baa00262

commit r12-2163-gd75dde1a7234c4ff556bd9e6ab55ca95baa00262
Author: Ghjuvan Lacambre <lacambre@adacore.com>
Date:   Thu May 27 14:54:14 2021 +0200

    [Ada] Duplicated D lines in ali files
    
    gcc/ada/
    
            * lib-writ.ads: Mention SCOs dependency as reason for duplicates.
            * lib.ads (Units): Update documentation to mention duplicated
            units.

Diff:
---
 gcc/ada/lib-writ.ads | 3 +++
 gcc/ada/lib.ads      | 4 +++-
 2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/gcc/ada/lib-writ.ads b/gcc/ada/lib-writ.ads
index b8370fab42a..ce5398b6259 100644
--- a/gcc/ada/lib-writ.ads
+++ b/gcc/ada/lib-writ.ads
@@ -1053,6 +1053,9 @@ package Lib.Writ is
    --  The Object parameter is true if an object file is created, and false
    --  otherwise. Note that the pseudo-object file generated in GNATprove mode
    --  does count as an object file from this point of view.
+   --  May output duplicate D lines caused by generic instantiations. This is
+   --  by design as GNATcoverage relies on them for its coverage of generic
+   --  instantiations, although this may be revisited in the future.
 
    procedure Add_Preprocessing_Dependency (S : Source_File_Index);
    --  Indicate that there is a dependency to be added on a preprocessing data
diff --git a/gcc/ada/lib.ads b/gcc/ada/lib.ads
index 1450124c99e..f2c6ef3553c 100644
--- a/gcc/ada/lib.ads
+++ b/gcc/ada/lib.ads
@@ -926,7 +926,9 @@ private
    --  The following table records a mapping between a name and the entry in
    --  the units table whose Unit_Name is this name. It is used to speed up
    --  the Is_Loaded function, whose original implementation (linear search)
-   --  could account for 2% of the time spent in the front end. Note that, in
+   --  could account for 2% of the time spent in the front end. When the unit
+   --  is an instance of a generic, the unit might get duplicated in the unit
+   --  table - see Make_Instance_Unit for more information. Note that, in
    --  the case of source files containing multiple units, the units table may
    --  temporarily contain two entries with the same Unit_Name during parsing,
    --  which means that the mapping must be to the first entry in the table.


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-07-08 13:37 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-08 13:37 [gcc r12-2163] [Ada] Duplicated D lines in ali files Pierre-Marie de Rodat

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).