[clang] [Clang] Implement C++26 P2748R5 "Disallow Binding a Returned Glvalue to a Temporary" (PR #89942)

2024-04-25 Thread via cfe-commits
https://github.com/yronglin updated https://github.com/llvm/llvm-project/pull/89942 >From 8c5f1d0f92d77bffec88759c19133a0bac130f32 Mon Sep 17 00:00:00 2001 From: yronglin Date: Wed, 24 Apr 2024 23:36:10 +0800 Subject: [PATCH 1/6] [Clang] Implement P2748R5 "Disallow Binding a Returned Glvalue

[clang] [Clang][CodeGen] Segfault when compiling weird code (PR #90165)

2024-04-25 Thread Tim Pham via cfe-commits
https://github.com/timmyhoa edited https://github.com/llvm/llvm-project/pull/90165 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][CodeGen] Segfault when compiling weird code (PR #90165)

2024-04-25 Thread Tim Pham via cfe-commits
https://github.com/timmyhoa edited https://github.com/llvm/llvm-project/pull/90165 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Implement C++26 P2748R5 "Disallow Binding a Returned Glvalue to a Temporary" (PR #89942)

2024-04-25 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff 21ef187654c819fd097171afcc6c9855dccdb36d 0ee6abe93159a29052af3ef9befff6a7e029eb31 --

[clang] [Clang] Implement C++26 P2748R5 "Disallow Binding a Returned Glvalue to a Temporary" (PR #89942)

2024-04-25 Thread via cfe-commits
https://github.com/yronglin updated https://github.com/llvm/llvm-project/pull/89942 >From 8c5f1d0f92d77bffec88759c19133a0bac130f32 Mon Sep 17 00:00:00 2001 From: yronglin Date: Wed, 24 Apr 2024 23:36:10 +0800 Subject: [PATCH 1/3] [Clang] Implement P2748R5 "Disallow Binding a Returned Glvalue

[clang] [Clang][CodeGen] Segfault when compiling weird code (PR #90165)

2024-04-25 Thread Tim Pham via cfe-commits
https://github.com/timmyhoa edited https://github.com/llvm/llvm-project/pull/90165 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][CodeGen] Segfault when compiling weird code (PR #90165)

2024-04-25 Thread Tim Pham via cfe-commits
https://github.com/timmyhoa converted_to_draft https://github.com/llvm/llvm-project/pull/90165 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][CodeGen] Segfault when compiling weird code (PR #90165)

2024-04-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: Tim Pham (timmyhoa) Changes Closes #88917 Do I really know what is going on? Nope. Do I know what the bug is? Enough to fix it (hopefully) :) I'm just a beginner so sorry for any obvious mistake. --- Full diff:

[clang] [clang] MangledSymbol: remove pointless copy of vector (PR #90012)

2024-04-25 Thread Andrew Sukach via cfe-commits
https://github.com/soukatch updated https://github.com/llvm/llvm-project/pull/90012 >From 9007597af4f138d2744405bb7980fce4555d7508 Mon Sep 17 00:00:00 2001 From: Andrew Sukach Date: Wed, 24 Apr 2024 22:50:50 -0400 Subject: [PATCH 1/2] [clang] MangledSymbol: remove pointless copy of vector ---

[clang] [Clang][CodeGen] Segfault when compiling weird code (PR #90165)

2024-04-25 Thread via cfe-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you,

[clang] [Clang][CodeGen] Segfault when compiling weird code (PR #90165)

2024-04-25 Thread Tim Pham via cfe-commits
https://github.com/timmyhoa created https://github.com/llvm/llvm-project/pull/90165 Closes #88917 Do I really know what is going on? Nope. Do I know what the bug is? Enough to fix it (hopefully) :) I'm just a beginner so sorry for any obvious mistake. >From

[clang] [clang] MangledSymbol: remove pointless copy of vector (PR #90012)

2024-04-25 Thread Andrew Sukach via cfe-commits
https://github.com/soukatch updated https://github.com/llvm/llvm-project/pull/90012 >From 9007597af4f138d2744405bb7980fce4555d7508 Mon Sep 17 00:00:00 2001 From: Andrew Sukach Date: Wed, 24 Apr 2024 22:50:50 -0400 Subject: [PATCH] [clang] MangledSymbol: remove pointless copy of vector ---

[clang] [clang] MangledSymbol: remove pointless copy of vector (PR #90012)

2024-04-25 Thread Andrew Sukach via cfe-commits
https://github.com/soukatch updated https://github.com/llvm/llvm-project/pull/90012 >From b8e20a5a3e37ab9a657ac640b848f638387215fa Mon Sep 17 00:00:00 2001 From: Andrew Sukach Date: Wed, 24 Apr 2024 22:50:50 -0400 Subject: [PATCH 1/2] [clang] MangledSymbol: remove pointless copy of vector ---

[clang] [clang-tools-extra] [PAC][clang] Define `PointerAuthQualifier` and `PointerAuthenticationMode` (PR #84384)

2024-04-25 Thread Daniil Kovalev via cfe-commits
https://github.com/kovdan01 closed https://github.com/llvm/llvm-project/pull/84384 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] f4efa06 - [PAC][clang] Define `PointerAuthQualifier` and `PointerAuthenticationMode` (#84384)

2024-04-25 Thread via cfe-commits
Author: Daniil Kovalev Date: 2024-04-26T08:26:15+03:00 New Revision: f4efa067435c8137718c907bf0de2b891b76552d URL: https://github.com/llvm/llvm-project/commit/f4efa067435c8137718c907bf0de2b891b76552d DIFF:

[clang] [clang] MangledSymbol: remove pointless copy of vector (PR #90012)

2024-04-25 Thread Shafik Yaghmour via cfe-commits
shafik wrote: > Looking at the logs, and the error seems to be unrelated to the changes made > https://buildkite.com/llvm-project/clang-ci/builds/16430#018f132d-506e-440c-b18b-fed98237def9/54-5446 You can try using `--allow-empty` to do an empty commit to kick off the build again.

[clang] [llvm] [RISCV] Teach .option arch to support experimental extensions. (PR #89727)

2024-04-25 Thread Yeting Kuo via cfe-commits
yetingk wrote: I fix the issue by using feature to control the permission of experimental extension. > Does this disable use of experimental extensions for a `.option arch` in an > inline assembly block without -menable-experimental-extensions.

[clang] Notifying assume directive as 'worked on'. (PR #90022)

2024-04-25 Thread Sandeep Kosuri via cfe-commits
https://github.com/sandeepkosuri closed https://github.com/llvm/llvm-project/pull/90022 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 4b25508 - Notifying assume directive as 'worked on'. (#90022)

2024-04-25 Thread via cfe-commits
Author: SunilKuravinakop Date: 2024-04-26T10:31:55+05:30 New Revision: 4b255085833b58392d7699aaf5c20ea49559fda9 URL: https://github.com/llvm/llvm-project/commit/4b255085833b58392d7699aaf5c20ea49559fda9 DIFF:

[clang] [llvm] [RISCV] Teach .option arch to support experimental extensions. (PR #89727)

2024-04-25 Thread Yeting Kuo via cfe-commits
https://github.com/yetingk updated https://github.com/llvm/llvm-project/pull/89727 >From a43014cf3daa1b0fd9092bfe41da979205ba64aa Mon Sep 17 00:00:00 2001 From: Yeting Kuo Date: Tue, 23 Apr 2024 02:16:04 -0700 Subject: [PATCH 1/4] [RISCV] Teach .option arch to support experimental extensions.

[clang] [compiler-rt] [llvm] [ConstantFolding] Canonicalize constexpr GEPs to i8 (PR #89872)

2024-04-25 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff d26002ac38ee1dea32053e7d12f1bb5dc420ac2d 2fa7299db558c2a953f641ffe760369f31a98b3d --

[clang] [clang][Sema] Improve error recovery for id-expressions referencing invalid decls (PR #81662)

2024-04-25 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Here is a reduced testcase for the OpenMP test failure: ```c++ #pragma omp declare target static long double ld_return1e() { return 0; } void external() { void *p1 = reinterpret_cast(_return1e); } #pragma omp end declare target ``` When built with the following

[clang] [clang] pointer to member with qualified-id enclosed in parentheses in unevaluated context should be invalid (PR #89713)

2024-04-25 Thread via cfe-commits
@@ -27,3 +26,20 @@ namespace rdar10544564 { X (Y::*func_mem_ptr1)() = ::memfunc1; X (Y::*func_mem_ptr2)() = ::memfunc2; } + +namespace test2 { + struct A { +int val; +void func() {} + }; + + void test() { +decltype(&(A::val)) ptr1; // expected-error

[clang] [llvm] [RISCV] Add processor definition for XiangShan-KunMingHu (PR #89359)

2024-04-25 Thread via cfe-commits
https://github.com/Khao7342 updated https://github.com/llvm/llvm-project/pull/89359 >From e51498e67409836b099fa892b17d71e44a7d403b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=83=9D=E5=BA=B7=E8=BE=BE?= Date: Fri, 19 Apr 2024 17:18:10 +0800 Subject: [PATCH] [RISCV] Add processor definition for

[clang] [clang-format] Do not update cursor pos if no includes replacement (PR #77456)

2024-04-25 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/77456 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 2de0bed - [clang-format] Do not update cursor pos if no includes replacement (#77456)

2024-04-25 Thread via cfe-commits
Author: NorthBlue333 Date: 2024-04-25T20:34:49-07:00 New Revision: 2de0bedfebb77a6c8a5b0d00902f796fa4022fd6 URL: https://github.com/llvm/llvm-project/commit/2de0bedfebb77a6c8a5b0d00902f796fa4022fd6 DIFF: https://github.com/llvm/llvm-project/commit/2de0bedfebb77a6c8a5b0d00902f796fa4022fd6.diff

[clang] [clang] MangledSymbol: remove pointless copy of vector (PR #90012)

2024-04-25 Thread Andrew Sukach via cfe-commits
soukatch wrote: Looking at the logs, and the error seems to be unrelated to the changes made https://buildkite.com/llvm-project/clang-ci/builds/16430#018f132d-506e-440c-b18b-fed98237def9/54-5446 https://github.com/llvm/llvm-project/pull/90012 ___

[clang] [clang-format] Add a space after a word token only if required (PR #90161)

2024-04-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes Fixes #78166. --- Full diff: https://github.com/llvm/llvm-project/pull/90161.diff 2 Files Affected: - (modified) clang/lib/Format/TokenAnnotator.cpp (+7-19) - (modified)

[clang] [clang-format] Add a space after a word token only if required (PR #90161)

2024-04-25 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/90161 Fixes #78166. >From 3f59076142bd6a87f4875dc79e95e4570f4af7c2 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Thu, 25 Apr 2024 20:08:03 -0700 Subject: [PATCH] [clang-format] Add a space after a word token only if

[clang] [clang-tools-extra] [clangd] Show struct fields and enum members in hovers (PR #89557)

2024-04-25 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > I'm planning to revise the patch to make the following changes: > >1. Put the new behaviour behind a config option (I'm thinking `Hover` --> > `ShowFields`) >2. Add C language mode tests >3. Use `PrintingCallbacks` instead of a `PrintingPolicy` flag These

[clang] [clang-tools-extra] [clangd] Show struct fields and enum members in hovers (PR #89557)

2024-04-25 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 ready_for_review https://github.com/llvm/llvm-project/pull/89557 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clangd] Show struct fields and enum members in hovers (PR #89557)

2024-04-25 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/89557 >From fcb2ac4c68554d9c708b3db779b5570ff94725e8 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Sun, 21 Apr 2024 20:30:16 -0400 Subject: [PATCH] [clangd] Show struct fields and enum members in hovers

[clang] [Clang][C++23] Core language changes from P1467R9 extended floating-point types and standard names. (PR #78503)

2024-04-25 Thread M. Zeeshan Siddiqui via cfe-commits
codemzs wrote: > @codemzs Any news? Thanks a lot for your work! @cor3ntin Sorry for the delay, I plan to get back to this PR in the next few weeks. Do you need this change for something? https://github.com/llvm/llvm-project/pull/78503 ___

[clang] [CUDA] make kernel stub ICF-proof (PR #90155)

2024-04-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: Yaxun (Sam) Liu (yxsamliu) Changes MSVC linker merges functions having comdat which have identical set of instructions. CUDA uses kernel stub function as key to look up kernels in device executables. If kernel stub function for

[clang] [CUDA] make kernel stub ICF-proof (PR #90155)

2024-04-25 Thread Yaxun Liu via cfe-commits
https://github.com/yxsamliu created https://github.com/llvm/llvm-project/pull/90155 MSVC linker merges functions having comdat which have identical set of instructions. CUDA uses kernel stub function as key to look up kernels in device executables. If kernel stub function for different

[clang] [alpha.webkit.UncountedCallArgsChecker] Avoid emitting warnings for Ref, RefPtr, and their variants. (PR #90153)

2024-04-25 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/90153 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Improve documented sampling profiler steps to best known methods (PR #88438)

2024-04-25 Thread Tim Creech via cfe-commits
https://github.com/tcreech-intel updated https://github.com/llvm/llvm-project/pull/88438 >From fe3404cbdf78b434f16f8351dc242175b4543112 Mon Sep 17 00:00:00 2001 From: Tim Creech Date: Thu, 11 Apr 2024 16:03:52 -0400 Subject: [PATCH 1/3] Improve documented sampling profiler steps to best known

[clang] [clang-format] adds a space after not inside macros (PR #78176)

2024-04-25 Thread Owen Pan via cfe-commits
https://github.com/owenca unassigned https://github.com/llvm/llvm-project/pull/78176 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [SCCP] Swap out range metadata to range attribute (PR #90134)

2024-04-25 Thread Nikita Popov via cfe-commits
https://github.com/nikic closed https://github.com/llvm/llvm-project/pull/90134 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 93de97d - [SCCP] Swap out range metadata to range attribute (#90134)

2024-04-25 Thread via cfe-commits
Author: Andreas Jonson Date: 2024-04-26T11:04:47+09:00 New Revision: 93de97d750548cd90c53efd4367dbd0367aa30fd URL: https://github.com/llvm/llvm-project/commit/93de97d750548cd90c53efd4367dbd0367aa30fd DIFF:

[clang] [llvm] [SCCP] Swap out range metadata to range attribute (PR #90134)

2024-04-25 Thread Nikita Popov via cfe-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/90134 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Implement C++26 P2748R5 "Disallow Binding a Returned Glvalue to a Temporary" (PR #89942)

2024-04-25 Thread A. Jiang via cfe-commits
@@ -8340,8 +8340,17 @@ void Sema::checkInitializerLifetime(const InitializedEntity , << Entity.getType()->isReferenceType() << CLE->getInitializer() << 2 << DiagRange; } else { -Diag(DiagLoc, diag::warn_ret_local_temp_addr_ref) -

[clang] [Driver] Don't default to -mrelax-all for non-RISCV -O0 (PR #90013)

2024-04-25 Thread Nikita Popov via cfe-commits
nikic wrote: FYI I'm seeing about 0.6% compile-time regressions for `O0` test-suite builds with this change (https://llvm-compile-time-tracker.com/compare.php?from=ef2ca97f48f1aee1483f0c29de5ba52979bec454=18376810f359dbd39d2a0aa0ddfc0f7f50eac199=instructions:u). Though there is also a 4.5%

[clang] [alpha.webkit.UncountedCallArgsChecker] Avoid emitting warnings for Ref, RefPtr, and their variants. (PR #90153)

2024-04-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-static-analyzer-1 @llvm/pr-subscribers-clang Author: Ryosuke Niwa (rniwa) Changes Skip the analysis of Ref, RefPtr, and their variant classes in UncountedCallArgsChecker since these classes are "trusted" to not do anything dangerous. --- Full

[clang] [clang-tools-extra] [Clang][Sema] Diagnose class member access expressions naming non-existent members of the current instantiation prior to instantiation in the absence of dependent base clas

2024-04-25 Thread Nikita Popov via cfe-commits
nikic wrote: FYI this change has some visible compile-time impact, with some 0.5-1% regressions on various LLVM files

[clang] [alpha.webkit.UncountedCallArgsChecker] Avoid emitting warnings for Ref, RefPtr, and their variants. (PR #90153)

2024-04-25 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa created https://github.com/llvm/llvm-project/pull/90153 Skip the analysis of Ref, RefPtr, and their variant classes in UncountedCallArgsChecker since these classes are "trusted" to not do anything dangerous. >From 04d9b292a48604ec0601e869d48d4f2c481f91bc Mon Sep 17

[clang] [flang] [lld] [flang] Generate main only when a Fortran program statement is present (PR #89938)

2024-04-25 Thread David Truby via cfe-commits
DavidTruby wrote: As regards the backwards compatibility break here, I guess my take is that this change needs to happen some time and sooner is always going to be better than later. While we are still called flang-new and marked experimental I'm inclined to think we should just rip the band

[clang] [flang] [lld] [flang] Generate main only when a Fortran program statement is present (PR #89938)

2024-04-25 Thread David Truby via cfe-commits
DavidTruby wrote: > Great work David, thanks! Could you add some documentation explaining _where_ > `main` would be coming from in the case of mixed-source compilation? In fact, > is that tested anywhere? > > Also, IMHO it would be good to advertise this on Discourse (thinking > specifically

[clang] [clang][CodeGen] fix UB in aarch64 bfloat16 scalar conversion (PR #89062)

2024-04-25 Thread via cfe-commits
nihui wrote: @ostannard hi, would you please review my fix :) https://github.com/llvm/llvm-project/pull/89062 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][HLSL] Add environment parameter to availability attribute (PR #89809)

2024-04-25 Thread Helena Kotas via cfe-commits
@@ -3859,7 +3862,7 @@ def warn_availability_fuchsia_unavailable_minor : Warning< InGroup; def warn_unguarded_availability : - Warning<"%0 is only available on %1 %2 or newer">, + Warning<"%0 %select{is only|is not}5 available %select{|in %4 environment }3on %1 %2

[clang] [Clang][HLSL] Add environment parameter to availability attribute (PR #89809)

2024-04-25 Thread Chris B via cfe-commits
@@ -3859,7 +3862,7 @@ def warn_availability_fuchsia_unavailable_minor : Warning< InGroup; def warn_unguarded_availability : - Warning<"%0 is only available on %1 %2 or newer">, + Warning<"%0 %select{is only|is not}5 available %select{|in %4 environment }3on %1 %2

[clang] [Clang][HLSL] Add environment parameter to availability attribute (PR #89809)

2024-04-25 Thread Chris B via cfe-commits
https://github.com/llvm-beanz edited https://github.com/llvm/llvm-project/pull/89809 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][HLSL] Add environment parameter to availability attribute (PR #89809)

2024-04-25 Thread Chris B via cfe-commits
https://github.com/llvm-beanz commented: Overall I really like the direction of this. I'm curious if any of the maintainers from Apple have thoughts since they're the primary users of availability annotations. I think this dramatically simplifies things for what we need, but it might also

[clang] [clang-scan-deps] Fix contention when updating `TrackingStatistic`s in hot code paths in `FileManager`. (PR #88427)

2024-04-25 Thread Fangrui Song via cfe-commits
MaskRay wrote: (BTW: https://discourse.llvm.org/t/hidden-emails-on-github-should-we-do-something-about-it/74223 The recommendation is to avoid the github "hidden email" feature.) https://github.com/llvm/llvm-project/pull/88427 ___ cfe-commits

[clang-tools-extra] 5a12f28 - LLVM_FALLTHROUGH => [[fallthrough]]. NFC

2024-04-25 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2024-04-25T17:50:59-07:00 New Revision: 5a12f2867a167bbe11099150f3cb6b6cb77d767c URL: https://github.com/llvm/llvm-project/commit/5a12f2867a167bbe11099150f3cb6b6cb77d767c DIFF: https://github.com/llvm/llvm-project/commit/5a12f2867a167bbe11099150f3cb6b6cb77d767c.diff

[clang] Clean up denormal handling with -ffp-model, -ffast-math, etc. (PR #89477)

2024-04-25 Thread Fangrui Song via cfe-commits
@@ -75,6 +76,7 @@ // RUN: --check-prefix=WARN12 %s // RUN: %clang -### -ffast-math -ffp-model=strict -c %s 2>&1 | FileCheck \ // RUN: --check-prefix=WARN12 %s +// WARN12: clang MaskRay wrote: `clang` is unneeded. For diagnostics or -cc1 options, we just

[clang] Clean up denormal handling with -ffp-model, -ffast-math, etc. (PR #89477)

2024-04-25 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay edited https://github.com/llvm/llvm-project/pull/89477 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Clean up denormal handling with -ffp-model, -ffast-math, etc. (PR #89477)

2024-04-25 Thread Fangrui Song via cfe-commits
@@ -1462,6 +1460,14 @@ floating point semantic models: precise (the default), strict, and fast. "allow_approximate_fns", "off", "off", "on" "allow_reassociation", "off", "off", "on" +The ``-fp-model`` option does not modify the "fdenormal-fp-math" or

[clang] [Clang][HLSL] Add environment parameter to availability attribute (PR #89809)

2024-04-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-hlsl Author: Helena Kotas (hekota) Changes Add `environment` parameter to Clang availability attribute. The allowed values for this parameter are a subset of values allowed in the `llvm::Triple` environment component. If the

[clang] [Clang][HLSL] Add environment parameter to availability attribute (PR #89809)

2024-04-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-x86 Author: Helena Kotas (hekota) Changes Add `environment` parameter to Clang availability attribute. The allowed values for this parameter are a subset of values allowed in the `llvm::Triple` environment component. If the `environment`

[clang] [Clang][HLSL] Add environment parameter to availability attribute (PR #89809)

2024-04-25 Thread Helena Kotas via cfe-commits
https://github.com/hekota ready_for_review https://github.com/llvm/llvm-project/pull/89809 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][HLSL] Add environment parameter to availability attribute (PR #89809)

2024-04-25 Thread Helena Kotas via cfe-commits
https://github.com/hekota edited https://github.com/llvm/llvm-project/pull/89809 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] Reapply "[Clang][Sema] Diagnose class member access expressions naming non-existent members of the current instantiation prior to instantiation in the absence of dependent

2024-04-25 Thread Krystian Stasiowski via cfe-commits
sdkrystian wrote: Will add tests tomorrow... https://github.com/llvm/llvm-project/pull/90152 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] Reapply "[Clang][Sema] Diagnose class member access expressions naming non-existent members of the current instantiation prior to instantiation in the absence of dependent

2024-04-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tidy Author: Krystian Stasiowski (sdkrystian) Changes Reapplies #84050, addressing a bug which cases a crash when an expression with the type of the current instantiation is used as the _postfix-expression_ in a class member access expression

[clang] [clang-tools-extra] Reapply "[Clang][Sema] Diagnose class member access expressions naming non-existent members of the current instantiation prior to instantiation in the absence of dependent

2024-04-25 Thread Krystian Stasiowski via cfe-commits
https://github.com/sdkrystian created https://github.com/llvm/llvm-project/pull/90152 Reapplies #84050, addressing a bug which cases a crash when an expression with the type of the current instantiation is used as the _postfix-expression_ in a class member access expression (arrow form).

[clang] [clang-tools-extra] [Clang][Sema] Diagnose class member access expressions naming non-existent members of the current instantiation prior to instantiation in the absence of dependent base clas

2024-04-25 Thread Pranav Kant via cfe-commits
pranavk wrote: Sorry, I just pushed the reverts. I reverted the commits for now. Feel free to re-land with fixes. https://github.com/llvm/llvm-project/pull/84050 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang-tools-extra] [Clang][Sema] Diagnose class member access expressions naming non-existent members of the current instantiation prior to instantiation in the absence of dependent base clas

2024-04-25 Thread Krystian Stasiowski via cfe-commits
sdkrystian wrote: @pranavk @ilovepi I have a potential fix ready... give me a few to test some edge cases https://github.com/llvm/llvm-project/pull/84050 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] 0c6e1ca - Revert "[Clang][Sema] Diagnose class member access expressions naming non-existent members of the current instantiation prior to instantiation in the absence of dependent base classe

2024-04-25 Thread Pranav Kant via cfe-commits
Author: Pranav Kant Date: 2024-04-26T00:18:08Z New Revision: 0c6e1ca1c704a3a0fb53ae54f7e3723736f477c7 URL: https://github.com/llvm/llvm-project/commit/0c6e1ca1c704a3a0fb53ae54f7e3723736f477c7 DIFF: https://github.com/llvm/llvm-project/commit/0c6e1ca1c704a3a0fb53ae54f7e3723736f477c7.diff LOG:

[clang] 45fc0e6 - Revert "[Clang][Sema] Fix warnings after #84050 (#90104)"

2024-04-25 Thread Pranav Kant via cfe-commits
Author: Pranav Kant Date: 2024-04-26T00:17:28Z New Revision: 45fc0e6b38b62a61b0ddcda2e7fe9b4fee7e3e58 URL: https://github.com/llvm/llvm-project/commit/45fc0e6b38b62a61b0ddcda2e7fe9b4fee7e3e58 DIFF: https://github.com/llvm/llvm-project/commit/45fc0e6b38b62a61b0ddcda2e7fe9b4fee7e3e58.diff LOG:

[clang] [Clang] Add wraps attribute (for granular integer overflow handling) (PR #86618)

2024-04-25 Thread Justin Stitt via cfe-commits
JustinStitt wrote: @efriedma-quic: > Attributes mostly do modify the type. The few that don't, like "aligned" and > "may_alias", are a constant source of problems because they get accidentally > stripped off. (I don't have any personal experience with "noderef".) So do you believe the current

[clang] [clang-tools-extra] [Clang][Sema] Diagnose class member access expressions naming non-existent members of the current instantiation prior to instantiation in the absence of dependent base clas

2024-04-25 Thread Pranav Kant via cfe-commits
pranavk wrote: Yes, I also think that this should be reverted. This commit seems to erroneously fail on cases like this: https://github.com/tink-crypto/tink-cc/blob/4501627fe9ee312ad5d413600f050827b5f725ed/tink/util/secret_proto.h#L62 Note that ParseFromArray is being on an instance of T. So

[clang] [clang codegen] Fix MS ABI detection of user-provided constructors. (PR #90151)

2024-04-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: Eli Friedman (efriedma-quic) Changes In the context of determining whether a class counts as an "aggregate", a constructor template counts as a user-provided constructor. Fixes #86384 --- Full diff:

[clang] [clang codegen] Fix MS ABI detection of user-provided constructors. (PR #90151)

2024-04-25 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic created https://github.com/llvm/llvm-project/pull/90151 In the context of determining whether a class counts as an "aggregate", a constructor template counts as a user-provided constructor. Fixes #86384 >From 9adeffc9ee780c84a525ce0535a84508105e05ae Mon Sep

[clang] [C++23] [CLANG] Adding C++23 constexpr math functions: fmin and frexp. (PR #88978)

2024-04-25 Thread Hubert Tong via cfe-commits
https://github.com/hubert-reinterpretcast requested changes to this pull request. https://github.com/llvm/llvm-project/pull/88978 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [C++23] [CLANG] Adding C++23 constexpr math functions: fmin and frexp. (PR #88978)

2024-04-25 Thread Hubert Tong via cfe-commits
@@ -0,0 +1,57 @@ +// RUN: %clang_cc1 -DWIN -verify -std=c++23 -fsyntax-only %s +// RUN: %clang_cc1 -verify -std=c++23 -fsyntax-only %s + +// expected-no-diagnostics + + +#ifdef WIN +#define INFINITY ((float)(1e+300 * 1e+300)) +#define NAN (-(float)(INFINITY * 0.0F)) +#else

[clang] [C++23] [CLANG] Adding C++23 constexpr math functions: fmin and frexp. (PR #88978)

2024-04-25 Thread Hubert Tong via cfe-commits
@@ -14547,6 +14547,17 @@ bool FloatExprEvaluator::VisitCallExpr(const CallExpr *E) { default: return false; + case Builtin::BI__builtin_frexpf: + case Builtin::BI__builtin_frexp: { +LValue Pointer; +if (!EvaluateFloat(E->getArg(0), Result, Info) || +

[clang] [C++23] [CLANG] Adding C++23 constexpr math functions: fmin and frexp. (PR #88978)

2024-04-25 Thread Hubert Tong via cfe-commits
https://github.com/hubert-reinterpretcast edited https://github.com/llvm/llvm-project/pull/88978 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][HLSL] Add environment parameter to availability attribute (PR #89809)

2024-04-25 Thread Helena Kotas via cfe-commits
https://github.com/hekota updated https://github.com/llvm/llvm-project/pull/89809 >From 22b67d30ca087d6a912183039c87fd1790eedfe4 Mon Sep 17 00:00:00 2001 From: Helena Kotas Date: Tue, 23 Apr 2024 00:49:28 -0700 Subject: [PATCH 1/3] Add environment parameter to clang availability attribute ---

[clang] [clang][dataflow] Fix crash when `ConstantExpr` is used in conditional operator. (PR #90112)

2024-04-25 Thread Yitzhak Mandelbaum via cfe-commits
https://github.com/ymand approved this pull request. https://github.com/llvm/llvm-project/pull/90112 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][HLSL] Add environment parameter to availability attribute (PR #89809)

2024-04-25 Thread Helena Kotas via cfe-commits
https://github.com/hekota updated https://github.com/llvm/llvm-project/pull/89809 >From 22b67d30ca087d6a912183039c87fd1790eedfe4 Mon Sep 17 00:00:00 2001 From: Helena Kotas Date: Tue, 23 Apr 2024 00:49:28 -0700 Subject: [PATCH 1/3] Add environment parameter to clang availability attribute ---

[clang] [clang-tools-extra] [Clang][Sema] Diagnose class member access expressions naming non-existent members of the current instantiation prior to instantiation in the absence of dependent base clas

2024-04-25 Thread Paul Kirth via cfe-commits
ilovepi wrote: we're seeing similar crashes when building Fuchsia. https://ci.chromium.org/ui/p/fuchsia/builders/ci/clang_toolchain.ci.core.arm64-host_test_only-mac/b8749648123122633169/overview A reproducer can be found here:

[clang] [Clang] Add wraps attribute (for granular integer overflow handling) (PR #86618)

2024-04-25 Thread Justin Stitt via cfe-commits
https://github.com/JustinStitt updated https://github.com/llvm/llvm-project/pull/86618 >From 50e7b1039e514dacc05bb8cd9ff9a3e3df9ed24d Mon Sep 17 00:00:00 2001 From: Justin Stitt Date: Tue, 5 Mar 2024 03:14:49 + Subject: [PATCH 01/15] implement wraps attribute Signed-off-by: Justin Stitt

[clang] [clang-tools-extra] [Clang][Sema] Diagnose class member access expressions naming non-existent members of the current instantiation prior to instantiation in the absence of dependent base clas

2024-04-25 Thread Pranav Kant via cfe-commits
pranavk wrote: This makes clang crash in some cases. Here's a sample: https://godbolt.org/z/4sbvna4WY https://github.com/llvm/llvm-project/pull/84050 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang][modules] HeaderSearch::MarkFileModuleHeader sets textual headers' HeaderFileInfo non-external when it shouldn't (PR #89005)

2024-04-25 Thread Ian Anderson via cfe-commits
ian-twilightcoder wrote: >From Jan: > Maybe we can add the number of external HeaderFileInfos to > HeaderSearch::PrintStats() and have a test that checks for it. > The flag to enable that output is -show-stats I think. https://github.com/llvm/llvm-project/pull/89005

[clang-tools-extra] [clangd] Show definition of underlying struct when hovering over a typedef (PR #89570)

2024-04-25 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff 9617da88ab961145047076c45bb2bb1ac4513634 44aba390954c7b551ed7102e8e7b4209207c0d87 --

[clang] [llvm] [AArch64] Add support for Neoverse-N3, Neoverse-V3 and Neoverse-V3AE (PR #90143)

2024-04-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: Jonathan Thackray (jthackray) Changes Neoverse-N3, Neoverse-V3 and Neoverse-V3AE are Armv9.2 AArch64 CPUs. Technical Reference Manual for Neoverse-N3: https://developer.arm.com/documentation/107997/latest/ Technical Reference

[clang-tools-extra] [clangd] Show definition of underlying struct when hovering over a typedef (PR #89570)

2024-04-25 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Updated patch with the following changes: * Decoupled from https://github.com/clangd/clangd/issues/959 * Handle the case of multiple layers of typedefs, and add tests for this case * Add C language specific tests https://github.com/llvm/llvm-project/pull/89570

[clang] [llvm] [AArch64] Add support for Neoverse-N3, Neoverse-V3 and Neoverse-V3AE (PR #90143)

2024-04-25 Thread Jonathan Thackray via cfe-commits
https://github.com/jthackray created https://github.com/llvm/llvm-project/pull/90143 Neoverse-N3, Neoverse-V3 and Neoverse-V3AE are Armv9.2 AArch64 CPUs. Technical Reference Manual for Neoverse-N3: https://developer.arm.com/documentation/107997/latest/ Technical Reference Manual for

[clang] [llvm] [AArch64] Add support for Neoverse-N3, Neoverse-V3 and Neoverse-V3AE (PR #87414)

2024-04-25 Thread Jonathan Thackray via cfe-commits
https://github.com/jthackray closed https://github.com/llvm/llvm-project/pull/87414 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Show definition of underlying struct when hovering over a typedef (PR #89570)

2024-04-25 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 edited https://github.com/llvm/llvm-project/pull/89570 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AArch64] Add support for Neoverse-N3, Neoverse-V3 and Neoverse-V3AE (PR #87414)

2024-04-25 Thread Jonathan Thackray via cfe-commits
https://github.com/jthackray updated https://github.com/llvm/llvm-project/pull/87414 >From 5ced9f33871ea66647e04f62c637b92259805c2e Mon Sep 17 00:00:00 2001 From: Jonathan Thackray Date: Tue, 2 Apr 2024 22:08:50 +0100 Subject: [PATCH] [AArch64] Add support for Neoverse-N3, Neoverse-V3 and

[clang-tools-extra] [clangd] Show struct members when hovering over a typedef (PR #89570)

2024-04-25 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 updated https://github.com/llvm/llvm-project/pull/89570 >From 44aba390954c7b551ed7102e8e7b4209207c0d87 Mon Sep 17 00:00:00 2001 From: Nathan Ridge Date: Mon, 22 Apr 2024 02:24:14 -0400 Subject: [PATCH] [clangd] Show definition of underlying struct when

[clang] [llvm] [CMake][Release] Enable CMAKE_POSITION_INDEPENDENT_CODE (PR #90139)

2024-04-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Tom Stellard (tstellar) Changes Set this in the cache file directly instead of via the test-release.sh script so that the release builds can be reproduced with just the cache file. --- Full diff:

[clang] [llvm] [CMake][Release] Enable CMAKE_POSITION_INDEPENDENT_CODE (PR #90139)

2024-04-25 Thread Tom Stellard via cfe-commits
https://github.com/tstellar created https://github.com/llvm/llvm-project/pull/90139 Set this in the cache file directly instead of via the test-release.sh script so that the release builds can be reproduced with just the cache file. >From 67f3d1ede686758238bb37a2ea50790750f7693f Mon Sep 17

[clang] [CMake][Release] Use the TGZ cpack generator for binaries (PR #90138)

2024-04-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Tom Stellard (tstellar) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/90138.diff 1 Files Affected: - (modified) clang/cmake/caches/Release.cmake (+1) ``diff diff --git a/clang/cmake/caches/Release.cmake

[clang] [CMake][Release] Use the TGZ cpack generator for binaries (PR #90138)

2024-04-25 Thread Tom Stellard via cfe-commits
https://github.com/tstellar created https://github.com/llvm/llvm-project/pull/90138 None >From 0d0484ac99affdc8ccb9bc3a1eff827cf996c51c Mon Sep 17 00:00:00 2001 From: Tom Stellard Date: Wed, 24 Apr 2024 07:54:41 -0700 Subject: [PATCH] [CMake][Release] Use the TGZ cpack generator for binaries

[clang] [CMake][Release] Refactor cache file and use two stages for non-PGO builds (PR #89812)

2024-04-25 Thread Tom Stellard via cfe-commits
https://github.com/tstellar closed https://github.com/llvm/llvm-project/pull/89812 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 6473fbf - [CMake][Release] Refactor cache file and use two stages for non-PGO builds (#89812)

2024-04-25 Thread via cfe-commits
Author: Tom Stellard Date: 2024-04-25T15:32:08-07:00 New Revision: 6473fbf2d68c8486d168f29afc35d3e8a6fabe69 URL: https://github.com/llvm/llvm-project/commit/6473fbf2d68c8486d168f29afc35d3e8a6fabe69 DIFF: https://github.com/llvm/llvm-project/commit/6473fbf2d68c8486d168f29afc35d3e8a6fabe69.diff

[clang] [llvm] [SCCP] Swap out range metadata to range attribute (PR #90134)

2024-04-25 Thread Andreas Jonson via cfe-commits
andjo403 wrote: CC @nikic as you have looked at the most of other range attribute PRs https://github.com/llvm/llvm-project/pull/90134 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [SCCP] Swap out range metadata to range attribute (PR #90134)

2024-04-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-llvm-ir Author: Andreas Jonson (andjo403) Changes Also moved the range from the function's call sites to the functions return value as that is possible now. --- Patch is 76.90 KiB, truncated to 20.00 KiB below, full version:

  1   2   3   4   >