[PATCH] D38074: Fix TBAA information for reference accesses

2017-09-26 Thread Ivan A. Kosarev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL314209: Fix TBAA information for reference accesses (authored by kosarev). Changed prior to commit: https://reviews.llvm.org/D38074?vs=116326&id=116721#toc Repository: rL LLVM https://reviews.llvm.o

[PATCH] D37826: Refine generation of TBAA information in clang

2017-09-27 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev added a comment. Colleagues, please let me know if I can do anything else to help with reviewing the patch. Thanks. https://reviews.llvm.org/D37826 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailma

[PATCH] D38404: [CodeGen] Do not refer to complete TBAA info where we actually deal with just TBAA access types

2017-09-29 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev created this revision. kosarev added a project: clang. This patch fixes misleading names of entities related to getting, setting and generation of TBAA access type descriptors. This is effectively an attempt to provide a review for https://reviews.llvm.org/D37826 by breaking it into sma

[PATCH] D38408: [CodeGen] Have a special function to get TBAA info for may-alias accesses

2017-09-29 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev created this revision. kosarev added a project: clang. This is part of https://reviews.llvm.org/D37826 reworked to be a separate patch to simplify review. Repository: rL LLVM https://reviews.llvm.org/D38408 Files: lib/CodeGen/CGExpr.cpp lib/CodeGen/CodeGenModule.cpp lib/CodeGe

[PATCH] D38404: [CodeGen] Do not refer to complete TBAA info where we actually deal with just TBAA access types

2017-10-02 Thread Ivan A. Kosarev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL314657: [CodeGen] Do not refer to complete TBAA info where we actually deal with just… (authored by kosarev). Changed prior to commit: https://reviews.llvm.org/D38404?vs=117143&id=117315#toc Repository

[PATCH] D38408: [CodeGen] Have a special function to get TBAA info for may-alias accesses

2017-10-02 Thread Ivan A. Kosarev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL314660: [CodeGen] Have a special function to get TBAA info for may-alias accesses (authored by kosarev). Changed prior to commit: https://reviews.llvm.org/D38408?vs=117162&id=117321#toc Repository: r

[PATCH] D38456: [CodeGen] Introduce generic TBAA access descriptors

2017-10-02 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev created this revision. kosarev added a project: clang. With this patch we implement a concept of TBAA access descriptors that are capable of representing both scalar and struct-path accesses in a generic way. This is part of https://reviews.llvm.org/D37826 reworked to be a separate patch

[PATCH] D38460: [CodeGen] Fix propagation of TBAA info for atomic accesses

2017-10-02 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev created this revision. kosarev added a project: clang. This patch fixes clang to propagate complete TBAA information for atomic accesses and not just the final access types. Prepared against https://reviews.llvm.org/D38456 and requires it to be committed first. This is part of https://r

[PATCH] D38456: [CodeGen] Introduce generic TBAA access descriptors

2017-10-03 Thread Ivan A. Kosarev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL314780: [CodeGen] Introduce generic TBAA access descriptors (authored by kosarev). Changed prior to commit: https://reviews.llvm.org/D38456?vs=117339&id=117494#toc Repository: rL LLVM https://review

[PATCH] D38460: [CodeGen] Fix propagation of TBAA info for atomic accesses

2017-10-03 Thread Ivan A. Kosarev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL314784: [CodeGen] Fix propagation of TBAA info for atomic accesses (authored by kosarev). Changed prior to commit: https://reviews.llvm.org/D38460?vs=117349&id=117498#toc Repository: rL LLVM https:/

[PATCH] D38460: [CodeGen] Fix propagation of TBAA info for atomic accesses

2017-10-03 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev added a comment. Answering your question: it's just to keep functional changes apart from purely refactoring patches. Repository: rL LLVM https://reviews.llvm.org/D38460 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://list

[PATCH] D38503: [CodeGen] Unify generation of scalar and struct-path TBAA tags

2017-10-03 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev created this revision. kosarev added a project: clang. This patch makes it possible to produce access tags in a uniform manner regardless whether the resulting tag will be a scalar or a struct-path one. getAccessTagInfo() now takes care of the actual translation of access descriptors to

