@@ -2099,6 +2099,70 @@ class Sema final : public SemaBase {
bool CheckCountedByAttrOnField(FieldDecl *FD, Expr *E, bool CountInBytes,
bool OrNull);
+ // AssignmentAction - This is used by all the assignment diagnostic functions
+ // to repr
https://github.com/delcypher edited
https://github.com/llvm/llvm-project/pull/106321
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -2440,6 +2440,26 @@ class alignas(TypeAlignment) Type : public
ExtQualsTypeCommonBase {
return !isFunctionType();
}
+ /// \returns True if the type is incomplete and it is also a type that
+ /// cannot be completed by a later type definition.
+ ///
+ /// E.g. For
@@ -2438,6 +2438,22 @@ bool Type::isIncompleteType(NamedDecl **Def) const {
}
}
+bool Type::isIncompletableIncompleteType() const {
+ if (!isIncompleteType())
+return false;
+
+ // Forward declarations of structs, classes, enums, and unions could be later
+ // complet
@@ -2438,6 +2438,22 @@ bool Type::isIncompleteType(NamedDecl **Def) const {
}
}
+bool Type::isIncompletableIncompleteType() const {
+ if (!isIncompleteType())
+return false;
+
+ // Forward declarations of structs, classes, enums, and unions could be later
+ // complet
@@ -186,4 +218,370 @@ bool Sema::CheckCountedByAttrOnField(FieldDecl *FD, Expr
*E, bool CountInBytes,
return false;
}
+SourceRange Sema::BoundsSafetySourceRangeFor(const CountAttributedType *CATy) {
+ // Note: This implementation relies on `CountAttributedType` being uniqu
@@ -8192,6 +8192,14 @@ ExprResult InitializationSequence::Perform(Sema &S,
Kind.getRange().getEnd());
} else {
CurInit = new (S.Context) ImplicitValueInitExpr(Step->Type);
+// Note the return value isn't used to return early
+// to pres
@@ -186,4 +218,370 @@ bool Sema::CheckCountedByAttrOnField(FieldDecl *FD, Expr
*E, bool CountInBytes,
return false;
}
+SourceRange Sema::BoundsSafetySourceRangeFor(const CountAttributedType *CATy) {
+ // Note: This implementation relies on `CountAttributedType` being uniqu
@@ -3862,6 +3878,27 @@ CountAttributedType::CountAttributedType(
DeclSlot[i] = CoupledDecls[i];
}
+StringRef CountAttributedType::GetAttributeName(bool WithMacroPrefix) const {
delcypher wrote:
> but the way this works for AttributedTypes is that the Att
@@ -186,4 +218,370 @@ bool Sema::CheckCountedByAttrOnField(FieldDecl *FD, Expr
*E, bool CountInBytes,
return false;
}
+SourceRange Sema::BoundsSafetySourceRangeFor(const CountAttributedType *CATy) {
delcypher wrote:
Yeah this isn't great. The whole functio
@@ -8192,6 +8192,14 @@ ExprResult InitializationSequence::Perform(Sema &S,
Kind.getRange().getEnd());
} else {
CurInit = new (S.Context) ImplicitValueInitExpr(Step->Type);
+// Note the return value isn't used to return early
+// to pres
https://github.com/delcypher created
https://github.com/llvm/llvm-project/pull/106453
The primary motivation behind this is to allow the enum type to be
referred to earlier in the `Sema.h` file which is needed for #106321.
It was requested in #106321 that a scoped enum be used (rather than
movi
@@ -2099,6 +2099,70 @@ class Sema final : public SemaBase {
bool CheckCountedByAttrOnField(FieldDecl *FD, Expr *E, bool CountInBytes,
bool OrNull);
+ // AssignmentAction - This is used by all the assignment diagnostic functions
+ // to repr
delcypher wrote:
@Endilll This is my attempt at implementing what you asked for in
https://github.com/llvm/llvm-project/pull/106321#discussion_r1734379624
I'm not a huge fan of this as I think this will be extremely annoying for
downstream forks with very little upside vs just moving the unsco
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/106453
>From 54a5f90ce219aad942074d78d986d24d6690b30c Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Wed, 28 Aug 2024 13:44:44 -0700
Subject: [PATCH 1/3] [NFC][Sema] Move `Sema::AssignmentAction` into its own
scoped
delcypher wrote:
@Endilll I've tried to address your feedback.
https://github.com/llvm/llvm-project/pull/106453
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/106453
>From 54a5f90ce219aad942074d78d986d24d6690b30c Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Wed, 28 Aug 2024 13:44:44 -0700
Subject: [PATCH 1/5] [NFC][Sema] Move `Sema::AssignmentAction` into its own
scoped
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/106453
>From 54a5f90ce219aad942074d78d986d24d6690b30c Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Wed, 28 Aug 2024 13:44:44 -0700
Subject: [PATCH 1/4] [NFC][Sema] Move `Sema::AssignmentAction` into its own
scoped
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/106453
>From 54a5f90ce219aad942074d78d986d24d6690b30c Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Wed, 28 Aug 2024 13:44:44 -0700
Subject: [PATCH 1/6] [NFC][Sema] Move `Sema::AssignmentAction` into its own
scoped
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/106453
>From 5497f530a717ff302deb85fc30ff75e59dba Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Thu, 29 Aug 2024 11:48:12 -0700
Subject: [PATCH] [NFC][Sema] Move Sema::AssignmentAction into its own scoped
enum
https://github.com/delcypher edited
https://github.com/llvm/llvm-project/pull/106453
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/delcypher closed
https://github.com/llvm/llvm-project/pull/106453
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/delcypher closed
https://github.com/llvm/llvm-project/pull/95455
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/delcypher created
https://github.com/llvm/llvm-project/pull/98954
This patch creates a `SemaBoundsSafety` class to create a clean
separation between `-fbounds-safety` Sema checks and
other Sema checks. A `SemaBoundsSafety` object is available via the
`Sema::BoundsSafety()` met
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/87596
>From 03266b74d973075eb5dfa27f32bb9c1bb75d73f9 Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Mon, 29 Apr 2024 16:46:31 -0700
Subject: [PATCH 1/4] [BoundsSafety] Allow 'counted_by' attribute on pointers
in stru
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/87596
>From 03266b74d973075eb5dfa27f32bb9c1bb75d73f9 Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Mon, 29 Apr 2024 16:46:31 -0700
Subject: [PATCH 1/4] [BoundsSafety] Allow 'counted_by' attribute on pointers
in stru
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/87596
>From 4e6130ea07e655081df3f2ca9c89fd1be035a68d Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Wed, 1 May 2024 13:56:52 -0700
Subject: [PATCH] [BoundsSafety] Allow 'counted_by' attribute on pointers in
structs i
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/87596
>From 50e628d2d6fb496c1cb2fa188b653529508e383c Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Wed, 1 May 2024 13:56:52 -0700
Subject: [PATCH] [BoundsSafety] Allow 'counted_by' attribute on pointers in
structs i
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/87596
>From a89cca7fecae5ef5130cd9c8da834a186e99dbb5 Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Wed, 1 May 2024 13:56:52 -0700
Subject: [PATCH] [BoundsSafety] Allow 'counted_by' attribute on pointers in
structs i
https://github.com/delcypher edited
https://github.com/llvm/llvm-project/pull/87596
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/delcypher created
https://github.com/llvm/llvm-project/pull/90786
Previously the attribute was only allowed on flexible array members. This patch
patch changes this to also allow the attribute on pointer fields in structs and
also allows late parsing of the attribute in some
delcypher wrote:
@rapidsna I've put my version of this PR in my own pull request because when I
edit the PR summary here it looks like you wrote it which is weird:
https://github.com/llvm/llvm-project/pull/90786
https://github.com/llvm/llvm-project/pull/87596
__
delcypher wrote:
@rapidsna You may want to close this PR but I'll leave this up to you.
https://github.com/llvm/llvm-project/pull/87596
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -8588,31 +8588,71 @@ static const RecordDecl
*GetEnclosingNamedOrTopAnonRecord(const FieldDecl *FD) {
return RD;
}
-static bool
-CheckCountExpr(Sema &S, FieldDecl *FD, Expr *E,
- llvm::SmallVectorImpl &Decls) {
+enum class CountedByInvalidPointeeTypeKind {
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/90786
>From 1f4d924768409d6bc61d160c6161e6acebf62b60 Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Wed, 1 May 2024 13:56:52 -0700
Subject: [PATCH 1/2] [BoundsSafety] Allow 'counted_by' attribute on pointers
in struc
@@ -335,6 +336,22 @@ Attribute Changes in Clang
- Clang now warns that the ``exclude_from_explicit_instantiation`` attribute
is ignored when applied to a local class or a member thereof.
+- The ``counted_by`` attribute can now be late parsed in C when
delcyp
@@ -6534,6 +6536,15 @@ def err_counted_by_attr_refer_to_union : Error<
"'counted_by' argument cannot refer to a union member">;
def note_flexible_array_counted_by_attr_field : Note<
"field %0 declared here">;
+def err_counted_by_attr_pointee_unknown_size : Error<
+ "'count
@@ -631,6 +631,18 @@ bool Type::isStructureType() const {
return false;
}
+bool Type::isStructureTypeWithFlexibleArrayMember() const {
+ const auto *RT = getAs();
+ if (!RT)
+return false;
+ const auto *Decl = RT->getDecl();
+ if (!Decl->isStruct())
+return false
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/90786
>From 1f4d924768409d6bc61d160c6161e6acebf62b60 Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Wed, 1 May 2024 13:56:52 -0700
Subject: [PATCH 1/3] [BoundsSafety] Allow 'counted_by' attribute on pointers
in struc
@@ -6534,6 +6536,15 @@ def err_counted_by_attr_refer_to_union : Error<
"'counted_by' argument cannot refer to a union member">;
def note_flexible_array_counted_by_attr_field : Note<
"field %0 declared here">;
+def err_counted_by_attr_pointee_unknown_size : Error<
+ "'count
@@ -335,6 +336,22 @@ Attribute Changes in Clang
- Clang now warns that the ``exclude_from_explicit_instantiation`` attribute
is ignored when applied to a local class or a member thereof.
+- The ``counted_by`` attribute can now be late parsed in C when
delcyp
https://github.com/delcypher created
https://github.com/llvm/llvm-project/pull/91032
Due to how `CodeGenFunction::EmitTrapCheck` is implemented `SanitizerHandler`
with numeric value 0x19 needs to be reserved because `-fbounds-safety`
generates trap instructions with that value embedded in the
delcypher wrote:
@bwendling
> I've been thinking about this restriction. Why is this necessary? My
> assumption was that applying counted_by to a pointer causes a bounds check on
> an index into the pointer rather than its underlying type.
@rapidsna Please add additional points if I accidenta
@@ -172,6 +172,27 @@ static bool checkArgCount(Sema &S, CallExpr *Call,
unsigned DesiredArgCount) {
<< /*is non object*/ 0 << Call->getArg(1)->getSourceRange();
}
+static bool checkBuiltinVerboseTrap(CallExpr *Call, Sema &S) {
delcypher wrote:
@ahat
delcypher wrote:
@vitalybuka Ping
https://github.com/llvm/llvm-project/pull/91032
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
delcypher wrote:
> @rapidsna @delcypher @apple-fcloutier @kees:
>
> Okay, I think I see what the complication is. Are you trying to prevent the
> use case of someone writing something like:
>
> ```c
> struct bar;
>
> struct foo {
> size_t count;
> struct bar *ptr __counted_by(count);
> };
delcypher wrote:
> It's not a lie, because the contents of a pointer don't contribute to the
> size of the struct containing that pointer.
Consider this example. It tries to illustrate why putting `__counted_by()` on a
pointer to a structs containing flexible array members doesn't make sense.
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/90786
>From 1f4d924768409d6bc61d160c6161e6acebf62b60 Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Wed, 1 May 2024 13:56:52 -0700
Subject: [PATCH 1/4] [BoundsSafety] Allow 'counted_by' attribute on pointers
in struc
@@ -0,0 +1,187 @@
+// RUN: %clang_cc1 -fsyntax-only -verify %s
+
+#define __counted_by(f) __attribute__((counted_by(f)))
+
+struct bar;
+
+struct not_found {
+ int count;
+ struct bar *fam[] __counted_by(bork); // expected-error {{use of undeclared
identifier 'bork'}}
+};
+
+s
delcypher wrote:
@bwendling @kees Any further feedback? If not, can you approve?
As @rapidsna said we'll follow up this PR with additional PRs to address the
two major concerns you had.
https://github.com/llvm/llvm-project/pull/90786
___
cfe-commits
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/90786
>From e6fb7a3374ada3d02b4c89263ffd14a037a7e56a Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Wed, 1 May 2024 13:56:52 -0700
Subject: [PATCH] [BoundsSafety] Allow 'counted_by' attribute on pointers in
structs i
https://github.com/delcypher closed
https://github.com/llvm/llvm-project/pull/91032
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
delcypher wrote:
@kees Thanks for approving.
I'm going to resolve the merge conflict in `clang/docs/ReleaseNotes.rst` and
then merge. I'll start looking at supporting `__counted_by()` on incomplete
pointee types next. @hnrklssn is going to start working on upstreaming the
`__sized_by` attribu
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/90786
>From 80dbab4c4b43eb78f29b7b8fa577f04772a7f52c Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Wed, 1 May 2024 13:56:52 -0700
Subject: [PATCH] [BoundsSafety] Allow 'counted_by' attribute on pointers in
structs i
https://github.com/delcypher closed
https://github.com/llvm/llvm-project/pull/90786
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
delcypher wrote:
Looks like I broke the
`clang/test/Misc/pragma-attribute-supported-attributes-list.test` test. I'll
push a follow up fix to that test once I've confirmed I've fixed it.
https://github.com/llvm/llvm-project/pull/90786
___
cfe-commits
Author: Dan Liew
Date: 2024-05-17T13:09:22-07:00
New Revision: 112eadd55f06bee15caadff688ea0b45acbfa804
URL:
https://github.com/llvm/llvm-project/commit/112eadd55f06bee15caadff688ea0b45acbfa804
DIFF:
https://github.com/llvm/llvm-project/commit/112eadd55f06bee15caadff688ea0b45acbfa804.diff
LOG:
delcypher wrote:
Test fixed by `112eadd55f06bee15caadff688ea0b45acbfa804`.
https://github.com/llvm/llvm-project/pull/90786
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
delcypher wrote:
@bwendling This is unfortunate
```
drivers/gpu/drm/radeon/pptable.h:442:5: error: 'counted_by' cannot be applied
to an array with element of unknown size because 'ATOM_PPLIB_STATE_V2' (aka
'struct _ATOM_PPLIB_STATE_V2') is a struct type with a flexible array member
442 |
Author: Dan Liew
Date: 2024-05-17T16:23:24-07:00
New Revision: cef6387e52578366c2332275dad88b9953b55336
URL:
https://github.com/llvm/llvm-project/commit/cef6387e52578366c2332275dad88b9953b55336
DIFF:
https://github.com/llvm/llvm-project/commit/cef6387e52578366c2332275dad88b9953b55336.diff
LOG:
delcypher wrote:
@kees @bwendling @rapidsna The workaround to downgrade this error to a warning
has landed
https://github.com/llvm/llvm-project/commit/cef6387e52578366c2332275dad88b9953b55336
https://github.com/llvm/llvm-project/pull/90786
___
cfe-com
https://github.com/delcypher created
https://github.com/llvm/llvm-project/pull/92623
This adds the `-fexperimental-bounds-safety` cc1 and corresponding language
option. This language option enables "-fbounds-safety" which is a bounds-safety
extension for C that is being incrementally upstreame
delcypher wrote:
This is based on #70480 but removes the driver part of the change and makes the
flag a CC1 flag only.
https://github.com/llvm/llvm-project/pull/92623
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-b
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/92623
>From ef46dd51c5c54cf5a76d83b9c15f8f3aee052e42 Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Fri, 17 May 2024 17:15:48 -0700
Subject: [PATCH] [BoundsSafety] Add `-fexperimental-bounds-safety` CC1 and
language
https://github.com/delcypher edited
https://github.com/llvm/llvm-project/pull/92623
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
delcypher wrote:
Hmm. Apparently there's a memory leak.
https://lab.llvm.org/buildbot/#/builders/239/builds/7043
```
-- Testing: 79948 of 79949 tests, 48 workers --
Testing:
FAIL: Clang :: AST/attr-counted-by-late-parsed-struct-ptrs.c (480 of 79948)
TEST 'Clang ::
AST/att
delcypher wrote:
Hmm. Apparently there's a memory leak.
https://lab.llvm.org/buildbot/#/builders/239/builds/7043
```
-- Testing: 79948 of 79949 tests, 48 workers --
Testing:
FAIL: Clang :: AST/attr-counted-by-late-parsed-struct-ptrs.c (480 of 79948)
TEST 'Clang ::
AST/att
delcypher wrote:
The leak via `clang::Parser::ParseLexedCAttribute` is
```c++
LA.Toks.push_back(AttrEnd);
```
and the leak via `clang::Parser::ParseGNUAttributes`
is
```
LateParsedAttribute *LA =
new LateParsedAttribute(this, *AttrName, AttrNameLoc);
```
which is really old
delcypher wrote:
Ok. Now I see what's happening.
These lines here are basically giving ownership of `LateParsedAttribute` to the
`LateParsedAttrList`
```
// Handle attributes with arguments that require late parsing.
LateParsedAttribute *LA =
new LateParsedAttribute(this,
delcypher wrote:
I'll put up a new version of this PR with the memory leak fixed soon.
https://github.com/llvm/llvm-project/pull/90786
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
delcypher wrote:
@erichkeane I posted the comment on the wrong PR. The memory leak is in #90786
not this PR so I deleted the comment i made here. #90786 has already been
reverted.
https://github.com/llvm/llvm-project/pull/88596
___
cfe-commits maili
https://github.com/delcypher created
https://github.com/llvm/llvm-project/pull/93121
This PR attempts to reland https://github.com/llvm/llvm-project/pull/90786 that
was reverted due to a memory leak.
This PR includes the following commits
1. The original commit in #90786 (originally
0ec3b97
@@ -744,7 +744,13 @@ void Parser::ParseLexedAttributeList(LateParsedAttrList
&LAs, Decl *D,
for (unsigned i = 0, ni = LAs.size(); i < ni; ++i) {
if (D)
LAs[i]->addDecl(D);
-ParseLexedAttribute(*LAs[i], EnterScope, OnDefinition);
+// FIXME: There has to be a
delcypher wrote:
@rapidsna Please check 604e274a5bc37b18c3bc89eed5749c8617de36e7 to check you
are happy with the way I'm fixing the memory leak.
https://github.com/llvm/llvm-project/pull/93121
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
ht
delcypher wrote:
This is blocked by #93121
https://github.com/llvm/llvm-project/pull/92623
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
delcypher wrote:
Hmm looks like I broke
```
Clang :: Sema/attr-capabilities.c
Clang :: Sema/diagnose_if.c
Clang :: Sema/warn-thread-safety-analysis.c
Clang :: SemaObjC/warn-thread-safety-analysis.m
```
Let's see if I can figure out what I did...
https://github.com/llvm/llvm-project/pul
delcypher wrote:
Okay this is interesting...
```
FAIL: Clang :: SemaObjC/warn-thread-safety-analysis.m (15515 of 19369)
TEST 'Clang :: SemaObjC/warn-thread-safety-analysis.m'
FAILED
Exit Code: 134
Command Output (stderr):
--
RUN: a
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/93121
>From 7f5af7cc180825e07b5f5292e3f6b860c8e8591e Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Fri, 17 May 2024 12:07:40 -0700
Subject: [PATCH 1/6] [BoundsSafety] Allow 'counted_by' attribute on pointers
in stru
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/93121
>From 7f5af7cc180825e07b5f5292e3f6b860c8e8591e Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Fri, 17 May 2024 12:07:40 -0700
Subject: [PATCH 1/7] [BoundsSafety] Allow 'counted_by' attribute on pointers
in stru
https://github.com/delcypher edited
https://github.com/llvm/llvm-project/pull/93121
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -4993,20 +4993,8 @@ void Parser::ParseLexedCAttribute(LateParsedAttribute
&LA,
"late field attribute expects to have at most one declaration.");
// Dispatch based on the attribute and parse it
- const AttributeCommonInfo::Form ParsedForm = ParsedAttr::Form::GNU
delcypher wrote:
Hmm looks like I'll have to tweak the assert. Looks like some unit tests don't
specify the language.
```
FAIL: Clang-Unit :: CodeGen/./ClangCodeGenTests/5/16 (19428 of 19653)
TEST 'Clang-Unit :: CodeGen/./ClangCodeGenTests/5/16'
FAILED
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/93121
>From 7f5af7cc180825e07b5f5292e3f6b860c8e8591e Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Fri, 17 May 2024 12:07:40 -0700
Subject: [PATCH 1/7] [BoundsSafety] Allow 'counted_by' attribute on pointers
in stru
@@ -4944,6 +4944,26 @@ void Parser::ParseStructDeclaration(
}
}
+// TODO: All callers of this function should be moved to
+// `Parser::ParseLexedAttributeList`.
+void Parser::ParseLexedCAttributeList(LateParsedAttrList &LAs, bool EnterScope,
+
@@ -4944,6 +4944,26 @@ void Parser::ParseStructDeclaration(
}
}
+// TODO: All callers of this function should be moved to
+// `Parser::ParseLexedAttributeList`.
+void Parser::ParseLexedCAttributeList(LateParsedAttrList &LAs, bool EnterScope,
+
@@ -4944,6 +4944,26 @@ void Parser::ParseStructDeclaration(
}
}
+// TODO: All callers of this function should be moved to
+// `Parser::ParseLexedAttributeList`.
+void Parser::ParseLexedCAttributeList(LateParsedAttrList &LAs, bool EnterScope,
+
@@ -4944,6 +4944,26 @@ void Parser::ParseStructDeclaration(
}
}
+// TODO: All callers of this function should be moved to
+// `Parser::ParseLexedAttributeList`.
+void Parser::ParseLexedCAttributeList(LateParsedAttrList &LAs, bool EnterScope,
+
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/93121
>From bc5b8bc34b50e2e98d2c6103c7b1c232a3e765b4 Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Fri, 17 May 2024 12:07:40 -0700
Subject: [PATCH] [BoundsSafety] Reland #93121 Allow 'counted_by' attribute on
pointe
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/93121
>From f9c8abdb243096b6fe0c2ad1a42023039ca7f1f2 Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Fri, 17 May 2024 12:07:40 -0700
Subject: [PATCH] [BoundsSafety] Reland #93121 Allow 'counted_by' attribute on
pointe
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/93121
>From 9e1a9e49b33d4b77d75cee243244dd66a40ea209 Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Fri, 17 May 2024 12:07:40 -0700
Subject: [PATCH] [BoundsSafety] Reland #93121 Allow 'counted_by' attribute on
pointe
https://github.com/delcypher edited
https://github.com/llvm/llvm-project/pull/93121
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/delcypher edited
https://github.com/llvm/llvm-project/pull/93121
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
delcypher wrote:
Filed to #93263 to track the potential refactor.
https://github.com/llvm/llvm-project/pull/93121
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/delcypher updated
https://github.com/llvm/llvm-project/pull/93121
>From c1f0914b1f8ae8416cebdf7f0573b4ff11f6110d Mon Sep 17 00:00:00 2001
From: Dan Liew
Date: Fri, 17 May 2024 12:07:40 -0700
Subject: [PATCH] [BoundsSafety] Reland #93121 Allow 'counted_by' attribute on
pointe
https://github.com/delcypher closed
https://github.com/llvm/llvm-project/pull/93121
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
delcypher wrote:
@hnrklssn #93121 has been landed. Let's hope it sticks this time 🤞
https://github.com/llvm/llvm-project/pull/93231
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/delcypher requested changes to this pull request.
Looks pretty good. I have some minor comments.
https://github.com/llvm/llvm-project/pull/93231
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/m
@@ -8641,22 +8641,33 @@ enum class CountedByInvalidPointeeTypeKind {
VALID,
};
-static bool CheckCountedByAttrOnField(
-Sema &S, FieldDecl *FD, Expr *E,
-llvm::SmallVectorImpl &Decls) {
+static bool
+CheckCountedByAttrOnField(Sema &S, FieldDecl *FD, Expr *E,
+
@@ -8641,22 +8641,33 @@ enum class CountedByInvalidPointeeTypeKind {
VALID,
};
-static bool CheckCountedByAttrOnField(
-Sema &S, FieldDecl *FD, Expr *E,
-llvm::SmallVectorImpl &Decls) {
+static bool
+CheckCountedByAttrOnField(Sema &S, FieldDecl *FD, Expr *E,
+
https://github.com/delcypher edited
https://github.com/llvm/llvm-project/pull/93231
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
201 - 300 of 447 matches
Mail list logo