mirror of git://gcc.gnu.org/git/gcc.git
lto-streamer-out.c (write_symbol): Use int_size_in_bytes rather than assembling high and low parts of size if...
* lto-streamer-out.c (write_symbol): Use int_size_in_bytes rather than assembling high and low parts of size if not using 32-bit HWINT; else use DECL_SIZE_UNITS, not DECL_SIZE. From-SVN: r166600
This commit is contained in:
parent
ad26988476
commit
a16e07c682
|
@ -1,3 +1,9 @@
|
|||
2010-11-11 Dave Korn <dave.korn.cygwin@gmail.com>
|
||||
|
||||
* lto-streamer-out.c (write_symbol): Use int_size_in_bytes rather than
|
||||
assembling high and low parts of size if not using 32-bit HWINT; else
|
||||
use DECL_SIZE_UNITS, not DECL_SIZE.
|
||||
|
||||
2010-11-11 Martin Jambor <mjambor@suse.cz>
|
||||
|
||||
PR tree-optimization/46383
|
||||
|
|
|
@ -2435,8 +2435,12 @@ write_symbol (struct lto_streamer_cache_d *cache,
|
|||
if (kind == GCCPK_COMMON
|
||||
&& DECL_SIZE (t)
|
||||
&& TREE_CODE (DECL_SIZE (t)) == INTEGER_CST)
|
||||
size = (((uint64_t) TREE_INT_CST_HIGH (DECL_SIZE (t))) << 32)
|
||||
| TREE_INT_CST_LOW (DECL_SIZE (t));
|
||||
{
|
||||
size = (HOST_BITS_PER_WIDE_INT >= 64)
|
||||
? (uint64_t) int_size_in_bytes (TREE_TYPE (t))
|
||||
: (((uint64_t) TREE_INT_CST_HIGH (DECL_SIZE_UNIT (t))) << 32)
|
||||
| TREE_INT_CST_LOW (DECL_SIZE_UNIT (t));
|
||||
}
|
||||
else
|
||||
size = 0;
|
||||
|
||||
|
|
Loading…
Reference in New Issue