Commit 47782a9d by Richard Guenther Committed by Richard Biener

re PR lto/47264 (Many tests fail with -flto due unaligned load in lto-plugin.c)

2011-01-12  Richard Guenther  <rguenther@suse.de>

	PR lto/47264
	* lto-plugin.c (parse_table_entry): Use memcpy to access
	unaligned fields.

From-SVN: r168708
parent 753cc685
2011-01-12 Richard Guenther <rguenther@suse.de>
PR lto/47264
* lto-plugin.c (parse_table_entry): Use memcpy to access
unaligned fields.
2010-12-20 Dave Korn <dave.korn.cygwin@gmail.com>
* Makefile.am (AM_LIBTOOLFLAGS): Define, adding disable-static tag.
......
......@@ -249,10 +249,10 @@ parse_table_entry (char *p, struct ld_plugin_symbol *entry,
entry->visibility = translate_visibility[t];
p++;
entry->size = *(uint64_t *) p;
memcpy (&entry->size, p, sizeof (uint64_t));
p += 8;
aux->slot = *(uint32_t *) p;
memcpy (&aux->slot, p, sizeof (uint32_t));
p += 4;
entry->resolution = LDPR_UNKNOWN;
......
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