[PATCH] D97915: [Coroutines] Handle overaligned frame allocation

2021-05-11 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen updated this revision to Diff 344602. ychen added a comment. - Rebase on updated D102145 (use `llvm.coro.raw.frame.ptr.addr` during allocation) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97915/new/ https

[PATCH] D97915: [Coroutines] Handle overaligned frame allocation

2021-05-11 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. In D97915#2747142 , @ChuanqiXu wrote: >> which should be correct. It is implemented by >> CodeGenFunction::EmitBuiltinAlignTo. > > I agree it is correct. I just want to say we should comment it to avoid > confusing. Happy to do it

[PATCH] D102147: [Clang][Coroutines] Implement P2014R0 Option 1 behind -fcoroutines-aligned-alloc

2021-05-11 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen updated this revision to Diff 344609. ychen added a comment. - rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102147/new/ https://reviews.llvm.org/D102147 Files: clang/docs/ClangCommandLineReference.rst clang/include/clang/Basic/Bu

[PATCH] D113146: [Sema] Fix the assertion in Sema::ActOnDependentMemberExpr

2022-01-04 Thread Yuanfang Chen 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 rGe902ffe6d756: [Sema] Fix the assertion in Sema::ActOnDependentMemberExpr (authored by ychen). Repository: rG LLVM Github Monorepo CHANGES SINCE L

[PATCH] D113146: [Sema] Fix the assertion in Sema::ActOnDependentMemberExpr

2022-01-04 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. Richard seems very busy. I just committed this based on Aaron's LGTM. Richard could still review this at any time. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113146/new/ https://reviews.llvm.org/D113146 _

[PATCH] D55134: [CTU] Add triple/lang mismatch handling

2022-01-05 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. Herald added a reviewer: Szelethus. Herald added a subscriber: steakhal. FWIW, ASTUnit seems to save an effective triple while the current AST uses the nominal triple. (for example, `armv7a-xx-xx-eabihf` vs `armv7a-xx-xx-eabi`). I'm not sure if there is a good solution oth

[PATCH] D114728: [Coroutine] Remove the prologue data of `-fsanitize=function` for split functions

2021-12-09 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. In D114728#3159303 , @rjmccall wrote: > I agree that coroutine resumption functions have a different formal type from > the ramp function and so would need different treatment from > `-fsanitize=functions` if it wants to sanitize

[PATCH] D113146: [Sema] Fix the assertion in Sema::ActOnDependentMemberExpr

2021-12-10 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113146/new/ https://reviews.llvm.org/D113146 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-b

[PATCH] D113245: [Sema] Mark explicit specialization declaration in a friend invalid

2021-12-14 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. ping:-) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113245/new/ https://reviews.llvm.org/D113245 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cg

[PATCH] D113245: [Sema] Mark explicit specialization declaration in a friend invalid

2021-12-14 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. Hi @aaron.ballman, does this make sense to you? Thanks. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113245/new/ https://reviews.llvm.org/D113245 ___ cfe-commits mailing list cfe-

[PATCH] D113245: [Sema] Mark explicit specialization declaration in a friend invalid

2021-12-14 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen updated this revision to Diff 394351. ychen added a comment. - Address Aaron's comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113245/new/ https://reviews.llvm.org/D113245 Files: clang/lib/Sema/SemaDecl.cpp clang/test/CXX/temp/te

[PATCH] D113245: [Sema] Mark explicit specialization declaration in a friend invalid

2021-12-14 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen updated this revision to Diff 394352. ychen added a comment. - format Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113245/new/ https://reviews.llvm.org/D113245 Files: clang/lib/Sema/SemaDecl.cpp clang/test/CXX/temp/temp.spec/temp.expl.s

[PATCH] D113245: [Sema] Mark explicit specialization declaration in a friend invalid

2021-12-15 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. @aaron.ballman Thanks for the review! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113245/new/ https://reviews.llvm.org/D113245 ___ cfe-commits mailing list cfe-commits@lists.llvm

[PATCH] D113245: [Sema] Mark explicit specialization declaration in a friend invalid

2021-12-15 Thread Yuanfang Chen 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 rG1510595dce9c: [Sema] Mark explicit specialization declaration in a friend invalid (authored by ychen). Repository: rG LLVM Github Monorepo CHANGE

[PATCH] D113146: [Sema] Fix the assertion in Sema::ActOnDependentMemberExpr

2021-12-15 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. @aaron.ballman Thanks for taking a look! Yep, I'll wait. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113146/new/ https://reviews.llvm.org/D113146 ___ cfe-commits mailing list cfe

