[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-05-30 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 100796. jyu2 added a comment. Okay this CFG version of this change. In this change I am basic using same algorithm with -Winfinite-recursion. In addition to my original implementation, I add handler type checking which basic using https://reviews.llvm.org/D

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-01 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 101167. jyu2 marked an inline comment as done. jyu2 added a comment. Update to address review comments. https://reviews.llvm.org/D3 Files: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/AnalysisBasedWarnings.cpp test/CXX/except/except.spec/p11.c

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-01 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked 8 inline comments as done. jyu2 added inline comments. Comment at: lib/Sema/AnalysisBasedWarnings.cpp:334 + continue; +else + HasThrowOutFunc = true; aaron.ballman wrote: > You can drop the `else` here and just set `HasThrowOutFunc` to t

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-01 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In https://reviews.llvm.org/D3#770238, @aaron.ballman wrote: > In https://reviews.llvm.org/D3#768332, @jyu2 wrote: > > > Okay this CFG version of this change. In this change I am basic using same > > algorithm with -Winfinite-recursion. > > > > In addition to my or

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-01 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked 12 inline comments as done. jyu2 added inline comments. Comment at: include/clang/Basic/DiagnosticSemaKinds.td:6341 +: Warning<"%0 has a non-throwing exception specification but can still " + "throw, may result in unexpected program termination.">, + In

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-02 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked 2 inline comments as done. jyu2 added inline comments. Comment at: lib/Sema/AnalysisBasedWarnings.cpp:334 + continue; +else + HasThrowOutFunc = true; jyu2 wrote: > aaron.ballman wrote: > > You can drop the `else` here and just set `HasTh

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-05 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 101373. jyu2 added a comment. Add more test include 1> throw/catch reference types. 2> try block. 3>unreachable code. https://reviews.llvm.org/D3 Files: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/AnalysisBasedWarnings.cpp test/CXX/except/ex

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-15 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 102754. jyu2 added a comment. Address Aaron's comments. https://reviews.llvm.org/D3 Files: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/AnalysisBasedWarnings.cpp test/CXX/except/except.spec/p11.cpp test/SemaCXX/warn-throw-out-noexcept-func.c

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-15 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 102759. jyu2 marked 13 inline comments as done. https://reviews.llvm.org/D3 Files: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/AnalysisBasedWarnings.cpp test/CXX/except/except.spec/p11.cpp test/SemaCXX/warn-throw-out-noexcept-func.cpp Index:

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-15 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked 7 inline comments as done. jyu2 added inline comments. Comment at: lib/Sema/AnalysisBasedWarnings.cpp:296 + + if (ThrowType->isReferenceType()) +ThrowType = ThrowType->castAs() aaron.ballman wrote: > If `ThrowType` can be null, there should be a

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-16 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 102828. jyu2 added a comment. Thanks Aaron!!! I just upload new patch to address your comments. I now understand your point on when I can use auto. https://reviews.llvm.org/D3 Files: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/AnalysisBased

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-16 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: test/SemaCXX/warn-throw-out-noexcept-func.cpp:1 +// RUN: %clang_cc1 %s -fdelayed-template-parsing -fcxx-exceptions -fexceptions -fsyntax-only -Wexceptions -verify -std=c++11 +struct A { aaron.ballman wrote: > aaron.ballma

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-16 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 102868. jyu2 added a comment. Update patch https://reviews.llvm.org/D3 Files: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/AnalysisBasedWarnings.cpp test/CXX/except/except.spec/p11.cpp test/SemaCXX/warn-throw-out-noexcept-func.cpp Index: li

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-16 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: test/SemaCXX/warn-throw-out-noexcept-func.cpp:27 +} + +struct N : A { aaron.ballman wrote: > jyu2 wrote: > > aaron.ballman wrote: > > > Can you add a test case like: > > > ``` > > > struct Throws { > > > ~Throws() noexcep

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-06-16 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 102877. jyu2 added a comment. update patch https://reviews.llvm.org/D3 Files: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/AnalysisBasedWarnings.cpp test/CXX/except/except.spec/p11.cpp test/SemaCXX/warn-throw-out-noexcept-func.cpp Index: li

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in LLVM

2019-01-11 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 181342. jyu2 added a comment. 1> I add code for CFG.cpp and a test for that, as efriedman request. 2> changes are respond the comments I received CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files:

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in LLVM

2019-01-11 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked 7 inline comments as done. jyu2 added inline comments. Comment at: lib/CodeGen/CGStmt.cpp:2182 +} + } + nickdesaulniers wrote: > If this new block was moved closer to the new one on L2227, I assume they > could be combined and possibly `IsGCCAsm

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in LLVM

2019-01-11 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked an inline comment as done. jyu2 added inline comments. Comment at: lib/Sema/SemaStmtAsm.cpp:470 +if (NS->isGCCAsmGoto() && +Exprs[ConstraintIdx]->getStmtClass() == Stmt::AddrLabelExprClass) + break; efriedma wrote: > jyu2 wrote: > > e

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in LLVM

2019-01-11 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 181403. jyu2 added a comment. Couple of change to respond Eli’s comments. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/Expr.h include/clang/AST/ExprCXX.h include/clang/AST/Expr

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in LLVM

2019-01-11 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked 3 inline comments as done. jyu2 added inline comments. Comment at: lib/Analysis/CFG.cpp:1474 + appendScopeBegin(JT.block, VD, G); + addSuccessor(B, JT.block); +} efriedma wrote: > Please don't copy-paste code. :-( changed

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in LLVM

2019-01-11 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked 2 inline comments as done. jyu2 added inline comments. Comment at: lib/Sema/SemaStmtAsm.cpp:470 +if (NS->isGCCAsmGoto() && +Exprs[ConstraintIdx]->getStmtClass() == Stmt::AddrLabelExprClass) + break; jyu2 wrote: > efriedma wrote: > > j

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-01-14 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked an inline comment as done. jyu2 added inline comments. Comment at: lib/Sema/SemaStmtAsm.cpp:470 +if (NS->isGCCAsmGoto() && +Exprs[ConstraintIdx]->getStmtClass() == Stmt::AddrLabelExprClass) + break; efriedma wrote: > jyu2 wrote: > > j

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-01-14 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 181702. jyu2 added a comment. Add code to diagnostic error for use of the "l" modifier that does not point to a label in the label list. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/A

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-01-14 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked an inline comment as done. jyu2 added inline comments. Comment at: lib/Sema/SemaStmtAsm.cpp:470 +if (NS->isGCCAsmGoto() && +Exprs[ConstraintIdx]->getStmtClass() == Stmt::AddrLabelExprClass) + break; efriedma wrote: > jyu2 wrote: > > e

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-01-15 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 181862. jyu2 added a comment. I add additional test. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/Expr.h include/clang/AST/ExprCXX.h include/clang/AST/ExprObjC.h include/clan

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-01-15 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked 2 inline comments as done. jyu2 added inline comments. Comment at: lib/Sema/SemaStmtAsm.cpp:470 +if (NS->isGCCAsmGoto() && +Exprs[ConstraintIdx]->getStmtClass() == Stmt::AddrLabelExprClass) + break; efriedma wrote: > jyu2 wrote: > > e

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-01-15 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 181973. jyu2 marked an inline comment as done. jyu2 added a comment. Change error message. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/Expr.h include/clang/AST/ExprCXX.h inclu

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-01-30 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 184349. jyu2 marked an inline comment as done. jyu2 added a comment. Change test for BE IR change. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/Expr.h include/clang/AST/ExprCXX.h

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-03-04 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 189205. jyu2 added a comment. Rebased CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/Stmt.h include/clang/Basic/DiagnosticParseKinds.td include/clang/Basic/DiagnosticSemaKinds.td

[PATCH] D58160: MS ABI: adding template static member in the linker directive section to make sure init function can be called before main.

2019-03-18 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In D58160#1433458 , @rnk wrote: > lgtm Thank you so much Reid! Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58160/new/ https://reviews.llvm.org/D58160 ___

[PATCH] D58160: MS ABI: adding template static member in the linker directive section to make sure init function can be called before main.

2019-04-03 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 closed this revision. jyu2 added a comment. Closed by commit rG0b28b8b09be7 : Bug-40323: MS ABI adding template static member in the linker directive section… (authored by jyu2). Repository: rL LLVM CHANGES SINCE LAS

[PATCH] D60912: MS ABI: handle inline static data member as template static data member

2019-04-19 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 created this revision. jyu2 added reviewers: rnk, majnemer, erichkeane, cfe-commits. Herald added a project: clang. MS only run time problem with inline static data member. A inline static data member’s init function gets called multiple time. To fix this, using template static data members

[PATCH] D60912: MS ABI: handle inline static data member as template static data member

2019-04-19 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In D60912#1472983 , @rnk wrote: > Thanks, I think there's another case to handle, though. Hi Reid, Thank you so much for the review. Yes, I check the following test case, both gnu and cl call foo twice. Do we want to do different

[PATCH] D60912: MS ABI: handle inline static data member as template static data member

2019-04-19 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In D60912#1472987 , @rnk wrote: > In D60912#1472986 , @jyu2 wrote: > > > inline static int aoo = foo(); // C++17 inline variable, thus also a > > definition > > > This is a `static inline` glo

[PATCH] D60930: [codeview] Fix symbol names for dynamic initializers and atexit stubs

2019-04-22 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. Looks good to me. We are basically de-mangled name for those __E initialize global’s function and __F destroy global's function. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60930/new/ https://reviews.llvm.org/D60930 _

[PATCH] D60912: MS ABI: handle inline static data member and inline variable as template static data member

2019-04-23 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 196346. jyu2 retitled this revision from "MS ABI: handle inline static data member as template static data member" to "MS ABI: handle inline static data member and inline variable as template static data member". jyu2 edited the summary of this revision. jyu2 ad

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-04-24 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In D56571#1476266 , @nickdesaulniers wrote: > @compudj email me the preprocessed output of basic_percpu_ops_test.c and I'll > take a look. (Should be able to find my email via `git log`). @nickdesaulniers, thanks for looking into

[PATCH] D60912: MS ABI: handle inline static data member and inline variable as template static data member

2019-04-25 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked an inline comment as done. jyu2 added inline comments. Comment at: lib/CodeGen/CGDeclCXX.cpp:470-471 PrioritizedCXXGlobalInits.push_back(std::make_pair(Key, Fn)); - } else if (isTemplateInstantiation(D->getTemplateSpecializationKind())) { + } else if (isTemplat

[PATCH] D60912: MS ABI: handle inline static data member and inline variable as template static data member

2019-04-25 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 closed this revision. jyu2 added a comment. committed rGc19f4f806972 : Fix bug 37903:MS ABI: handle inline static data member and inline variable as… (authored by jyu2). CHANGES SINCE LAST ACTION https://reviews.llvm.

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-04 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 commandeered this revision. jyu2 edited reviewers, added: craig.topper; removed: jyu2. jyu2 added inline comments. Comment at: lib/Analysis/CFG.cpp:2126 + if (cast(S)->isGCCAsmGoto()) +return VisitGCCAsmStmt(cast(S)); + return VisitStmt(S, asc); ---

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-04 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 185094. jyu2 added a comment. 1> Add code for scope checking 2> Using CastInterator 3> CFG change to remove duplicate Block list CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/Stmt.h

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-04 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked 12 inline comments as done. jyu2 added inline comments. Comment at: include/clang/AST/Stmt.h:1008 + (*iterator_adaptor_base::I)->getStmtClass() <= lastExprConstant); + return *reinterpret_cast(iterator_adaptor_base::I); } rsmith

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-04 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked 2 inline comments as done. jyu2 added inline comments. Comment at: lib/Sema/JumpDiagnostics.cpp:347 + LabelAndGotoScopes[S] = ParentScope; + Jumps.push_back(S); +} efriedma wrote: > This doesn't look right; I think we need to add it to I

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-04 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 185206. jyu2 marked 8 inline comments as done. jyu2 added a comment. More review comments addressed. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/Stmt.h include/clang/Basic/Diagn

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-04 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: lib/AST/Stmt.cpp:457-460 this->NumOutputs = NumOutputs; this->NumInputs = NumInputs; this->NumClobbers = NumClobbers; + this->NumLabels = NumLabels; rsmith wrote: > Please assert that you don't have both outputs a

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-05 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 185360. jyu2 added a comment. 1>emit better error for use of output constraints. 2> Add assert for NumLabels and NumOutputs are both larger than 0. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: inclu

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-05 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked 2 inline comments as done. jyu2 added inline comments. Comment at: lib/AST/Stmt.cpp:457-460 this->NumOutputs = NumOutputs; this->NumInputs = NumInputs; this->NumClobbers = NumClobbers; + this->NumLabels = NumLabels; rsmith wrote: > jyu2 wrot

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-05 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 185477. jyu2 marked 4 inline comments as done. jyu2 added a comment. More change from review. Add scope checking for asm-goto. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/Stmt.h

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-05 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: lib/AST/Stmt.cpp:457-458 + this->NumLabels = NumLabels; + assert((NumLabels != 0 && NumOutputs == 0) || + (NumOutputs != 0 && NumLabels == 0)); rsmith wrote: > This can be simplified a little: > ``` > assert(!(N

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-05 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 185489. jyu2 added a comment. small fix. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/Stmt.h include/clang/Basic/DiagnosticASTKinds.td include/clang/Basic/DiagnosticParseKinds.

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-07 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 marked an inline comment as done. jyu2 added inline comments. Comment at: lib/AST/Stmt.cpp:628 + DiagOffs = CurPtr-StrStart-1; + return diag::err_asm_invalid_operand_for_goto_labels; +} rsmith wrote: > jyu2 wrote: > > rsmith wrote:

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-07 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 185911. jyu2 marked an inline comment as done. jyu2 added a comment. Remove check for %lN Fix missing successor of asm goto in CFG build. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/A

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-07 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: lib/Analysis/CFG.cpp:3137 + + Block = createBlock(false); + Block->setTerminator(G); efriedma wrote: > efriedma wrote: > > Passing add_successor=false seems suspect; this could probably use more > > test coverage. > Did

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-11 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 186356. jyu2 added a comment. I find some ambiguous error for asm-goto out of scope. Instead call VerifyIndirectOrAsmJumps one time, call that function twice one for indirect-goto one for asm-goto. Let me know if you see any problems. Thanks for all the review

[PATCH] D58160: Fix runtime problem from //bugs.llvm.org/show_bug.cgi?id=40323

2019-02-12 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 created this revision. jyu2 added reviewers: cfe-commits, rnk, majnemer, erichkeane. Herald added subscribers: llvm-commits, jdoerfert. Herald added a project: LLVM. A MS only run time problem, because the init function for template static member is not getting called when the template stati

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-12 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 186577. jyu2 added a comment. Cleanup CFG code, remove obj-lifetime code when build CFE for asm-goto. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/Stmt.h include/clang/Basic/Diag

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-15 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 187036. jyu2 marked an inline comment as done. jyu2 added a comment. Review comment addressed CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/Stmt.h include/clang/Basic/DiagnosticPa

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-15 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: lib/Sema/JumpDiagnostics.cpp:675 + // asm-goto. + //if (!IsAsmGoto && IndirectJumpTargets.empty()) { + if (JumpTargets.empty()) { efriedma wrote: > Commented-out code? > > We probably don't need a diagnostic for an asm

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-15 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: lib/AST/StmtProfile.cpp:324 VisitStringLiteral(S->getClobberStringLiteral(I)); + ID.AddInteger(S->getNumLabels()); } rsmith wrote: > Don't we also need to profile the labels themselves? How this can be lost? :-( Ch

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-15 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 187124. jyu2 marked 5 inline comments as done. jyu2 added a comment. Herald added a subscriber: rnkovacs. Review comments addressed. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/St

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-02-22 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 188021. jyu2 added a comment. Rebase CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/ https://reviews.llvm.org/D56571 Files: include/clang/AST/Stmt.h include/clang/Basic/DiagnosticParseKinds.td include/clang/Basic/DiagnosticSemaKinds.td

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-06-01 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. jyu2 committed rG954ec09aed4f : clang support gnu asm goto In D56571#1523895 , @nickdesaulniers wrote: > Was this committed accidentally? > > Today in master I s