[PATCH] D38503: [CodeGen] Unify generation of scalar and struct-path TBAA tags

2017-10-03 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev added a comment. Just in case, please let me know if you think this change should further be broken down into smaller pieces. Thanks. Repository: rL LLVM https://reviews.llvm.org/D38503 ___ cfe-commits mailing list cfe-commits@lists.llvm

[PATCH] D37826: Refine generation of TBAA information in clang

2017-10-04 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev updated this revision to Diff 117653. kosarev added a comment. Rebased. This is how how the rebased patch differs from the mainline: - It incorporates changes from (not landed yet) https://reviews.llvm.org/D38503. - Simplifies generation of TBAA info in EmitLValueForField(). - Replaces T

[PATCH] D37826: Refine generation of TBAA information in clang

2017-10-04 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev added a comment. In https://reviews.llvm.org/D37826#887820, @rjmccall wrote: > I assume I should wait on reviewing this until all of these smaller TBAA > patches land? These small patches are actually part of this diff. Generally, It depends on how you would like it: if you can review

[PATCH] D38503: [CodeGen] Unify generation of scalar and struct-path TBAA tags

2017-10-05 Thread Ivan A. Kosarev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL314977: [CodeGen] Unify generation of scalar and struct-path TBAA tags (authored by kosarev). Changed prior to commit: https://reviews.llvm.org/D38503?vs=117519&id=117791#toc Repository: rL LLVM htt

[PATCH] D37826: Refine generation of TBAA information in clang

2017-10-05 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev updated this revision to Diff 117823. kosarev added a comment. - Rebased on top of https://reviews.llvm.org/D38503. - The tbaa-for-vptr.cpp test is changed to be more specific about the instructions to test. Otherwise, we fail on some triples, such as s390x-ibm-linux and x86_64-pc-mingw3

[PATCH] D37826: Refine generation of TBAA information in clang

2017-10-05 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev added inline comments. Comment at: lib/CodeGen/CodeGenTBAA.h:129 - /// getBaseTypeInfo - Get metadata node for a given base access type. - llvm::MDNode *getBaseTypeInfo(QualType QType); + /// getTBAABaseTypeMetadata - Get metadata that describes the given base + ///

[PATCH] D37826: Refine generation of TBAA information in clang

2017-10-06 Thread Ivan A. Kosarev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL315048: Refine generation of TBAA information in clang (authored by kosarev). Changed prior to commit: https://reviews.llvm.org/D37826?vs=117823&id=117961#toc Repository: rL LLVM https://reviews.llv

[PATCH] D38126: Make TBAA information to be part of LValueBaseInfo

2017-10-06 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev updated this revision to Diff 118045. kosarev edited the summary of this revision. kosarev added a comment. Re-based on top of the previous refinements: https://reviews.llvm.org/D38404, https://reviews.llvm.org/D38408, https://reviews.llvm.org/D38456, https://reviews.llvm.org/D38460, htt

[PATCH] D38126: Make TBAA information to be part of LValueBaseInfo

2017-10-06 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev added inline comments. Comment at: lib/CodeGen/CodeGenModule.cpp:55 #include "llvm/IR/Module.h" +#include "llvm/IR/Verifier.h" // TODO #include "llvm/ProfileData/InstrProfReader.h" Oops. Will be removed. https://reviews.llvm.org/D38126 ___

[PATCH] D38126: Make TBAA information to be part of LValueBaseInfo

2017-10-09 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev updated this revision to Diff 118200. kosarev added a comment. Removed the extra ###include##. https://reviews.llvm.org/D38126 Files: lib/CodeGen/CGAtomic.cpp lib/CodeGen/CGBlocks.cpp lib/CodeGen/CGExpr.cpp lib/CodeGen/CGObjC.cpp lib/CodeGen/CGObjCRuntime.cpp lib/CodeGen/CGO

[PATCH] D38695: [CodeGen] Do not construct complete LValue base info in trivial cases

2017-10-09 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev created this revision. kosarev added a project: clang. Besides obvious code simplification, avoiding explicit creation of LValueBaseInfo objects makes it easier to make TBAA information to be part of such objects. This is part of https://reviews.llvm.org/D38126 reworked to be a separate

