From 921bb9d1a3981bc801b6e22eccc8af2a248b9e81 Mon Sep 17 00:00:00 2001 From: Richard Biener Date: Fri, 22 Feb 2019 10:59:33 +0000 Subject: [PATCH] c-pch.c (no_checksum): Remove. 2019-02-22 Richard Biener c-family/ * c-pch.c (no_checksum): Remove. (pch_init): Remove assertion that executable_checksum is not all zero. (c_common_valid_pch): Likewise. From-SVN: r269113 --- gcc/c-family/ChangeLog | 7 +++++++ gcc/c-family/c-pch.c | 8 -------- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/gcc/c-family/ChangeLog b/gcc/c-family/ChangeLog index 2d3839ee5a7..951231efaac 100644 --- a/gcc/c-family/ChangeLog +++ b/gcc/c-family/ChangeLog @@ -1,3 +1,10 @@ +2019-02-22 Richard Biener + + * c-pch.c (no_checksum): Remove. + (pch_init): Remove assertion that executable_checksum is not + all zero. + (c_common_valid_pch): Likewise. + 2019-02-18 Martin Sebor PR middle-end/89294 diff --git a/gcc/c-family/c-pch.c b/gcc/c-family/c-pch.c index 77740244860..5492752a5af 100644 --- a/gcc/c-family/c-pch.c +++ b/gcc/c-family/c-pch.c @@ -45,10 +45,6 @@ enum { MATCH_SIZE = ARRAY_SIZE (pch_matching) }; -/* The value of the checksum in the dummy compiler that is actually - checksummed. That compiler should never be run. */ -static const char no_checksum[16] = { 0 }; - /* Information about flags and suchlike that affect PCH validity. Before this structure is read, both an initial 8-character identification @@ -111,8 +107,6 @@ pch_init (void) pch_file); pch_outfile = f; - gcc_assert (memcmp (executable_checksum, no_checksum, 16) != 0); - memset (&v, '\0', sizeof (v)); v.debug_info_type = write_symbols; { @@ -212,8 +206,6 @@ c_common_valid_pch (cpp_reader *pfile, const char *name, int fd) /* Perform a quick test of whether this is a valid precompiled header for the current language. */ - gcc_assert (memcmp (executable_checksum, no_checksum, 16) != 0); - sizeread = read (fd, ident, IDENT_LENGTH + 16); if (sizeread == -1) fatal_error (input_location, "can%'t read %s: %m", name); -- 2.30.2