Commit 7297afa0 by Daniel Berlin Committed by Daniel Berlin

ggc-zone.c (ggc_pch_write_object): Calculate object size using ggc_get_size…

ggc-zone.c (ggc_pch_write_object): Calculate object size using ggc_get_size (which accounts for large objects...

2003-12-01  Daniel Berlin  <dberlin@dberlin.org>

	* ggc-zone.c (ggc_pch_write_object): Calculate object size using
	ggc_get_size (which accounts for large objects properly).

From-SVN: r74114
parent fccab17e
2003-12-01 Daniel Berlin <dberlin@dberlin.org>
* ggc-zone.c (ggc_pch_write_object): Calculate object size using
ggc_get_size (which accounts for large objects properly).
2003-12-01 Jeff Sturm <jsturm@one-point.com>
PR optimization/13024
......
......@@ -1663,7 +1663,7 @@ ggc_pch_write_object (struct ggc_pch_data *d ATTRIBUTE_UNUSED,
if (!is_string)
{
struct alloc_chunk *chunk = (struct alloc_chunk *) ((char *)x - CHUNK_OVERHEAD);
size = chunk->size;
size = ggc_get_size (x);
if (fwrite (chunk, size + CHUNK_OVERHEAD, 1, f) != 1)
fatal_error ("can't write PCH file: %m");
d->written += size + CHUNK_OVERHEAD;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment