@@ -84,6 +84,29 @@ void test_macro_expansion4() {
#undef MY_NULL
}
+template struct pear {
+ // If you say __null (or NULL), we assume that T will always be a pointer
fmayer wrote:
why are we only testing one of those?
https://github.com/llvm/llvm-project/
@@ -84,6 +84,29 @@ void test_macro_expansion4() {
#undef MY_NULL
}
+template struct pear {
+ // If you say __null (or NULL), we assume that T will always be a pointer
fmayer wrote:
Sorry, the implication of my comment was: explain why in a comment, because
https://github.com/fmayer approved this pull request.
https://github.com/llvm/llvm-project/pull/109169
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -84,6 +84,29 @@ void test_macro_expansion4() {
#undef MY_NULL
}
+template struct pear {
+ // If you say __null (or NULL), we assume that T will always be a pointer
fmayer wrote:
Thanks, otherwise this comment will only cause confusion.
https://github.co
https://github.com/fmayer approved this pull request.
LGTM % vitaly's comment
https://github.com/llvm/llvm-project/pull/100937
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -84,6 +84,28 @@ void test_macro_expansion4() {
#undef MY_NULL
}
+template struct pear {
+ // If you say __null (or NULL), we assume that T will always be a pointer
+ // type, so we suggest replacing it with nullptr.
+ void f() { x = __null; }
+ // CHECK-MESSAGES: :[[@L
@@ -84,6 +84,28 @@ void test_macro_expansion4() {
#undef MY_NULL
}
+template struct pear {
+ // If you say __null (or NULL), we assume that T will always be a pointer
+ // type, so we suggest replacing it with nullptr.
+ void f() { x = __null; }
+ // CHECK-MESSAGES: :[[@L
@@ -84,6 +84,28 @@ void test_macro_expansion4() {
#undef MY_NULL
}
+template struct pear {
+ // If you say __null (or NULL), we assume that T will always be a pointer
+ // type, so we suggest replacing it with nullptr.
+ void f() { x = __null; }
+ // CHECK-MESSAGES: :[[@L
@@ -84,6 +84,28 @@ void test_macro_expansion4() {
#undef MY_NULL
}
+template struct pear {
+ // If you say __null (or NULL), we assume that T will always be a pointer
+ // type, so we suggest replacing it with nullptr.
+ void f() { x = __null; }
+ // CHECK-MESSAGES: :[[@L
https://github.com/fmayer closed
https://github.com/llvm/llvm-project/pull/109169
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/111918
>From 3a962270521aa7b48b64e5ac5fa0edb900990023 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 10 Oct 2024 16:05:50 -0700
Subject: [PATCH 1/4] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UT
fmayer wrote:
An example dump that is now possible but crashed before

https://github.com/llvm/llvm-project/pull/112457
___
cfe-commits mailing list
cfe-commits@l
https://github.com/fmayer created
https://github.com/llvm/llvm-project/pull/112457
We have an internal analysis that uses them, and the HTML dump would
fail on the assertion.
>From 4264fe1dfed3fc54f339ad4a769d76158c5ee7d5 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Tue, 15 Oct 2024 17:
@@ -764,11 +764,17 @@ void AsmPrinter::emitGlobalVariable(const GlobalVariable
*GV) {
const DataLayout &DL = GV->getDataLayout();
uint64_t Size = DL.getTypeAllocSize(GV->getValueType());
+ if (GV->isTagged())
+Size = alignTo(Size, 16);
// If the alignment is spe
@@ -194,12 +198,43 @@ Some issues with flags can be debugged using the
``verbosity=$NUM`` flag:
misspelled_flag
...
-Disabling
--
+Disabling and suppressing
+-
-In some circumstances, you may want to suppress error reporting in a specif
fmayer wrote:
> LLVM Buildbot has detected a new failure on builder
> `sanitizer-aarch64-linux-bootstrap-hwasan` running on `sanitizer-buildbot11`
> while building `clang-tools-extra` at step 2 "annotate".
>
> Full details are available at:
> https://lab.llvm.org/buildbot/#/builders/55/builds
https://github.com/fmayer approved this pull request.
https://github.com/llvm/llvm-project/pull/116302
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer created
https://github.com/llvm/llvm-project/pull/125958
one would assume that `getCanonicalTypeUnqualified` returns an
unqualified type, but sadly one would be wrong. the current logic fails
for std::optional as implemented in libcxx, because Star and Arrow types
misma
https://github.com/fmayer ready_for_review
https://github.com/llvm/llvm-project/pull/125958
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -7,6 +7,16 @@
// RUN: %clang_cc1 -emit-llvm -triple x86_64 -fstrict-flex-arrays=2
-fsanitize=array-bounds -x c++ %s -o - | FileCheck %s
--check-prefixes=CHECK,CHECK-STRICT-2,CXX
// RUN: %clang_cc1 -emit-llvm -triple x86_64 -fstrict-flex-arrays=3
-fsanitize=array-bounds
@@ -444,6 +444,19 @@ class LangOptionsBase {
IncompleteOnly = 3,
};
+ enum class ArrayBoundsStrictFlexArraysLevelKind {
fmayer wrote:
we can't use -1 because it's a bitfield, but I can use 4
https://github.com/llvm/llvm-project/pull/126163
___
@@ -444,6 +444,19 @@ class LangOptionsBase {
IncompleteOnly = 3,
};
+ enum class ArrayBoundsStrictFlexArraysLevelKind {
fmayer wrote:
Wouldn't that mean that cc1 and clang have different semantics for this flag?
https://github.com/llvm/llvm-project/pu
@@ -1192,13 +1193,40 @@ llvm::Value *CodeGenFunction::EmitLoadOfCountedByField(
return nullptr;
}
+LangOptions::StrictFlexArraysLevelKind
+CodeGenFunction::effectiveArrayBoundsFlexArraysLevel() {
+ using StrictFlexArraysLevelKind = LangOptions::StrictFlexArraysLevelKind;
+
@@ -444,6 +444,19 @@ class LangOptionsBase {
IncompleteOnly = 3,
};
+ enum class ArrayBoundsStrictFlexArraysLevelKind {
fmayer wrote:
because we currently only store 3 bits for this, using -1 would be out of range
of that and just truncate to 111 = 7
https://github.com/fmayer deleted
https://github.com/llvm/llvm-project/pull/126163
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -444,6 +444,19 @@ class LangOptionsBase {
IncompleteOnly = 3,
};
+ enum class ArrayBoundsStrictFlexArraysLevelKind {
fmayer wrote:
i have a weak preference for flags to have a value that can represent the state
that is the same as if they were not
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/126163
>From e9f2dbecb2b4836100a565b4c741fc3425d08966 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 6 Feb 2025 16:50:02 -0800
Subject: [PATCH 1/2] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UTF
@@ -1192,13 +1193,40 @@ llvm::Value *CodeGenFunction::EmitLoadOfCountedByField(
return nullptr;
}
+LangOptions::StrictFlexArraysLevelKind
+CodeGenFunction::effectiveArrayBoundsFlexArraysLevel() {
+ using StrictFlexArraysLevelKind = LangOptions::StrictFlexArraysLevelKind;
+
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/126163
>From e9f2dbecb2b4836100a565b4c741fc3425d08966 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 6 Feb 2025 16:50:02 -0800
Subject: [PATCH 1/3] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UTF
https://github.com/fmayer edited
https://github.com/llvm/llvm-project/pull/126163
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
fmayer wrote:
> Usually our tweak flags looks like -fsanitize--
>
> "bounds" is a group for (array-bounds + local-bounds) "undefined" is also
> group, but we already have -fsanitize-undefined-, but they kind of affect a
> few sanitizers
>
> so: `-fsanitize-undefined-strict-flex-arrays` or
>
fmayer wrote:
> What else even uses the level? __builtin_object_size codegen? Can you add a
> DocBrief to the flag explaining when you'd want to use it?
Let me find out details. We have some code that miscompiles with
`-fstrict-flex-arrays=1`, so something is exploiting the UB.
https://githu
https://github.com/fmayer created
https://github.com/llvm/llvm-project/pull/126166
Fix existing failure
>From 85540ede2e0ba1b6f0b8a69ac6d5a6ddf56fdfc8 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 6 Feb 2025 17:41:59 -0800
Subject: [PATCH] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=9
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/126166
>From 85540ede2e0ba1b6f0b8a69ac6d5a6ddf56fdfc8 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 6 Feb 2025 17:41:59 -0800
Subject: [PATCH 1/2] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UTF
https://github.com/fmayer closed
https://github.com/llvm/llvm-project/pull/125958
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer created
https://github.com/llvm/llvm-project/pull/126163
This is the control the definition of flex arrays separately for bounds
sanitizer than for the codegen.
>From e9f2dbecb2b4836100a565b4c741fc3425d08966 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 6 F
https://github.com/fmayer ready_for_review
https://github.com/llvm/llvm-project/pull/126163
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
fmayer wrote:
@zahiraam the default of the `ComplexRange`, `CX_None` does overflow the `2`
storage bits. That means we were probably still using `CX_Full` (4 should
overflow to `0`) even after https://github.com/llvm/llvm-project/pull/78330 (I
am not sure why "make sure why that changed the de
https://github.com/fmayer ready_for_review
https://github.com/llvm/llvm-project/pull/126166
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
fmayer wrote:
> > @zahiraam the default of the `ComplexRange`, `CX_None` does overflow the
> > `2` storage bits. That means we were probably still using `CX_Full` (4
> > should overflow to `0`) even after #78330 (I am not sure why why that
> > changed the default in the first place). Also it's
fmayer wrote:
> > > Not sure I understand your question? Which assertion? `clang.exe t.c` is
> > > triggering an assertion?
> >
> >
> > I don't understand why you say
> > > The value `CX_None` is the defaut value given to the `Range` when no
> > > `fcomplex-arithmetic` is used on the command
fmayer wrote:
> Not sure I understand your question? Which assertion? `clang.exe t.c` is
> triggering an assertion?
I don't understand why you say
> The value `CX_None` is the defaut value given to the `Range` when no
> `fcomplex-arithmetic` is used on the command lin
but imply it does not n
fmayer wrote:
> A fix-forward for a `-Werror` failure is much easier
> [07f2154](https://github.com/llvm/llvm-project/commit/07f21541424c95b4451292b288e5d69272c8020c).
Yeah I realised, so I closed this :) Sorry for the spam
https://github.com/llvm/llvm-project/pull/126610
_
fmayer wrote:
> > > > > Not sure I understand your question? Which assertion? `clang.exe t.c`
> > > > > is triggering an assertion?
> > > >
> > > >
> > > > I don't understand why you say
> > > > > The value `CX_None` is the defaut value given to the `Range` when no
> > > > > `fcomplex-arithme
https://github.com/fmayer created
https://github.com/llvm/llvm-project/pull/126658
IsLastOrInvalidFieldDecl would always return true if `Invalid=true`, so
we know that !IsLastOrInvalidFieldDecl(...) means !Invalid.
>From cc8aa7242294c5af5ae839396f02acc22b3afbb5 Mon Sep 17 00:00:00 2001
From: F
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/126658
>From cc8aa7242294c5af5ae839396f02acc22b3afbb5 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Mon, 10 Feb 2025 19:10:56 -0800
Subject: [PATCH 1/2] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UT
https://github.com/fmayer created
https://github.com/llvm/llvm-project/pull/126610
Reverts llvm/llvm-project#126544
This broke the build on sanitizer buildbots:
https://lab.llvm.org/buildbot/#/builders/66/builds/9811
>From 7d3737f2374f489256bc3fce9cb96283e8307f75 Mon Sep 17 00:00:00 2001
From
https://github.com/fmayer closed
https://github.com/llvm/llvm-project/pull/126610
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer created
https://github.com/llvm/llvm-project/pull/126796
None
>From 9811b24583640d9d70e5a496d1e3444ee86fea77 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Tue, 11 Feb 2025 13:14:26 -0800
Subject: [PATCH] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20initia?=
https://github.com/fmayer ready_for_review
https://github.com/llvm/llvm-project/pull/126796
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/126166
>From 85540ede2e0ba1b6f0b8a69ac6d5a6ddf56fdfc8 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 6 Feb 2025 17:41:59 -0800
Subject: [PATCH 1/2] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UTF
https://github.com/fmayer closed
https://github.com/llvm/llvm-project/pull/126166
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer closed
https://github.com/llvm/llvm-project/pull/126658
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/111918
>From 3a962270521aa7b48b64e5ac5fa0edb900990023 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 10 Oct 2024 16:05:50 -0700
Subject: [PATCH 1/5] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UT
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/111918
>From 3a962270521aa7b48b64e5ac5fa0edb900990023 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 10 Oct 2024 16:05:50 -0700
Subject: [PATCH 1/5] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UT
fmayer wrote:
sorry, messed up the upload
https://github.com/llvm/llvm-project/pull/111918
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/111918
error: too big or took too long to generate
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
fmayer wrote:
@pcc does this look better now?
https://github.com/llvm/llvm-project/pull/111918
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -808,6 +808,10 @@ void Verifier::visitGlobalValue(const GlobalValue &GV) {
"visibility must be dso_local!",
&GV);
+ if (GV.isTagged()) {
fmayer wrote:
The codegen has "is section == precisely honor alignment"
```
Align DataLayout::get
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/111918
error: too big or took too long to generate
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -2406,12 +2406,55 @@ void
AsmPrinter::emitRemarksSection(remarks::RemarkStreamer &RS) {
OutStreamer->emitBinaryData(Buf);
}
+static void tagGlobalDefinition(Module &M, GlobalVariable *G) {
+ Constant *Initializer = G->getInitializer();
+ uint64_t SizeInBytes =
+ M
https://github.com/fmayer closed
https://github.com/llvm/llvm-project/pull/111918
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,194 @@
+//===- unittests/Analysis/FlowSensitive/SmartPointerAccessorCachingTest.cpp
==//
+//
+// 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,134 @@
+#include "clang/Analysis/FlowSensitive/SmartPointerAccessorCaching.h"
+
+#include "clang/AST/CanonicalType.h"
+#include "clang/AST/DeclCXX.h"
+#include "clang/ASTMatchers/ASTMatchers.h"
+#include "clang/Basic/OperatorKinds.h"
+
+namespace clang::dataflow {
+
+na
fmayer wrote:
> > I had to do something very similar for CHERI downstream: We have to ensure
> > that all globals are precisely representable (which may require rounding up
> > the size+alignment) so you don't end up creating bounds that include
> > adjacent ones. The original patch from 2019
fmayer wrote:
> Remove functional pass
function pass?
https://github.com/llvm/llvm-project/pull/119739
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer approved this pull request.
https://github.com/llvm/llvm-project/pull/119739
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/111918
error: too big or took too long to generate
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -2406,12 +2406,55 @@ void
AsmPrinter::emitRemarksSection(remarks::RemarkStreamer &RS) {
OutStreamer->emitBinaryData(Buf);
}
+static void tagGlobalDefinition(Module &M, GlobalVariable *G) {
+ Constant *Initializer = G->getInitializer();
+ uint64_t SizeInBytes =
+ M
https://github.com/fmayer approved this pull request.
https://github.com/llvm/llvm-project/pull/119904
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
fmayer wrote:
I was working on this miscompile. I cannot give a reproducer right now, but the
following observations:
The generated IR is clearly incorrect (the `inbounds nuw`), of the form:
```
%x = alloca [12 x i32], align 16
[...]
%59 = getelementptr inbounds nuw i8, ptr %x, i64 -4
%wide.ma
fmayer wrote:
Seems like the root cause was an vectorizer bug, sent
https://github.com/llvm/llvm-project/pull/120730 that fixes it.
https://github.com/llvm/llvm-project/pull/119225
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.
fmayer wrote:
Fails buildbot:
https://lab.llvm.org/buildbot/#/builders/24/builds/2791/steps/10/logs/stdio
```
-- Testing: 83950 of 83951 tests, 48 workers --
Testing: 0.. 10..
FAIL: Clang :: Preprocessor/has_builtin_cpuid.c (15996 of 83950)
TEST 'Clang :: Preprocessor/has_
https://github.com/fmayer approved this pull request.
https://github.com/llvm/llvm-project/pull/117187
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -25,3 +25,7 @@ attributes #0 = { mustprogress noinline sanitize_realtime
optnone ssp uwtable(sy
; RealtimeSanitizer pass should insert __rtsan_realtime_exit right before
function return
; CHECK: call{{.*}}@__rtsan_realtime_exit
; CHECK-NEXT: ret{{.*}}void
+
+; RealtimeSani
https://github.com/fmayer approved this pull request.
https://github.com/llvm/llvm-project/pull/118989
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
fmayer wrote:
> Seems like the root cause was an vectorizer bug, sent
> https://github.com/llvm/llvm-project/pull/120730 that fixes it.
This is landed, so from that side we could reland this.
https://github.com/llvm/llvm-project/pull/119225
___
cfe-c
https://github.com/fmayer created
https://github.com/llvm/llvm-project/pull/123228
This slightly simplifies the code.
>From 010c9738c2182d3e269c305fd97dbb498a5dc717 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 16 Jan 2025 11:23:54 -0800
Subject: [PATCH] =?UTF-8?q?[=F0=9D=98=80=F0=9
https://github.com/fmayer closed
https://github.com/llvm/llvm-project/pull/123228
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer ready_for_review
https://github.com/llvm/llvm-project/pull/123228
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
fmayer wrote:
> The idea here makes sense to me and I don't mind if it lands without "NFC" in
> the title, but I think enforcing this at compile time would be more robust.
> Could we use `static_assert` with something like `llvm::BitWidth` and
> supporting infrastructure from `llvm/include/ADT
Author: Florian Mayer
Date: 2025-02-11T13:42:31-08:00
New Revision: ad905f133c5b22896900f3f335de990d0daf1ff4
URL:
https://github.com/llvm/llvm-project/commit/ad905f133c5b22896900f3f335de990d0daf1ff4
DIFF:
https://github.com/llvm/llvm-project/commit/ad905f133c5b22896900f3f335de990d0daf1ff4.diff
fmayer wrote:
> I think isa should be preferred if the result of dyncast is not used. Same
> applied to the surrounding ifs too.
https://github.com/llvm/llvm-project/commit/ad905f133c5b22896900f3f335de990d0daf1ff4
https://github.com/llvm/llvm-project/pull/126796
___
https://github.com/fmayer closed
https://github.com/llvm/llvm-project/pull/126796
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1681,7 +1681,7 @@ std::optional
Sema::GetDecompositionElementCount(QualType T,
llvm::APSInt TupleSize(Ctx.getTypeSize(Ctx.getSizeType()));
switch (isTupleLike(*this, Loc, T, TupleSize)) {
case IsTupleLike::Error:
-return {};
+return std::nullopt;
fmayer wrote:
Please take a look at the sanitizer buildbot failure above.
https://github.com/llvm/llvm-project/pull/132037
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer approved this pull request.
https://github.com/llvm/llvm-project/pull/132091
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer closed
https://github.com/llvm/llvm-project/pull/132314
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1681,7 +1681,7 @@ std::optional
Sema::GetDecompositionElementCount(QualType T,
llvm::APSInt TupleSize(Ctx.getTypeSize(Ctx.getSizeType()));
switch (isTupleLike(*this, Loc, T, TupleSize)) {
case IsTupleLike::Error:
-return {};
+return std::nullopt;
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/134310
>From 44f9ccd6b4104fb07ad9cf9581c41c6d473525ec Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 3 Apr 2025 14:53:29 -0700
Subject: [PATCH 1/2] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UTF
fmayer wrote:
Looks like this CL broke the MSAN bot:
https://lab.llvm.org/buildbot/#/builders/169/builds/10068
https://github.com/llvm/llvm-project/pull/132748
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/ma
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/134310
>From 44f9ccd6b4104fb07ad9cf9581c41c6d473525ec Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 3 Apr 2025 14:53:29 -0700
Subject: [PATCH 1/3] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UTF
https://github.com/fmayer closed
https://github.com/llvm/llvm-project/pull/132993
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/133350
>From 8ece858e76fad0962b2567f03bf80bcaf2828348 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 27 Mar 2025 18:25:23 -0700
Subject: [PATCH 1/4] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UT
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/133350
>From 8ece858e76fad0962b2567f03bf80bcaf2828348 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 27 Mar 2025 18:25:23 -0700
Subject: [PATCH 1/2] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UT
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/133350
>From 8ece858e76fad0962b2567f03bf80bcaf2828348 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 27 Mar 2025 18:25:23 -0700
Subject: [PATCH 1/3] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UT
https://github.com/fmayer created
https://github.com/llvm/llvm-project/pull/132993
None
>From 4bd5834b5f32250269e67a9b26e406b9e01a37b1 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Tue, 25 Mar 2025 14:05:31 -0700
Subject: [PATCH] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20initia?=
@@ -41,31 +41,31 @@ void caller(void (*f)(void)) {
// CHECK: [[CONT1]]:
// CHECK: %[[NOT_1:.*]] = icmp ne i8 %[[KIND]], 1
-// CHECK: br i1 %[[NOT_1]], label %[[CONT2:.*]], label %[[HANDLE1:.*]],
!nosanitize
+// CHECK: br i1 %[[NOT_1]], label %[[CONT2:.*]], label %[[HAND
https://github.com/fmayer updated
https://github.com/llvm/llvm-project/pull/133350
>From 8ece858e76fad0962b2567f03bf80bcaf2828348 Mon Sep 17 00:00:00 2001
From: Florian Mayer
Date: Thu, 27 Mar 2025 18:25:23 -0700
Subject: [PATCH 1/7] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UT
@@ -23,12 +24,27 @@ using ast_matchers::pointerType;
using ast_matchers::referenceType;
using ast_matchers::returns;
-bool hasSmartPointerClassShape(const CXXRecordDecl &RD, bool &HasGet,
- bool &HasValue) {
+CanQualType getLikeReturnType(QualType
101 - 200 of 281 matches
Mail list logo