This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: tree-ssa: a weird (mis)optimization


On Tue, Nov 30, 2004 at 06:14:52PM +0000, Andrew Haley wrote:
>  > >   <tmp>_4 = x_3->length;
>  > >
>  > > has disappeared.  This should not have happened, because the operation
>  > > should have may_trap_p() set -- we're deleting a trapping instruction.
>  > 
>  > Does Java require a trap here, even if the result is not needed
>  > and the entire expression could otherwise be deleted?
> 
> Yes.

Then you're going to have to mark this as a volatile load.
Because the result *is* dead, and there's nothing else to
keep this load from being deleted.


r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]