Re: GCC 4.4.1 bug? need help isolating problem

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Corey Hickey <bugfood-ml@xxxxxxxxxx> writes:

> The line it complains about is:
>
> grow_array((void **)&mkv_d->cluster_positions, mkv_d->num_cluster_pos,
>     sizeof(uint64_t));
>
> Would that indeed be a bug of the sort to which you refer? 

Yes, that is the kind of thing Andrew meant.  The grow_array function
is going to change a value of type void*.  When using
-fstrict-aliasing, the compiler knows that that assignment can not
change a value of type uint64_t*, such as
mkv_d->cluster_positions.  So instruction scheduling will be permitted
to move the use of mkv_d->cluster_positions above the assignment to
the void* pointer in grow_array.

This seems consistent with your earlier report since it requires
function inlining + strict aliasing + instruction scheduling.

Ian

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux