[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-11-10 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu added inline comments. Comment at: clang/lib/CodeGen/CoverageMappingGen.cpp:607 +// compiler has broken. +assert((!StartLoc || StartLoc->isValid()) && "Start location is not valid"); +assert((!EndLoc || EndLoc->isValid()) && "End location is not valid");

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-11-09 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang/lib/CodeGen/CoverageMappingGen.cpp:607 +// compiler has broken. +assert((!StartLoc || StartLoc->isValid()) && "Start location is not valid"); +assert((!EndLoc || EndLoc->isValid()) && "End location is not valid");

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-13 Thread Zequan Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG0529da5b948c: [Coverage] Handle invalid end location of an expression/statement. (authored by zequanwu). Changed prior to commit: https://reviews.llvm.org/D147073?vs=512971=513236#toc Repository: rG

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-13 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. LGTM! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147073/new/ https://reviews.llvm.org/D147073 ___ cfe-commits mailing list

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-12 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu updated this revision to Diff 512971. zequanwu edited the summary of this revision. zequanwu added a comment. - Filed an github issue: - Added release note. - Updated commit message and summary. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-12 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Thank you! I think there's only a few small things left then: - Add a release note about the fact that we worked around this issue in non-asserts builds but that assert builds may see new assertions triggered from this and to file an issue with a reproducer if

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-12 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu updated this revision to Diff 512868. zequanwu added a comment. Add assertion on source locations in `pushRegion`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147073/new/ https://reviews.llvm.org/D147073 Files:

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-12 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D147073#4261633 , @zequanwu wrote: > In D147073#4258981 , @aaron.ballman > wrote: > >> Perhaps a way to split the middle would be to assert that the source >> locations are

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-12 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu added a comment. In D147073#4258981 , @aaron.ballman wrote: > In D147073#4258664 , @zequanwu > wrote: > >> In D147073#4258529 , >> @aaron.ballman wrote: >>

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D147073#4258664 , @zequanwu wrote: > In D147073#4258529 , @aaron.ballman > wrote: > >> In D147073#4258426 , @zequanwu >> wrote: >> >>>

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-11 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu added a comment. In D147073#4258529 , @aaron.ballman wrote: > In D147073#4258426 , @zequanwu > wrote: > >> In D147073#4258396 , >> @aaron.ballman wrote: >>

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D147073#4258426 , @zequanwu wrote: > In D147073#4258396 , @aaron.ballman > wrote: > >> In D147073#4258384 , @hans wrote: >> >>> Again

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-11 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu added a comment. In D147073#4258396 , @aaron.ballman wrote: > In D147073#4258384 , @hans wrote: > >> Again not an expert here, but lgtm. >> >> (Nit: the >>

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D147073#4258384 , @hans wrote: > Again not an expert here, but lgtm. > > (Nit: the > https://github.com/llvm/llvm-project/blob/main/clang/lib/Sema/SemaExprCXX.cpp#L1528-L1530 > link in the description seems to point to

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-11 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. Again not an expert here, but lgtm. (Nit: the https://github.com/llvm/llvm-project/blob/main/clang/lib/Sema/SemaExprCXX.cpp#L1528-L1530 link in the description seems to point to the wrong code

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-04 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu updated this revision to Diff 510938. zequanwu added a comment. Split to another patch: D147569 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147073/new/ https://reviews.llvm.org/D147073 Files:

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-04 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D147073#4242566 , @hans wrote: > In D147073#4240793 , @zequanwu > wrote: > >> In D147073#4240017 , @hans wrote: >> >>> I'm not familiar

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-04 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. In D147073#4240793 , @zequanwu wrote: > In D147073#4240017 , @hans wrote: > >> I'm not familiar with this code. I suppose the question is whether it's >> reasonable for this code to expect

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-03 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu updated this revision to Diff 510514. zequanwu added a comment. Address comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147073/new/ https://reviews.llvm.org/D147073 Files: clang/lib/CodeGen/CoverageMappingGen.cpp

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-03 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu marked an inline comment as done. zequanwu added a comment. In D147073#4240017 , @hans wrote: > I'm not familiar with this code. I suppose the question is whether it's > reasonable for this code to expect that the source locations are always

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-04-03 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. I'm not familiar with this code. I suppose the question is whether it's reasonable for this code to expect that the source locations are always valid or not? Comment at: clang/lib/CodeGen/CoverageMappingGen.cpp:605 +// If the either location is

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-03-30 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu updated this revision to Diff 509802. zequanwu added a comment. Add test case from https://github.com/llvm/llvm-project/issues/45481#issuecomment-981028897. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147073/new/

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-03-30 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment. In D147073#4228290 , @zequanwu wrote: > I'm trying to add the test case from: > https://github.com/llvm/llvm-project/issues/45481#issuecomment-981028897, but > lit test fails in `` not found. You can just define your own

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-03-28 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu added a comment. I'm trying to add the test case from: https://github.com/llvm/llvm-project/issues/45481#issuecomment-981028897, but lit test fails in `` not found. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147073/new/

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-03-28 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu updated this revision to Diff 509098. zequanwu added a comment. - Handle invalid start location. - Add a test case. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D147073/new/ https://reviews.llvm.org/D147073 Files:

[PATCH] D147073: [Coverage] Handle invalid end location of an expression/statement.

2023-03-28 Thread Zequan Wu via Phabricator via cfe-commits
zequanwu created this revision. zequanwu added reviewers: hans, shafik, rsmith, MaggieYi, gulfem. Herald added a project: All. zequanwu requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. https://github.com/llvm/llvm-project/issues/45481