From e8864c8522f08528685762e6e3611da1354c31c2 Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Thu, 13 Nov 2014 13:08:12 +0000 Subject: [PATCH] Use POINTER_SIZE to check for pointer size PR tree-optimization/63828 * ipa-polymorphic-call.c (possible_placement_new): Check POINTER_SIZE, instead of BITS_PER_WORD, for pointer size. From-SVN: r217483 --- gcc/ChangeLog | 6 ++++++ gcc/ipa-polymorphic-call.c | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d418c82d724..d909f67067c 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2014-11-13 H.J. Lu + + PR tree-optimization/63828 + * ipa-polymorphic-call.c (possible_placement_new): Check + POINTER_SIZE, instead of BITS_PER_WORD, for pointer size. + 2014-11-13 Eric Botcazou * doc/tm.texi.in (SELECT_CC_MODE): Update example. diff --git a/gcc/ipa-polymorphic-call.c b/gcc/ipa-polymorphic-call.c index 33dd1a8c384..30b5db242af 100644 --- a/gcc/ipa-polymorphic-call.c +++ b/gcc/ipa-polymorphic-call.c @@ -106,7 +106,7 @@ possible_placement_new (tree type, tree expected_type, { return ((TREE_CODE (type) != RECORD_TYPE || !TYPE_BINFO (type) - || cur_offset >= BITS_PER_WORD + || cur_offset >= POINTER_SIZE || !polymorphic_type_binfo_p (TYPE_BINFO (type))) && (!TYPE_SIZE (type) || !tree_fits_shwi_p (TYPE_SIZE (type)) -- 2.30.2