@@ -0,0 +1,469 @@
+//===--- APINotesManager.cpp - Manage API Notes Files
-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Ap
https://github.com/egorzhdan updated
https://github.com/llvm/llvm-project/pull/72389
>From 9e171fa5e51a1c6572938da815f9d129f49fb046 Mon Sep 17 00:00:00 2001
From: Egor Zhdan
Date: Wed, 15 Nov 2023 13:46:54 +
Subject: [PATCH] [APINotes] Upstream APINotesManager
This upstreams more of the Cl
@@ -0,0 +1,469 @@
+//===--- APINotesManager.cpp - Manage API Notes Files
-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Ap
rjmccall wrote:
I definitely don't think we should be handling this in the lexer by trying to
retroactively make this a keyword. I was just thinking that we might have some
sort of parser-level recovery for e.g. `unrecognized_identifier_t x = 5;` that
might guess that `unrecognized_identifier_
https://github.com/yuxuanchen1997 updated
https://github.com/llvm/llvm-project/pull/72346
>From f238608b792f69b93eb445ee596125f3e20acf39 Mon Sep 17 00:00:00 2001
From: Yuxuan Chen
Date: Tue, 14 Nov 2023 20:52:21 -0800
Subject: [PATCH 1/5] [Clang] Fix ICE caused by mishandling template
speciali
@@ -5031,7 +5031,12 @@ void RecordDecl::completeDefinition() {
/// This which can be turned on with an attribute, pragma, or the
/// -mms-bitfields command-line option.
bool RecordDecl::isMsStruct(const ASTContext &C) const {
- return hasAttr() || C.getLangOpts().MSBitfields =
https://github.com/DanShaders edited
https://github.com/llvm/llvm-project/pull/71148
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/DanShaders edited
https://github.com/llvm/llvm-project/pull/71148
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
yuxuanchen1997 wrote:
@AaronBallman , mind providing some feedback on this patch? I think this can
solve #70375
https://github.com/llvm/llvm-project/pull/72346
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mail
jwanggit86 wrote:
> > So, while it's possible to create a combined option, using a separate
> > option also makes sense. Do we generally try to avoid creating new
> > command-line options?
>
> Looking again, I see they are different and unrelated. I don't really
> understand why we have amdgp
https://github.com/mtrofin updated
https://github.com/llvm/llvm-project/pull/71262
>From 184936c339ea73ccfc4349e023ff165aa9f8392e Mon Sep 17 00:00:00 2001
From: Mircea Trofin
Date: Fri, 3 Nov 2023 18:19:15 -0700
Subject: [PATCH 1/4] [coro][pgp] Do not insert counters in the `suspend` block
If
@@ -61,6 +63,7 @@ registerAllGPUToLLVMIRTranslations(DialectRegistry ®istry)
{
registerLLVMDialectTranslation(registry);
registerNVVMDialectTranslation(registry);
registerROCDLDialectTranslation(registry);
+ registerSPIRVDialectTranslation(registry);
si
https://github.com/bob80905 approved this pull request.
https://github.com/llvm/llvm-project/pull/72414
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
vpykhtin wrote:
> I think the code change looks fine. I left a few questions inline about
> existing code -- you don't necessarily need to address these.
>
> Could you regenerate the tests as a separate NFC commit (or PR), so this PR
> only shows test changes from the code change?
Thank you f
@@ -425,29 +414,41 @@ bool GCNRewritePartialRegUses::rewriteReg(Register Reg)
const {
return false;
for (MachineOperand &MO : Range) {
vpykhtin wrote:
Yes, it avoids any processing for unsuitable registers. Replaced the loop with
any_of.
https://gith
@@ -425,29 +414,41 @@ bool GCNRewritePartialRegUses::rewriteReg(Register Reg)
const {
return false;
for (MachineOperand &MO : Range) {
-if (MO.getSubReg() == AMDGPU::NoSubRegister) // Whole reg used, quit.
+if (MO.getSubReg() == AMDGPU::NoSubRegister) // Whole r
@@ -1,32 +1,31 @@
# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
# RUN: llc -mtriple=amdgcn-amd-amdhsa
-amdgpu-enable-rewrite-partial-reg-uses=true -verify-machineinstrs
-start-before=rename-independent-subregs -stop-after=rewrite-partial-reg-use
https://github.com/DanShaders edited
https://github.com/llvm/llvm-project/pull/71148
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/david-xl approved this pull request.
Please also update the comment about tail call and symmetric transfer.
https://github.com/llvm/llvm-project/pull/71262
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.or
zmodem wrote:
Thanks!
https://github.com/llvm/llvm-project/pull/71780
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -5031,7 +5031,12 @@ void RecordDecl::completeDefinition() {
/// This which can be turned on with an attribute, pragma, or the
/// -mms-bitfields command-line option.
bool RecordDecl::isMsStruct(const ASTContext &C) const {
- return hasAttr() || C.getLangOpts().MSBitfields =
Author: Brad Smith
Date: 2023-11-15T13:36:16-05:00
New Revision: f0ad2e9fda5f78149198f67461e417d101318df5
URL:
https://github.com/llvm/llvm-project/commit/f0ad2e9fda5f78149198f67461e417d101318df5
DIFF:
https://github.com/llvm/llvm-project/commit/f0ad2e9fda5f78149198f67461e417d101318df5.diff
LO
https://github.com/brad0 closed https://github.com/llvm/llvm-project/pull/71371
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jyu2-git updated
https://github.com/llvm/llvm-project/pull/71748
>From 3313aca0622da3882a9e5bf304b89f28fecce7fe Mon Sep 17 00:00:00 2001
From: Jennifer Yu
Date: Mon, 6 Nov 2023 20:51:39 -0800
Subject: [PATCH 1/3] [SEH] Fix assertin when return scalar value from __try
block.
aeubanks wrote:
we're seeing debug info verifier issues in Rust with this change, e.g.
```
invalid tag
!50 = !DIDerivedType(tag: DW_TAG_imported_declaration, name: "DISCR_EXACT",
scope: !37, file: !2, baseType: !51, flags: DIFlagStaticMember, extraData: i64
0)
invalid tag
!61 = !DIDerivedTy
DanShaders wrote:
@rjmccall Would you mind merging this then? (I don't have write access)
https://github.com/llvm/llvm-project/pull/71148
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit
@@ -11,557 +11,614 @@
namespace hlsl {
-__attribute__((availability(shadermodel, introduced = 6.0)))
-__attribute__((clang_builtin_alias(__builtin_hlsl_wave_active_count_bits)))
uint
-WaveActiveCountBits(bool bBit);
+// Note: Functions in this file are sorted alphabetically,
https://github.com/smanna12 updated
https://github.com/llvm/llvm-project/pull/70762
>From 93d46d40f46663cfa30fc01da965887508684e25 Mon Sep 17 00:00:00 2001
From: "Manna, Soumi"
Date: Mon, 30 Oct 2023 21:41:00 -0700
Subject: [PATCH 01/23] [clang] Add support for new loop attribute
[[clang::code
https://github.com/capfredf updated
https://github.com/llvm/llvm-project/pull/67349
>From 2e01c0e7974977d5dd13ef2dcab765c4d714f5ce Mon Sep 17 00:00:00 2001
From: Fred Fu
Date: Tue, 29 Aug 2023 11:56:59 -0400
Subject: [PATCH] [ClangRepl] Add type directed code completion to clang-repl
use CodeC
@@ -322,6 +322,79 @@ static Attr *handleUnlikely(Sema &S, Stmt *St, const
ParsedAttr &A,
return ::new (S.Context) UnlikelyAttr(S.Context, A);
}
+CodeAlignAttr *Sema::BuildCodeAlignAttr(const AttributeCommonInfo &CI,
+Expr *E) {
+ if
@@ -7482,3 +7482,26 @@ generation of the other destruction cases, optimizing
the above `foo.destroy` to
}];
}
+
+def MSStructDocs : Documentation {
+ let Category = DocCatDecl;
+ let Content = [{
+The ``ms_struct`` and ``gcc_struct`` attributes request the compiler to ent
@@ -3643,7 +3643,14 @@ def CFGuard : InheritableAttr,
TargetSpecificAttr {
def MSStruct : InheritableAttr {
let Spellings = [GCC<"ms_struct">];
let Subjects = SubjectList<[Record]>;
- let Documentation = [Undocumented];
+ let Documentation = [MSStructDocs];
+ let Simple
https://github.com/DanShaders updated
https://github.com/llvm/llvm-project/pull/71148
>From 5fb6768149bf2b4e7d74c4874e17dbf4e0e656b7 Mon Sep 17 00:00:00 2001
From: Dan Klishch
Date: Fri, 3 Nov 2023 21:18:06 -0400
Subject: [PATCH 1/5] [clang] Stub out gcc_struct attribute
This commit implements
abidh wrote:
> Thanks for the pointer. However, the description doesn't appear to have
> sufficient information to justify the `--gcc-toolchain=` dependent decision.
> A toolchain should be selected completely from the target triple. I think
> `RISCVToolChain` should be adjusted to either sele
amykhuang wrote:
ping for review?
https://github.com/llvm/llvm-project/pull/70877
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
Michael137 wrote:
> we're seeing debug info verifier issues in Rust with this change, e.g.
>
> ```
>
> invalid tag
>
> !50 = !DIDerivedType(tag: DW_TAG_imported_declaration, name: "DISCR_EXACT",
> scope: !37, file: !2, baseType: !51, flags: DIFlagStaticMember, extraData:
> i64 0)
>
> inv
@@ -0,0 +1,333 @@
+//=- ClangDiagnosticsEmitter.cpp - Generate Clang diagnostics tables -*- C++
-*-
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Ap
https://github.com/AaronBallman edited
https://github.com/llvm/llvm-project/pull/68324
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/AaronBallman commented:
I'm in favor of the changes in this patch, but precommit CI is currently
failing with relevant failures that should be addressed.
https://github.com/llvm/llvm-project/pull/68324
___
cfe-commits mailing list
c
@@ -0,0 +1,333 @@
+//=- ClangDiagnosticsEmitter.cpp - Generate Clang diagnostics tables -*- C++
-*-
AaronBallman wrote:
```suggestion
//=- ClangBuiltinsEmitter.cpp - Generate Clang builtins tables -*- C++ -*-
```
May need to adjust formatting.
https://github.c
@@ -0,0 +1,333 @@
+//=- ClangDiagnosticsEmitter.cpp - Generate Clang diagnostics tables -*- C++
-*-
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Ap
@@ -0,0 +1,121 @@
+//===--- BuiltinsBase.td - common structured used by builtins ---*- C++
-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Ap
@@ -0,0 +1,121 @@
+//===--- BuiltinsBase.td - common structured used by builtins ---*- C++
-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Ap
@@ -0,0 +1,121 @@
+//===--- BuiltinsBase.td - common structured used by builtins ---*- C++
-*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Ap
aeubanks wrote:
ah I see, that definitely sounds plausible
I've also recently done some NFC changes to better catch issues like this in
https://github.com/llvm/llvm-project/pull/66295
https://github.com/llvm/llvm-project/pull/72234
___
cfe-commits ma
https://github.com/smanna12 updated
https://github.com/llvm/llvm-project/pull/70762
>From 93d46d40f46663cfa30fc01da965887508684e25 Mon Sep 17 00:00:00 2001
From: "Manna, Soumi"
Date: Mon, 30 Oct 2023 21:41:00 -0700
Subject: [PATCH 01/24] [clang] Add support for new loop attribute
[[clang::code
aeubanks wrote:
actually I think the caller is in Rust, so perhaps we should just update Rust
instead. but making some of these params more strongly typed would be good
https://github.com/llvm/llvm-project/pull/72234
___
cfe-commits mailing list
cfe-c
Michael137 wrote:
Is it possible that this is to be fixed at the callsites in the rust frontend?
Dont think i missed any callers in LLVM (then again I'm not at a PC to confirm
this atm)
https://github.com/llvm/llvm-project/pull/72234
___
cfe-commits
https://github.com/AaronBallman approved this pull request.
> ping for review?
My apologies for the delay!
The changes LGTM but there is a precommit CI failure with libc++. As best I can
tell, that looks to be a transient issue and not caused by your patch, but it
would be good to verify that
https://github.com/schenker updated
https://github.com/llvm/llvm-project/pull/71974
>From dabfdee1a982000605e4b33930ba433c63d1684f Mon Sep 17 00:00:00 2001
From: Thomas Schenker
Date: Fri, 10 Nov 2023 18:58:26 +0100
Subject: [PATCH 1/4] [clang-tidy] bugprone-assert-side-effect non-const
operat
https://github.com/AaronBallman commented:
The attribute bits LGTM, but I added some more reviewers to double-check the
driver changes.
https://github.com/llvm/llvm-project/pull/71148
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lis
https://github.com/mtrofin edited
https://github.com/llvm/llvm-project/pull/71262
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/mtrofin closed
https://github.com/llvm/llvm-project/pull/71262
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
efriedma-quic wrote:
Looks fine now. (You might want to change the title before merging.)
https://github.com/llvm/llvm-project/pull/71748
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commi
https://github.com/AaronBallman edited
https://github.com/llvm/llvm-project/pull/71807
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/AaronBallman approved this pull request.
LGTM but asking for some extra tests.
https://github.com/llvm/llvm-project/pull/71807
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cf
@@ -157,4 +157,13 @@ namespace Bitfields {
// expected-warning {{changes value from 100 to 0}}
}
+namespace BitOps {
+ constexpr unsigned __int128 UZero = 0;
+ constexpr unsigned __int128 Max = ~UZero;
+ static_assert(Max == ~0, "");
+ static_assert
https://github.com/AaronBallman approved this pull request.
LGTM!
https://github.com/llvm/llvm-project/pull/71648
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/Artem-B edited
https://github.com/llvm/llvm-project/pull/72394
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/Artem-B approved this pull request.
LGTM with a couple of nits.
https://github.com/llvm/llvm-project/pull/72394
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -12,7 +12,7 @@ extern "C" void host_fn() {}
struct Dummy {};
struct S {
- S() {}
+ S() { x = 1; }
Artem-B wrote:
Can we make the purpose of non-trivial constructor more descriptive, here and
in other places?
E.g. `S() { static int nontrivial_ctor = 1; }
@@ -772,6 +772,26 @@ void Sema::maybeAddCUDAHostDeviceAttrs(FunctionDecl *NewD,
NewD->addAttr(CUDADeviceAttr::CreateImplicit(Context));
}
+// If a trivial ctor/dtor has no host/device
+// attributes, make it implicitly host device function.
+void Sema::maybeAddCUDAHostDevice
@@ -627,7 +628,7 @@ class Target : public std::enable_shared_from_this,
// used.
const lldb::ProcessSP &CreateProcess(lldb::ListenerSP listener_sp,
llvm::StringRef plugin_name,
- const FileSpec *cr
@@ -244,9 +245,38 @@ SBProcess SBTarget::LoadCore(const char *core_file,
lldb::SBError &error) {
TargetSP target_sp(GetSP());
if (target_sp) {
FileSpec filespec(core_file);
-FileSystem::Instance().Resolve(filespec);
+auto file = FileSystem::Instance().Open(
+
@@ -3174,8 +3174,17 @@ class TargetCreateFormDelegate : public FormDelegate {
core_file_directory_spec.SetDirectory(core_file_spec.GetDirectory());
target_sp->AppendExecutableSearchPaths(core_file_directory_spec);
-ProcessSP process_sp(target_sp->CreateProcess(
-
https://github.com/clayborg requested changes to this pull request.
https://github.com/llvm/llvm-project/pull/71769
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -194,11 +194,12 @@ void ProcessGDBRemote::Terminate() {
PluginManager::UnregisterPlugin(ProcessGDBRemote::CreateInstance);
}
-lldb::ProcessSP ProcessGDBRemote::CreateInstance(
-lldb::TargetSP target_sp, ListenerSP listener_sp,
-const FileSpec *crash_file_path, boo
https://github.com/clayborg edited
https://github.com/llvm/llvm-project/pull/71769
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -427,8 +427,17 @@ class CommandObjectTargetCreate : public
CommandObjectParsed {
core_file_dir.SetDirectory(core_file.GetDirectory());
target_sp->AppendExecutableSearchPaths(core_file_dir);
+auto file = FileSystem::Instance().Open(
+core
@@ -102,10 +102,10 @@ void ProcessKDP::Terminate() {
lldb::ProcessSP ProcessKDP::CreateInstance(TargetSP target_sp,
ListenerSP listener_sp,
- const FileSpec *crash_file_path,
+
@@ -322,6 +322,90 @@ static Attr *handleUnlikely(Sema &S, Stmt *St, const
ParsedAttr &A,
return ::new (S.Context) UnlikelyAttr(S.Context, A);
}
+CodeAlignAttr *Sema::BuildCodeAlignAttr(const AttributeCommonInfo &CI,
+Expr *E) {
+ if
@@ -322,6 +322,90 @@ static Attr *handleUnlikely(Sema &S, Stmt *St, const
ParsedAttr &A,
return ::new (S.Context) UnlikelyAttr(S.Context, A);
}
+CodeAlignAttr *Sema::BuildCodeAlignAttr(const AttributeCommonInfo &CI,
+Expr *E) {
+ if
@@ -296,10 +296,16 @@ bool CodeGen::isEmptyRecord(ASTContext &Context, QualType
T, bool AllowArrays,
return false;
// If this is a C++ record, check the bases first.
- if (const CXXRecordDecl *CXXRD = dyn_cast(RD))
+ if (const CXXRecordDecl *CXXRD = dyn_cast(RD)) {
https://github.com/amy-kwan edited
https://github.com/llvm/llvm-project/pull/68919
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1,11 +1,16 @@
-// RUN: %clang_cc1 -triple x86_64-pc-linux-gnu -emit-llvm < %s| FileCheck %s
+// RUN: %clang_cc1 -triple x86_64-pc-linux-gnu -emit-llvm < %s | FileCheck %s \
+// RUN: --check-prefix=CHECK-X86
+// RUN: %clang_cc1 -triple ppc64le-linux-gnu -emit-llvm < %s | File
https://github.com/amy-kwan commented:
Additional group review comments.
https://github.com/llvm/llvm-project/pull/68919
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -15,38 +20,57 @@ int main(void) {
if (__builtin_cpu_supports("sse4.2"))
a("sse4.2");
- // CHECK: [[LOAD:%[^ ]+]] = load i32, ptr getelementptr inbounds ({ i32,
i32, i32, [1 x i32] }, ptr @__cpu_model, i32 0, i32 3, i32 0)
- // CHECK: [[AND:%[^ ]+]] = and i32 [[LOAD
https://github.com/AaronBallman edited
https://github.com/llvm/llvm-project/pull/72197
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -296,10 +296,16 @@ bool CodeGen::isEmptyRecord(ASTContext &Context, QualType
T, bool AllowArrays,
return false;
// If this is a C++ record, check the bases first.
- if (const CXXRecordDecl *CXXRD = dyn_cast(RD))
+ if (const CXXRecordDecl *CXXRD = dyn_cast(RD)) {
--
https://github.com/AaronBallman commented:
Thank you for this! Please be sure to add a release note to
`clang/docs/ReleaseNotes.rst` as well so users know about the change in
behavior.
https://github.com/llvm/llvm-project/pull/72197
___
cfe-commits m
@@ -65,3 +65,9 @@ EXTERNC struct SortOfEmpty sort_of_empty_ret(void) {
struct SortOfEmpty e;
return e;
}
+
+// CHECK-GNU-CXX: define{{.*}} i32 @empty_align_arg(i128 %a.coerce, i32
noundef %b)
+struct EmptyAlign { long long int __attribute__((aligned)) : 0; };
-
@@ -65,3 +65,9 @@ EXTERNC struct SortOfEmpty sort_of_empty_ret(void) {
struct SortOfEmpty e;
return e;
}
+
+// CHECK-GNU-CXX: define{{.*}} i32 @empty_align_arg(i128 %a.coerce, i32
noundef %b)
+struct EmptyAlign { long long int __attribute__((aligned)) : 0; };
+EXTERNC int
@@ -296,10 +296,16 @@ bool CodeGen::isEmptyRecord(ASTContext &Context, QualType
T, bool AllowArrays,
return false;
// If this is a C++ record, check the bases first.
- if (const CXXRecordDecl *CXXRD = dyn_cast(RD))
+ if (const CXXRecordDecl *CXXRD = dyn_cast(RD)) {
@@ -772,6 +772,26 @@ void Sema::maybeAddCUDAHostDeviceAttrs(FunctionDecl *NewD,
NewD->addAttr(CUDADeviceAttr::CreateImplicit(Context));
}
+// If a trivial ctor/dtor has no host/device
+// attributes, make it implicitly host device function.
+void Sema::maybeAddCUDAHostDevice
@@ -12,7 +12,7 @@ extern "C" void host_fn() {}
struct Dummy {};
struct S {
- S() {}
+ S() { x = 1; }
yxsamliu wrote:
will do
https://github.com/llvm/llvm-project/pull/72394
___
cfe-commits mailing list
cfe-commit
https://github.com/hokein created
https://github.com/llvm/llvm-project/pull/72428
Fix #67495, #72198
CC @ADKaster, @ecnelises
>From 13b97a2239c93fe528174ec9ecc20f3d3ca49e23 Mon Sep 17 00:00:00 2001
From: Haojian Wu
Date: Wed, 15 Nov 2023 20:31:12 +0100
Subject: [PATCH] [clang][AST] Invalidate
arichardson wrote:
> Gentle ping!
Sorry for the delay - I was busy with the RISC-V summit last week, hoping to
get to this PR later this week.
https://github.com/llvm/llvm-project/pull/67860
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
htt
llvmbot wrote:
@llvm/pr-subscribers-clang
Author: Haojian Wu (hokein)
Changes
Fix #67495, #72198
CC @ADKaster, @ecnelises
---
Full diff: https://github.com/llvm/llvm-project/pull/72428.diff
2 Files Affected:
- (modified) clang/lib/Sema/SemaDecl.cpp (+9)
- (modified) clang/test/AST/as
https://github.com/AaronBallman edited
https://github.com/llvm/llvm-project/pull/71687
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/AaronBallman approved this pull request.
The changes seem reasonable to me but I think we should start putting some
effort in to support _BitInt because I have a sneaking suspicion that will be
hard to support with all the power-of-two literals being used, and the more
integ
@@ -59,13 +59,54 @@ static void pushInt(InterpState &S, int32_t Val) {
llvm_unreachable("Int isn't 16 or 32 bit?");
}
-static bool retInt(InterpState &S, CodePtr OpPC, APValue &Result) {
- PrimType IntType = getIntPrimType(S);
- if (IntType == PT_Sint32)
-return Ret(
https://github.com/AaronBallman approved this pull request.
LGTM
https://github.com/llvm/llvm-project/pull/71662
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/AaronBallman approved this pull request.
LGTM!
https://github.com/llvm/llvm-project/pull/72243
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/jyu2-git edited
https://github.com/llvm/llvm-project/pull/71748
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -11486,6 +11486,7 @@ bool IntExprEvaluator::CheckReferencedDecl(const Expr*
E, const Decl* D) {
/// Values returned by __builtin_classify_type, chosen to match the values
/// produced by GCC's builtin.
+/// The values can be found in gcc/typeclass.h in the GCC repository.
https://github.com/AaronBallman approved this pull request.
LGTM
https://github.com/llvm/llvm-project/pull/72036
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/AaronBallman edited
https://github.com/llvm/llvm-project/pull/72036
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -217,6 +217,8 @@ Non-comprehensive list of changes in this release
(e.g., ``uint16x8_t``), this returns the constant number of elements at
compile-time.
For scalable vectors, e.g., SVE or RISC-V V, the number of elements is not
known at compile-time and is
determined
@@ -439,6 +439,194 @@ static bool interp__builtin_popcount(InterpState &S,
CodePtr OpPC,
return true;
}
+// Values returned by __builtin_classify_type, chosen to match the values
+/// produced by GCC's builtin.
+enum class GCCTypeClass {
+ None = -1,
+ Void = 0,
+ Intege
@@ -0,0 +1,55 @@
+// RUN: %clang_cc1 -std=c++20 -Wunsafe-buffer-usage \
+// RUN:-fsafe-buffer-usage-suggestions \
+// RUN:-fdiagnostics-parseable-fixits %s 2>&1 | FileCheck %s
+void foo(int * , int *);
+
+void add_assign_test(unsigned int n, int *a, int y)
301 - 400 of 594 matches
Mail list logo