[PATCH] D56571: [RFC prototype] Implementation of asm-goto support in clang

2019-06-04 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 closed this revision. jyu2 added a comment. jyu2 committed rGb8fee677bf8e : Re-check in clang support gun asm goto after fixing tests. (authored by jyu2). CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56571/new/

[PATCH] D79743: [clang][asm goto][slh] Warn if asm goto + SLH

2020-05-19 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 accepted this revision. jyu2 added a comment. This revision is now accepted and ready to land. LGTM. Please changed format for td file. Comment at: clang/include/clang/Basic/DiagnosticCommonKinds.td:247 + + def warn_slh_does_not_support_asm_goto : Warning< +"Speculat

[PATCH] D82832: Correctly generate invert xor value for Binary Atomics of int size > 64

2020-07-07 Thread Jennifer Yu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG6cf0dac1ca3f: orrectly generate invert xor value for Binary Atomics of int size > 64 (authored by jyu2). Herald added a project: clang. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION h

[PATCH] D82832: Correctly generate invert xor value for Binary Atomics of int size > 64

2020-07-07 Thread Jennifer Yu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG6cf0dac1ca3f: orrectly generate invert xor value for Binary Atomics of int size > 64 (authored by jyu2). Herald added a project: clang. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION h

[PATCH] D82832: Correctly generate invert xor value for Binary Atomics of int size > 64

