This is the mail archive of the gcc-bugs@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]

[Bug c++/38334] New: pmf accesses violate strict-aliasing rules


For g++.dg/opt/pmf1.C we generate

  struct Container t;
...

<bb 3>:
  D.1857_10 = (int (*__vtbl_ptr_type) (void) * *) &t;
  D.1858_11 = *D.1857_10;

a strict-aliasing warning is created if SRA is enabled and PR36509 is fixed.
The frontend should probably use a ref-all pointer for the access.


-- 
           Summary: pmf accesses violate strict-aliasing rules
           Product: gcc
           Version: 4.4.0
            Status: UNCONFIRMED
          Keywords: wrong-code
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: rguenth at gcc dot gnu dot org
OtherBugsDependingO 36509
             nThis:


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


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