On Thu, Dec 22, 2016 at 5:41 PM Richard Smith via cfe-commits <
cfe-commits@lists.llvm.org> wrote:
>
> ==
> --- cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td (original)
> +++ cfe/trunk/include/clang/Basic/Diagnostic
Author: chandlerc
Date: Thu Dec 22 23:19:47 2016
New Revision: 290417
URL: http://llvm.org/viewvc/llvm-project?rev=290417&view=rev
Log:
Add an assert to catch improperly constructed %diff sequences in
diagnostics and fix one such diagnostic.
Sadly, this assert doesn't catch this bug because we ha
ahatanak added a comment.
Ah, good idea. That sounds like a much simpler and less invasive approach. I
agree that the performance impact would probably be small, and if it turns out
to have a significant impact, we can reduce the number of times we move the
lifetime.start (without moving it ret
Author: ayartsev
Date: Thu Dec 22 22:09:18 2016
New Revision: 290415
URL: http://llvm.org/viewvc/llvm-project?rev=290415&view=rev
Log:
Revert changes made by r290413 until regression is fixed.
Modified:
cfe/trunk/lib/StaticAnalyzer/Core/ExprEngineC.cpp
cfe/trunk/lib/StaticAnalyzer/Core/Si
Author: ayartsev
Date: Thu Dec 22 21:31:00 2016
New Revision: 290413
URL: http://llvm.org/viewvc/llvm-project?rev=290413&view=rev
Log:
Fix for PR15623. The patch eliminates unwanted ProgramState checker data
propagation from an operand of the logical operation to operation result.
The patch also
rjmccall added a comment.
In https://reviews.llvm.org/D27680#629182, @ahatanak wrote:
> In https://reviews.llvm.org/D27680#628272, @rjmccall wrote:
>
> > Wouldn't it be simpler to just record an insertion point for the beginning
> > of the current lexical scope and insert the lifetime.begin ther
ahatanak updated this revision to Diff 82394.
ahatanak added a comment.
Rebase.
r286584 changed getCurLambda to optionally skip CapturedRegionScopeInfos. This
patch changes it to skip BlockScopeInfos too.
https://reviews.llvm.org/D25556
Files:
include/clang/Sema/Sema.h
lib/Sema/Sema.cpp
Author: rsmith
Date: Thu Dec 22 20:10:11 2016
New Revision: 290405
URL: http://llvm.org/viewvc/llvm-project?rev=290405&view=rev
Log:
Move generation of injected template arguments for a template parameter list
out of an internal function and into ASTContext; this is needed in template
argument ded
Author: rsmith
Date: Thu Dec 22 20:00:24 2016
New Revision: 290403
URL: http://llvm.org/viewvc/llvm-project?rev=290403&view=rev
Log:
Only substitute into type of non-type template parameter once, rather than
twice, in finalization of template argument deduction.
This is a re-commit of r290310 (re
Author: rsmith
Date: Thu Dec 22 19:30:39 2016
New Revision: 290399
URL: http://llvm.org/viewvc/llvm-project?rev=290399&view=rev
Log:
When merging two deduced non-type template arguments for the same parameter,
fail the merge if the arguments have different types (except if one of them was
deduced
This revision was automatically updated to reflect the committed changes.
Closed by commit rL290398: Cleanup the handling of noinline function
attributes, -fno-inline, (authored by chandlerc).
Changed prior to commit:
https://reviews.llvm.org/D28053?vs=82356&id=82390#toc
Repository:
rL LLVM
Author: chandlerc
Date: Thu Dec 22 19:24:49 2016
New Revision: 290398
URL: http://llvm.org/viewvc/llvm-project?rev=290398&view=rev
Log:
Cleanup the handling of noinline function attributes, -fno-inline,
-fno-inline-functions, -O0, and optnone.
These were really, really tangled together:
- We used
It looks like the root of this is that we're treating calls to `allocsize`
functions as AllocLike (e.g. any allocation function type except realloc)
functions, which caused us to perform invalid optimizations. For example,
in ReallocFreedPointerTest, EarlyCSE DCE'd the realloc because
llvm::isInstr
This revision was automatically updated to reflect the committed changes.
Closed by commit rL290392: Make '-disable-llvm-optzns' an alias for
'-disable-llvm-passes'. (authored by chandlerc).
Changed prior to commit:
https://reviews.llvm.org/D28047?vs=82313&id=82383#toc
Repository:
rL LLVM
h
Author: chandlerc
Date: Thu Dec 22 18:23:01 2016
New Revision: 290392
URL: http://llvm.org/viewvc/llvm-project?rev=290392&view=rev
Log:
Make '-disable-llvm-optzns' an alias for '-disable-llvm-passes'.
Much to my surprise, '-disable-llvm-optzns' which I thought was the
magical flag I wanted to get
Author: jroelofs
Date: Thu Dec 22 17:48:23 2016
New Revision: 290390
URL: http://llvm.org/viewvc/llvm-project?rev=290390&view=rev
Log:
Fix example: byref struct's init was incorrect, and the block literal's holder
should point to it.
Modified:
cfe/trunk/docs/Block-ABI-Apple.rst
Modified: cf
mehdi_amini accepted this revision.
mehdi_amini added a comment.
This revision is now accepted and ready to land.
In https://reviews.llvm.org/D28047#629922, @chandlerc wrote:
> In https://reviews.llvm.org/D28047#629892, @mehdi_amini wrote:
>
> > LGTM, but please wait for @rnk to confirm :)
> >
pekka.jaaskelainen accepted this revision.
pekka.jaaskelainen added a reviewer: pekka.jaaskelainen.
pekka.jaaskelainen added a comment.
This revision is now accepted and ready to land.
In https://reviews.llvm.org/D28048#629569, @Anastasia wrote:
> @pekka.jaaskelainen, I think you are using x86 ta
Okay, I'm seeing this failure now if I tag my system's `realloc`
declaration with `alloc_size`. (Which FreeBSD seems to do in their
headers). Because all that clang does with `alloc_size` is use it to answer
`__builtin_object_size` queries and lower it to LLVM's `allocsize`
attribute, this is presu
This revision was automatically updated to reflect the committed changes.
Closed by commit rL290367: Testbed and skeleton of a new expression parser
(authored by spyffe).
Changed prior to commit:
https://reviews.llvm.org/D27180?vs=81991&id=82360#toc
Repository:
rL LLVM
https://reviews.llvm.
Author: spyffe
Date: Thu Dec 22 14:03:14 2016
New Revision: 290367
URL: http://llvm.org/viewvc/llvm-project?rev=290367&view=rev
Log:
Testbed and skeleton of a new expression parser
Recommitted after formal approval.
LLVM's JIT is now the foundation of dynamic-compilation features for many
langu
mehdi_amini added a comment.
> That said, I agree with Reid that it is a bit surprising. After thinking
> about it a lot, the reason I personally find it surprising is actually that I
> find -O0 being the default surprising. But I'm OK with not changing that
> here, and maybe never changing tha
This is when running "ninja check-all", in a tree with llvm, clang and
compiler-rt checked out. The first program that shows a failure is
projects/compiler-rt/lib/asan/tests/default/Asan-i386-inline-Test:
[==] Running 92 tests from 3 test cases.
[--] Global test environment set-
mehdi_amini added inline comments.
Comment at: lib/Frontend/CompilerInvocation.cpp:453
+// There is no effect at O0 when we won't inline anyways.
+if (Opts.OptimizationLevel > 1) {
+ const Option &InlineOpt = InlineArg->getOption();
chandlerc wrote:
Author: abataev
Date: Thu Dec 22 13:44:05 2016
New Revision: 290364
URL: http://llvm.org/viewvc/llvm-project?rev=290364&view=rev
Log:
[OPENMP] Fix for PR31417: assert failure when compiling trivial openmp
program
Offload related code is not quite ready yet, but some simple examples
must not crash
chandlerc added a comment.
In https://reviews.llvm.org/D28047#629892, @mehdi_amini wrote:
> LGTM, but please wait for @rnk to confirm :)
>
> Also any opinion about a driver option -emit-raw-llvm as @joerg suggested?
I like the idea generally, but I don't have an immediate use case and would
d
chandlerc added a comment.
In https://reviews.llvm.org/D28053#629834, @mehdi_amini wrote:
> In https://reviews.llvm.org/D28053#629768, @rnk wrote:
>
> > The big change here is that `clang -O0` now applies the noinline attribute
> > everywhere. I can see why someone might expect things to work th
chandlerc updated this revision to Diff 82356.
chandlerc added a comment.
Herald added a subscriber: wdng.
Fix an thinko found in review, clean up comments, and clean up pass pipeline
selection as that actually needs to happen in this patch as well.
Also update one test using -O1 and observing th
Yes, this was reapplied in r290297 with fixes for the msan issue we caught;
these asan unit test failures are news to me. Can you give me the command
that you're using to run these tests, please?
On Thu, Dec 22, 2016 at 11:10 AM, Dimitry Andric wrote:
> On 20 Dec 2016, at 09:28, Chandler Carruth
rnk added a comment.
In https://reviews.llvm.org/D28047#629889, @chandlerc wrote:
> I only have a mild preference for how we spell the name based on the fact
> that i've told people to use -disable-llvm-optzns for years. If we want to go
> with ...-passes, fine with me.
We have some freedom t
mehdi_amini added a comment.
LGTM, but please wait for @rnk to confirm :)
Also any opinion about a driver option -emit-raw-llvm as @joerg suggested?
https://reviews.llvm.org/D28047
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lis
chandlerc added a comment.
In https://reviews.llvm.org/D28053#629830, @mehdi_amini wrote:
> > It would be awesome if attribute sets were a bit more FileCheck friendly,
> > but oh well.
>
> I've been wondering about that, what's the point of attribute sets in the
> textual IR?
> I understand th
chandlerc added a comment.
In https://reviews.llvm.org/D28047#629824, @mehdi_amini wrote:
> In https://reviews.llvm.org/D28047#629746, @rnk wrote:
>
> > How about standardizing on -disable-llvm-passes instead of
> > -disable-llvm-optzns? I never liked "optzns" and can't remember how to
> > spel
On 20 Dec 2016, at 09:28, Chandler Carruth via cfe-commits
wrote:
> Author: chandlerc
> Date: Tue Dec 20 02:28:19 2016
> New Revision: 290169
>
> URL: http://llvm.org/viewvc/llvm-project?rev=290169&view=rev
> Log:
> Revert r290149: Add the alloc_size attribute to clang.
>
> This commit fails MS
Author: gbiv
Date: Thu Dec 22 13:00:31 2016
New Revision: 290356
URL: http://llvm.org/viewvc/llvm-project?rev=290356&view=rev
Log:
Fix warning introduced by r290297.
Modified:
cfe/trunk/lib/Sema/SemaDeclAttr.cpp
Modified: cfe/trunk/lib/Sema/SemaDeclAttr.cpp
URL:
http://llvm.org/viewvc/llvm-
Author: gbiv
Date: Thu Dec 22 12:48:34 2016
New Revision: 290353
URL: http://llvm.org/viewvc/llvm-project?rev=290353&view=rev
Log:
Make alloc_size only applicable to Functions.
I don't remember why I didn't make alloc_size only applicable to
Functions a year ago, but I can't see any compelling re
scanon added inline comments.
Comment at: lib/builtins/floatuntitf.c:73
+long_double_bits fb;
+fb.u.high.all = (du_int)(e + 16383) << 48/* exponent */
+ | ((a >> 64) & 0xLL); /* mantissa */
mgorny wrote:
> ren
mgorny added inline comments.
Comment at: lib/builtins/floatuntitf.c:73
+long_double_bits fb;
+fb.u.high.all = (du_int)(e + 16383) << 48/* exponent */
+ | ((a >> 64) & 0xLL); /* mantissa */
rengolin wrote:
> r
scanon added inline comments.
Comment at: lib/builtins/floattitf.c:65
+if (a & ((tu_int)1 << LDBL_MANT_DIG)) {
+a >>= 1;
+++e;
Strictly speaking there's no need to adjust `a` here. If we rounded up into a
new binade, then `a` is n
mehdi_amini added inline comments.
Comment at: lib/Frontend/CompilerInvocation.cpp:453
+// There is no effect at O0 when we won't inline anyways.
+if (Opts.OptimizationLevel > 1) {
+ const Option &InlineOpt = InlineArg->getOption();
mehdi_amini wrote
scanon added a comment.
Please s/mantissa/significand/. I know that "mantissa" is used in a number of
places in llvm sources, but it's incorrect terminology. Significand is the
IEEE-754 nomenclature, which any new work should follow.
https://reviews.llvm.org/D27898
_
rengolin added inline comments.
Comment at: lib/builtins/floatuntitf.c:73
+long_double_bits fb;
+fb.u.high.all = (du_int)(e + 16383) << 48/* exponent */
+ | ((a >> 64) & 0xLL); /* mantissa */
rengolin wrote:
>
rengolin added inline comments.
Comment at: lib/builtins/floatuntitf.c:73
+long_double_bits fb;
+fb.u.high.all = (du_int)(e + 16383) << 48/* exponent */
+ | ((a >> 64) & 0xLL); /* mantissa */
mgorny wrote:
> r
mehdi_amini added inline comments.
Comment at: lib/Frontend/CompilerInvocation.cpp:453
+// There is no effect at O0 when we won't inline anyways.
+if (Opts.OptimizationLevel > 1) {
+ const Option &InlineOpt = InlineArg->getOption();
I'd switch the tw
mgorny added inline comments.
Comment at: lib/builtins/floatuntitf.c:73
+long_double_bits fb;
+fb.u.high.all = (du_int)(e + 16383) << 48/* exponent */
+ | ((a >> 64) & 0xLL); /* mantissa */
rengolin wrote:
> n
mehdi_amini added a comment.
In https://reviews.llvm.org/D28053#629768, @rnk wrote:
> The big change here is that `clang -O0` now applies the noinline attribute
> everywhere. I can see why someone might expect things to work that way, but
> it seems surprising to me at first glance.
>
> Before
Author: dcoughlin
Date: Thu Dec 22 11:52:57 2016
New Revision: 290352
URL: http://llvm.org/viewvc/llvm-project?rev=290352&view=rev
Log:
[analyzer] Update GTestChecker to tighten API detection
Update the GTestChecker to tighten up the API detection and make it
cleaner in response to post-commit fe
dcoughlin added a comment.
I cleaned up the parameter detection and added more tests in r290352.
https://reviews.llvm.org/D27773
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
mehdi_amini added a comment.
> It would be awesome if attribute sets were a bit more FileCheck friendly, but
> oh well.
I've been wondering about that, what's the point of attribute sets in the
textual IR?
I understand the idea for saving space in the Bitcode, but the IR does not have
to use t
mehdi_amini added a comment.
In https://reviews.llvm.org/D28047#629746, @rnk wrote:
> How about standardizing on -disable-llvm-passes instead of
> -disable-llvm-optzns? I never liked "optzns" and can't remember how to spell
> it. Also, this flag disables LLVM instrumentation passes (ASan) as we
rengolin accepted this revision.
rengolin added a comment.
This revision is now accepted and ready to land.
My floating-point-fu is lacking, so I'll trust you guys that this makes sense.
:)
I didn't see anything egregious, so LGTM with the nit inline.
cheers,
--renato
Commen
rnk added a comment.
The big change here is that `clang -O0` now applies the noinline attribute
everywhere. I can see why someone might expect things to work that way, but it
seems surprising to me at first glance.
Before this change I can imagine someone distributing a static archive of
bitco
ioeric updated this revision to Diff 82345.
ioeric marked 3 inline comments as done.
ioeric added a comment.
- addressed review comments.
https://reviews.llvm.org/D28052
Files:
change-namespace/ChangeNamespace.cpp
change-namespace/ChangeNamespace.h
unittests/change-namespace/ChangeNamespa
rnk added a comment.
How about standardizing on -disable-llvm-passes instead of
-disable-llvm-optzns? I never liked "optzns" and can't remember how to spell
it. Also, this flag disables LLVM instrumentation passes (ASan) as well as
optimization passes, so I think -disable-llvm-passes is the bet
On Thu, Dec 22, 2016 at 11:43 AM, NAKAMURA Takumi wrote:
> Does the test invoke cl.exe? I supposed it were clang.
It shouldn't, but the test also does not specify a target triple, so
the behavior depends on what version of MSVC you built clang (and
clang-tidy) with. What version of MSVC is used t
Does the test invoke cl.exe? I supposed it were clang.
On Thu, Dec 22, 2016 at 11:24 PM Aaron Ballman
wrote:
> On Wed, Dec 21, 2016 at 6:10 PM, NAKAMURA Takumi
> wrote:
> > It'd be the issue if the test depended on installed headers. The builder
> > doesn't have MS headers installed.
>
> Those
dmitry created this revision.
dmitry added a reviewer: yaxunl.
dmitry added subscribers: Anastasia, cfe-commits.
Since we don't have an ideal option for ndrange_t implementation (which was
discussed there: https://reviews.llvm.org/D23086), I propose to stick with
identification by name approach
aaron.ballman added a comment.
I really like this attribute, thank you for working on it!
Comment at: include/clang/Basic/Attr.td:1584
+def DiagnoseIf : InheritableAttr {
+ let Spellings = [GNU<"diagnose_if">];
+ let Subjects = SubjectList<[Function]>;
I thin
Hi George,
I'm guessing this may have caused PR31453. Simple reproducer included
in bug report.
Chad
On 2016-12-21 21:50, George Burgess IV via cfe-commits wrote:
Author: gbiv
Date: Wed Dec 21 20:50:20 2016
New Revision: 290297
URL: http://llvm.org/viewvc/llvm-project?rev=290297&view=rev
L
hokein added inline comments.
Comment at: change-namespace/ChangeNamespace.cpp:719
+// The alias is defined in some namespace.
+assert(AliasQualifiedName.size() >= AliasName.size() + 2);
+llvm::StringRef AliasNs =
maybe `assert(StringRef(A
aaron.ballman added inline comments.
Comment at: clang-tidy/performance/UnnecessaryValueParamCheck.cpp:96
- // Do not trigger on non-const value parameters when:
- // 1. they are in a constructor definition since they can likely trigger
- //modernize-pass-by-value which
aaron.ballman accepted this revision.
aaron.ballman added a reviewer: aaron.ballman.
aaron.ballman added a comment.
This revision is now accepted and ready to land.
LGTM, modulo the unrelated documentation changes.
https://reviews.llvm.org/D28034
__
This revision was automatically updated to reflect the committed changes.
Closed by commit rL290341: [analyzer] Improve suppress-on-sink behavior in
incomplete analyses. (authored by dergachev).
Changed prior to commit:
https://reviews.llvm.org/D28023?vs=82229&id=82339#toc
Repository:
rL LLV
Author: dergachev
Date: Thu Dec 22 08:48:52 2016
New Revision: 290341
URL: http://llvm.org/viewvc/llvm-project?rev=290341&view=rev
Log:
[analyzer] Improve suppress-on-sink behavior in incomplete analyses.
Warnings with suppress-on-sink are discarded during FlushReports when
BugReporter notices th
alexfh added inline comments.
Comment at: clang-tidy/performance/UnnecessaryValueParamCheck.cpp:96
- // Do not trigger on non-const value parameters when:
- // 1. they are in a constructor definition since they can likely trigger
- //modernize-pass-by-value which will su
On Wed, Dec 21, 2016 at 6:10 PM, NAKAMURA Takumi wrote:
> It'd be the issue if the test depended on installed headers. The builder
> doesn't have MS headers installed.
Those type names do not require any headers to be installed. They're
keywords in C++11 and later, but MSVC did not support them u
Author: courbet
Date: Thu Dec 22 08:12:31 2016
New Revision: 290340
URL: http://llvm.org/viewvc/llvm-project?rev=290340&view=rev
Log:
[clang-tidy] cppcoreguidelines-slicing: display discarded state size in bytes
https://reviews.llvm.org/D27212
Modified:
clang-tools-extra/trunk/clang-tidy/cpp
gerazo marked an inline comment as done.
gerazo added a comment.
So thank you again for the valuable questions.
In this checker, I give warnings for values which are both tainted and were
also not checked by the programmer. So unlike GenericTaintChecker, I do
implement the boundedness check here
gerazo marked 6 inline comments as done.
gerazo added a comment.
Thank you very much for your help. I've added all suggested modifications
including tests covering all checker option settings.
https://reviews.llvm.org/D27753
___
cfe-commits mailing
gerazo updated this revision to Diff 82336.
https://reviews.llvm.org/D27753
Files:
include/clang/StaticAnalyzer/Checkers/Checkers.td
lib/StaticAnalyzer/Checkers/CMakeLists.txt
lib/StaticAnalyzer/Checkers/DirtyScalarChecker.cpp
lib/StaticAnalyzer/Checkers/GenericTaintChecker.cpp
test/Ana
chandlerc created this revision.
chandlerc added reviewers: rsmith, rnk, mehdi_amini.
chandlerc added a subscriber: cfe-commits.
chandlerc added a dependency: D28047: Remove the '-disable-llvm-passes' flag
(which I didn't even know existed, and I suspect many others aren't aware of
either) and st
Author: djasper
Date: Thu Dec 22 06:37:06 2016
New Revision: 290337
URL: http://llvm.org/viewvc/llvm-project?rev=290337&view=rev
Log:
clang-format: Less eagerly try to keep label-value pairs on a line.
Before:
string v =
StrCat("aaa: ", SomeFunction(,
Anastasia accepted this revision.
Anastasia added a comment.
This revision is now accepted and ready to land.
LGTM! If you checked there are no warnings any more, it seems fine to commit! :)
https://reviews.llvm.org/D27981
___
cfe-commits mailing li
Anastasia added a subscriber: pekka.jaaskelainen.
Anastasia added a comment.
I believe it's not that important what those numbers actually are, but having
the consistency with SPIR might be better indeed at least even for
documentation purposes!
@pekka.jaaskelainen, I think you are using x86 ta
ogoffart added a comment.
ping2
https://reviews.llvm.org/D26350
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
joerg added a comment.
There are two issues I have with the flags right now. The first one you are
addressing with this patch. The second issue is they remain CC1-only flags. Can
we introduce a proper "-emit-raw-llvm" flag to work like "-emit-llvm" but
without the additional IR processing. We c
ogoffart updated this revision to Diff 82325.
ogoffart marked an inline comment as done.
https://reviews.llvm.org/D26465
Files:
include/clang/Basic/Diagnostic.h
include/clang/Basic/DiagnosticIDs.h
lib/Basic/Diagnostic.cpp
lib/Basic/DiagnosticIDs.cpp
lib/Serialization/ASTReader.cpp
Inde
ogoffart marked an inline comment as done.
ogoffart added a comment.
In https://reviews.llvm.org/D26465#607860, @arphaman wrote:
> What did you test the parsing on? Will this patch get similar improvements
> for code that compiles without errors and warnings?
It was benchamerked with https://g
ioeric created this revision.
ioeric added a reviewer: hokein.
ioeric added a subscriber: cfe-commits.
https://reviews.llvm.org/D28052
Files:
change-namespace/ChangeNamespace.cpp
change-namespace/ChangeNamespace.h
unittests/change-namespace/ChangeNamespaceTests.cpp
Index: unittests/change-
malcolm.parsons added inline comments.
Comment at: docs/LibASTMatchersReference.html:2442
};
-fieldDecl(isBitField())
+fieldDecl(hasBitWidth(2))
matches 'int a;' and 'int c;' but not 'int b;'.
Prazek wrote:
> Fix not connected to patch?
Yes. The documentati
echuraev created this revision.
echuraev added a reviewer: Anastasia.
echuraev added subscribers: cfe-commits, bader, yaxunl.
We compile user opencl kernel code with spir triple. But built-ins are written
in OpenCL and we compile it with triple x86_64 to be able to use x86
intrinsics. And we nee
Prazek added inline comments.
Comment at: docs/LibASTMatchersReference.html:2442
};
-fieldDecl(isBitField())
+fieldDecl(hasBitWidth(2))
matches 'int a;' and 'int c;' but not 'int b;'.
Fix not connected to patch?
Comment at: docs/LibASTMat
chandlerc created this revision.
chandlerc added reviewers: rsmith, mehdi_amini.
chandlerc added a subscriber: cfe-commits.
Herald added a subscriber: mcrosier.
Much to my surprise, '-disable-llvm-optzns' which I thought was the
magical flag I wanted to get at the raw LLVM IR coming out of Clang
d
83 matches
Mail list logo