r360446 - [Sema] Mark array element destructors referenced during initialization

2019-05-10 Thread Erik Pilkington via cfe-commits
Author: epilk Date: Fri May 10 10:52:26 2019 New Revision: 360446 URL: http://llvm.org/viewvc/llvm-project?rev=360446=rev Log: [Sema] Mark array element destructors referenced during initialization This fixes a crash where we would neglect to mark a destructor referenced for an

[PATCH] D61165: Fix a crash where a [[no_destroy]] destructor was not emitted in an array

2019-05-10 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL360446: [Sema] Mark array element destructors referenced during initialization (authored by epilk, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to

[PATCH] D61634: [clang/llvm] Allow efficient implementation of libc's memory functions in C/C++

2019-05-10 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. > -fno-builtin* is about preventing clang/llvm from recognizing that a piece of > code has the same semantic as a particular IR intrinsic, it has nothing to do > with preventing the compiler from generating runtime calls. It has a dual purpose for C library functions.

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 199073. gtbercea added a comment. - Add tests. Exclude additional abs definition. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61765/new/ https://reviews.llvm.org/D61765 Files: lib/Driver/ToolChains/Clang.cpp

[PATCH] D61350: [clang-tidy] New check calling out uses of +new in Objective-C code

2019-05-10 Thread Michael Wyman via Phabricator via cfe-commits
mwyman accepted this revision. mwyman added a comment. I don't have commit access, so if somebody could submit them that would be wonderful! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61350/new/ https://reviews.llvm.org/D61350 ___

[PATCH] D61803: [CodeGen][ObjC] Emit invoke instead of call to call `objc_release` when necessary.

2019-05-10 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak created this revision. ahatanak added reviewers: pete, rjmccall. ahatanak added a project: clang. Herald added subscribers: dexonsmith, jkorous. Prior to r349952, clang used to call `objc_msgSend` when sending a release messages, emitting an invoke instruction instead of a call

[PATCH] D61749: [clang-tidy] initial version of readability-static-const-method

2019-05-10 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre added a comment. I have thought about splitting the check into separate `static` & `const`, but kept it together because the analysis for both cases is very similar, i.e. finding the usage of `this`. Also, both checks share many preconditions, e.g. not applying them to virtual methods

[PATCH] D61804: Support building shared and static libraries simultaneously

2019-05-10 Thread Wink Saville via Phabricator via cfe-commits
winksaville created this revision. winksaville added reviewers: tstellar, morehouse, gottesmm, chapuni. Herald added subscribers: llvm-commits, cfe-commits, mgorny. Herald added projects: clang, LLVM. I ran into the need for both while trying to compile zig (https://ziglang.org) on my Arch Linux

[PATCH] D60974: Clang IFSO driver action.

2019-05-10 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi added a comment. In D60974#1498604 , @compnerd wrote: > This really needs more tests. Please add a positive/negative test for the > driver argument. Please try to organise the tests a bit to show what it is > that they are testing, emission of

[PATCH] D61743: New clang option -MD-filter=prefix to filter files from make dependencies

2019-05-10 Thread Melanie Blower via Phabricator via cfe-commits
mibintc updated this revision to Diff 199082. mibintc added a comment. respond to suggestion from @xbolva00 (thanks). Added a test case where prefix fails to match CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61743/new/ https://reviews.llvm.org/D61743 Files:

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea marked an inline comment as done. gtbercea added inline comments. Comment at: lib/Headers/__clang_cuda_math_forward_declares.h:30-38 +#ifndef _OPENMP +__DEVICE__ long abs(long); +__DEVICE__ long long abs(long long); +#else +#ifndef __cplusplus __DEVICE__ long

[PATCH] D61756: Add a __FILE_NAME__ macro.

2019-05-10 Thread Kristina Brooks via Phabricator via cfe-commits
kristina updated this revision to Diff 199104. kristina edited the summary of this revision. kristina added a comment. Actually I got it wrong, the path is normalized to use regular slashes at that point, so there is no point in handling backslashes in paths at all even with Microsoft

[PATCH] D58320: [Darwin] Introduce a new flag, -fapple-link-rtlib that forces linking of the builtins library.

2019-05-10 Thread Amara Emerson via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rL360483: [Darwin] Introduce a new flag, -fapple-link-rtlib that forces linking of the… (authored by aemerson, committed by

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 199041. gtbercea added a comment. - Fix cstdlib issue. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61765/new/ https://reviews.llvm.org/D61765 Files: lib/Driver/ToolChains/Clang.cpp lib/Headers/CMakeLists.txt

[PATCH] D60974: Clang IFSO driver action.

2019-05-10 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi marked an inline comment as done. plotfi added a comment. In D60974#1498240 , @jakehehrlich wrote: > This shouldn't emit the .tbe format at all, the .tbe format is meant to be in > near 1-1 correspondence with .so files, not with .o files. It has

[PATCH] D61788: Make getObjCEncodingForTypeImpl() take a bitmask instead of 8 bools

2019-05-10 Thread Nico Weber via Phabricator via cfe-commits
thakis marked 2 inline comments as done. thakis added inline comments. Comment at: clang/include/clang/AST/ASTContext.h:2877 +OCET_EncodePointerToObjCTypedef = 1 << 7, + }; + void getObjCEncodingForTypeImpl(QualType t, std::string , unsigned Options,

[PATCH] D57860: [analyzer] Validate checker option names and values

2019-05-10 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. In D57860#1432728 , @dcoughlin wrote: > Setting compatibility mode to be true in the driver is not sufficient since > many build systems call the frontend directly. This doesn't seem to be the case; all

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea marked an inline comment as done. gtbercea added inline comments. Comment at: lib/Headers/__clang_cuda_math_forward_declares.h:30-38 +#ifndef _OPENMP +__DEVICE__ long abs(long); +__DEVICE__ long long abs(long long); +#else +#ifndef __cplusplus __DEVICE__ long

[PATCH] D60593: [GwpAsan] Introduce GWP-ASan.

2019-05-10 Thread Mitch Phillips via Phabricator via cfe-commits
hctim added a comment. In D60593#1495428 , @gribozavr wrote: > What does GWP stand for? Google Wide Profiling . We use the name GWP-ASan, even though it's "technically

[PATCH] D57858: [analyzer] Add a new frontend flag to display all checker options

2019-05-10 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. Also, for CodeChecker purposes wouldn't you rather have a machine-readable dump? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57858/new/ https://reviews.llvm.org/D57858 ___ cfe-commits mailing list

[PATCH] D61809: [BPF] Preserve original struct/union type name/access index and array subscripts

2019-05-10 Thread Yonghong Song via Phabricator via cfe-commits
yonghong-song created this revision. yonghong-song added reviewers: eli.friedman, ast. Herald added subscribers: cfe-commits, arphaman, kosarev. Herald added a project: clang. For background of BPF CO-RE project, please refer to http://vger.kernel.org/bpfconf2019.html In summary, BPF CO-RE

[PATCH] D60974: Clang IFSO driver action.

2019-05-10 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi updated this revision to Diff 199112. plotfi added a comment. Adding lit test cases. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60974/new/ https://reviews.llvm.org/D60974 Files: clang/include/clang/Driver/Options.td

r360448 - Fix and test for assertion error in P41835.

2019-05-10 Thread Leonard Chan via cfe-commits
Author: leonardchan Date: Fri May 10 11:05:15 2019 New Revision: 360448 URL: http://llvm.org/viewvc/llvm-project?rev=360448=rev Log: Fix and test for assertion error in P41835. Modified: cfe/trunk/lib/AST/ASTContext.cpp cfe/trunk/test/Frontend/macro_defined_type.cpp Modified:

[PATCH] D57858: [analyzer] Add a new frontend flag to display all checker options

2019-05-10 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. Let's land this together with @Szelethus's proposed solution of hiding hidden options (like checkers in D60925 ). I'm still in favor of hiding alpha checkers (as they are for development only, much like debug flags; i'd recommend hiding

r360474 - [CodeGen][ObjC] Emit invoke instead of call to call `objc_release` when

2019-05-10 Thread Akira Hatanaka via cfe-commits
Author: ahatanak Date: Fri May 10 14:54:16 2019 New Revision: 360474 URL: http://llvm.org/viewvc/llvm-project?rev=360474=rev Log: [CodeGen][ObjC] Emit invoke instead of call to call `objc_release` when necessary. Prior to r349952, clang used to call objc_msgSend when sending a release messages,

[PATCH] D61809: [BPF] Preserve original struct/union type name/access index and array subscripts

2019-05-10 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Tests seems to be missing? Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61809/new/ https://reviews.llvm.org/D61809 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D61788: Make getObjCEncodingForTypeImpl() take a bitmask instead of 8 bools

2019-05-10 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: clang/include/clang/AST/ASTContext.h:2877 +OCET_EncodePointerToObjCTypedef = 1 << 7, + }; + void getObjCEncodingForTypeImpl(QualType t, std::string , unsigned Options, I like the idea of doing this, but can you

[PATCH] D60629: [clang-tidy] Change the namespace for llvm checkers from 'llvm' to 'llvm_check'

2019-05-10 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE360450: [clang-tidy] Change the namespace for llvm checkers from llvm to llvm_check (authored by dhinton, committed by ). Changed prior to commit:

[clang-tools-extra] r360451 - Removing an unused member variable; NFC.

2019-05-10 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Fri May 10 11:29:10 2019 New Revision: 360451 URL: http://llvm.org/viewvc/llvm-project?rev=360451=rev Log: Removing an unused member variable; NFC. Modified: clang-tools-extra/trunk/clang-tidy/modernize/UseTrailingReturnTypeCheck.cpp Modified:

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. What about `abs` tests? Comment at: lib/Headers/openmp_wrappers/__clang_openmp_math_declares.h:17 + #include + #include +#endif Why do we need the stdlib includes again? Comment at:

[PATCH] D60974: Clang IFSO driver action.

2019-05-10 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd added a comment. This really needs more tests. Please add a positive/negative test for the driver argument. Please try to organise the tests a bit to show what it is that they are testing, emission of public functions, not of protected functions or hidden functions. Behaviour with

[PATCH] D61803: [CodeGen][ObjC] Emit invoke instead of call to call `objc_release` when necessary.

2019-05-10 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington accepted this revision. erik.pilkington added a comment. This revision is now accepted and ready to land. LGTM, thanks! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61803/new/ https://reviews.llvm.org/D61803

[PATCH] D61749: [clang-tidy] initial version of readability-static-const-method

2019-05-10 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a reviewer: lebedev.ri. lebedev.ri added a comment. In D61749#1497162 , @Eugene.Zelenko wrote: > @JonasToth tried to implement const check, so probably const and static part > should be split. I agree, there is D54943

r360465 - Add target triple to test.

2019-05-10 Thread Leonard Chan via cfe-commits
Author: leonardchan Date: Fri May 10 13:07:47 2019 New Revision: 360465 URL: http://llvm.org/viewvc/llvm-project?rev=360465=rev Log: Add target triple to test. Modified: cfe/trunk/test/Frontend/macro_defined_type.cpp Modified: cfe/trunk/test/Frontend/macro_defined_type.cpp URL:

[PATCH] D61749: [clang-tidy] initial version of readability-static-const-method

2019-05-10 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In D61749#1498541 , @mgehre wrote: > ... Still, this is two separate checks, logically. You can put the `FindUsageOfThis` e.g. into a new file in `clang-tidy/utils`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[PATCH] D58320: [Darwin] Introduce a new flag, -fapple-link-rtlib that forces linking of the builtins library.

2019-05-10 Thread Amara Emerson via Phabricator via cfe-commits
aemerson marked an inline comment as done. aemerson added inline comments. Comment at: clang/lib/Driver/ToolChains/Darwin.cpp:2084 AddLinkRuntimeLib(Args, CmdArgs, CompilerRT, RLO_IsEmbedded); } ab wrote: > This is different from 'builtins'. Are you OK

[PATCH] D61756: Add a __FILE_NAME__ macro.

2019-05-10 Thread Kristina Brooks via Phabricator via cfe-commits
kristina added a comment. Need @rsmith to bless this as it's introducing a nonstandard extension, however small it may be. The original diff did have a consensus on it, so I didn't really put up a formal RFC on `cfe-dev`. Repository: rC Clang CHANGES SINCE LAST ACTION

[PATCH] D51329: [Attribute/Diagnostics] Print macro if definition is an attribute declaration

2019-05-10 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan added a comment. In D51329#1498193 , @miyuki wrote: > This caused https://bugs.llvm.org/show_bug.cgi?id=41835 > Could you please look into it? Sorry for the delay. I submitted r360448 as a fix for this. Repository: rC Clang CHANGES

[PATCH] D61788: Make getObjCEncodingForTypeImpl() take a bitmask instead of 8 bools

2019-05-10 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: clang/include/clang/AST/ASTContext.h:2877 +OCET_EncodePointerToObjCTypedef = 1 << 7, + }; + void getObjCEncodingForTypeImpl(QualType t, std::string , unsigned Options, thakis wrote: > rjmccall wrote: > > I like

r360468 - [ThinLTO] Clang test changes for new CanAutoHide flag

2019-05-10 Thread Teresa Johnson via cfe-commits
Author: tejohnson Date: Fri May 10 13:38:31 2019 New Revision: 360468 URL: http://llvm.org/viewvc/llvm-project?rev=360468=rev Log: [ThinLTO] Clang test changes for new CanAutoHide flag Modified: cfe/trunk/test/CodeGen/thinlto-distributed-cfi-devirt.ll

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 199080. gtbercea added a comment. - Error if not in OpenMP. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61765/new/ https://reviews.llvm.org/D61765 Files: lib/Driver/ToolChains/Clang.cpp lib/Headers/CMakeLists.txt

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: lib/Headers/__clang_cuda_math_forward_declares.h:30-38 +#ifndef _OPENMP +__DEVICE__ long abs(long); +__DEVICE__ long long abs(long long); +#else +#ifndef __cplusplus __DEVICE__ long abs(long); __DEVICE__ long long abs(long long);

[PATCH] D60974: Clang IFSO driver action.

2019-05-10 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi added a comment. In D60974#1498240 , @jakehehrlich wrote: > This shouldn't emit the .tbe format at all, the .tbe format is meant to be in > near 1-1 correspondence with .so files, not with .o files. It has things like > DT_NEEDED, and DT_SONAME

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: lib/Headers/__clang_cuda_math_forward_declares.h:30-38 +#ifndef _OPENMP +__DEVICE__ long abs(long); +__DEVICE__ long long abs(long long); +#else +#ifndef __cplusplus __DEVICE__ long abs(long); __DEVICE__ long long abs(long long);

[PATCH] D60593: [GwpAsan] Introduce GWP-ASan.

2019-05-10 Thread Mitch Phillips via Phabricator via cfe-commits
hctim updated this revision to Diff 199083. hctim marked an inline comment as done. hctim added a comment. Herald added a project: clang. Herald added a subscriber: cfe-commits. - Updated tests to use unittests rather than expose a public interface and exercise that. Minor perf improvements to

[clang-tools-extra] r360450 - [clang-tidy] Change the namespace for llvm checkers from 'llvm' to 'llvm_check'

2019-05-10 Thread Don Hinton via cfe-commits
Author: dhinton Date: Fri May 10 11:27:09 2019 New Revision: 360450 URL: http://llvm.org/viewvc/llvm-project?rev=360450=rev Log: [clang-tidy] Change the namespace for llvm checkers from 'llvm' to 'llvm_check' Summary: Change the namespace for llvm checkers from 'llvm' to 'llvm_check', and modify

[PATCH] D60974: Clang IFSO driver action.

2019-05-10 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi marked 2 inline comments as done. plotfi added inline comments. Comment at: llvm/include/llvm/TextAPI/ELF/ELFStub.h:58 ELFArch Arch; + Optional Endian; std::vector NeededLibs; jakehehrlich wrote: > Why do we need or want this? If it is needed can

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 199062. gtbercea added a comment. - Clean test header. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61765/new/ https://reviews.llvm.org/D61765 Files: lib/Driver/ToolChains/Clang.cpp lib/Headers/CMakeLists.txt

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added inline comments. Comment at: lib/Headers/openmp_wrappers/__clang_openmp_math_declares.h:17 + #include + #include +#endif gtbercea wrote: > jdoerfert wrote: > > Why do we need the stdlib includes again? > They are both prone to abs inclusion.

r360464 - Fix handling of objects under construction during constant expression

2019-05-10 Thread Richard Smith via cfe-commits
Author: rsmith Date: Fri May 10 13:05:32 2019 New Revision: 360464 URL: http://llvm.org/viewvc/llvm-project?rev=360464=rev Log: Fix handling of objects under construction during constant expression evaluation. It's not enough to just track the LValueBase that we're evaluating, we need to also

r360467 - Fixed tests where grep was not matching the linefeed

2019-05-10 Thread Alexandre Ganea via cfe-commits
Author: aganea Date: Fri May 10 13:11:36 2019 New Revision: 360467 URL: http://llvm.org/viewvc/llvm-project?rev=360467=rev Log: Fixed tests where grep was not matching the linefeed When files are synchronized locally as CRLF on Windows, grep didn't match the newline. Switched to FileCheck

r360463 - Improve interface of APValuePathEntry.

2019-05-10 Thread Richard Smith via cfe-commits
Author: rsmith Date: Fri May 10 13:05:31 2019 New Revision: 360463 URL: http://llvm.org/viewvc/llvm-project?rev=360463=rev Log: Improve interface of APValuePathEntry. Modified: cfe/trunk/include/clang/AST/APValue.h cfe/trunk/lib/AST/APValue.cpp cfe/trunk/lib/AST/ExprConstant.cpp

[PATCH] D61496: Fixed tests where grep was not matching the linefeed

2019-05-10 Thread Alexandre Ganea via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC360467: Fixed tests where grep was not matching the linefeed (authored by aganea, committed by ). Changed prior to commit: https://reviews.llvm.org/D61496?vs=197990=199069#toc Repository: rC Clang

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea marked an inline comment as done. gtbercea added inline comments. Comment at: lib/Headers/__clang_cuda_math_forward_declares.h:30-38 +#ifndef _OPENMP +__DEVICE__ long abs(long); +__DEVICE__ long long abs(long long); +#else +#ifndef __cplusplus __DEVICE__ long

[PATCH] D61803: [CodeGen][ObjC] Emit invoke instead of call to call `objc_release` when necessary.

2019-05-10 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak updated this revision to Diff 199081. ahatanak marked an inline comment as done. ahatanak added a comment. Just call `EmitCallOrInvoke`. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61803/new/ https://reviews.llvm.org/D61803 Files:

[PATCH] D60593: [GwpAsan] Introduce GWP-ASan.

2019-05-10 Thread Matt Morehouse via Phabricator via cfe-commits
morehouse added a comment. This diff is helpful to get an overall idea of how things fit together, but it is very difficult to review thoroughly. Let's start splicing off pieces for individual review. I suggest: - Individual reviews for each prereq (mutex, random, etc.) - Review for base GPA

[PATCH] D59885: [Lex] Allow to consume tokens while preprocessing

2019-05-10 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. In D59885#1496734 , @ilya-biryukov wrote: > Overall, the performance cost in empty-callback case seems to be lower than > `5%`. This is significant, but hopefully acceptable. 5% is a lot to pay for something that we won't be

r360452 - Replace 'REQUIRES: nozlib' with '!zlib' because we don't need two ways

2019-05-10 Thread Paul Robinson via cfe-commits
Author: probinson Date: Fri May 10 11:32:53 2019 New Revision: 360452 URL: http://llvm.org/viewvc/llvm-project?rev=360452=rev Log: Replace 'REQUIRES: nozlib' with '!zlib' because we don't need two ways to say the same thing. Modified: cfe/trunk/test/Driver/nozlibcompress.c Modified:

[PATCH] D43576: Solution to fix PR27066 - Redefinition with same mangled name as another definition (dllexport and uuid)

2019-05-10 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: include/clang/AST/Decl.h:4281 + class DeclSpecUuidDecl : public Decl { + StringRef StrUuid; + public: Can we store a `StringLiteral*` here instead? Comment at: include/clang/Sema/Sema.h:393-394 +

[PATCH] D61709: [NewPM] Port HWASan and Kernel HWASan

2019-05-10 Thread Philip Pfaffe via Phabricator via cfe-commits
philip.pfaffe accepted this revision. philip.pfaffe added a comment. This revision is now accepted and ready to land. Nit aside, looks good! Comment at: llvm/lib/Transforms/Instrumentation/HWAddressSanitizer.cpp:179 - bool runOnFunction(Function ) override; - bool

[PATCH] D61803: [CodeGen][ObjC] Emit invoke instead of call to call `objc_release` when necessary.

2019-05-10 Thread Akira Hatanaka via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL360474: [CodeGen][ObjC] Emit invoke instead of call to call `objc_release` when (authored by ahatanak, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior

[PATCH] D61809: [BPF] Preserve original struct/union type name/access index and array subscripts

2019-05-10 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. If I understand correctly, you want to be able to compile a program against some `struct` and `union` layouts, and then at load time "update" the program to cope with the actual layouts for those types being something else, but containing (at least) the set of members

r360483 - [Darwin] Introduce a new flag, -fapple-link-rtlib that forces linking of the builtins library.

2019-05-10 Thread Amara Emerson via cfe-commits
Author: aemerson Date: Fri May 10 16:24:20 2019 New Revision: 360483 URL: http://llvm.org/viewvc/llvm-project?rev=360483=rev Log: [Darwin] Introduce a new flag, -fapple-link-rtlib that forces linking of the builtins library. This driver flag is useful when users want to link against the

r360447 - Replace 'REQUIRES: not_?san' with 'UNSUPPORTED: ?san' as that better

2019-05-10 Thread Paul Robinson via cfe-commits
Author: probinson Date: Fri May 10 10:57:22 2019 New Revision: 360447 URL: http://llvm.org/viewvc/llvm-project?rev=360447=rev Log: Replace 'REQUIRES: not_?san' with 'UNSUPPORTED: ?san' as that better expresses the intent of the exclusion. Modified:

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea marked 2 inline comments as done. gtbercea added inline comments. Comment at: lib/Headers/openmp_wrappers/__clang_openmp_math_declares.h:17 + #include + #include +#endif jdoerfert wrote: > Why do we need the stdlib includes again? They are both

[PATCH] D60974: Clang IFSO driver action.

2019-05-10 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi updated this revision to Diff 199058. plotfi added a comment. Changing !tapi-tbe to !experimental-tapi-elf-v1, removing Endianness field from tapi-tbe. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60974/new/

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: lib/Headers/__clang_cuda_math_forward_declares.h:30-38 +#ifndef _OPENMP +__DEVICE__ long abs(long); +__DEVICE__ long long abs(long long); +#else +#ifndef __cplusplus __DEVICE__ long abs(long); __DEVICE__ long long abs(long long);

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 199075. gtbercea added a comment. - Simplify conditions. Add guards. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61765/new/ https://reviews.llvm.org/D61765 Files: lib/Driver/ToolChains/Clang.cpp

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. Last issue I have (in addition to the check @tra suggested) is the order in which we include math.h and cstdlib. can you flip it in one of the test cases? Comment at: lib/Headers/__clang_cuda_math_forward_declares.h:30-38 +#ifndef _OPENMP

[PATCH] D61803: [CodeGen][ObjC] Emit invoke instead of call to call `objc_release` when necessary.

2019-05-10 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington added inline comments. Comment at: lib/CodeGen/CGObjC.cpp:2634-2646 + ASTContext = getContext(); + const ImplicitParamDecl *paramDecl = + ImplicitParamDecl::Create(Ctx, nullptr, SourceLocation(), nullptr, +Ctx.VoidPtrTy,

[PATCH] D61765: [OpenMP][Clang][BugFix] Split declares and math functions inclusion.

2019-05-10 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: lib/Headers/__clang_cuda_math_forward_declares.h:30-38 +#ifndef _OPENMP +__DEVICE__ long abs(long); +__DEVICE__ long long abs(long long); +#else +#ifndef __cplusplus __DEVICE__ long abs(long); __DEVICE__ long long abs(long long);

[PATCH] D61809: [BPF] Preserve original struct/union type name/access index and array subscripts

2019-05-10 Thread Yonghong Song via Phabricator via cfe-commits
yonghong-song added a comment. @lebedev.ri Thanks for the comment. This patch is not ready to land yet. Yes, tests are missing and I am going to add tests later. More importantly, I want to get a sense whether what I am implementing here is the right direction or not. The following two other

[PATCH] D59919: [Attributor] Deduce "returned" argument attribute

2019-05-10 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert updated this revision to Diff 199114. jdoerfert added a comment. Rebase on newest Attributor design Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59919/new/ https://reviews.llvm.org/D59919 Files: clang/test/CodeGenOpenCL/as_type.cl

r360495 - [cc1as] Change -compress-debug-sections= to use --

2019-05-10 Thread Fangrui Song via cfe-commits
Author: maskray Date: Fri May 10 18:14:50 2019 New Revision: 360495 URL: http://llvm.org/viewvc/llvm-project?rev=360495=rev Log: [cc1as] Change -compress-debug-sections= to use -- The double dash form is documented by GNU as, used by gcc, and accepted by llvm-mc. Modified:

[PATCH] D61788: Make getObjCEncodingForTypeImpl() take a bitmask instead of 8 bools

2019-05-10 Thread Nico Weber via Phabricator via cfe-commits
thakis added inline comments. Comment at: clang/include/clang/AST/ASTContext.h:2877 +OCET_EncodePointerToObjCTypedef = 1 << 7, + }; + void getObjCEncodingForTypeImpl(QualType t, std::string , unsigned Options, rjmccall wrote: > thakis wrote: > > rjmccall

[PATCH] D61788: Make getObjCEncodingForTypeImpl() take a bitmask instead of 8 bools

2019-05-10 Thread Nico Weber via Phabricator via cfe-commits
thakis updated this revision to Diff 199116. thakis marked 4 inline comments as done. thakis added a comment. comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61788/new/ https://reviews.llvm.org/D61788 Files: clang/include/clang/AST/ASTContext.h clang/lib/AST/ASTContext.cpp

[PATCH] D61814: [CFG] NFC: Remove implicit conversion from CFGTerminator to Stmt *, make it a variant class instead.

2019-05-10 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. NoQ added reviewers: dcoughlin, xazax.hun, a_sidorin, rnkovacs, mikhail.ramalho, Szelethus, baloghadamsoftware, Charusso. Herald added subscribers: cfe-commits, zzheng, whisperity. Herald added a project: clang. This conversion does indeed save some code, but i plan to

[PATCH] D61817: [analyzer] Add a prunable note for skipping virtual base initializers in subclasses.

2019-05-10 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. This is how it looks: F8864205: Screen Shot 2019-05-10 at 8.23.34 PM.png CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61817/new/ https://reviews.llvm.org/D61817 ___ cfe-commits

[PATCH] D61777: [cc1as] Change -compress-debug-sections= to use --

2019-05-10 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay abandoned this revision. MaskRay added a comment. Sorry, I have to commit this rC360495 now to unbreak our internal builds. Not sure whether the single dash form is necessary, but rC360495 keeps it. Repository:

r360499 - Reject attempts to call non-static member functions on objects outside

2019-05-10 Thread Richard Smith via cfe-commits
Author: rsmith Date: Fri May 10 19:00:06 2019 New Revision: 360499 URL: http://llvm.org/viewvc/llvm-project?rev=360499=rev Log: Reject attempts to call non-static member functions on objects outside their lifetime in constant expressions. This is undefined behavior per [class.cdtor]p2. We

[PATCH] D61809: [BPF] Preserve original struct/union type name/access index and array subscripts

2019-05-10 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. > The size you allocate here will presumably need to vary as the struct layout > changes, and you have no way of knowing which allocas will need their sizes > to be changed. Your example is just a pointer; the size of a pointer won't change. That said, yes, address

[PATCH] D61817: [analyzer] Add a prunable note for skipping virtual base initializers in subclasses.

2019-05-10 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. NoQ added reviewers: dcoughlin, xazax.hun, a_sidorin, rnkovacs, mikhail.ramalho, Szelethus, baloghadamsoftware, Charusso. Herald added subscribers: cfe-commits, dkrupp, donat.nagy, a.sidorin, szepet. Herald added a project: clang. NoQ updated this revision to Diff

[PATCH] D61817: [analyzer] Add a prunable note for skipping virtual base initializers in subclasses.

2019-05-10 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 199121. NoQ added a comment. Fix formatting in tests. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61817/new/ https://reviews.llvm.org/D61817 Files: clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h

r360411 - Revert "Revert "[clang-format] Keep protobuf "package" statement on one line""

2019-05-10 Thread Krasimir Georgiev via cfe-commits
Author: krasimir Date: Fri May 10 02:15:11 2019 New Revision: 360411 URL: http://llvm.org/viewvc/llvm-project?rev=360411=rev Log: Revert "Revert "[clang-format] Keep protobuf "package" statement on one line"" Summary: Top-level "package" and "import" statements should generally be kept on one

r360418 - [Preamble] Stop circular inclusion of main file when building preamble

2019-05-10 Thread Nikolai Kosjar via cfe-commits
Author: nik Date: Fri May 10 03:25:35 2019 New Revision: 360418 URL: http://llvm.org/viewvc/llvm-project?rev=360418=rev Log: [Preamble] Stop circular inclusion of main file when building preamble If a header file was processed for the second time, we could end up with a wrong conditional stack

[PATCH] D60661: Revert "Revert "[clang-format] Keep protobuf "package" statement on one line""

2019-05-10 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC360411: Revert Revert [clang-format] Keep protobuf package statement on one line (authored by krasimir, committed by ). Changed prior to commit: https://reviews.llvm.org/D60661?vs=198585=198992#toc

[PATCH] D61743: New clang option -MD-filter=prefix to filter files from make dependencies

2019-05-10 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added inline comments. Comment at: lib/Frontend/DependencyFile.cpp:279 + if (DependencyFilter.size() && + strncmp(Filename, DependencyFilter.c_str(), DependencyFilter.size()) == 0) +// Remove dependencies that are prefixed by the Filter string.

[PATCH] D60661: Revert "Revert "[clang-format] Keep protobuf "package" statement on one line""

2019-05-10 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir accepted this revision. krasimir added a comment. Sorry for the delay. I'll submit this for you. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60661/new/ https://reviews.llvm.org/D60661 ___ cfe-commits

[PATCH] D53866: [Preamble] Stop circular inclusion of main file when building preamble

2019-05-10 Thread Nikolai Kosjar via Phabricator via cfe-commits
nik updated this revision to Diff 198997. nik marked an inline comment as done and an inline comment as not done. nik added a comment. Renamed to err_pp_including_mainfile_in_preamble. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D53866/new/

r360408 - Delete write-only HasQualifiers after rC360370

2019-05-10 Thread Fangrui Song via cfe-commits
Author: maskray Date: Thu May 9 23:59:50 2019 New Revision: 360408 URL: http://llvm.org/viewvc/llvm-project?rev=360408=rev Log: Delete write-only HasQualifiers after rC360370 Modified: cfe/trunk/lib/AST/ExprConstant.cpp Modified: cfe/trunk/lib/AST/ExprConstant.cpp URL:

[PATCH] D61485: Added an assert in `isConstantInitializer`: initializer lists must be in semantic form

2019-05-10 Thread Dmitri Gribenko via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL360406: Added an assert in `isConstantInitializer`: initializer lists must be in… (authored by gribozavr, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed

r360406 - Added an assert in `isConstantInitializer`: initializer lists must be in semantic form

2019-05-10 Thread Dmitri Gribenko via cfe-commits
Author: gribozavr Date: Thu May 9 23:39:20 2019 New Revision: 360406 URL: http://llvm.org/viewvc/llvm-project?rev=360406=rev Log: Added an assert in `isConstantInitializer`: initializer lists must be in semantic form Subscribers: cfe-commits Tags: #clang Differential Revision:

Re: [PATCH] D28462: clang-format: Add new style option AlignConsecutiveMacros

2019-05-10 Thread Manuel Klimek via cfe-commits
*From: *MyDeveloperDay via Phabricator *Date: *Fri, May 10, 2019 at 12:30 PM *To: * , , , < krasi...@google.com>, , *Cc: * , , , < marcosbe...@gmail.com>, , , < shua2...@gmail.com>, , , < vit9...@avp.su>, , , < mydeveloper...@gmail.com>, , < bderickson+llvm...@gmail.com>, , < vee...@veegee.org>,

[PATCH] D61438: [ASTImporter] Use llvm::Expected and Error in the importer API

2019-05-10 Thread Gabor Marton via Phabricator via cfe-commits
martong marked an inline comment as done. martong added inline comments. Comment at: clang/include/clang/AST/ASTImporter.h:203 /// context, or the import error. -llvm::Expected Import_New(TypeSourceInfo *FromTSI); -// FIXME: Remove this version. -TypeSourceInfo

[PATCH] D61634: [clang/llvm] Allow efficient implementation of libc's memory functions in C/C++

2019-05-10 Thread Guillaume Chatelet via Phabricator via cfe-commits
gchatelet added a comment. In D61634#1494518 , @alexandre.isoard wrote: > I'm not convinced by the approach. > > Can it still recognize the loop idiom into memcpy implementation but use > `memmove` (as only `memcpy` has been blacklisted)? Yes it can

r360419 - Fix Wdocumentation warning. NFCI.

2019-05-10 Thread Simon Pilgrim via cfe-commits
Author: rksimon Date: Fri May 10 03:36:37 2019 New Revision: 360419 URL: http://llvm.org/viewvc/llvm-project?rev=360419=rev Log: Fix Wdocumentation warning. NFCI. Modified: cfe/trunk/lib/CodeGen/CodeGenModule.h Modified: cfe/trunk/lib/CodeGen/CodeGenModule.h URL:

[PATCH] D61627: [clang driver] Allow -fembed-bitcode combined with -mno-red-zone

2019-05-10 Thread Anders Waldenborg via Phabricator via cfe-commits
wanders added a comment. > Why are you interested in expending this list? I have a (kernel) that is compiled with `-mno-red-zone` and `-mcmodel=large` which I want to compile with `-fembed-bitcode` for a debugging tool that needs the bitcode. But I can carry these patches locally for now.

[PATCH] D28462: clang-format: Add new style option AlignConsecutiveMacros

2019-05-10 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added a comment. When I spoke with one of the code owners, they seemed to have a problem accepting this review based on there not being a general description/understanding of how this algorithm works. Having said that, all of the "AlignToken" based functions

[PATCH] D60763: Prototype OpenCL BIFs using Tablegen

2019-05-10 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia added a comment. The overall structure looks very clear now! I just have a couple of nitpicks! Thank you! Comment at: clang/include/clang/Basic/OpenCLBuiltins.td:11 +// +// This file contains data structures representing OpenCL builtin functions +// prototypes. In

[PATCH] D61634: [clang/llvm] Allow efficient implementation of libc's memory functions in C/C++

2019-05-10 Thread Guillaume Chatelet via Phabricator via cfe-commits
gchatelet added a comment. In D61634#1493927 , @efriedma wrote: > I would be careful about trying to over-generalize here. There are a few > different related bits of functionality which seem to be interesting, given > the discussion in the llvm-dev

  1   2   >