This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: role of executable_checksum & LTO?


Basile Starynkevitch <basile@starynkevitch.net> writes:

> What is the role of executable_checksum from c-common.h & generated by
> genchecksum.

It is used for precompiled headers.  It verifies that the precompiled
header was generated by precisely the same compiler as the one trying to
use the precompiled header.  This approach is used because a precompiled
header is essentially a memory dump of the compiler after parsing the
header.  It would not work to use a memory of one compiler in another
compiler.

> What is the reason of not having executable_checksum inside lto1 binary?

lto1 does not use precompiled headers, and as such does not need
executable_checksum.  The executable_checksum variable only appears in
those frontends which need it, namely the C family frontends.

Ian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]