------- Comment #162 from dberlin at gcc dot gnu dot org  2007-05-28 11:24 
-------
Subject: Re:  [4.0/4.1/4.2/4.3 Regression] placement new does not change the
dynamic type as it should

On 28 May 2007 11:14:20 -0000, rguenther at suse dot de
<[EMAIL PROTECTED]> wrote:
>
>
> ------- Comment #161 from rguenther at suse dot de  2007-05-28 11:14 -------
> Subject: Re:  [4.0/4.1/4.2/4.3 Regression] placement
>  new does not change the dynamic type as it should
>
> Btw, it could save us many bugs (or bug reports) if if PTA says must-alias
> we'd trust it, instead of using TBAA to say "but it shouldn't".  Like for
> the (invalid)
>
> int foo(void *p)
> {
>   double *q = p;
>   int *r = p;
>   *q = 1.0;
>   return *r;
> }
>
> where we correctly figure that
>
> Points-to sets
> q_2 = same as p
> r_3 = same as p
>

These are just collapsed because of pointer equivalences.
There is no guarantee that we will discover all pointer equivalences,
and their are in fact cases where we won't.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29286

Reply via email to