Author: Timm Baeder
Date: 2024-08-18T08:59:34+02:00
New Revision: dac182990dabe8d15cfb8079aba68df2ded015aa
URL:
https://github.com/llvm/llvm-project/commit/dac182990dabe8d15cfb8079aba68df2ded015aa
DIFF:
https://github.com/llvm/llvm-project/commit/dac182990dabe8d15cfb8079aba68df2ded015aa.diff
L
https://github.com/tbaederr closed
https://github.com/llvm/llvm-project/pull/104686
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
Author: Timm Bäder
Date: 2024-08-18T08:55:22+02:00
New Revision: 07bd3bb9b7eb34426a81de2b988f53f08611ab35
URL:
https://github.com/llvm/llvm-project/commit/07bd3bb9b7eb34426a81de2b988f53f08611ab35
DIFF:
https://github.com/llvm/llvm-project/commit/07bd3bb9b7eb34426a81de2b988f53f08611ab35.diff
LO
llvmbot wrote:
@llvm/pr-subscribers-clang-tidy
Author: None (c8ef)
Changes
close: #40544.
---
Full diff: https://github.com/llvm/llvm-project/pull/104694.diff
3 Files Affected:
- (modified)
clang-tools-extra/clang-tidy/readability/ImplicitBoolConversionCheck.cpp
(+27-9)
- (modified)
https://github.com/c8ef edited https://github.com/llvm/llvm-project/pull/104694
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/c8ef created https://github.com/llvm/llvm-project/pull/104694
None
>From 5e2cd3fa3ce2676e4d528bd8c1342af138cca604 Mon Sep 17 00:00:00 2001
From: c8ef
Date: Sun, 18 Aug 2024 06:17:32 +
Subject: [PATCH] [clang-tidy] readability-implicit-bool-conversion take
readability-upp
https://github.com/xgupta closed
https://github.com/llvm/llvm-project/pull/104674
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
Author: Mike Crowe
Date: 2024-08-18T11:28:25+05:30
New Revision: 88f801037338a2c273a8f6dea8ebcb0c48a2cc06
URL:
https://github.com/llvm/llvm-project/commit/88f801037338a2c273a8f6dea8ebcb0c48a2cc06
DIFF:
https://github.com/llvm/llvm-project/commit/88f801037338a2c273a8f6dea8ebcb0c48a2cc06.diff
LO
https://github.com/xgupta approved this pull request.
Thanks!
https://github.com/llvm/llvm-project/pull/104674
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/ergawy updated
https://github.com/llvm/llvm-project/pull/104664
>From 8b911e77c30edb19cc5dbb95423de0290ddf2c6b Mon Sep 17 00:00:00 2001
From: ergawy
Date: Sat, 17 Aug 2024 00:20:11 -0500
Subject: [PATCH] [flang][driver] Add pre-processing type to `.i` files
This diff allows
https://github.com/farzonl edited
https://github.com/llvm/llvm-project/pull/104619
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1122,6 +1122,154 @@ bool Sema::CheckInstantiatedFunctionTemplateConstraints(
PointOfInstantiation, Satisfaction);
}
+namespace {
+
+// We employ a TreeTransform because RAV couldn't recurse into a bunch of
+// Exprs e.g. SizeOfPackExpr,
DTeachs wrote:
We should probably backport this to 19.x
https://github.com/llvm/llvm-project/pull/104663
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
Endilll wrote:
@MitalAshok Is there anything left to do here?
https://github.com/llvm/llvm-project/pull/94118
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
github-actions[bot] wrote:
:warning: C/C++ code formatter, clang-format found issues in your code.
:warning:
You can test this locally with the following command:
``bash
git-clang-format --diff 27d37ee4d067f42e9a46a0871d3cb961323e5c85
919da31d73a408f16e1c855cb658359b73ad1d28 --e
llvmbot wrote:
@llvm/pr-subscribers-clang
Author: Timm Baeder (tbaederr)
Changes
... to current offset. This breaks other tests which this commit also fixes.
Namely, getIndex() should return the integer representation for non-block
pointers.
---
Full diff: https://github.com/llvm/llvm-p
https://github.com/tbaederr created
https://github.com/llvm/llvm-project/pull/104686
... to current offset. This breaks other tests which this commit also fixes.
Namely, getIndex() should return the integer representation for non-block
pointers.
>From c85a03aa716aa2c3d23ed2567b1d81066b160dee
cor3ntin wrote:
can you add a test for void? we should make sure this still warns!
https://github.com/llvm/llvm-project/pull/104677
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -402,6 +402,21 @@
// MCPU-SIFIVE-P670-SAME: "-target-feature" "+zvkt"
// MCPU-SIFIVE-P670-SAME: "-target-abi" "lp64d"
+// RUN: %clang -target riscv32 -### -c %s 2>&1 -mcpu=rp2350-hazard3 |
FileCheck -check-prefix=MCPU-HAZARD3 %s
+// MCPU-HAZARD3: "-target-cpu" "rp2350-haza
@@ -362,6 +364,34 @@ static bool expandClampIntrinsic(CallInst *Orig,
Intrinsic::ID ClampIntrinsic) {
return true;
}
+static bool expandSaturateIntrinsic(CallInst *SaturateCall) {
+ FunctionType *FT = SaturateCall->getFunctionType();
+ Type *FTRetTy = FT->getReturnType();
https://github.com/farzonl edited
https://github.com/llvm/llvm-project/pull/104619
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -325,6 +325,16 @@ def Abs : DXILOp<6, unary> {
let attributes = [Attributes];
}
+def Saturate : DXILOp<7, unary> {
+ let Doc = "Clamps a single or double precision floating point value to
[0.0f...1.0f].";
+ let LLVMIntrinsic = int_dx_saturate;
+ let arguments = [ove
@@ -1122,6 +1122,154 @@ bool Sema::CheckInstantiatedFunctionTemplateConstraints(
PointOfInstantiation, Satisfaction);
}
+namespace {
+
+// We employ a TreeTransform because RAV couldn't recurse into a bunch of
+// Exprs e.g. SizeOfPackExpr,
llvm-ci wrote:
LLVM Buildbot has detected a new failure on builder `sanitizer-windows` running
on `sanitizer-windows` while building `clang` at step 4 "annotate".
Full details are available at:
https://lab.llvm.org/buildbot/#/builders/107/builds/1989
Here is the relevant piece of the build lo
Author: Timm Baeder
Date: 2024-08-17T22:57:19+02:00
New Revision: 555399d562201f3114fb22f883cd1b6710af1a0d
URL:
https://github.com/llvm/llvm-project/commit/555399d562201f3114fb22f883cd1b6710af1a0d
DIFF:
https://github.com/llvm/llvm-project/commit/555399d562201f3114fb22f883cd1b6710af1a0d.diff
L
https://github.com/tbaederr closed
https://github.com/llvm/llvm-project/pull/104663
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -14638,6 +14649,8 @@ bool FloatExprEvaluator::VisitCallExpr(const CallExpr
*E) {
return true;
}
+ case Builtin::BIfmin:
+ case Builtin::BIfminf:
philnik777 wrote:
I don't think anything should happen to the libc++ documentation in this patch.
We
https://github.com/PiotrZSL approved this pull request.
https://github.com/llvm/llvm-project/pull/104675
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
Author: Timm Baeder
Date: 2024-08-17T22:06:46+02:00
New Revision: f620c5b692dd0bc08692979236073db0db27f0fc
URL:
https://github.com/llvm/llvm-project/commit/f620c5b692dd0bc08692979236073db0db27f0fc
DIFF:
https://github.com/llvm/llvm-project/commit/f620c5b692dd0bc08692979236073db0db27f0fc.diff
L
https://github.com/tbaederr closed
https://github.com/llvm/llvm-project/pull/104662
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -402,6 +402,21 @@
// MCPU-SIFIVE-P670-SAME: "-target-feature" "+zvkt"
// MCPU-SIFIVE-P670-SAME: "-target-abi" "lp64d"
+// RUN: %clang -target riscv32 -### -c %s 2>&1 -mcpu=rp2350-hazard3 |
FileCheck -check-prefix=MCPU-HAZARD3 %s
+// MCPU-HAZARD3: "-target-cpu" "rp2350-haza
@@ -402,6 +402,21 @@
// MCPU-SIFIVE-P670-SAME: "-target-feature" "+zvkt"
// MCPU-SIFIVE-P670-SAME: "-target-abi" "lp64d"
+// RUN: %clang -target riscv32 -### -c %s 2>&1 -mcpu=rp2350-hazard3 |
FileCheck -check-prefix=MCPU-HAZARD3 %s
+// MCPU-HAZARD3: "-target-cpu" "rp2350-haza
https://github.com/mikecrowe updated
https://github.com/llvm/llvm-project/pull/104675
>From afdd6c2a12735e1da69a46c6ff78b5d4e0dcdb6e Mon Sep 17 00:00:00 2001
From: Mike Crowe
Date: Sun, 21 Jul 2024 20:37:02 +0100
Subject: [PATCH 1/2] [clang-tidy] Support member functions with
modernize-use-std
@@ -104,6 +104,12 @@ New check aliases
Changes in existing checks
^^
+- Improved :doc:`modernize-use-std-print
+ ` and
PiotrZSL wrote:
wrong name, and split that entry into 2, even if you would need to duplicate
description
https://
https://github.com/PiotrZSL approved this pull request.
https://github.com/llvm/llvm-project/pull/104675
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
MaskRay wrote:
Thanks! I'll land this in a few days.
I believe it's now up to the gp default users to justify the default and why
they cannot user a Clang configuration file (this is difficult to justify, as
we've many many decisions to Clang configuration files). I think this is
important to
MaskRay wrote:
> @MaskRay Are you OK with this change?
Sorry for the delay. I've read through
https://discourse.llvm.org/t/making-ffp-model-fast-more-user-friendly/78402,
how we ended up with `-ffp-contract=fast-honor-pragmas` beside `=fast` (GCC
compatibility, sigh), some notes that ICC/GCC
@@ -163,23 +183,41 @@
// CHECK-FEB-IGNORE: "-fno-rounding-math"
// CHECK-FEB-IGNORE: "-ffp-exception-behavior=ignore"
-// RUN: %clang -### -nostdinc -Werror -ffast-math -ffp-model=fast -c %s 2>&1 \
+// RUN: %clang -### -nostdinc -Werror -ffast-math -ffp-model=aggressive -c %s
@@ -109,20 +112,37 @@
// CHECK-TRAP: "-cc1"
// CHECK-TRAP: "-ffp-exception-behavior=strict"
+// RUN: %clang -### -nostdinc -ffp-model=aggressive -c %s 2>&1 \
+// RUN: | FileCheck --check-prefix=CHECK-FPM-AGGR %s
+// CHECK-FPM-AGGR: "-cc1"
+// CHECK-FPM-AGGR: "-menable-no-inf
@@ -3033,8 +3039,8 @@ static void RenderFloatingPointOptions(const ToolChain
&TC, const Driver &D,
SignedZeros = true;
StringRef Val = A->getValue();
- if (OFastEnabled && Val != "fast") {
-// Only -ffp-model=fast is compatible with OFast, ignore.
+
https://github.com/MaskRay approved this pull request.
fp-model= => -ffp-model=
LGTM. I expect that the subject explicit mentions -ffp-model=fast behavior
difference, even if it becomes less aggressive and unlikely breaks users.
With "Introduce ...", nobody would expect behavior differences.
@@ -2879,10 +2879,31 @@ static void RenderFloatingPointOptions(const ToolChain
&TC, const Driver &D,
std::string ComplexRangeStr = "";
std::string GccRangeComplexOption = "";
+ auto setComplexRange = [&](LangOptions::ComplexRangeKind NewRange) {
+// Warn if user expe
@@ -2,13 +2,13 @@
// and other floating point options get a warning diagnostic.
//
-// RUN: %clang -### -ffp-model=fast -ffp-contract=off -c %s 2>&1 \
+// RUN: %clang -### -ffp-model=aggressive -ffp-contract=off -c %s 2>&1 \
MaskRay wrote:
It's still useful t
https://github.com/MaskRay edited
https://github.com/llvm/llvm-project/pull/100453
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
yonghong-song wrote:
@AaronBallman the llvm side of change looks good to me!
https://github.com/llvm/llvm-project/pull/101228
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,90 @@
+// Use --implicit-check-not to ensure no additional CPUs are in this list
+
+// RUN: not %clang_cc1 -triple arm64--- -target-cpu not-a-cpu -fsyntax-only %s
2>&1 | FileCheck %s --implicit-check-not={{[a-zA-Z0-9]}}
+// RUN: not %clang_cc1 -triple arm64--- -tune-cp
llvmbot wrote:
@llvm/pr-subscribers-clang
Author: Oleksandr T. (a-tarasyuk)
Changes
Fixes #104391
---
Full diff: https://github.com/llvm/llvm-project/pull/104677.diff
3 Files Affected:
- (modified) clang/docs/ReleaseNotes.rst (+2)
- (modified) clang/lib/Sema/SemaStmt.cpp (+2-1)
- (mo
https://github.com/a-tarasyuk created
https://github.com/llvm/llvm-project/pull/104677
Fixes #104391
>From cd7ce740464c9c46ab231cf773fd1cf28e3495eb Mon Sep 17 00:00:00 2001
From: Oleksandr T
Date: Sat, 17 Aug 2024 19:43:45 +0300
Subject: [PATCH] [Clang] warn on discarded [[nodiscard]] function
https://github.com/zyn0217 updated
https://github.com/llvm/llvm-project/pull/102857
>From 1119f0a8d180e482bff45c999d488827ac5ae49e Mon Sep 17 00:00:00 2001
From: Younan Zhang
Date: Mon, 12 Aug 2024 23:32:34 +0800
Subject: [PATCH 1/9] [Clang][NFCI] Slightly refactor
getTemplateInstantiationArgs
@@ -0,0 +1,90 @@
+// Use --implicit-check-not to ensure no additional CPUs are in this list
+
+// RUN: not %clang_cc1 -triple arm64--- -target-cpu not-a-cpu -fsyntax-only %s
2>&1 | FileCheck %s --implicit-check-not={{[a-zA-Z0-9]}}
+// RUN: not %clang_cc1 -triple arm64--- -tune-cp
llvmbot wrote:
@llvm/pr-subscribers-clang-tools-extra
Author: Mike Crowe (mikecrowe)
Changes
These checks can be made to work on member functions quite easily and it's not
unknown to have at least printf-style functions as members. Let's remove the
restriction.
---
Full diff: https://gi
https://github.com/mikecrowe created
https://github.com/llvm/llvm-project/pull/104675
These checks can be made to work on member functions quite easily and it's not
unknown to have at least printf-style functions as members. Let's remove the
restriction.
>From afdd6c2a12735e1da69a46c6ff78b5d4
llvmbot wrote:
@llvm/pr-subscribers-clang-tools-extra
Author: Mike Crowe (mikecrowe)
Changes
---
Full diff: https://github.com/llvm/llvm-project/pull/104674.diff
1 Files Affected:
- (modified) clang-tools-extra/docs/ReleaseNotes.rst (+1-1)
``diff
diff --git a/clang-tools-ex
https://github.com/mikecrowe created
https://github.com/llvm/llvm-project/pull/104674
None
>From b96dfbca33c5beb5ca3c984bc9388d11f0d7f707 Mon Sep 17 00:00:00 2001
From: Mike Crowe
Date: Sat, 17 Aug 2024 17:04:06 +0100
Subject: [PATCH] [clang-tidy] Correct typo in ReleaseNotes.rst
---
clang-t
https://github.com/zyn0217 updated
https://github.com/llvm/llvm-project/pull/102857
>From 1119f0a8d180e482bff45c999d488827ac5ae49e Mon Sep 17 00:00:00 2001
From: Younan Zhang
Date: Mon, 12 Aug 2024 23:32:34 +0800
Subject: [PATCH 1/8] [Clang][NFCI] Slightly refactor
getTemplateInstantiationArgs
https://github.com/zyn0217 edited
https://github.com/llvm/llvm-project/pull/102857
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/zyn0217 updated
https://github.com/llvm/llvm-project/pull/102857
>From 1119f0a8d180e482bff45c999d488827ac5ae49e Mon Sep 17 00:00:00 2001
From: Younan Zhang
Date: Mon, 12 Aug 2024 23:32:34 +0800
Subject: [PATCH 1/7] [Clang][NFCI] Slightly refactor
getTemplateInstantiationArgs
https://github.com/zyn0217 updated
https://github.com/llvm/llvm-project/pull/102857
>From 1119f0a8d180e482bff45c999d488827ac5ae49e Mon Sep 17 00:00:00 2001
From: Younan Zhang
Date: Mon, 12 Aug 2024 23:32:34 +0800
Subject: [PATCH 1/6] [Clang][NFCI] Slightly refactor
getTemplateInstantiationArgs
https://github.com/zyn0217 updated
https://github.com/llvm/llvm-project/pull/102857
>From 1119f0a8d180e482bff45c999d488827ac5ae49e Mon Sep 17 00:00:00 2001
From: Younan Zhang
Date: Mon, 12 Aug 2024 23:32:34 +0800
Subject: [PATCH 1/5] [Clang][NFCI] Slightly refactor
getTemplateInstantiationArgs
https://github.com/tmatheson-arm closed
https://github.com/llvm/llvm-project/pull/104435
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
Author: Tomas Matheson
Date: 2024-08-17T13:36:40+01:00
New Revision: 362142c4bb5cc657151f592e507f552d5b9f7dde
URL:
https://github.com/llvm/llvm-project/commit/362142c4bb5cc657151f592e507f552d5b9f7dde
DIFF:
https://github.com/llvm/llvm-project/commit/362142c4bb5cc657151f592e507f552d5b9f7dde.diff
Author: Vlad Serebrennikov
Date: 2024-08-17T14:57:59+03:00
New Revision: 27d37ee4d067f42e9a46a0871d3cb961323e5c85
URL:
https://github.com/llvm/llvm-project/commit/27d37ee4d067f42e9a46a0871d3cb961323e5c85
DIFF:
https://github.com/llvm/llvm-project/commit/27d37ee4d067f42e9a46a0871d3cb961323e5c85.
@@ -1192,20 +1192,36 @@ struct FormatStyle {
/// \version 3.7
bool BinPackArguments;
- /// If ``false``, a function declaration's or function definition's
- /// parameters will either all be on the same line or will have one line
each.
- /// \code
- /// true:
- ///
https://github.com/owenca updated
https://github.com/llvm/llvm-project/pull/104669
>From d7c7c0da69864067999ecd9b1621fdbb85d4d365 Mon Sep 17 00:00:00 2001
From: Owen Pan
Date: Sat, 17 Aug 2024 02:32:19 -0700
Subject: [PATCH 1/2] [clang-format] Change GNU style language standard to
LS_Latest
F
@@ -1192,20 +1192,36 @@ struct FormatStyle {
/// \version 3.7
bool BinPackArguments;
- /// If ``false``, a function declaration's or function definition's
- /// parameters will either all be on the same line or will have one line
each.
- /// \code
- /// true:
- ///
llvmbot wrote:
@llvm/pr-subscribers-clang-format
Author: Owen Pan (owenca)
Changes
Fixes #104655.
---
Full diff: https://github.com/llvm/llvm-project/pull/104669.diff
2 Files Affected:
- (modified) clang/lib/Format/Format.cpp (-1)
- (modified) clang/unittests/Format/TokenAnnotatorTest
https://github.com/owenca created
https://github.com/llvm/llvm-project/pull/104669
Fixes #104655.
>From d7c7c0da69864067999ecd9b1621fdbb85d4d365 Mon Sep 17 00:00:00 2001
From: Owen Pan
Date: Sat, 17 Aug 2024 02:32:19 -0700
Subject: [PATCH] [clang-format] Change GNU style language standard to
https://github.com/c8ef updated https://github.com/llvm/llvm-project/pull/104666
>From b58b9c3ad5fb2b37715ba9f52c905b6961159f0c Mon Sep 17 00:00:00 2001
From: c8ef
Date: Sat, 17 Aug 2024 05:42:39 +
Subject: [PATCH 1/3] [clang] fix divide by zero in ComplexExprEvaluator
---
clang/lib/AST/Ex
@@ -1192,20 +1192,36 @@ struct FormatStyle {
/// \version 3.7
bool BinPackArguments;
- /// If ``false``, a function declaration's or function definition's
- /// parameters will either all be on the same line or will have one line
each.
- /// \code
- /// true:
- ///
@@ -0,0 +1,3 @@
+// RUN: %clang_cc1 -fsyntax-only %s
+
+auto f() { return 43273096 / 65536j; }
c8ef wrote:
Thank you for your suggestion! I have relocated the test case and included the
relevant release note.
https://github.com/llvm/llvm-project/pull/104666
___
https://github.com/c8ef updated https://github.com/llvm/llvm-project/pull/104666
>From b58b9c3ad5fb2b37715ba9f52c905b6961159f0c Mon Sep 17 00:00:00 2001
From: c8ef
Date: Sat, 17 Aug 2024 05:42:39 +
Subject: [PATCH 1/2] [clang] fix divide by zero in ComplexExprEvaluator
---
clang/lib/AST/Ex
@@ -1192,20 +1192,36 @@ struct FormatStyle {
/// \version 3.7
bool BinPackArguments;
- /// If ``false``, a function declaration's or function definition's
- /// parameters will either all be on the same line or will have one line
each.
- /// \code
- /// true:
- ///
@@ -128,25 +128,6 @@ static bool startsSegmentOfBuilderTypeCall(const
FormatToken &Tok) {
return Tok.isMemberAccess() && Tok.Previous && Tok.Previous->closesScope();
}
-// Returns \c true if \c Current starts a new parameter.
-static bool startsNextParameter(const FormatTok
@@ -1978,6 +1978,25 @@ inline bool continuesLineComment(const FormatToken
&FormatTok,
FormatTok.OriginalColumn >= MinContinueColumn;
}
+// Returns \c true if \c Current starts a new parameter.
+static bool startsNextParameter(const FormatToken &Current,
-
@@ -0,0 +1,90 @@
+// Use --implicit-check-not to ensure no additional CPUs are in this list
+
+// RUN: not %clang_cc1 -triple arm64--- -target-cpu not-a-cpu -fsyntax-only %s
2>&1 | FileCheck %s --implicit-check-not={{[a-zA-Z0-9]}}
+// RUN: not %clang_cc1 -triple arm64--- -tune-cp
https://github.com/tmatheson-arm updated
https://github.com/llvm/llvm-project/pull/104435
>From f79eb28441491f1625691886cc92bd05d3b3cb6a Mon Sep 17 00:00:00 2001
From: Tomas Matheson
Date: Thu, 15 Aug 2024 13:41:31 +0100
Subject: [PATCH 01/18] [AArch64] Add a check for invalid default features
@@ -128,25 +128,6 @@ static bool startsSegmentOfBuilderTypeCall(const
FormatToken &Tok) {
return Tok.isMemberAccess() && Tok.Previous && Tok.Previous->closesScope();
}
-// Returns \c true if \c Current starts a new parameter.
-static bool startsNextParameter(const FormatTok
cor3ntin wrote:
This change needs a release note.
Please add an entry to `clang/docs/ReleaseNotes.rst` in the section the most
adapted to the change, and referencing any Github issue this change fixes.
Thanks!
The fix itself looks good
https://github.com/llvm/llvm-project/pull/104666
@@ -0,0 +1,3 @@
+// RUN: %clang_cc1 -fsyntax-only %s
+
+auto f() { return 43273096 / 65536j; }
cor3ntin wrote:
can you move that to , for example
`clang/test/SemaCXX/constant-expression-cxx11.cpp`
and make sure that actually always get evaluated?
maybe `constexp
@@ -0,0 +1,90 @@
+// Use --implicit-check-not to ensure no additional CPUs are in this list
+
+// RUN: not %clang_cc1 -triple arm64--- -target-cpu not-a-cpu -fsyntax-only %s
2>&1 | FileCheck %s --implicit-check-not={{[a-zA-Z0-9]}}
+// RUN: not %clang_cc1 -triple arm64--- -tune-cp
owenca wrote:
> > Whilst I can understand BinPackParameters being deprecated, as its one of
> > the original options I do worry a little about just how much impact such a
> > deprecation might have... it needs to be completely seemless because there
> > is ALOT of documentation references to i
@@ -7165,7 +7165,7 @@ TEST_F(FormatTest, LineBreakingInBinaryExpressions) {
"}");
FormatStyle OnePerLine = getLLVMStyle();
- OnePerLine.BinPackParameters = false;
+ OnePerLine.BinPackParameters = FormatStyle::BPPS_Never;
owenca wrote:
Ditto
@@ -362,6 +362,26 @@ TEST_F(FormatTestComments,
KeepsParameterWithTrailingCommentsOnTheirOwnLine) {
format("aa((,\n"
"), //\n"
", b);"));
+
+ FormatStyle BreakAlways = getLLVMStyle();
+ BreakAlways
@@ -2338,7 +2338,7 @@ TEST_F(FormatTest, FormatsForLoop) {
"for (const Foo &baz = in.value(); !baz.at_end(); ++baz) {\n}");
FormatStyle NoBinPacking = getLLVMStyle();
- NoBinPacking.BinPackParameters = false;
+ NoBinPacking.BinPackParameters = FormatStyle::BPPS_Never
@@ -7694,7 +7694,7 @@ TEST_F(FormatTest, ConstructorInitializers) {
": a(aa, aa,\n"
"aa) {}",
OnePerLine);
- OnePerLine.BinPackParameters = false;
+ On
@@ -8925,6 +8925,97 @@ TEST_F(FormatTest,
FormatsOneParameterPerLineIfNecessary) {
NoBinPacking);
}
+TEST_F(FormatTest, FormatsDeclarationBreakAlways) {
+ FormatStyle BreakAlways = getGoogleStyle();
+ BreakAlways.BinPackParameters = FormatStyle::BPPS_OnePerLine;
+ ve
@@ -7954,7 +7954,7 @@ TEST_F(FormatTest, AllowAllArgumentsOnNextLine) {
}
// This parameter should not affect declarations.
- Style.BinPackParameters = false;
+ Style.BinPackParameters = FormatStyle::BPPS_Never;
owenca wrote:
Ditto.
https://github.com/
@@ -1850,7 +1863,7 @@ FormatStyle getMozillaStyle() {
MozillaStyle.AlwaysBreakAfterDefinitionReturnType =
FormatStyle::DRTBS_TopLevel;
MozillaStyle.BinPackArguments = false;
- MozillaStyle.BinPackParameters = false;
+ MozillaStyle.BinPackParameters = FormatStyle::BP
@@ -8925,6 +8925,97 @@ TEST_F(FormatTest,
FormatsOneParameterPerLineIfNecessary) {
NoBinPacking);
}
+TEST_F(FormatTest, FormatsDeclarationBreakAlways) {
+ FormatStyle BreakAlways = getGoogleStyle();
+ BreakAlways.BinPackParameters = FormatStyle::BPPS_OnePerLine;
+ ve
@@ -8925,6 +8925,97 @@ TEST_F(FormatTest,
FormatsOneParameterPerLineIfNecessary) {
NoBinPacking);
}
+TEST_F(FormatTest, FormatsDeclarationBreakAlways) {
+ FormatStyle BreakAlways = getGoogleStyle();
+ BreakAlways.BinPackParameters = FormatStyle::BPPS_OnePerLine;
+ ve
@@ -8244,7 +8244,7 @@ TEST_F(FormatTest,
BreakConstructorInitializersAfterColon) {
"a(aa, aa,\n"
" aa) {}",
OnePerLine);
- OnePerLine.BinPackParameters =
@@ -8925,6 +8925,97 @@ TEST_F(FormatTest,
FormatsOneParameterPerLineIfNecessary) {
NoBinPacking);
}
+TEST_F(FormatTest, FormatsDeclarationBreakAlways) {
+ FormatStyle BreakAlways = getGoogleStyle();
+ BreakAlways.BinPackParameters = FormatStyle::BPPS_OnePerLine;
+ ve
@@ -128,25 +128,6 @@ static bool startsSegmentOfBuilderTypeCall(const
FormatToken &Tok) {
return Tok.isMemberAccess() && Tok.Previous && Tok.Previous->closesScope();
}
-// Returns \c true if \c Current starts a new parameter.
-static bool startsNextParameter(const FormatTok
@@ -8925,6 +8925,97 @@ TEST_F(FormatTest,
FormatsOneParameterPerLineIfNecessary) {
NoBinPacking);
}
+TEST_F(FormatTest, FormatsDeclarationBreakAlways) {
+ FormatStyle BreakAlways = getGoogleStyle();
+ BreakAlways.BinPackParameters = FormatStyle::BPPS_OnePerLine;
-
@@ -1192,20 +1192,36 @@ struct FormatStyle {
/// \version 3.7
bool BinPackArguments;
- /// If ``false``, a function declaration's or function definition's
- /// parameters will either all be on the same line or will have one line
each.
- /// \code
- /// true:
- ///
@@ -5475,6 +5475,14 @@ bool TokenAnnotator::mustBreakBefore(const AnnotatedLine
&Line,
return true;
}
+ // Ignores the first parameter as this will be handled separately by
+ // BreakFunctionDefinitionParameters or AlignAfterOpenBracket.
+ if (FormatStyle::BPPS_OnePe
@@ -8925,6 +8925,97 @@ TEST_F(FormatTest,
FormatsOneParameterPerLineIfNecessary) {
NoBinPacking);
}
+TEST_F(FormatTest, FormatsDeclarationBreakAlways) {
+ FormatStyle BreakAlways = getGoogleStyle();
+ BreakAlways.BinPackParameters = FormatStyle::BPPS_OnePerLine;
+ ve
97 matches
Mail list logo