summaryrefslogtreecommitdiff
path: root/gcc/target.h
diff options
context:
space:
mode:
authorgeoffk <geoffk@138bc75d-0d04-0410-961f-82ee72b054a4>2003-10-24 21:28:13 +0000
committergeoffk <geoffk@138bc75d-0d04-0410-961f-82ee72b054a4>2003-10-24 21:28:13 +0000
commit7988d6e261f71ae9e293e727e7286c860d4ed8d2 (patch)
treed43094488963890ba2a849eb20c57b70ebe80264 /gcc/target.h
parent262c6367352ee365cb78533d503308e0d2d64c6d (diff)
downloadgcc-7988d6e261f71ae9e293e727e7286c860d4ed8d2.tar.gz
PR 10757
* c-pch.c: Include target.h. Improve comments. (struct c_pch_validity): Add target_data_length. (pch_init): Add target's validity data. (c_common_valid_pch): Check target's validity data. * target-def.h (TARGET_GET_PCH_VALIDITY): New. (TARGET_PCH_VALID_P): New. (TARGET_INITIALIZER): Add new fields. * target.h: Include tm.h. (struct gcc_target): Add get_pch_validity, pch_valid_p. * toplev.h (default_get_pch_validity): New prototype. (default_pch_valid_p): New prototype. * toplev.c (default_get_pch_validity): New routine. (default_pch_valid_p): New routine. * Makefile.in (TARGET_H): Add TM_H. Replace all users of target.h with $(TARGET_H). (c-pch.o): Add TARGET_H. * doc/tm.texi (PCH Target): New node. (TARGET_GET_PCH_VALIDITY): Document. (TARGET_PCH_VALID_P): Document. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@72909 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/target.h')
-rw-r--r--gcc/target.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/gcc/target.h b/gcc/target.h
index 8d77dfde2d0..0b19445456a 100644
--- a/gcc/target.h
+++ b/gcc/target.h
@@ -44,6 +44,8 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
to gradually reduce the amount of conditional compilation that is
scattered throughout GCC. */
+#include "tm.h"
+
struct gcc_target
{
/* Functions that output assembler for the target. */
@@ -380,6 +382,15 @@ struct gcc_target
delayed-branch scheduling. */
void (* machine_dependent_reorg) (void);
+ /* Validity-checking routines for PCH files, target-specific.
+ get_pch_validity returns a pointer to the data to be stored,
+ and stores the size in its argument. pch_valid_p gets the same
+ information back and returns NULL if the PCH is valid,
+ or an error message if not.
+ */
+ void * (* get_pch_validity) (size_t *);
+ const char * (* pch_valid_p) (const void *, size_t);
+
/* Leave the boolean fields at the end. */
/* True if arbitrary sections are supported. */