Now that we do not depend on the LTO streamer anymore, these calls are unnecessary. There are still some remnants that will be necessary until I factor the pickling buffers out of lto-streamer.h.
Tested on x86_64. Committed to branch. Diego. * pph-streamer-in.c (pph_init_read): Do not call lto_reader_init. * pph-streamer-out.c (pph_init_write): Do not call lto_streamer_init. (pph_out_body): Do not call lto_output_decl_state_streams nor lto_output_decl_state_refs. diff --git a/gcc/cp/pph-streamer-in.c b/gcc/cp/pph-streamer-in.c index 1e31427..e644113 100644 --- a/gcc/cp/pph-streamer-in.c +++ b/gcc/cp/pph-streamer-in.c @@ -87,8 +87,6 @@ pph_init_read (pph_stream *stream) const char *strtab, *body; char *new_strtab; - lto_reader_init (); - /* Read STREAM->NAME into the memory buffer stream->encoder.r.file_data. */ retcode = fstat (fileno (stream->file), &st); gcc_assert (retcode == 0); diff --git a/gcc/cp/pph-streamer-out.c b/gcc/cp/pph-streamer-out.c index ec95532..2e5543a 100644 --- a/gcc/cp/pph-streamer-out.c +++ b/gcc/cp/pph-streamer-out.c @@ -45,7 +45,6 @@ static pph_stream *pph_out_stream = NULL; void pph_init_write (pph_stream *stream) { - lto_streamer_init (); stream->encoder.w.out_state = lto_new_out_decl_state (); lto_push_out_decl_state (stream->encoder.w.out_state); stream->encoder.w.decl_state_stream = XCNEW (struct lto_output_stream); @@ -149,17 +148,7 @@ pph_out_body (pph_stream *stream) /* Write the string table. */ lto_write_stream (stream->encoder.w.ob->string_stream); - /* Write out the physical representation for every AST in all the - streams in STREAM->ENCODER.W.OUT_STATE. */ - lto_output_decl_state_streams (stream->encoder.w.ob, - stream->encoder.w.out_state); - - /* Now write the vector of all AST references. */ - lto_output_decl_state_refs (stream->encoder.w.ob, - stream->encoder.w.decl_state_stream, - stream->encoder.w.out_state); - - /* Finally, physically write all the streams. */ + /* Write the main stream where we have been pickling the parse trees. */ lto_write_stream (stream->encoder.w.ob->main_stream); } -- This patch is available for review at http://codereview.appspot.com/4869045