[PATCH] D38126: Make TBAA information to be part of LValueBaseInfo

2017-10-09 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev added a comment. Please take a look at https://reviews.llvm.org/D38695, if you want this by smaller pieces. Thanks. https://reviews.llvm.org/D38126 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailma

[PATCH] D38695: [CodeGen] Do not construct complete LValue base info in trivial cases

2017-10-10 Thread Ivan A. Kosarev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL315289: [CodeGen] Do not construct complete LValue base info in trivial cases (authored by kosarev). Changed prior to commit: https://reviews.llvm.org/D38695?vs=118234&id=118335#toc Repository: rL LL

[PATCH] D38733: [CodeGen] Generate TBAA info along with LValue base info

2017-10-10 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev created this revision. kosarev added a project: clang. This patch enables explicit generation of TBAA information in all cases where LValue base info is propagated or constructed in non-trivial ways. Eventually, we will consider each of these cases to make sure the TBAA information is c

[PATCH] D38733: [CodeGen] Generate TBAA info along with LValue base info

2017-10-11 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev updated this revision to Diff 118551. kosarev added a comment. Removed changes related to functions like getNaturalTypeAlignment() that generate LValue base info objects to simplify the patch. These removed changes will be addressed with separate patches. https://reviews.llvm.org/D3873

[PATCH] D38788: [CodeGen] EmitCXXMemberDataPointerAddress() to generate TBAA info along with LValue base info

2017-10-11 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev created this revision. kosarev added a project: clang. Prepared on top of https://reviews.llvm.org/D38733. Repository: rL LLVM https://reviews.llvm.org/D38788 Files: CodeGen/CGClass.cpp CodeGen/CGExpr.cpp CodeGen/CodeGenFunction.h Index: CodeGen/CodeGenFunction.h

[PATCH] D38791: [CodeGen] EmitLoadOfPointerLValue() to generate TBAA info along with LValue base info

2017-10-11 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev created this revision. kosarev added a project: clang. This patch should not bring in any functional changes. Prepared on top of https://reviews.llvm.org/D38733. Repository: rL LLVM https://reviews.llvm.org/D38791 Files: CodeGen/CGExpr.cpp CodeGen/CodeGenFunction.h Index: Code

[PATCH] D38793: [CodeGen] EmitLoadOfReference() to generate TBAA info along with LValue base info

2017-10-11 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev created this revision. kosarev added a project: clang. Repository: rL LLVM https://reviews.llvm.org/D38793 Files: CodeGen/CGExpr.cpp CodeGen/CodeGenFunction.h Index: CodeGen/CodeGenFunction.h === --- CodeGen/CodeGenF

[PATCH] D38794: [CodeGen] getNaturalTypeAlignment() to generate TBAA info along with LValue base info

2017-10-11 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev created this revision. kosarev added a project: clang. This patch should not bring in any functional changes. Prepared on top of https://reviews.llvm.org/D38733, https://reviews.llvm.org/D38788, https://reviews.llvm.org/D38791 and https://reviews.llvm.org/D38793. Repository: rL LLVM

[PATCH] D38126: Make TBAA information to be part of LValueBaseInfo

2017-09-22 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev added a comment. Sure, will do. Just added it to https://reviews.llvm.org/D38074. Thanks. https://reviews.llvm.org/D38126 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D38074: Fix TBAA information for reference accesses

2017-09-22 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev updated this revision to Diff 116325. kosarev added a comment. Added a check for the initialization of the reference member in B::B(S&). (That in fact was my original intent; thanks for catching it.) As to reference loads, we generate them with CodeGenFunction::EmitLoadOfReference() tha

[PATCH] D38074: Fix TBAA information for reference accesses

2017-09-22 Thread Ivan A. Kosarev via Phabricator via cfe-commits
kosarev updated this revision to Diff 116326. kosarev added a comment. Refined the TODO wording. https://reviews.llvm.org/D38074 Files: lib/CodeGen/CodeGenTBAA.cpp test/CodeGen/tbaa-reference.cpp Index: test/CodeGen/tbaa-reference.cpp ==