[PATCH] D115844: [ubsan] Using metadata instead of prologue data for function sanitizer

2021-12-15 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen created this revision. ychen added reviewers: pcc, vsk, rjmccall. Herald added subscribers: dexonsmith, hiraditya. ychen requested review of this revision. Herald added projects: clang, LLVM. Herald added subscribers: llvm-commits, cfe-commits. Information in the function `Prologue Data` is

[PATCH] D114728: [Coroutine] Remove the prologue data of `-fsanitize=function` for split functions

2021-12-15 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. In D114728#3196591 , @rjmccall wrote: > I don't have a strong opinion about attribute vs. metadata; if metadata are > the best technical path forward, that's fine with me. I don't think function > metadata can be "lost" the same

[PATCH] D98110: [NFC][clangd] Use table to collect option aliases

2021-03-16 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. Herald added a project: clang-tools-extra. ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D98110/new/ https://reviews.llvm.org/D98110 ___ cfe-commits mailing list cfe-commits@li

[PATCH] D97831: [Clang][Sema] Implement GCC -Wcast-function-type

2021-03-16 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. ping. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97831/new/ https://reviews.llvm.org/D97831 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bi

[PATCH] D97915: [Coroutines] Handle overaligned frame allocation

2021-03-17 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. In D97915#2632493 , @lxfind wrote: > I am not sure how this would work, maybe I am missing something. > But this patch tries to round up the frame pointer by looking at the > difference between the alignment of new and the alignment

[PATCH] D97831: [Clang][Sema] Implement GCC -Wcast-function-type

2021-03-22 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen updated this revision to Diff 332384. ychen added a comment. - update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97831/new/ https://reviews.llvm.org/D97831 Files: clang/docs/DiagnosticsReference.rst clang/include/clang/Basic/Diagnosti

[PATCH] D97831: [Clang][Sema] Implement GCC -Wcast-function-type

2021-03-23 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97831/new/ https://reviews.llvm.org/D97831 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin

[PATCH] D97831: [Clang][Sema] Implement GCC -Wcast-function-type

2021-03-23 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen updated this revision to Diff 332840. ychen marked 3 inline comments as done. ychen added a comment. - Add code/tests for `function -> function pointer` and `block pointer -> function pointer`. - Use Context.hasSameUnqualifiedType - Style Repository: rG LLVM Github Monorepo CHANGES SIN

[PATCH] D97831: [Clang][Sema] Implement GCC -Wcast-function-type

2021-03-23 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added inline comments. Comment at: clang/lib/Sema/SemaCast.cpp:1044-1048 + // Allow integral type mismatch if their size are equal. + if (SrcType->isIntegralType(Context) && DestType->isIntegralType(Context)) +if (Context.getTypeInfoInChars(SrcType).Width == +

[PATCH] D97831: [Clang][Sema] Implement GCC -Wcast-function-type

2021-03-24 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. Thanks for the insightful suggestions. I'll definitely send a follow-up patch for these (pointerLike arguments, TargetInfo refactoring, promotable integral types). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97831/new/ ht

[PATCH] D97831: [Clang][Sema] Implement GCC -Wcast-function-type

2021-03-24 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen updated this revision to Diff 333162. ychen added a comment. - update doc to match diagnostics Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97831/new/ https://reviews.llvm.org/D97831 Files: clang/docs/DiagnosticsReference.rst clang/incl

[PATCH] D97831: [Clang][Sema] Implement GCC -Wcast-function-type

2021-03-24 Thread Yuanfang Chen 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 rG217f0f735afe: [Clang][Sema] Implement GCC -Wcast-function-type (authored by ychen). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D99903: [Clang][Sema] better -Wcast-function-type diagnose for pointer parameters and parameters with cv-qualifiers

2021-04-05 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen created this revision. ychen added a reviewer: rsmith. ychen requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. 1. Skip diagnosing all pointer-like parameters. 2. Replace `Context.hasSameUnqualifiedType` with `Context.hasSimilarType`. 3.

[PATCH] D99903: [Clang][Sema] better -Wcast-function-type diagnose for pointer parameters and parameters with cv-qualifiers

2021-04-12 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. ping.. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99903/new/ https://reviews.llvm.org/D99903 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-b

[PATCH] D100282: [Coroutines] Set presplit attribute in Clang instead of CoroEarly pass

