kparzysz added a comment. In https://reviews.llvm.org/D31885#748889, @rjmccall wrote:
> Sounds to me like we should just not apply struct-path TBAA data that runs > through a union field because either LLVM's representation can't handle it or > Clang isn't generating the representation right. That should be simple to do > in a targeted place in Clang rather than awkwardly doing it retroactively > like in the current patch. The TBAA information seems to be assembled from several smaller pieces during code generation. There is already a check for unions in EmitLValueForField, which turns off path TBAA information for union fields, but that is not sufficient to avoid problems. Both testcases will still fail with this code in place (the C++ testcase needs to be updated: it's missing "-O2 -std=c++11"). Repository: rL LLVM https://reviews.llvm.org/D31885 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits