[clang] [Clang] Implement P3034R1 Module Declarations Shouldn’t be Macros (PR #90574)

2024-07-17 Thread Chuanqi Xu via cfe-commits
@@ -3071,6 +3073,45 @@ struct EmbedAnnotationData { /// Registry of pragma handlers added by plugins using PragmaHandlerRegistry = llvm::Registry; +/// Module/Partition name token sequance. +/// +/// module-name: +/// module-name-qualifier[opt] identifier +/// +/

[clang] [Clang] Implement P3034R1 Module Declarations Shouldn’t be Macros (PR #90574)

2024-07-17 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 edited https://github.com/llvm/llvm-project/pull/90574 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [APFloat] Add support for f8E4M3 IEEE 754 type (PR #97179)

2024-07-17 Thread Alexander Pivovarov via cfe-commits
https://github.com/apivovarov closed https://github.com/llvm/llvm-project/pull/97179 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] f363317 - [APFloat] Add support for f8E4M3 IEEE 754 type (#97179)

2024-07-17 Thread via cfe-commits
Author: Alexander Pivovarov Date: 2024-07-17T23:33:52-07:00 New Revision: f36331770267501e157ac34afc3ca7d7a0bfb52c URL: https://github.com/llvm/llvm-project/commit/f36331770267501e157ac34afc3ca7d7a0bfb52c DIFF: https://github.com/llvm/llvm-project/commit/f36331770267501e157ac34afc3ca7d7a0bfb52c

[clang] fbf8b82 - [clang][Interp][NFC] Be more cautious about Block initialization state

2024-07-17 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2024-07-18T08:01:24+02:00 New Revision: fbf8b82cd02818c005bb39abbf550333bea6 URL: https://github.com/llvm/llvm-project/commit/fbf8b82cd02818c005bb39abbf550333bea6 DIFF: https://github.com/llvm/llvm-project/commit/fbf8b82cd02818c005bb39abbf550333bea6.diff LO

[clang] [Clang] Implement P3034R1 Module Declarations Shouldn’t be Macros (PR #90574)

2024-07-17 Thread Vassil Vassilev via cfe-commits
@@ -905,6 +912,7 @@ void Preprocessor::Lex(Token &Result) { // This token is injected to represent the translation of '#include "a.h"' // into "import a.h;". Mimic the notional ';'. case tok::annot_module_include: +case tok::annot_repl_input_end: ---

[clang] [llvm] [RISCV][FMV] Support target_clones (PR #85786)

2024-07-17 Thread Craig Topper via cfe-commits
@@ -2854,10 +2854,121 @@ void CodeGenFunction::EmitMultiVersionResolver( case llvm::Triple::aarch64: EmitAArch64MultiVersionResolver(Resolver, Options); return; + case llvm::Triple::riscv32: + case llvm::Triple::riscv64: +EmitRISCVMultiVersionResolver(Resolver,

[clang] [OpenMP] Fix calculation of dependencies for multi-dimensional iteration space (PR #99347)

2024-07-17 Thread via cfe-commits
https://github.com/jprotze closed https://github.com/llvm/llvm-project/pull/99347 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 4782a4a - [OpenMP] Fix calculation of dependencies for multi-dimensional iteration space (#99347)

2024-07-17 Thread via cfe-commits
Author: Joachim Date: 2024-07-18T07:41:41+02:00 New Revision: 4782a4ab0ad43b2f47f20afbe025b841d7f0ac04 URL: https://github.com/llvm/llvm-project/commit/4782a4ab0ad43b2f47f20afbe025b841d7f0ac04 DIFF: https://github.com/llvm/llvm-project/commit/4782a4ab0ad43b2f47f20afbe025b841d7f0ac04.diff LOG:

[clang] [llvm] [RISCV][FMV] Support target_version (PR #99040)

2024-07-17 Thread Piyou Chen via cfe-commits
https://github.com/BeMg updated https://github.com/llvm/llvm-project/pull/99040 >From 4260683c6d589bc5a64ceffd5e409336f81d85eb Mon Sep 17 00:00:00 2001 From: Piyou Chen Date: Wed, 5 Jun 2024 01:17:03 -0700 Subject: [PATCH 1/5] [RISCV] Add groupid/bitmask for RISC-V extension Base on https://git

[clang] [clang-format] Fix a bug in annotating `*` in `#define`s (PR #99433)

2024-07-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes Fixes #99271. --- Full diff: https://github.com/llvm/llvm-project/pull/99433.diff 2 Files Affected: - (modified) clang/lib/Format/TokenAnnotator.cpp (+2-1) - (modified) clang/unittests/Format/TokenAnnot

[clang] [clang-format] Fix a bug in annotating `*` in `#define`s (PR #99433)

2024-07-17 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/99433 Fixes #99271. >From ebf25d890ff47be48bd153942d943906943a247b Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Wed, 17 Jul 2024 22:30:21 -0700 Subject: [PATCH] [clang-format] Fix a bug in annotating `*` in `#define`s

[clang] [llvm] [RISCV][FMV] Support target_version (PR #99040)

2024-07-17 Thread Piyou Chen via cfe-commits
https://github.com/BeMg updated https://github.com/llvm/llvm-project/pull/99040 >From 4260683c6d589bc5a64ceffd5e409336f81d85eb Mon Sep 17 00:00:00 2001 From: Piyou Chen Date: Wed, 5 Jun 2024 01:17:03 -0700 Subject: [PATCH 1/3] [RISCV] Add groupid/bitmask for RISC-V extension Base on https://git

[libunwind] [libunwind] Add GCS support for AArch64 (PR #99335)

2024-07-17 Thread Fangrui Song via cfe-commits
@@ -170,6 +183,10 @@ unwind_phase1(unw_context_t *uc, unw_cursor_t *cursor, _Unwind_Exception *except } extern int __unw_step_stage2(unw_cursor_t *); +#if defined(_LIBUNWIND_USE_CET) && defined(_LIBUNWIND_TARGET_AARCH64) MaskRay wrote: Mixing CET and AArch64

[libunwind] [libunwind] Add GCS support for AArch64 (PR #99335)

2024-07-17 Thread Fangrui Song via cfe-commits
@@ -35,6 +35,25 @@ } while (0) #endif +// On AArch64 we use _LIBUNWIND_USE_CET to indicate that GCS is supported. We +// need to guard any use of GCS instructions with __chkfeat though, as GCS may +// not be enabled. +#if defined(_LIBUNWIND_TARGET_AARCH64) && defined(__ARM_F

[clang] [llvm] Remove 3dnow from X86TargetParser. (PR #99352)

2024-07-17 Thread Freddy Ye via cfe-commits
https://github.com/FreddyLeaf edited https://github.com/llvm/llvm-project/pull/99352 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Remove 3dnow from X86TargetParser. (PR #99352)

2024-07-17 Thread Freddy Ye via cfe-commits
@@ -175,8 +175,6 @@ X86_FEATURE_COMPAT(AVX512BF16, "avx512bf16", 34) X86_FEATURE_COMPAT(AVX512VP2INTERSECT, "avx512vp2intersect", 35) // Below Features has some missings comparing to gcc, it's because gcc has some // not one-to-one mapped in llvm. -X86_FEATURE_

[clang] [Clang] Refactor uses of `Cand->Function` in SemaOverload.cpp (PR #98965)

2024-07-17 Thread via cfe-commits
vortex73 wrote: @shafik I've made the changes. Please merge as I do not have write access. https://github.com/llvm/llvm-project/pull/98965 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commi

[clang] [Clang SA]: add support for mismatched ownership_returns+ownership_takes calls for custom allocation classes (PR #98941)

2024-07-17 Thread Balazs Benics via cfe-commits
@@ -1877,16 +1923,43 @@ static bool didPreviousFreeFail(ProgramStateRef State, return false; } +static void printOwnershipTakesList(raw_ostream &os, CheckerContext &C, +const Expr *E) { + if (const CallExpr *CE = dyn_cast(E)) { +const

[clang] [Clang SA]: add support for mismatched ownership_returns+ownership_takes calls for custom allocation classes (PR #98941)

2024-07-17 Thread Balazs Benics via cfe-commits
@@ -1877,16 +1923,43 @@ static bool didPreviousFreeFail(ProgramStateRef State, return false; } +static void printOwnershipTakesList(raw_ostream &os, CheckerContext &C, +const Expr *E) { + if (const CallExpr *CE = dyn_cast(E)) { --

[clang] [Clang SA]: add support for mismatched ownership_returns+ownership_takes calls for custom allocation classes (PR #98941)

2024-07-17 Thread Balazs Benics via cfe-commits
@@ -1877,16 +1923,43 @@ static bool didPreviousFreeFail(ProgramStateRef State, return false; } +static void printOwnershipTakesList(raw_ostream &os, CheckerContext &C, +const Expr *E) { + if (const CallExpr *CE = dyn_cast(E)) { +const

[clang] [Clang SA]: add support for mismatched ownership_returns+ownership_takes calls for custom allocation classes (PR #98941)

2024-07-17 Thread Balazs Benics via cfe-commits
@@ -1877,16 +1923,43 @@ static bool didPreviousFreeFail(ProgramStateRef State, return false; } +static void printOwnershipTakesList(raw_ostream &os, CheckerContext &C, +const Expr *E) { + if (const CallExpr *CE = dyn_cast(E)) { +const

[clang] [Clang SA]: add support for mismatched ownership_returns+ownership_takes calls for custom allocation classes (PR #98941)

2024-07-17 Thread Balazs Benics via cfe-commits
https://github.com/steakhal approved this pull request. I think it looks great. Only a few more stylistic remarks are left, but it should be already in a good shape functional-wise. I'll let you decide if you wanna apply my suggestions or not. One more remark - this time w.r.t. the workflow. U

[clang] [Clang SA]: add support for mismatched ownership_returns+ownership_takes calls for custom allocation classes (PR #98941)

2024-07-17 Thread Balazs Benics via cfe-commits
https://github.com/steakhal edited https://github.com/llvm/llvm-project/pull/98941 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Refactor uses of `Cand->Function` in SemaOverload.cpp (PR #98965)

2024-07-17 Thread via cfe-commits
https://github.com/vortex73 updated https://github.com/llvm/llvm-project/pull/98965 >From 60a51d9150fa3f31c3eab89e1f1da3b30d190b48 Mon Sep 17 00:00:00 2001 From: Vortex Date: Tue, 16 Jul 2024 03:01:14 +0530 Subject: [PATCH 1/5] [Clang] Refactor uses of in SemaOverload.cpp --- clang/lib/Sema/

[clang] [llvm] Remove 3dnow from X86TargetParser. (PR #99352)

2024-07-17 Thread Shengchen Kan via cfe-commits
@@ -175,8 +175,6 @@ X86_FEATURE_COMPAT(AVX512BF16, "avx512bf16", 34) X86_FEATURE_COMPAT(AVX512VP2INTERSECT, "avx512vp2intersect", 35) // Below Features has some missings comparing to gcc, it's because gcc has some // not one-to-one mapped in llvm. -X86_FEATURE_

[clang] [Clang SA]: add support for mismatched ownership_returns+ownership_takes calls for custom allocation classes (PR #98941)

2024-07-17 Thread Balazs Benics via cfe-commits
@@ -103,14 +103,49 @@ using namespace std::placeholders; namespace { // Used to check correspondence between allocators and deallocators. -enum AllocationFamily { +enum AllocationFamilyKind { AF_None, AF_Malloc, AF_CXXNew, AF_CXXNewArray, AF_IfNameIndex, AF_A

[clang-tools-extra] [clangd] Support go-to-definition on type hints. The core part (PR #86629)

2024-07-17 Thread Younan Zhang via cfe-commits
zyn0217 wrote: @HighCommander4 Given that this PR has been growing larger, I plan to split it up. Hopefully, this will make the code review easier. Moreover, I realized it's probably insufficient to build the whole thing on top of a `TypeVisitor`. Like, a pointer to an array, we have to handle

[clang] [Clang] Refactor uses of `Cand->Function` in SemaOverload.cpp (PR #98965)

2024-07-17 Thread via cfe-commits
https://github.com/vortex73 updated https://github.com/llvm/llvm-project/pull/98965 >From 60a51d9150fa3f31c3eab89e1f1da3b30d190b48 Mon Sep 17 00:00:00 2001 From: Vortex Date: Tue, 16 Jul 2024 03:01:14 +0530 Subject: [PATCH 1/4] [Clang] Refactor uses of in SemaOverload.cpp --- clang/lib/Sema/

[clang] [lldb] [clang][AST] fix ast-print of extern with >=2 declarators, fixed, fixed (PR #98795)

2024-07-17 Thread Lang Hames via cfe-commits
lhames wrote: > > Regarding the orc-rt test failures: I tried building one of the failing > > objects and I can't reproduce the failure. Perhaps, because the tests are > > run on Windows and I'm running on Linux? It would be very helpful if > > @Prabhuk could run the failing command on a debug

[clang] [Clang] [docs] [MSVC] Add sections on `__forceinline` and intrinsic behaviour differences between Clang and MSVC (PR #99426)

2024-07-17 Thread Max Winkler via cfe-commits
https://github.com/MaxEW707 updated https://github.com/llvm/llvm-project/pull/99426 >From 37f6bb1a6bc061357f1971c59c101ef7e6b53141 Mon Sep 17 00:00:00 2001 From: MaxEW707 Date: Thu, 11 Jul 2024 23:07:35 -0700 Subject: [PATCH 1/4] Update MSVC compatibility docs --- clang/docs/MSVCCompatibility

[clang] Fix diagnostics-dsym.test on mac-arm64 (PR #99399)

2024-07-17 Thread Cyndy Ishida via cfe-commits
cyndyishida wrote: Thank you @zeroomega ! I am also running on arm64-mac and that test is passing. What is your `cmake` invocation? I'd like to dig into the underlying cause of non-stable ordering. It looks like the darwin-aarch64 is passing the test as well https://lab.llvm.org/buildbot/#/bui

[clang] [Clang] [docs] [MSVC] Add sections on `__forceinline` and intrinsic behaviour differences between Clang and MSVC (PR #99426)

2024-07-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Max Winkler (MaxEW707) Changes We have had quite a few issues created around how Clang treats intrinsics vs how MSVC treats intrinsics. While I was writing this I also added some sections on behaviour changes that caught me while porting

[clang] [Clang] [docs] [MSVC] Add sections on `__forceinline` and intrinsic behaviour differences between Clang and MSVC (PR #99426)

2024-07-17 Thread Max Winkler via cfe-commits
https://github.com/MaxEW707 created https://github.com/llvm/llvm-project/pull/99426 We have had quite a few issues created around how Clang treats intrinsics vs how MSVC treats intrinsics. While I was writing this I also added some sections on behaviour changes that caught me while porting my

[clang] c184b94 - [C++20] [Modules] Write ODRHash for decls in GMF

2024-07-17 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2024-07-18T11:42:23+08:00 New Revision: c184b94ff6546c8ba8ac54b5127189427567978f URL: https://github.com/llvm/llvm-project/commit/c184b94ff6546c8ba8ac54b5127189427567978f DIFF: https://github.com/llvm/llvm-project/commit/c184b94ff6546c8ba8ac54b5127189427567978f.diff LO

[clang] [clang] Add deprecation warning for `-Ofast` driver option (PR #98736)

2024-07-17 Thread Shafik Yaghmour via cfe-commits
@@ -931,7 +931,9 @@ def O : Joined<["-"], "O">, Group, def O_flag : Flag<["-"], "O">, Visibility<[ClangOption, CC1Option, FC1Option]>, Alias, AliasArgs<["1"]>; def Ofast : Joined<["-"], "Ofast">, Group, - Visibility<[ClangOption, CC1Option, FlangOption]>; + Visibility<[Clan

[clang] [llvm] Remove 3dnow from X86TargetParser. (PR #99352)

2024-07-17 Thread Freddy Ye via cfe-commits
@@ -175,8 +175,6 @@ X86_FEATURE_COMPAT(AVX512BF16, "avx512bf16", 34) X86_FEATURE_COMPAT(AVX512VP2INTERSECT, "avx512vp2intersect", 35) // Below Features has some missings comparing to gcc, it's because gcc has some // not one-to-one mapped in llvm. -X86_FEATURE_

[clang] [Clang] Refactor uses of `Cand->Function` in SemaOverload.cpp (PR #98965)

2024-07-17 Thread Shafik Yaghmour via cfe-commits
@@ -11846,19 +11854,21 @@ static void DiagnoseFailedEnableIfAttr(Sema &S, OverloadCandidate *Cand) { } static void DiagnoseFailedExplicitSpec(Sema &S, OverloadCandidate *Cand) { - ExplicitSpecifier ES = ExplicitSpecifier::getFromDecl(Cand->Function); + assert(Cand->Function

[clang] [Clang] Refactor uses of `Cand->Function` in SemaOverload.cpp (PR #98965)

2024-07-17 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik edited https://github.com/llvm/llvm-project/pull/98965 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Refactor uses of `Cand->Function` in SemaOverload.cpp (PR #98965)

2024-07-17 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik requested changes to this pull request. https://github.com/llvm/llvm-project/pull/98965 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Refactor uses of `Cand->Function` in SemaOverload.cpp (PR #98965)

2024-07-17 Thread Shafik Yaghmour via cfe-commits
@@ -9994,8 +9995,9 @@ Sema::AddArgumentDependentLookupCandidates(DeclarationName Name, CandEnd = CandidateSet.end(); Cand != CandEnd; ++Cand) if (Cand->Function) { - Fns.erase(Cand->Function); - if (FunctionTemplateDecl *

[clang] [Clang] Refactor uses of `Cand->Function` in SemaOverload.cpp (PR #98965)

2024-07-17 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik approved this pull request. Thank you for this refactor, just a couple of minor comments but otherwise looks good. Please fix first and then merge after it passes tests, if you need someone to merge for you please let me know. https://github.com/llvm/llvm-project/pull

[clang] [Clang] Refactor uses of `Cand->Function` in SemaOverload.cpp (PR #98965)

2024-07-17 Thread Shafik Yaghmour via cfe-commits
@@ -11846,19 +11854,21 @@ static void DiagnoseFailedEnableIfAttr(Sema &S, OverloadCandidate *Cand) { } static void DiagnoseFailedExplicitSpec(Sema &S, OverloadCandidate *Cand) { - ExplicitSpecifier ES = ExplicitSpecifier::getFromDecl(Cand->Function); + assert(Cand->Function

[clang] [Clang] Refactor uses of `Cand->Function` in SemaOverload.cpp (PR #98965)

2024-07-17 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik edited https://github.com/llvm/llvm-project/pull/98965 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Remove 3dnow from X86TargetParser. (PR #99352)

2024-07-17 Thread Freddy Ye via cfe-commits
@@ -175,8 +175,6 @@ X86_FEATURE_COMPAT(AVX512BF16, "avx512bf16", 34) X86_FEATURE_COMPAT(AVX512VP2INTERSECT, "avx512vp2intersect", 35) // Below Features has some missings comparing to gcc, it's because gcc has some // not one-to-one mapped in llvm. -X86_FEATURE_

[clang] [llvm] [RISCV][FMV] Support target_version (PR #99040)

2024-07-17 Thread Piyou Chen via cfe-commits
@@ -3127,6 +3142,32 @@ bool Sema::checkTargetClonesAttrString( /*IncludeLocallyStreaming=*/false)) return Diag(LiteralLoc, diag::err_sme_streaming_cannot_be_multiversioned); +} else if (TInfo.getTriple().isRISCV()

[clang] [llvm] Remove 3dnow from X86TargetParser. (PR #99352)

2024-07-17 Thread Phoebe Wang via cfe-commits
@@ -175,8 +175,6 @@ X86_FEATURE_COMPAT(AVX512BF16, "avx512bf16", 34) X86_FEATURE_COMPAT(AVX512VP2INTERSECT, "avx512vp2intersect", 35) // Below Features has some missings comparing to gcc, it's because gcc has some // not one-to-one mapped in llvm. -X86_FEATURE_

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

2024-07-17 Thread Hubert Tong via cfe-commits
hubert-reinterpretcast wrote: For info, the cases where the _id-expression_ is transformed into a class member access expression (`q` and `h` below) do not run into this code (see https://cplusplus.github.io/CWG/issues/2902.html regarding said transformation): ```cpp #include struct S { int

[clang-tools-extra] [clangd] [C++20] [Modules] Introduce initial support for C++20 Modules (PR #66462)

2024-07-17 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 closed https://github.com/llvm/llvm-project/pull/66462 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] fe6c240 - [clangd] [C++20] [Modules] Introduce initial support for C++20 Modules (#66462)

2024-07-17 Thread via cfe-commits
Author: Chuanqi Xu Date: 2024-07-18T10:10:22+08:00 New Revision: fe6c24000f2d7316899d4ec4c12273892326ed47 URL: https://github.com/llvm/llvm-project/commit/fe6c24000f2d7316899d4ec4c12273892326ed47 DIFF: https://github.com/llvm/llvm-project/commit/fe6c24000f2d7316899d4ec4c12273892326ed47.diff LO

[clang] [clang] Implement P2582R1: CTAD from inherited constructors (PR #98788)

2024-07-17 Thread via cfe-commits
antangelo wrote: > Thanks for implementing it! > > I haven't looked into the implementation details yet. Before doing so, I want > to ensure I understand the standard correctly (the standard's wording is a > bit hard to follow). > That looks correct to my understanding of the standard. http

[clang-tools-extra] [clangd] [C++20] [Modules] Introduce initial support for C++20 Modules (PR #66462)

2024-07-17 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: Given this is approved, I'd like to land this to give it more baking times. I think the current one is reusable as long as the users can be tolerant about the long latency for openning each file. If users want it to be more faster by reusing module files, users can test http

[clang] [clang][driver][clang-cl] Support `--precompile` and `-fmodule-*` options in Clang-CL (PR #98761)

2024-07-17 Thread Chuanqi Xu via cfe-commits
@@ -0,0 +1,65 @@ +// REQUIRES: system-windows + +// RUN: rm -rf %t +// RUN: mkdir -p %t +// RUN: split-file %s %t + +// RUN: %clang_cl /std:c++20 --precompile "%/t/Hello.cppm" "/Fo%/t/Hello.pcm" ChuanqiXu9 wrote: Maybe something like: ``` // RUN: %clang_cl /std:

[clang] [clang] Add method 'backupStr' to ASTContext (PR #99417)

2024-07-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Youngsuk Kim (JOE1994) Changes Method 'backupStr' extracts common code of manually allocating memory with ASTContext to hold a copy of a string's contents. --- Full diff: https://github.com/llvm/llvm-project/pull/99417.diff 4 Files Affe

[clang] [clang] Add method 'backupStr' to ASTContext (PR #99417)

2024-07-17 Thread Youngsuk Kim via cfe-commits
https://github.com/JOE1994 created https://github.com/llvm/llvm-project/pull/99417 Method 'backupStr' extracts common code of manually allocating memory with ASTContext to hold a copy of a string's contents. >From a2c89a383b340c1da61c6c32790f4cd03976c3a0 Mon Sep 17 00:00:00 2001 From: Youngsuk

[clang] [clang codegen] Emit int TBAA metadata on FP math libcall expf (PR #96025)

2024-07-17 Thread via cfe-commits
vfdff wrote: hi @efriedma-quic @zahiraam I have rebase the PR base on the top main branch, and also addresss all comments, please help to check any new sugguestion? thanks. https://github.com/llvm/llvm-project/pull/96025 ___ cfe-commits mailing list

[clang] [NFCI][clang][analyzer] Make ProgramStatePartialTrait a template definition (PR #98150)

2024-07-17 Thread Endre Fülöp via cfe-commits
gamesh411 wrote: @steakhal Thanks for the feedback on the intention behind using this trait. From this perspective, I see merit in being as conservative as possible with the types we allow in the ProgramState. > If the issue was that the warning was cryptic, we can continue the discussion > i

[clang] Fix diagnostics-dsym.test on mac-arm64 (PR #99399)

2024-07-17 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/99399 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Handle constant "pointers" for `__atomic_always_lock_free`/`__atomic_is_lock_free`. (PR #99340)

2024-07-17 Thread James Y Knight via cfe-commits
@@ -124,6 +124,24 @@ _Static_assert(__atomic_always_lock_free(4, &i64), ""); _Static_assert(!__atomic_always_lock_free(8, &i32), ""); _Static_assert(__atomic_always_lock_free(8, &i64), ""); +// Validate use with fake pointers constants. This mechanism is used to allow +// vali

[clang-tools-extra] [clangd] fix extract-to-function for overloaded operators (PR #81640)

2024-07-17 Thread via cfe-commits
BenBlumer wrote: I can confirm this builds and fixes the issue. For example, in: ``` #include #include int main() { int a = 5; int b = 7; int c; c = a+b; std::cout << a+b << std::endl; return 0; } ``` Without this patch, there is no refactor available for: ``` c = a+b; std::

[clang] [Sema] Don't drop weak_import from a declaration that follows a declaration directly contained in a linkage-specification (PR #85886)

2024-07-17 Thread Akira Hatanaka via cfe-commits
https://github.com/ahatanak closed https://github.com/llvm/llvm-project/pull/85886 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 884772f - [Sema] Don't drop weak_import from a declaration if its definition isn't seen (#85886)

2024-07-17 Thread via cfe-commits
Author: Akira Hatanaka Date: 2024-07-17T16:19:21-07:00 New Revision: 884772fdd6213c1bc16316b1e57fe08d85bdbc2d URL: https://github.com/llvm/llvm-project/commit/884772fdd6213c1bc16316b1e57fe08d85bdbc2d DIFF: https://github.com/llvm/llvm-project/commit/884772fdd6213c1bc16316b1e57fe08d85bdbc2d.diff

[clang] [llvm] Remove 3dnow from X86TargetParser. (PR #99352)

2024-07-17 Thread James Y Knight via cfe-commits
https://github.com/jyknight updated https://github.com/llvm/llvm-project/pull/99352 >From 70160e033ac94de92fc2cd6289548094cd893498 Mon Sep 17 00:00:00 2001 From: James Y Knight Date: Wed, 17 Jul 2024 11:40:38 -0400 Subject: [PATCH 1/3] Remove 3dnow from X86TargetParser. This should've been par

[clang] [Sema] Don't drop weak_import from a declaration that follows a declaration directly contained in a linkage-specification (PR #85886)

2024-07-17 Thread John McCall via cfe-commits
https://github.com/rjmccall approved this pull request. https://github.com/llvm/llvm-project/pull/85886 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix diagnostics-dsym.test on mac-arm64 (PR #99399)

2024-07-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Haowei (zeroomega) Changes The check ordering of diagnostics-dsym.test is wrong and it causes test failure when running on mac-arm64 machine. This patch fixes it. --- Full diff: https://github.com/llvm/llvm-project/pull/99399.diff 1 Fil

[clang] Fix diagnostics-dsym.test on mac-arm64 (PR #99399)

2024-07-17 Thread via cfe-commits
https://github.com/zeroomega ready_for_review https://github.com/llvm/llvm-project/pull/99399 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix diagnostics-dsym.test on mac-arm64 (PR #99399)

2024-07-17 Thread via cfe-commits
zeroomega wrote: Example of the failure: ``` TEST 'Clang :: InstallAPI/diagnostics-dsym.test' FAILED Exit Code: 1 Command Output (stderr): -- RUN: at line 4: rm -rf /Volumes/Work/s/w/ir/x/w/llvm_build/tools/clang/stage2-bins/tools/clang/test/InstallAP

[clang] [llvm] Remove 3dnow from X86TargetParser. (PR #99352)

2024-07-17 Thread James Y Knight via cfe-commits
@@ -171,14 +171,14 @@ constexpr FeatureBitset FeaturesClearwaterforest = // Geode Processor. constexpr FeatureBitset FeaturesGeode = -FeatureX87 | FeatureCMPXCHG8B | FeatureMMX | Feature3DNOW | Feature3DNOWA; jyknight wrote: OK, making the change. I note

[clang] [llvm] [APFloat] Add support for f8E4M3 IEEE 754 type (PR #97179)

2024-07-17 Thread Alexander Pivovarov via cfe-commits
apivovarov wrote: If there are no further questions, comments, or objections, I will merge this PR in a few hours. https://github.com/llvm/llvm-project/pull/97179 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/m

[clang] Fix diagnostics-dsym.test on mac-arm64 (PR #99399)

2024-07-17 Thread via cfe-commits
https://github.com/zeroomega created https://github.com/llvm/llvm-project/pull/99399 The check ordering of diagnostics-dsym.test is wrong and it causes test failure when running on mac-arm64 machine. This patch fixes it. >From 05f1e5185f95d82f0b05b6151c37f3785baa6e54 Mon Sep 17 00:00:00 2001 F

[clang] [clang][deps] Don't treat ObjC method args as module directives (PR #97654)

2024-07-17 Thread Argyrios Kyrtzidis via cfe-commits
https://github.com/akyrtzi approved this pull request. https://github.com/llvm/llvm-project/pull/97654 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix Microsoft ABI inheritance model when member pointer is used in a base specifier (PR #91990)

2024-07-17 Thread Reid Kleckner via cfe-commits
@@ -9015,11 +9015,20 @@ bool Sema::RequireCompleteTypeImpl(SourceLocation Loc, QualType T, if (const MemberPointerType *MPTy = T->getAs()) { if (!MPTy->getClass()->isDependentType()) { - if (getLangOpts().CompleteMemberPointers && - !MPTy->getClass()->getA

[clang] [Clang] Fix Microsoft ABI inheritance model when member pointer is used in a base specifier (PR #91990)

2024-07-17 Thread Reid Kleckner via cfe-commits
@@ -215,6 +215,14 @@ struct NewUnspecified; SingleTemplate tmpl_single; UnspecTemplate tmpl_unspec; +// Member pointers used in base specifiers force an unspecified inheritance model +struct MemPtrInBase : UnspecTemplate {}; rnk wrote: I guess this memptr ty

[clang] [Clang] Fix Microsoft ABI inheritance model when member pointer is used in a base specifier (PR #91990)

2024-07-17 Thread Reid Kleckner via cfe-commits
@@ -13,3 +15,18 @@ template struct S3 { int T::*foo; }; + +template struct Base {}; +struct +S5 // #S5 +: +Base +// expected-error@-1 {{member pointer has incomplete base type 'S5'}} rnk wrote: Should this be an error in Microsoft mode? Shouldn't we silentl

[clang] [flang] [flang] Add -rtlib flag (PR #99058)

2024-07-17 Thread David Truby via cfe-commits
https://github.com/DavidTruby closed https://github.com/llvm/llvm-project/pull/99058 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 7647174 - [flang] Add -rtlib flag (#99058)

2024-07-17 Thread via cfe-commits
Author: David Truby Date: 2024-07-17T23:28:36+01:00 New Revision: 7647174738bf1b8e58c854c488183a849403d5db URL: https://github.com/llvm/llvm-project/commit/7647174738bf1b8e58c854c488183a849403d5db DIFF: https://github.com/llvm/llvm-project/commit/7647174738bf1b8e58c854c488183a849403d5db.diff L

[clang] [flang] [flang] Add -rtlib flag (PR #99058)

2024-07-17 Thread David Truby via cfe-commits
DavidTruby wrote: Linux builds appear to have stopped, but all the previous linux builds worked so I think this is fine to merge. I will revert if it breaks post-commit. https://github.com/llvm/llvm-project/pull/99058 ___ cfe-commits mailing list cfe-

[clang] [clang][deps] Don't treat ObjC method args as module directives (PR #97654)

2024-07-17 Thread Michael Spencer via cfe-commits
https://github.com/Bigcheese updated https://github.com/llvm/llvm-project/pull/97654 >From b5f39ac8b2ed97e53e13dd71618d8da993a48480 Mon Sep 17 00:00:00 2001 From: Michael Spencer Date: Wed, 10 Jul 2024 17:02:39 -0700 Subject: [PATCH] [clang][deps] Don't treat ObjC method args as module directi

[clang] [clang] Ensure pointers passed to runtime support functions are correctly signed (PR #98276)

2024-07-17 Thread Ahmed Bougacha via cfe-commits
https://github.com/ahmedbougacha closed https://github.com/llvm/llvm-project/pull/98276 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 07f8a65 - [clang] Ensure pointers passed to runtime support functions are correctly signed (#98276)

2024-07-17 Thread via cfe-commits
Author: Oliver Hunt Date: 2024-07-17T15:22:53-07:00 New Revision: 07f8a65d09608d67bfd6adbd62bb0999c7363456 URL: https://github.com/llvm/llvm-project/commit/07f8a65d09608d67bfd6adbd62bb0999c7363456 DIFF: https://github.com/llvm/llvm-project/commit/07f8a65d09608d67bfd6adbd62bb0999c7363456.diff L

[clang] [llvm] [PAC][Driver] Support `pauthtest` ABI for AArch64 Linux triples (PR #97237)

2024-07-17 Thread Peter Smith via cfe-commits
https://github.com/smithp35 commented: Apologies for the delay in responding, been a bit backed up. I like the idea of pauthtest as it does give some leeway to change the signing schema. I expect that with some work this could be made to work with bare-metal targets too, but I think it is best

[clang] [llvm] [PAC][Driver] Support `pauthtest` ABI for AArch64 Linux triples (PR #97237)

2024-07-17 Thread Peter Smith via cfe-commits
@@ -1546,16 +1581,28 @@ static void CollectARMPACBTIOptions(const ToolChain &TC, const ArgList &Args, CmdArgs.push_back( Args.MakeArgString(Twine("-msign-return-address=") + Scope)); - if (Scope != "none") + if (Scope != "none") { +if (Triple.getEnvironment() ==

[clang] [llvm] [PAC][Driver] Support `pauthtest` ABI for AArch64 Linux triples (PR #97237)

2024-07-17 Thread Peter Smith via cfe-commits
https://github.com/smithp35 edited https://github.com/llvm/llvm-project/pull/97237 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Don't drop weak_import from a declaration that follows a declaration directly contained in a linkage-specification (PR #85886)

2024-07-17 Thread Akira Hatanaka via cfe-commits
https://github.com/ahatanak updated https://github.com/llvm/llvm-project/pull/85886 >From d39667c7e65c10babb478d8f8d54fecb66d90568 Mon Sep 17 00:00:00 2001 From: Akira Hatanaka Date: Tue, 19 Mar 2024 15:50:00 -0700 Subject: [PATCH 1/5] [Sema] Don't drop weak_import from a declaration that foll

[clang] [llvm] Remove 3dnow from X86TargetParser. (PR #99352)

2024-07-17 Thread Simon Pilgrim via cfe-commits
@@ -171,14 +171,14 @@ constexpr FeatureBitset FeaturesClearwaterforest = // Geode Processor. constexpr FeatureBitset FeaturesGeode = -FeatureX87 | FeatureCMPXCHG8B | FeatureMMX | Feature3DNOW | Feature3DNOWA; RKSimon wrote: I think we should add the defin

[clang] [Clang] Fix Microsoft ABI inheritance model when member pointer is used in a base specifier (PR #91990)

2024-07-17 Thread Mital Ashok via cfe-commits
@@ -9015,11 +9015,20 @@ bool Sema::RequireCompleteTypeImpl(SourceLocation Loc, QualType T, if (const MemberPointerType *MPTy = T->getAs()) { if (!MPTy->getClass()->isDependentType()) { - if (getLangOpts().CompleteMemberPointers && - !MPTy->getClass()->getA

[clang] Remove FiniteMathOnly and use only NoHonorINFs and NoHonorNANs. (PR #97342)

2024-07-17 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam updated https://github.com/llvm/llvm-project/pull/97342 >From aea6519809340024226d587303e26c800c1a3756 Mon Sep 17 00:00:00 2001 From: Zahira Ammarguellat Date: Mon, 1 Jul 2024 12:56:07 -0700 Subject: [PATCH 01/13] [NFC] Add assertion to ensure that FiniteMathOnly to

[clang-tools-extra] [clangd] fix extract-to-function for overloaded operators (PR #81640)

2024-07-17 Thread via cfe-commits
BenBlumer wrote: Would be great to see this merged. This bug prevents basic function extractions from working. https://github.com/llvm/llvm-project/pull/81640 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mail

[clang] [llvm] [AArch64][PAC] Sign block addresses used in indirectbr. (PR #97647)

2024-07-17 Thread Jon Roelofs via cfe-commits
@@ -0,0 +1,106 @@ +; RUN: llc -mtriple arm64e-apple-darwin \ jroelofs wrote: does update_test_checks do horrible things to the CHECK lines in this? https://github.com/llvm/llvm-project/pull/97647 ___ cfe-commits mailin

[clang] [llvm] [WebAssembly] Implement f16x8.replace_lane instruction. (PR #99388)

2024-07-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-webassembly @llvm/pr-subscribers-mc Author: Brendan Dahl (brendandahl) Changes Use a builtin and intrinsic until half types are better supported for instruction selection. --- Full diff: https://github.com/llvm/llvm-project/pull/99388.diff 7

[clang] [llvm] [WebAssembly] Implement f16x8.replace_lane instruction. (PR #99388)

2024-07-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Brendan Dahl (brendandahl) Changes Use a builtin and intrinsic until half types are better supported for instruction selection. --- Full diff: https://github.com/llvm/llvm-project/pull/99388.diff 7 Files Affected: - (modified) clang/in

[clang] [llvm] [WebAssembly] Implement f16x8.replace_lane instruction. (PR #99388)

2024-07-17 Thread Brendan Dahl via cfe-commits
https://github.com/brendandahl created https://github.com/llvm/llvm-project/pull/99388 Use a builtin and intrinsic until half types are better supported for instruction selection. >From a6d65f276fba7487fdecf2e31edef457f74fbafe Mon Sep 17 00:00:00 2001 From: Brendan Dahl Date: Wed, 17 Jul 2024

[clang] [llvm] [Clang] C++20 Coroutines: Introduce Frontend Attribute [[clang::coro_await_elidable]] (PR #99282)

2024-07-17 Thread Yuxuan Chen via cfe-commits
https://github.com/yuxuanchen1997 edited https://github.com/llvm/llvm-project/pull/99282 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [msan] Implement support for Arm NEON vst{2,3,4} instructions (PR #99360)

2024-07-17 Thread Vitaly Buka via cfe-commits
@@ -3865,6 +3866,42 @@ struct MemorySanitizerVisitor : public InstVisitor { setOriginForNaryOp(I); } + /// Handle Arm NEON vector store intrinsics (vst{2,3,4}). + /// + /// Arm NEON vector store intrinsics have the output address (pointer) as the + /// last argument

[clang] [llvm] [Clang] C++20 Coroutines: Introduce Frontend Attribute [[clang::coro_await_elidable]] (PR #99282)

2024-07-17 Thread Yuxuan Chen via cfe-commits
https://github.com/yuxuanchen1997 edited https://github.com/llvm/llvm-project/pull/99282 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [msan] Implement support for Arm NEON vst{2,3,4} instructions (PR #99360)

2024-07-17 Thread Vitaly Buka via cfe-commits
@@ -3865,6 +3866,42 @@ struct MemorySanitizerVisitor : public InstVisitor { setOriginForNaryOp(I); } + /// Handle Arm NEON vector store intrinsics (vst{2,3,4}). + /// + /// Arm NEON vector store intrinsics have the output address (pointer) as the + /// last argument

[clang] [llvm] [msan] Implement support for Arm NEON vst{2,3,4} instructions (PR #99360)

2024-07-17 Thread Vitaly Buka via cfe-commits
@@ -3865,6 +3866,42 @@ struct MemorySanitizerVisitor : public InstVisitor { setOriginForNaryOp(I); } + /// Handle Arm NEON vector store intrinsics (vst{2,3,4}). + /// + /// Arm NEON vector store intrinsics have the output address (pointer) as the + /// last argument

[clang] [Clang] Reuse tail-padding for more types that are not POD for the purpose of layout (PR #90462)

2024-07-17 Thread Mital Ashok via cfe-commits
MitalAshok wrote: I have reached out to Fuschia on their discord and am still waiting for a response. I was unable to find a place to ask someone related to IBM XL what is supposed to happen (and I couldn't get the xl++ compiler to check what it does). Would be grateful if someone more knowl

[clang] [llvm] [Clang] C++20 Coroutines: Introduce Frontend Attribute [[clang::coro_inplace_task]] (PR #99282)

2024-07-17 Thread Yuxuan Chen via cfe-commits
https://github.com/yuxuanchen1997 updated https://github.com/llvm/llvm-project/pull/99282 >From dfb903c47573a01c25a67ea1025fdc3c268673c8 Mon Sep 17 00:00:00 2001 From: Yuxuan Chen Date: Tue, 4 Jun 2024 23:22:00 -0700 Subject: [PATCH] [Clang] Introduce [[clang::coro_await_elidable]] --- clang/

[clang] [llvm] [msan] Implement support for Arm NEON vst{2,3,4} instructions (PR #99360)

2024-07-17 Thread Thurston Dang via cfe-commits
https://github.com/thurstond ready_for_review https://github.com/llvm/llvm-project/pull/99360 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

  1   2   3   4   5   >