2021-04-13 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. I think the setting is in CoroEarly from the beginning is that it is an implementation detail? Clients should only worry about coroutine shape. Maybe we could set `noinline` in frontends to express the intent and remove it in coroearly/corosplit? Repository: rG LLVM

[PATCH] D100739: [Coroutines] Handle overaligned frame allocation (2)

2021-04-18 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen created this revision. ychen added reviewers: rjmccall, lxfind, ChuanqiXu. Herald added a subscriber: hiraditya. ychen requested review of this revision. Herald added subscribers: llvm-commits, cfe-commits, jdoerfert. Herald added projects: clang, LLVM. This is an alternative to D97915

[PATCH] D100739: [Coroutines] Handle overaligned frame allocation (2)

2021-04-18 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen updated this revision to Diff 338430. ychen added a comment. fix comment Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100739/new/ https://reviews.llvm.org/D100739 Files: clang/docs/LanguageExtensions.rst clang/include/clang/Basic/Builti

[PATCH] D100739: [Coroutines] Handle overaligned frame allocation (2)

2021-04-18 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen updated this revision to Diff 338431. ychen added a comment. Fix comment. Ready for review. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100739/new/ https://reviews.llvm.org/D100739 Files: clang/docs/LanguageExtensions.rst clang/include

[PATCH] D100739: [Coroutines] Handle overaligned frame allocation (2)

2021-04-19 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. In D100739#2700273 , @ChuanqiXu wrote: > I hadn't looked into the details. I would try to make it. > But from my understanding to this problem, the correct solution should remain > the previous behavior if the end user doesn't spec

[PATCH] D100739: [Coroutines] Handle overaligned frame allocation (2)

2021-04-20 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added inline comments. Comment at: clang/docs/LanguageExtensions.rst:2689 - size_t __builtin_coro_size() + size_t __builtin_coro_size(bool alloc) void *__builtin_coro_frame() lxfind wrote: > Do we need to change __builtin_coro_size? The argument wil

[PATCH] D100739: [Coroutines] Handle overaligned frame allocation (2)

2021-04-20 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added inline comments. Comment at: clang/docs/LanguageExtensions.rst:2689 - size_t __builtin_coro_size() + size_t __builtin_coro_size(bool alloc) void *__builtin_coro_frame() ChuanqiXu wrote: > ychen wrote: > > lxfind wrote: > > > Do we need to chan

[PATCH] D58751: Order File Instrumentation: add clang support for -forder-file-instrumentation

2021-10-14 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. Herald added a subscriber: dang. In D58751#1417467 , @manmanren wrote: > r355333 Hello, thanks for this nice feature. Are there any docs on how to use it? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.or

[PATCH] D112353: [bazel] fixes for windows build

2021-10-22 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen created this revision. ychen added a reviewer: GMNGeoffrey. ychen requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Giving Bazel a try on Win10 by following the README. It needs these fixes to build through. Think that I should sent it

[PATCH] D112353: [bazel] fixes for windows build

2021-10-25 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added inline comments. Comment at: utils/bazel/llvm-project-overlay/llvm/config.bzl:63 # MSVC specific -"stricmp=_stricmp", -"strdup=_strdup", +#"stricmp=_stricmp", +#"strdup=_strdup", GMNGeoffrey wrote: > Just commenting these out isn'

[PATCH] D102531: PR45881: Properly use CXXThisOverride for templated lambda

2021-09-07 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. In D102531#2987367 , @gulfem wrote: > Any update on this review? Our builds are still broken. I'll commit this by the end of the day if @rsmith wasn't able to take a look. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[PATCH] D102531: PR45881: Properly use CXXThisOverride for templated lambda

2021-09-07 Thread Yuanfang Chen via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG61d1cce2f835: PR45881: Properly use CXXThisOverride for templated lambda (authored by ychen). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102531/new/ http

[PATCH] D103938: Diagnose -Wunused-value in constant evaluation context

2021-09-07 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen updated this revision to Diff 371221. ychen added a comment. Herald added a subscriber: jdoerfert. - Use more specific diagnoses "left operand of comma operator has no effect" when left operand of comma operator has no effect instead of "expression result is unused". Repository: rG LL

[PATCH] D103938: Diagnose -Wunused-value in constant evaluation context

2021-09-07 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added inline comments. Comment at: clang/test/Sema/i-c-e.c:77-78 + // expected-warning {{expression result unused}} +int comma3[(1, 2)]; // expected-warning {{variable length array folded to constant array as an extension}} \ + /

<    2   3   4   5   6   7