2020-06-29 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 created this revision. jyu2 added reviewers: hfinkel, erichkeane, rjmccall, cfe-commits. Herald added a subscriber: jfb. When using __sync_nand_and_fetch with __int128, a problem is found that the wrong value for the 'invert' value gets emitted to the xor in case where the int size is greater

[PATCH] D79743: [clang][asm goto][slh] Warn if asm goto + SLH

2020-05-13 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. Two questions: 1> What happen under SLH, will asm goto gets removed, or a runtime problem? 2> Should we emit error or warning in the Parser instead? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D79743/new/ https://re

[PATCH] D79743: [clang][asm goto][slh] Warn if asm goto + SLH

2020-05-13 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In D79743#2034945 , @zbrid wrote: > In D79743#2034792 , @jyu2 wrote: > > > Two questions: > > 1> What happen under SLH, will asm goto gets removed, or a runtime problem? > > 2> Should we emit

[PATCH] D79743: [clang][asm goto][slh] Warn if asm goto + SLH

2020-05-14 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. I don’t know what consequences is of using asm goto under SLH. In general, if asm-goto is not allowed, the diagnostic should be emitted during the parser. If asm-goto is not allowed under specified condition, the diagnostic should be emitted during sema. Diagnostic shoul

[PATCH] D79743: [clang][asm goto][slh] Warn if asm goto + SLH

