This is the mail archive of the gcc-patches@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: [RFA] [PR tree-optimization/33562] [PATCH 1/4] Byte tracking in DSE


On 12/16/2016 11:35 AM, Joseph Myers wrote:
On Thu, 15 Dec 2016, Jeff Law wrote:

This version attacks the problem by improving DSE to track stores to memory at
a byte level.  That allows us to determine if a series of stores completely
covers an earlier store (thus making the earlier store dead).

Question: suppose you have an assignment for a struct with padding, then
stores for all the elements.  Does it detect that the original assignment
is dead (because there is no need to copy padding on struct assignment)?
It would not detect the original assignment as dead in that case as it does not know anything special about the padding bytes.

So we'd likely end up just trimming the original assignment, particularly if it was done via a CONSTRUCTOR assignment or memset.

This situation could be addressed by handling the padding bytes specially -- ie, just clear them from LIVE when LIVE is initialized. It'd likely "just work" then.

Seems like it might be a reasonable follow-up as it'd hopefully make more of the original assignments fully dead rather than just trimmable.

jeff



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