shuaiwang marked an inline comment as done.
shuaiwang added a comment.
Hi @alexfh, @hokein, @JonasToth, I've updated this diff to be just adding the
helper function `isModified()` with a set of dedicated unit tests. What do you
think of the approach of getting this change committed and then
devnexen added inline comments.
Comment at: lib/Driver/ToolChains/OpenBSD.cpp:189
if (getToolChain().ShouldLinkCXXStdlib(Args))
-getToolChain().AddCXXStdlibLibArgs(Args, CmdArgs);
+ToolChain.AddCXXStdlibLibArgs(Args, CmdArgs);
if
nik added a comment.
Ping
https://reviews.llvm.org/D38615
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
shiva0217 added a comment.
In https://reviews.llvm.org/D44888#1068806, @asb wrote:
> Thanks Kito. -mrelax and -mno-relax currently only affect the backend. For
> completeness, I think this patch needs to pass the appropriate flag to the
> linker depending on relax/no-relax.
Hi Alex.
gparker42 added a comment.
Note that we recently relaxed a similar diagnostic for `NSNumber *` in the
static analyzer. Such code is semantically similar to `inttype *`.
https://reviews.llvm.org/D44044
https://reviews.llvm.org/D45601
___
klimek accepted this revision.
klimek added a comment.
This revision is now accepted and ready to land.
lg
https://reviews.llvm.org/D38615
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
kpw added a comment.
My editor got a bit carried away with automatically clang-formatting
lib/CodeGen/CodeGenFunction.cpp. I'll fix that so that I'm not messing up the
revision history.
Repository:
rC Clang
https://reviews.llvm.org/D45716
___
dberris added a comment.
In https://reviews.llvm.org/D45716#1069557, @kpw wrote:
> My editor got a bit carried away with automatically clang-formatting
> lib/CodeGen/CodeGenFunction.cpp. I'll fix that so that I'm not messing up the
> revision history.
Yes please. :)
Also, if you can add to
devnexen updated this revision to Diff 142740.
devnexen added a comment.
- Making base gcc 4.2.1 stdc++ having profile version supported as well.
https://reviews.llvm.org/D45662
Files:
lib/Driver/ToolChains/OpenBSD.cpp
lib/Driver/ToolChains/OpenBSD.h
Index:
dberris accepted this revision.
dberris added a comment.
This revision is now accepted and ready to land.
In https://reviews.llvm.org/D45716#1069567, @dberris wrote:
> In https://reviews.llvm.org/D45716#1069557, @kpw wrote:
>
> > My editor got a bit carried away with automatically
devnexen added inline comments.
Comment at: lib/Driver/ToolChains/OpenBSD.cpp:189
if (getToolChain().ShouldLinkCXXStdlib(Args))
-getToolChain().AddCXXStdlibLibArgs(Args, CmdArgs);
+ToolChain.AddCXXStdlibLibArgs(Args, CmdArgs);
if
nik added a comment.
Huch, seems already submitted. Ignore :>
Repository:
rL LLVM
https://reviews.llvm.org/D36390
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
This revision was automatically updated to reflect the committed changes.
Closed by commit rL330182: [clangd] Fix fail to create file URI
warnings in FileIndexTest. (authored by hokein, committed by ).
Herald added a subscriber: llvm-commits.
Repository:
rL LLVM
Author: hokein
Date: Tue Apr 17 01:34:50 2018
New Revision: 330182
URL: http://llvm.org/viewvc/llvm-project?rev=330182=rev
Log:
[clangd] Fix "fail to create file URI" warnings in FileIndexTest.
Summary:
When running the FileIndexTest, it shows "Failed to create an URI
for file XXX: not a valid
JonasToth added a comment.
In https://reviews.llvm.org/D45444#1069488, @shuaiwang wrote:
> I've updated https://reviews.llvm.org/D45679 and I think the `isModified()`
> function there is now sufficiently covering the cases you've covered here and
> can be used as a good starting version if you
JonasToth added a comment.
Short note here too: I think having `isModified` return a track record, like a
vector for each
1. modifications
2. non-const handle taking
3. (const usages)
would be nice. Every user can decide how to react to it. Then the function
would be more like `usageRecord`
hokein created this revision.
hokein added a reviewer: sammccall.
Herald added subscribers: MaskRay, ioeric, jkorous-apple, ilya-biryukov, klimek.
This patch adds index support for GoToDefinition -- when we don't get the
definition from local AST, we query our index (Static) index to
get it.
JonasToth added a comment.
*hust* /llvm/tools/clang/lib/Analysis/PseudoConstantAnalysis.cpp
I will check this one first, before we get crazy and implemented something
twice.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D45679
sberg added a comment.
It looks like this caused a clang-cl regression
https://bugs.llvm.org/show_bug.cgi?id=37146 "clang-cl emits special functions
for non-trivial C-structs ('__destructor_8') introduced for Objective-C".
Repository:
rL LLVM
https://reviews.llvm.org/D41228
devnexen added inline comments.
Comment at: lib/Driver/ToolChains/OpenBSD.cpp:189
if (getToolChain().ShouldLinkCXXStdlib(Args))
-getToolChain().AddCXXStdlibLibArgs(Args, CmdArgs);
+ToolChain.AddCXXStdlibLibArgs(Args, CmdArgs);
if
paulsemel added a comment.
In https://reviews.llvm.org/D45665#1069075, @aaron.ballman wrote:
> LGTM!
Nice to hear ! As for the last time, as I don't have any rights to push this, I
would really appreciate if you could do it for me ! :)
Repository:
rC Clang
https://reviews.llvm.org/D45665
nik added a comment.
Herald added a subscriber: llvm-commits.
Ping
Repository:
rL LLVM
https://reviews.llvm.org/D36390
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
JonasToth added inline comments.
Comment at: test/clang-tidy/read_file_config.cpp:1
+// RUN: mkdir -p %T/read-file-config/
+// RUN: cp %s %T/read-file-config/test.cpp
Will this work on windows?
Repository:
rCTE Clang Tools Extra
sberg added a comment.
A random data point from trying this patch on the LibreOffice code base:
- a little over 100 cases that are easily identified as false positives (many
of the form "if (p) *p = ...")
- two or three cases that looked suspicious on first glance but turned out to
be false
dberris added inline comments.
Comment at: lib/Driver/ToolChains/OpenBSD.cpp:189
if (getToolChain().ShouldLinkCXXStdlib(Args))
-getToolChain().AddCXXStdlibLibArgs(Args, CmdArgs);
+ToolChain.AddCXXStdlibLibArgs(Args, CmdArgs);
if
dberris added inline comments.
Comment at: lib/Driver/ToolChains/OpenBSD.cpp:189
if (getToolChain().ShouldLinkCXXStdlib(Args))
-getToolChain().AddCXXStdlibLibArgs(Args, CmdArgs);
+ToolChain.AddCXXStdlibLibArgs(Args, CmdArgs);
if
dberris added inline comments.
Comment at: lib/Driver/ToolChains/OpenBSD.cpp:189
if (getToolChain().ShouldLinkCXXStdlib(Args))
-getToolChain().AddCXXStdlibLibArgs(Args, CmdArgs);
+ToolChain.AddCXXStdlibLibArgs(Args, CmdArgs);
if
shuaiwang updated this revision to Diff 142739.
shuaiwang added a comment.
Change to just add a helper function `isModified`
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D45679
Files:
clang-tidy/utils/ASTUtils.cpp
clang-tidy/utils/ASTUtils.h
Author: chandlerc
Date: Tue Apr 17 04:08:05 2018
New Revision: 330184
URL: http://llvm.org/viewvc/llvm-project?rev=330184=rev
Log:
Add some infuriatingly necessary comments to this test case.
Without these comments, by "luck" the contents of SomeKit's SKWidget.h
are precisely the same as
hokein added inline comments.
Comment at: test/clang-tidy/read_file_config.cpp:5
+// RUN: echo '[{"command": "cc -c -o test.o test.cpp", "directory":
"%T/read-file-config", "file": "%T/read-file-config/test.cpp"}]' >
%T/read-file-config/compile_commands.json
+// RUN:
aaron.ballman closed this revision.
aaron.ballman added a comment.
I've committed in r330185, thank you for the patch!
Repository:
rC Clang
https://reviews.llvm.org/D45665
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
lebedev.ri added inline comments.
Comment at: include/clang/Basic/DiagnosticSemaKinds.td:7806
+ "comparing %0 as a boolean">,
+ InGroup;
def warn_format_argument_needs_cast : Warning<
thakis wrote:
> lebedev.ri wrote:
> > Also, this really really should be
ilya-biryukov added a comment.
Could you elaborate on why the old behaviour is broken?
Repository:
rC Clang
https://reviews.llvm.org/D42966
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
mikhail.ramalho added a comment.
Sure. Basically, the previous code would not generate the USR for the
function's parameters.
The issue was that SM.getFileEntryForID would return NULL because there is no
actual file, that's why I changed to get the presumedLoc and build the name
using the
sammccall added a comment.
OK, I didn't get through all the detail, but we should talk about the MR stuff
today :)
Comment at: clang-doc/BitcodeReader.cpp:25
+void ClangDocBitcodeReader::storeData(SymbolID , llvm::StringRef Blob) {
+ assert(Record[0] == 20);
+ // First
rsmith added a comment.
Definitely some interesting questions to take to CWG here. :)
Comment at: lib/Sema/SemaOverload.cpp:9218-9219
+// --- F2 is a rewritten candidate ([over.match.oper]) and F1 is not.
+if (Cand2.getRewrittenKind() && !Cand1.getRewrittenKind())
+
alexfh created this revision.
alexfh added a reviewer: george.karpenkov.
Herald added a subscriber: a.sidorin.
Add an extension point to allow registration of statically-linked Clang Static
Analyzer checkers that are not a part of the Clang tree. This extension point
employs the mechanism used
paulsemel updated this revision to Diff 142750.
paulsemel added a comment.
Removed the two existing types.
Added the correct format sizing.
Added tests for those formats.
These version is now relying on the previous patch :
https://reviews.llvm.org/D45665
Repository:
rC Clang
Author: aaronballman
Date: Tue Apr 17 04:57:47 2018
New Revision: 330185
URL: http://llvm.org/viewvc/llvm-project?rev=330185=rev
Log:
Add checks for format specifiers used by __builtin_dump_struct and added a new
specifier for null-terminated constant strings.
Patch by Paul Semel.
Modified:
rsmith added inline comments.
Comment at: lib/Sema/SemaExpr.cpp:9816
+RHS = S.ImpCastExprToType(RHS.get(), Type, CK_BitCast);
+ } else {
+// C++2a [expr.spaceship]p4
EricWF wrote:
> rsmith wrote:
> > We still need to apply the usual arithmetic
whisperity added a comment.
In https://reviews.llvm.org/D45532#1068700, @Szelethus wrote:
> In https://reviews.llvm.org/D45532#1068647, @dkrupp wrote:
>
> > This bug report also mentions assignment operator. But for that a warning
> > may be not so useful. In that case the members of the
EricWF added inline comments.
Comment at: lib/Sema/SemaOverload.cpp:9218-9219
+// --- F2 is a rewritten candidate ([over.match.oper]) and F1 is not.
+if (Cand2.getRewrittenKind() && !Cand1.getRewrittenKind())
+ return true;
+if (Cand1.getRewrittenKind() &&
whisperity requested changes to this revision.
whisperity added a comment.
This revision now requires changes to proceed.
There is something that came up in my mind:
Consider a construct like this:
class A
{
A()
{
memset(X, 0, 10 * sizeof(int));
}
int X[10];
};
I
Szelethus updated this revision to Diff 142760.
Szelethus added a comment.
In https://reviews.llvm.org/D45532#1068700, @Szelethus wrote:
> Also, I managed to cause a crash with the class `linked_ptr_internal` from
> google's boringssl when I analyzed the grpc project. I'll look deeper into
>
thakis added inline comments.
Comment at: include/clang/Basic/DiagnosticSemaKinds.td:7806
+ "comparing %0 as a boolean">,
+ InGroup;
def warn_format_argument_needs_cast : Warning<
lebedev.ri wrote:
> Also, this really really should be under it's own flag,
alexfh requested changes to this revision.
alexfh added a comment.
This revision now requires changes to proceed.
Thank you for investigating and fixing this!
One comment re: the test below.
Comment at: test/clang-tidy/read_file_config.cpp:5
+// RUN: echo '[{"command": "cc -c
MTC added a comment.
In https://reviews.llvm.org/D45532#1069683, @whisperity wrote:
> There is something that came up in my mind:
>
> Consider a construct like this:
>
> class A
> {
> A()
> {
> memset(X, 0, 10 * sizeof(int));
> }
>
> int X[10];
> };
>
>
> I think
avt77 updated this revision to Diff 142755.
avt77 added a comment.
I moved FrontendTiming.cpp from lib/Basic/ to lib/Frontend/.
https://reviews.llvm.org/D45619
Files:
include/clang/Frontend/Utils.h
lib/CodeGen/BackendUtil.cpp
lib/CodeGen/CodeGenAction.cpp
lib/Frontend/CMakeLists.txt
hokein updated this revision to Diff 142759.
hokein marked an inline comment as done.
hokein added a comment.
Add one more test to ensure the test code triggering "clang-analyzer-*" checks.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D45697
Files:
hokein added inline comments.
Comment at: test/clang-tidy/read_file_config.cpp:1
+// RUN: mkdir -p %T/read-file-config/
+// RUN: cp %s %T/read-file-config/test.cpp
JonasToth wrote:
> Will this work on windows?
I believe it works on windows (although I don't have
kosarev added a comment.
The NEON Intrinsics Reference
(http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.ihi0073a/index.html)
reads like they are AArch64-only.
https://reviews.llvm.org/D45668
___
cfe-commits mailing list
aaron.ballman accepted this revision.
aaron.ballman added a comment.
This revision is now accepted and ready to land.
LGTM! I will go ahead and commit on your behalf. Btw, if you're thinking of
making additional patches, now might be a good time to ask for commit
privileges
Eugene.Zelenko added a comment.
In https://reviews.llvm.org/D45679#1069638, @JonasToth wrote:
> *hust* /llvm/tools/clang/lib/Analysis/PseudoConstantAnalysis.cpp
>
> I will check this one first, before we get crazy and implemented something
> twice.
But this is IR-level analysis. Clang has own
mike.dvoretsky created this revision.
mike.dvoretsky added reviewers: craig.topper, spatel.
Herald added a subscriber: cfe-commits.
This patch lowers the X86 vector packing with saturation intrinsics to native
LLVM IR. Comes with an LLVM patch.
Repository:
rC Clang
hiraditya updated this revision to Diff 142776.
hiraditya added a comment.
Warn on bool* to bool conversion during a call only.
https://reviews.llvm.org/D45601
Files:
include/clang/Basic/DiagnosticSemaKinds.td
lib/Sema/SemaChecking.cpp
test/SemaCXX/warn-bool-ptr-to-bool.cpp
Index:
aaron.ballman added a comment.
In https://reviews.llvm.org/D41648#1047799, @JonasToth wrote:
> I checked several codebases and implemented a little helper script to see
> which kind of macros exist. Then I added some filter regex as configuration
> and tried again, here are the results:
>
>
Author: aaronballman
Date: Tue Apr 17 07:00:06 2018
New Revision: 330188
URL: http://llvm.org/viewvc/llvm-project?rev=330188=rev
Log:
Add modifiers for unsigned char and signed char field printing for
__builtin_dump_struct.
Patch by Paul Semel.
Modified:
cfe/trunk/lib/CodeGen/CGBuiltin.cpp
aaron.ballman closed this revision.
aaron.ballman added a comment.
Committed in r330188, thank you for the patch!
Repository:
rC Clang
https://reviews.llvm.org/D45615
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
mike.dvoretsky created this revision.
mike.dvoretsky added reviewers: craig.topper, spatel.
Herald added a subscriber: cfe-commits.
This patch lowers the SAD intrinsics to native LLVM IR. Comes with an LLVM
patch.
Repository:
rC Clang
https://reviews.llvm.org/D45722
Files:
yaxunl marked an inline comment as done.
yaxunl added inline comments.
Comment at: lib/Frontend/InitPreprocessor.cpp:473
+ Builder.defineMacro("__HIP_DEVICE_COMPILE__");
+ }
}
rjmccall wrote:
> I assume these names are defined by the HIP spec.
Yes these
Author: tejohnson
Date: Tue Apr 17 09:39:25 2018
New Revision: 330194
URL: http://llvm.org/viewvc/llvm-project?rev=330194=rev
Log:
[ThinLTO] Pass -save-temps to LTO backend for distributed ThinLTO builds
Summary:
The clang driver option -save-temps was not passed to the LTO config,
so when
This revision was automatically updated to reflect the committed changes.
Closed by commit rL330195: [NEON] Define vget_high_f16() and vget_low_f16()
intrinsics in AArch64 mode only (authored by kosarev, committed by ).
Herald added a subscriber: llvm-commits.
Changed prior to commit:
Author: kosarev
Date: Tue Apr 17 09:43:07 2018
New Revision: 330195
URL: http://llvm.org/viewvc/llvm-project?rev=330195=rev
Log:
[NEON] Define vget_high_f16() and vget_low_f16() intrinsics in AArch64 mode only
Differential Revision: https://reviews.llvm.org/D45668
Modified:
This revision was automatically updated to reflect the committed changes.
Closed by commit rL330194: [ThinLTO] Pass -save-temps to LTO backend for
distributed ThinLTO builds (authored by tejohnson, committed by ).
Herald added a subscriber: llvm-commits.
Repository:
rL LLVM
koldaniel added a comment.
In https://reviews.llvm.org/D35068#1049530, @george.karpenkov wrote:
> @koldaniel Have you evaluated this checker? On which codebases? Were the
> warnings real security issues, or were they mostly spurious? The code seems
> fine, but I'm not sure whether it should be
klimek created this revision.
klimek added a reviewer: krasimir.
...doesn't
work correctly for "} else {".
2. We needed to change the API of AffectedRangeManager to not use iterators; we
always passed in begin / end for the whole container before, so there was no
mismatch in generality.
3.
kpw updated this revision to Diff 142790.
kpw added a comment.
Undoing formatting change.
Repository:
rC Clang
https://reviews.llvm.org/D45716
Files:
include/clang/Basic/Builtins.def
include/clang/Basic/LangOptions.def
include/clang/Basic/XRayInstr.h
include/clang/Driver/Options.td
malaperle added a comment.
Any objections to the latest version?
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D44882
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
shuaiwang updated this revision to Diff 142882.
shuaiwang added a comment.
Better range for loop handling.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D45679
Files:
clang-tidy/utils/ASTUtils.cpp
clang-tidy/utils/ASTUtils.h
unittests/clang-tidy/CMakeLists.txt
This revision was automatically updated to reflect the committed changes.
Closed by commit rL330187: [NEON] Fix the architecture condition for the crypto
intrinsics (authored by kosarev, committed by ).
Herald added a subscriber: llvm-commits.
Changed prior to commit:
alexfh accepted this revision.
alexfh added inline comments.
This revision is now accepted and ready to land.
Comment at: test/clang-tidy/read_file_config.cpp:5
+// RUN: echo '[{"command": "cc -c -o test.o test.cpp", "directory":
"%T/read-file-config", "file":
This revision was automatically updated to reflect the committed changes.
Closed by commit rC330187: [NEON] Fix the architecture condition for the crypto
intrinsics (authored by kosarev, committed by ).
Repository:
rL LLVM
https://reviews.llvm.org/D45669
Files:
Author: kosarev
Date: Tue Apr 17 06:37:30 2018
New Revision: 330187
URL: http://llvm.org/viewvc/llvm-project?rev=330187=rev
Log:
[NEON] Fix the architecture condition for the crypto intrinsics
Differential Revision: https://reviews.llvm.org/D45669
Modified:
SjoerdMeijer accepted this revision.
SjoerdMeijer added a comment.
This revision is now accepted and ready to land.
Yep, agreed, also on the new shiny
https://developer.arm.com/technologies/neon/intrinsics it is listed as A64 only.
https://reviews.llvm.org/D45668
kosarev updated this revision to Diff 142784.
kosarev added a comment.
Removed checks for unused bitcasts. Thanks for catching!
https://reviews.llvm.org/D45670
Files:
include/clang/Basic/arm_neon.td
test/CodeGen/arm-neon-fma.c
Index: test/CodeGen/arm-neon-fma.c
Author: ahatanak
Date: Tue Apr 17 12:05:17 2018
New Revision: 330201
URL: http://llvm.org/viewvc/llvm-project?rev=330201=rev
Log:
Move the visitor classes that are used to traverse non-trivial C structs
to a header file.
This is in preparation for using the visitor classes to warn about
Author: jvesely
Date: Tue Apr 17 12:35:32 2018
New Revision: 330207
URL: http://llvm.org/viewvc/llvm-project?rev=330207=rev
Log:
powr: Use denormal path only
It's OK to either flush to 0 or return denormal result if the device
does not support denormals. See sec 7.2 and 7.5.3 of OCL specs
Fixes
Author: jvesely
Date: Tue Apr 17 12:35:30 2018
New Revision: 330206
URL: http://llvm.org/viewvc/llvm-project?rev=330206=rev
Log:
pown: Use denormal path only
It's OK to either flush to 0 or return denormal result if the device
does not support denormals. See sec 7.2 and 7.5.3 of OCL specs
Fixes
Author: jvesely
Date: Tue Apr 17 12:35:28 2018
New Revision: 330205
URL: http://llvm.org/viewvc/llvm-project?rev=330205=rev
Log:
pow: Use denormal path only
It's OK to either flush to 0 or return denormal result if the device
does not support denormals. See sec 7.2 and 7.5.3 of OCL specs
Fixes
yaxunl updated this revision to Diff 142818.
yaxunl marked an inline comment as done.
yaxunl retitled this revision from "[HIP] Add hip file type and codegen for
kernel launching" to "[HIP] Add hip input kind and codegen for kernel
launching".
yaxunl edited the summary of this revision.
yaxunl
hokein updated this revision to Diff 142817.
hokein marked an inline comment as done.
hokein added a comment.
Make grep pattern more obvious.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D45697
Files:
clang-tidy/ClangTidyOptions.cpp
clang-tidy/ClangTidyOptions.h
tejohnson added inline comments.
Comment at: cfe/trunk/lib/Driver/ToolChains/Clang.cpp:3270
+ if (const Arg *A = Args.getLastArg(options::OPT_save_temps_EQ))
+Args.AddLastArg(CmdArgs, options::OPT_save_temps_EQ);
bjope wrote:
> A is not used, so this does
devnexen added inline comments.
Comment at: lib/Driver/ToolChains/OpenBSD.cpp:189
if (getToolChain().ShouldLinkCXXStdlib(Args))
-getToolChain().AddCXXStdlibLibArgs(Args, CmdArgs);
+ToolChain.AddCXXStdlibLibArgs(Args, CmdArgs);
if
devnexen updated this revision to Diff 142811.
devnexen retitled this revision from "Fuzzer, add libcxx for OpenBSD" to
"OpenBSD add C++ runtime in a driver's standpoint".
devnexen edited the summary of this revision.
https://reviews.llvm.org/D45662
Files:
lib/Driver/ToolChains/OpenBSD.cpp
devnexen added inline comments.
Comment at: lib/Driver/ToolChains/OpenBSD.cpp:189
if (getToolChain().ShouldLinkCXXStdlib(Args))
-getToolChain().AddCXXStdlibLibArgs(Args, CmdArgs);
+ToolChain.AddCXXStdlibLibArgs(Args, CmdArgs);
if
This revision was automatically updated to reflect the committed changes.
Closed by commit rC330202: [Sema] Warn about memcpying non-trivial C
structs. (authored by ahatanak, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D45310?vs=142705=142815#toc
Repository:
rC Clang
Author: ahatanak
Date: Tue Apr 17 12:13:41 2018
New Revision: 330202
URL: http://llvm.org/viewvc/llvm-project?rev=330202=rev
Log:
[Sema] Warn about memcpy'ing non-trivial C structs.
Issue a warning when non-trivial C structs are copied or initialized by
calls to memset, bzero, memcpy, or
yaxunl marked 2 inline comments as done.
yaxunl added inline comments.
Comment at: lib/Frontend/CompilerInvocation.cpp:2109
+ Opts.HIP = true;
+ }
+
rjmccall wrote:
> yaxunl wrote:
> > rjmccall wrote:
> > > Why is this done here? We infer the language
bjope added inline comments.
Comment at: cfe/trunk/lib/Driver/ToolChains/Clang.cpp:3270
+ if (const Arg *A = Args.getLastArg(options::OPT_save_temps_EQ))
+Args.AddLastArg(CmdArgs, options::OPT_save_temps_EQ);
A is not used, so this does not compile when
danalbert marked an inline comment as done.
danalbert added inline comments.
Comment at: lib/Driver/ToolChains/Linux.cpp:25
#include "llvm/Support/Path.h"
+#include "llvm/Support/ScopedPrinter.h"
#include
eugenis wrote:
> I don't see why this include is
Author: tejohnson
Date: Tue Apr 17 13:21:53 2018
New Revision: 330210
URL: http://llvm.org/viewvc/llvm-project?rev=330210=rev
Log:
Remove unused variable
Fixes unused variable error introduced in r330194.
Modified:
cfe/trunk/lib/Driver/ToolChains/Clang.cpp
Modified:
tejohnson added inline comments.
Comment at: cfe/trunk/lib/Driver/ToolChains/Clang.cpp:3270
+ if (const Arg *A = Args.getLastArg(options::OPT_save_temps_EQ))
+Args.AddLastArg(CmdArgs, options::OPT_save_temps_EQ);
tejohnson wrote:
> bjope wrote:
> > A is
Author: jvesely
Date: Tue Apr 17 11:08:08 2018
New Revision: 330197
URL: http://llvm.org/viewvc/llvm-project?rev=330197=rev
Log:
exp10: Port from amd builtins
Passes CTS on carrizo and turks.
Signed-off-by: Jan Vesely
Reviewed and Tested (on RX 580) by: Aaron Watry
efriedma added a comment.
The thing about the bool*-only version is that bool pointers are rare in C++,
so I'm not sure we're gaining much. But if we can't do something more general,
there's still some benefit.
I see your point about false positives for the more general version. I was sort
Quuxplusone added inline comments.
Comment at: lib/Sema/SemaChecking.cpp:2623
+QualType QT = Pointer->getType()->getPointeeType();
+if (!QT.isNull() && QT->isBooleanType())
+ // Warn on bool* to bool conversion.
Author: ahatanak
Date: Tue Apr 17 11:41:52 2018
New Revision: 330199
URL: http://llvm.org/viewvc/llvm-project?rev=330199=rev
Log:
Add a command line option 'fregister_global_dtors_with_atexit' to
register destructor functions annotated with __attribute__((destructor))
using __cxa_atexit or
This revision was automatically updated to reflect the committed changes.
Closed by commit rL330199: Add a command line option
fregister_global_dtors_with_atexit to (authored by ahatanak,
committed by ).
Herald added a subscriber: llvm-commits.
Changed prior to commit:
craig.topper added inline comments.
Comment at: lib/CodeGen/CGBuiltin.cpp:8420
+ if (IsUnsigned) {
+MinVal = (IsDW) ? llvm::APInt::getMinValue(16).getZExtValue()
+: llvm::APInt::getMinValue(8).getZExtValue();
Why can't these just be
ahatanak updated this revision to Diff 142792.
ahatanak added a comment.
Deactivate the cleanups for callee-destructed parameters that are being
forwarded to a delegated constructor.
I also added a new member (CurrentCleanupStackDepth) to CodeGenFunction that
tracks the stack depth of the most
aaron.ballman added inline comments.
Comment at: lib/Sema/SemaChecking.cpp:2623
+QualType QT = Pointer->getType()->getPointeeType();
+if (!QT.isNull() && QT->isBooleanType())
+ // Warn on bool* to bool conversion.
1 - 100 of 141 matches
Mail list logo