2020-05-19 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. This looks good to me. Could you also add a test to use this new DiagGroup (-Wno-slh-asm-goto)? Thanks. Jennifer Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D79743/new/ https://reviews.llvm.org/D79743 _

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-06-29 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 441039. jyu2 added a comment. Thanks Alexey for the review. Add change in TreeTransform.h to rebuilt member expression. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D127803/new/ https://reviews.llvm.org/D127803 F

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-06-29 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 441257. jyu2 added a comment. Thanks Alexey for the review. This is to address Alexey's comments, CHANGES SINCE LAST ACTION https://reviews.llvm.org/D127803/new/ https://reviews.llvm.org/D127803 Files: clang/lib/Sema/SemaOpenMP.cpp clang/lib/Sema/Tree

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-06-30 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:17480 DeclRefExpr *Ref = nullptr; -if (!VD && !CurContext->isDependentContext()) - Ref = buildCapture(*this, D, SimpleRefExpr, /*WithInit=*/false); -DSAStack->addDSA(D, RefExpr->IgnoreParens()

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-06-30 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 441565. jyu2 added a comment. Thanks Alexey for the review. This patch to address his comment. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D127803/new/ https://reviews.llvm.org/D127803 Files: clang/include/cl

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-06-30 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:212 +}; +/// List of captuer fields +llvm::SmallVector ABataev wrote: > Captured? Fixed. Thanks. Comment at: clang/lib/Sema/TreeTransform.h:122 + /// the Rebuil

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-07-01 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:2273-2274 +bool Sema::isOpenMPRebuildMemberExpr(ValueDecl *D) { + if (getCurCapturedRegion() && + getCurCapturedRegion()->CapRegionKind == CR_OpenMP) { +DSAStackTy::DSAVarData DVarPrivate = DSAStack->

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-07-01 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaOpenMP.cpp:2273-2274 +bool Sema::isOpenMPRebuildMemberExpr(ValueDecl *D) { + if (getCurCapturedRegion() && + getCurCapturedRegion()->CapRegionKind == CR_OpenMP) { +DSAStackTy::DSAVarData DVarPrivate = DSAStack->

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-07-01 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 441765. jyu2 added a comment. Thank Alexey for the review. This is remove check for omp region just use hasDSA. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D127803/new/ https://reviews.llvm.org/D127803 Files:

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-07-01 Thread Jennifer Yu via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG927156a67445: Generate the capture for the field when the field is used in openmp (authored by jyu2). Repository: rG LLVM Github Monorepo CHANGES

[PATCH] D122338: [OPENMP] Eliminate extra set of simd variant function attribute.

2022-03-23 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 created this revision. jyu2 added reviewers: ABataev, mikerice. jyu2 added projects: OpenMP, clang. Herald added subscribers: guansong, yaxunl. Herald added a project: All. jyu2 requested review of this revision. Herald added a reviewer: jdoerfert. Herald added a subscriber: sstefan1. Current

[PATCH] D122338: [OPENMP] Eliminate extra set of simd variant function attribute.

2022-03-23 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In D122338#3403414 , @ABataev wrote: > If ParamPositions grows, it means that the item is not found. Is it correct > behavior if the compiler inserts new item in the ParamPositions map? I see. Thanks! Then it seems ParamPositions

[PATCH] D122338: [OPENMP] Eliminate extra set of simd variant function attribute.

2022-03-23 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 417746. jyu2 edited the summary of this revision. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122338/new/ https://reviews.llvm.org/D122338 Files: clang/lib/CodeGen/CGOpenMPRuntime.cpp clang/test/OpenMP/declare_simd_codegen.cpp Index: clang/test/

[PATCH] D122338: [OPENMP] Eliminate extra set of simd variant function attribute.

2022-03-24 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 417944. jyu2 added a comment. Address Alexey's comment. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122338/new/ https://reviews.llvm.org/D122338 Files: clang/lib/CodeGen/CGOpenMPRuntime.cpp clang/test/OpenM

[PATCH] D122338: [OPENMP] Eliminate extra set of simd variant function attribute.

2022-03-24 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 417981. jyu2 added a comment. Address Alexey comment. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122338/new/ https://reviews.llvm.org/D122338 Files: clang/lib/CodeGen/CGOpenMPRuntime.cpp clang/test/OpenMP/

[PATCH] D122338: [OPENMP] Eliminate extra set of simd variant function attribute.

2022-03-24 Thread Jennifer Yu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGa6cdac48ffaf: Eliminate extra set of simd variant function attribute. (authored by jyu2). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122338/new/ https://

[PATCH] D122338: [OPENMP] Eliminate extra set of simd variant function attribute.

2022-03-24 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In D122338#3405948 , @ABataev wrote: > LG Thank you so much Alexey. Comment at: clang/lib/CodeGen/CGOpenMPRuntime.cpp:11988 if (isa(E)) { Pos = ParamPositions[FD]; } else { --

[PATCH] D122852: [OPENMP] Fix assertion in clang::ASTContext::getTypeInfoImpl

2022-03-31 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 created this revision. jyu2 added reviewers: ABataev, jdoerfert, mikerice. jyu2 added a project: OpenMP. Herald added subscribers: guansong, yaxunl. Herald added a project: All. jyu2 requested review of this revision. Herald added a subscriber: sstefan1. The problem is when mapping of array s

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-08-02 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In D127803#3693301 , @mgabka wrote: > I noticed that this patch is causing now an assertion failure for cases like : > > class A{ > > void a() { > #pragma omp parallel > a(b); > } > > }; > > The failed assertion is: "cons

[PATCH] D127803: Generate the capture for field when the field is used in openmp region with implicit default in the member function.

2022-08-02 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In D127803#3693660 , @ABataev wrote: > In D127803#3693655 , @jyu2 wrote: > >> In D127803#3693301 , @mgabka wrote: >> >>> I noticed that this patch is

[PATCH] D131024: Fix assert in the call to isOpenMPRebuildMemberExpr

2022-08-02 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 created this revision. Herald added subscribers: guansong, yaxunl. Herald added a project: All. jyu2 requested review of this revision. Herald added a reviewer: jdoerfert. Herald added subscribers: cfe-commits, sstefan1. Herald added a project: clang. This is to fix https://github.com/llvm/ll

[PATCH] D131024: Fix assert in the call to isOpenMPRebuildMemberExpr

2022-08-03 Thread Jennifer Yu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGa7bca18bc50c: Fix assert during the call to getCanonicalDecl. (authored by jyu2). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131024/new/ https://reviews.

[PATCH] D107141: [Inline-asm] Add diagnosts for unsupported inline assembly arguments

2022-03-09 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaStmtAsm.cpp:679 + !llvm::isPowerOf2_32(OutSize)) +targetDiag(OutputExpr->getExprLoc(), diag::err_store_value_to_reg); + Error message is not very clear to me. I think we should create mo

[PATCH] D107141: [Inline-asm] Add diagnosts for unsupported inline assembly arguments

2022-03-10 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaStmtAsm.cpp:622 +if (InTy->isIntegerType() || InTy->isPointerType() || +InTy->isStructureType() || InTy->isConstantArrayType()) InputDomain = AD_Int; Are you sure you want to change the

[PATCH] D107141: [Inline-asm] Add diagnosts for unsupported inline assembly arguments

2022-03-21 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added inline comments. Comment at: clang/lib/Sema/SemaStmtAsm.cpp:622 +if (InTy->isIntegerType() || InTy->isPointerType() || +InTy->isStructureType() || InTy->isConstantArrayType()) InputDomain = AD_Int; pengfei wrote: > jyu2 wrote: > > Ar

[PATCH] D107141: [Inline-asm] Add diagnosts for unsupported inline assembly arguments

2022-03-22 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 accepted this revision. jyu2 added a comment. This revision is now accepted and ready to land. This is okay with me. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D107141/new/ https://reviews.llvm.org/D107141 __

[PATCH] D123402: [clang][OpenMP5.1] Initial parsing/sema for has_device_addr

2022-04-08 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 created this revision. jyu2 added reviewers: ABataev, mikerice, jdoerfert. jyu2 added projects: clang, OpenMP. Herald added subscribers: arphaman, guansong, yaxunl. Herald added a reviewer: sscalpone. Herald added projects: Flang, All. jyu2 requested review of this revision. Herald added subsc

[PATCH] D123402: [clang][OpenMP5.1] Initial parsing/sema for has_device_addr

2022-04-08 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 421637. jyu2 added a comment. Thanks Alexey, for the review! This patch addresses his comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D123402/new/ https://reviews.llvm.org/D123402 Files: clang/include/c

[PATCH] D123402: [clang][OpenMP5.1] Initial parsing/sema for has_device_addr

2022-04-08 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 421639. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D123402/new/ https://reviews.llvm.org/D123402 Files: clang/include/clang/AST/OpenMPClause.h clang/include/clang/AST/RecursiveASTVisitor.h clang/include/cla

[PATCH] D123402: [clang][OpenMP5.1] Initial parsing/sema for has_device_addr

2022-04-08 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 421657. jyu2 added a comment. Add test in cfg-openmp.cpp Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D123402/new/ https://reviews.llvm.org/D123402 Files: clang/include/clang/AST/OpenMPClause.h clang/include/

  1   2   3   4   >