[Bug target/94103] Wrong optimization: reading value of a variable changes its representation for optimizer

rguenth at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Thu Mar 12 13:21:45 GMT 2020


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94103

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Assignee|unassigned at gcc dot gnu.org      |rguenth at gcc dot gnu.org
             Status|NEW                         |ASSIGNED
      Known to work|                            |10.0

--- Comment #7 from Richard Biener <rguenth at gcc dot gnu.org> ---
commit 1dc00a8ec9aeba86b74b16bff6f171824bb7b4a1 (HEAD -> master, origin/master,
origin/HEAD)
Author: Richard Biener <rguenther@suse.de>
Date:   Thu Mar 12 14:18:35 2020 +0100

    tree-optimization/94103 avoid CSE of loads with padding

    VN currently replaces a load of a 16 byte entity 128 bits of precision
    (TImode) with the result of a load of a 16 byte entity with 80 bits of
    mode precision (XFmode).  That will go downhill since if the padding
    bits are not actually filled with memory contents those bits are
    missing.

    2020-03-12  Richard Biener  <rguenther@suse.de>

            PR tree-optimization/94103
            * tree-ssa-sccvn.c (visit_reference_op_load): Avoid type
            punning when the mode precision is not sufficient.

            * gcc.target/i386/pr94103.c: New testcase.


More information about the Gcc-bugs mailing list