summaryrefslogtreecommitdiffstats
path: root/clang
Commit message (Collapse)AuthorAgeFilesLines
...
* [OPENMP] Fix -Wunused-lambda-capture. NFCFangrui Song2018-04-181-0/+1
| | | | llvm-svn: 330284
* [CUDA] added missing __ldg(const signed char *)Artem Belevich2018-04-181-0/+3
| | | | | | Differential Revision: https://reviews.llvm.org/D45780 llvm-svn: 330280
* [HIP] Add driver input type for HIPYaxun Liu2018-04-183-6/+22
| | | | | | | | | Patch by Greg Rodgers. Revised by Yaxun Liu. Differential Revision: https://reviews.llvm.org/D45489 llvm-svn: 330279
* [MinGW] Try to fix asan testing after r330244Martin Storsjo2018-04-181-6/+5
| | | | | | Twines shouldn't be stored as they can refer to temporaries. llvm-svn: 330277
* [NVPTX] Emit debug info in DWARF-2 by default for Cuda devices.Alexey Bataev2018-04-185-4/+134
| | | | | | | | | | | | | | Summary: NVPTX target supports debug info in DWARF-2 format. Patch adds emission of debug info in DWARF-2 by default. Reviewers: tra, jlebar Subscribers: aprantl, JDevlieghere, cfe-commits Differential Revision: https://reviews.llvm.org/D42581 llvm-svn: 330272
* [OPENMP] Code cleanup and code improvements.Alexey Bataev2018-04-187-1085/+1071
| | | | llvm-svn: 330270
* [Sema] Disable built-in increment operator for bool in overload resolution ↵Jan Korous2018-04-182-5/+21
| | | | | | | | | | | | | | | | | in C++17 Following: https://llvm.org/svn/llvm-project/cfe/trunk@329804 For C++17 the wording of [over.built] p4 excluded bool: For every pair (T , vq), where T is an arithmetic type other than bool, there exist candidate operator functions of the form vq T & operator++(vq T &); T operator++(vq T &, int); Differential Revision: https://reviews.llvm.org/D45569 llvm-svn: 330254
* Revert r330195 "[NEON] Define vget_high_f16() and vget_low_f16() intrinsics ↵Ivan A. Kosarev2018-04-182-8/+16
| | | | | | | | in AArch64 mode only". Differential Revision: https://reviews.llvm.org/D45668 llvm-svn: 330248
* [MinGW] Look for a cross sysroot relative to the clang binaryMartin Storsjo2018-04-182-1/+25
| | | | | | | | | If found, prefer this over looking for a similar gcc later in the system path. Differential Revision: https://reviews.llvm.org/D45504 llvm-svn: 330244
* [Modules] Turn on system header validation for implicit modulesBruno Cardoso Lopes2018-04-183-1/+15
| | | | | | | | | | After r300027 implicit builds might fail when updating the SDK on darwin. Make validation of system headers default when implicit modules is on and allow modules to be rebuild when system headers change. rdar://problem/19767523 llvm-svn: 330240
* [AAch64] Add the __ARM_FEATURE_DOTPROD macro definitionJunmo Park2018-04-173-0/+11
| | | | | | | | | This matches what GCC does. https://github.com/gcc-mirror/gcc/blob/master/gcc/config/aarch64/aarch64-c.c Differential Revision: https://reviews.llvm.org/D45544 llvm-svn: 330229
* Add Microsoft mangling for _Float16Erich Keane2018-04-172-0/+7
| | | | | | | | | | | | Enables _Float16 on Windows by creating a mangling mechanism in MicrosoftMangle. It accomplishes this by mangling as a structure type of __clang::_Float16, similar to how Complex works. Patch By: mibintc Differential Revision: https://reviews.llvm.org/D45738 llvm-svn: 330225
* [XRay] Add clang builtin for xray typed events.Keith Wyss2018-04-1715-11/+153
| | | | | | | | | | | | | | | | | | | Summary: A clang builtin for xray typed events. Differs from __xray_customevent(...) by the presence of a type tag that is vended by compiler-rt in typical usage. This allows xray handlers to expand logged events with their type description and plugins to process traced events based on type. This change depends on D45633 for the intrinsic definition. Reviewers: dberris, pelikan, rnk, eizan Subscribers: cfe-commits, llvm-commits Differential Revision: https://reviews.llvm.org/D45716 llvm-svn: 330220
* [Driver] Use the per-API level Android library directories.Dan Albert2018-04-1799-90/+56
| | | | | | | | | | | | | | | | Summary: Android sysroots contain libraries for each OS version, as well as a handful of unversioned libraries in the typical multiarch directory. Reviewers: srhines, eugenis, george.burgess.iv Reviewed By: eugenis Subscribers: javed.absar, cfe-commits Differential Revision: https://reviews.llvm.org/D45290 llvm-svn: 330213
* Require shell for testTeresa Johnson2018-04-171-1/+2
| | | | | | | | Attempt to fix windows bot which doesn't like the "(cd .." invocation added in r330194: http://lab.llvm.org:8011/builders/clang-with-thin-lto-windows/builds/8704/steps/stage%202%20check/logs/stdio llvm-svn: 330212
* Remove unused variableTeresa Johnson2018-04-171-1/+1
| | | | | | Fixes unused variable error introduced in r330194. llvm-svn: 330210
* [Sema] Warn about memcpy'ing non-trivial C structs.Akira Hatanaka2018-04-173-1/+156
| | | | | | | | | | | Issue a warning when non-trivial C structs are copied or initialized by calls to memset, bzero, memcpy, or memmove. rdar://problem/36124208 Differential Revision: https://reviews.llvm.org/D45310 llvm-svn: 330202
* Move the visitor classes that are used to traverse non-trivial C structsAkira Hatanaka2018-04-172-118/+202
| | | | | | | | | | | | | | to a header file. This is in preparation for using the visitor classes to warn about memcpy'ing non-trivial C structs. See the discussion here: https://reviews.llvm.org/D45310 rdar://problem/36124208 llvm-svn: 330201
* Add a command line option 'fregister_global_dtors_with_atexit' toAkira Hatanaka2018-04-1713-9/+150
| | | | | | | | | | | | | | | | | | | | | register destructor functions annotated with __attribute__((destructor)) using __cxa_atexit or atexit. Register destructor functions annotated with __attribute__((destructor)) calling __cxa_atexit in a synthesized constructor function instead of emitting references to the functions in a special section. The primary reason for adding this option is that we are planning to deprecate the __mod_term_funcs section on Darwin in the future. This feature is enabled by default only on Darwin. Users who do not want this can use command line option 'fno_register_global_dtors_with_atexit' to disable it. rdar://problem/33887655 Differential Revision: https://reviews.llvm.org/D45578 llvm-svn: 330199
* [NEON] Define vget_high_f16() and vget_low_f16() intrinsics in AArch64 mode onlyIvan A. Kosarev2018-04-172-16/+8
| | | | | | Differential Revision: https://reviews.llvm.org/D45668 llvm-svn: 330195
* [ThinLTO] Pass -save-temps to LTO backend for distributed ThinLTO buildsTeresa Johnson2018-04-178-7/+61
| | | | | | | | | | | | | | | | | | | | | | | Summary: The clang driver option -save-temps was not passed to the LTO config, so when invoking the ThinLTO backends via clang during distributed builds there was no way to get LTO to save temp files. Getting this to work with ThinLTO distributed builds also required changing the driver to avoid a separate compile step to emit unoptimized bitcode when the input was already bitcode under -save-temps. Not only is this unnecessary in general, it is problematic for ThinLTO backends since the temporary bitcode file to the backend would not match the module path in the combined index, leading to incorrect ThinLTO backend index-based optimizations. Reviewers: pcc Subscribers: mehdi_amini, inglorion, eraman, cfe-commits Differential Revision: https://reviews.llvm.org/D45217 llvm-svn: 330194
* Add modifiers for unsigned char and signed char field printing for ↵Aaron Ballman2018-04-172-0/+51
| | | | | | | | __builtin_dump_struct. Patch by Paul Semel. llvm-svn: 330188
* [NEON] Fix the architecture condition for the crypto intrinsicsIvan A. Kosarev2018-04-171-1/+1
| | | | | | Differential Revision: https://reviews.llvm.org/D45669 llvm-svn: 330187
* Add checks for format specifiers used by __builtin_dump_struct and added a ↵Aaron Ballman2018-04-172-62/+154
| | | | | | | | new specifier for null-terminated constant strings. Patch by Paul Semel. llvm-svn: 330185
* Add some infuriatingly necessary comments to this test case.Chandler Carruth2018-04-174-0/+12
| | | | | | | | | | | | | | | | | | | | | | Without these comments, by "luck" the contents of SomeKit's SKWidget.h are precisely the same as SomeKitCore's SomeKitCore.h. This can create havoc if anything canonicalizes on the inode and your filesystem assigns a common inode to files with identical file content. Alternatively, if your build system uses symlinks into a content-addressed-storage (as Google's does), you end up with these files being symlinks to the same file. The end result is that Clang deduplicates them internally, and then believes that the SomeKit framework includes the SomeKitCore.h header, and does not include the SKWidget.h in SomeKit. This in turn results in warnings in this test and eventually errors as Clang becomes confused because the umbrella header for SomeKitCore has already been included into another framework's module (SomeKit). Yay. If anyone has a better idea about how to avoid this, I'm all ears. Nothing other than causing the file content to change worked for me. llvm-svn: 330184
* Fix malformed table introduced by r330174Duncan P. N. Exon Smith2018-04-171-2/+2
| | | | | | http://lab.llvm.org:8011/builders/clang-sphinx-docs/builds/23573 llvm-svn: 330177
* Remove GC-related warning terminologyDuncan P. N. Exon Smith2018-04-174-4/+4
| | | | | | | | ObjC-GC isn't used any more; clean up this warning text. rdar://problem/39049693 llvm-svn: 330174
* [ARM] Compute a target feature which corresponds to the ARM version.Eli Friedman2018-04-165-22/+78
| | | | | | | | | | | | | | | | Currently, the interaction between the triple, the CPU, and the supported features is a mess: the driver edits the triple to indicate the supported architecture version, and the LLVM backend uses this to figure out what instructions are legal. This makes it difficult to understand what's happening, and makes it impossible to LTO together two modules with different computed architectures. Instead of relying on triple rewriting to get the correct target features, we should add the right target features explicitly. Differential Revision: https://reviews.llvm.org/D45240 llvm-svn: 330169
* [Availability] Improve availability to consider functions run at load timeSteven Wu2018-04-165-1/+79
| | | | | | | | | | | | | | | | | | | | | | Summary: There are some functions/methods that run when the application launches or the library loads. Those functions will run reguardless the OS version as long as it satifies the minimum deployment target. Annotate them with availability attributes doesn't really make sense because they are essentially available on all targets since minimum deployment target. rdar://problem/36093384 Reviewers: arphaman, erik.pilkington Reviewed By: erik.pilkington Subscribers: erik.pilkington, cfe-commits Differential Revision: https://reviews.llvm.org/D45699 llvm-svn: 330166
* Limit types of builtins that can be redeclared.Erich Keane2018-04-168-0/+60
| | | | | | | | | | | | | | | | | | As reported here: https://bugs.llvm.org/show_bug.cgi?id=37033 Any usage of a builtin function that uses a va_list by reference will cause an assertion when redeclaring it. After discussion in the review, it was concluded that the correct way of accomplishing this fix is to make attempts to redeclare certain builtins an error. Unfortunately, doing this limitation for all builtins is likely a breaking change, so this commit simply limits it to types with custom type checking and those that take a reference. Two tests needed to be updated to make this work. Differential Revision: https://reviews.llvm.org/D45383 llvm-svn: 330160
* Defer adding keywords to the identifier table until after the language ↵Aaron Ballman2018-04-164-14/+91
| | | | | | | | | | options have been loaded from the AST file. This fixes issues with "class" being reported as an identifier in "enum class" because the construct is not present when using default language options. Patch by Johann Klähn. llvm-svn: 330159
* [OPENMP] Allow to use declare target variables in map clausesAlexey Bataev2018-04-162-11/+8
| | | | | | | | Global variables marked as declare target are allowed to be used in map clauses. Patch fixes the crash of the compiler on the declare target variables in map clauses. llvm-svn: 330156
* [CodeGen] Fix a crash that occurs when a non-trivial C struct with aAkira Hatanaka2018-04-162-15/+45
| | | | | | | | | | | | | | volatile array field is copied. The crash occurs because method 'visitArray' passes a null FieldDecl to method 'visit' and some of the methods called downstream expect a non-null FieldDecl to be passed. This reapplies r330151 with a fix to the test case. rdar://problem/33599681 llvm-svn: 330155
* [OPENMP] General code improvements.Alexey Bataev2018-04-163-136/+140
| | | | llvm-svn: 330154
* Revert "[CodeGen] Fix a crash that occurs when a non-trivial C struct with a"Akira Hatanaka2018-04-162-43/+15
| | | | | | This reverts commit r330151, which caused bots to fail. llvm-svn: 330153
* Use export_as for autolinking frameworksBruno Cardoso Lopes2018-04-1617-0/+128
| | | | | | | | | | | | | | | | framework module SomeKitCore { ... export_as SomeKit } Given the module above, while generting autolink information during codegen, clang should to emit '-framework SomeKitCore' only if SomeKit was not imported in the relevant TU, otherwise it should use '-framework SomeKit' instead. rdar://problem/38269782 llvm-svn: 330152
* [CodeGen] Fix a crash that occurs when a non-trivial C struct with aAkira Hatanaka2018-04-162-15/+43
| | | | | | | | | | | | volatile array field is copied. The crash occurs because method 'visitArray' passes a null FieldDecl to method 'visit' and some of the methods called downstream expect a non-null FieldDecl to be passed. rdar://problem/33599681 llvm-svn: 330151
* [Hexagon] Emit a warning when -fvectorize is given without -mhvxKrzysztof Parzyszek2018-04-164-7/+20
| | | | llvm-svn: 330150
* [OPENMP] General code improvements.Alexey Bataev2018-04-1655-1252/+1395
| | | | llvm-svn: 330140
* [CodeView] Initial support for emitting S_THUNK32 symbols for compiler...Brock Wyma2018-04-164-30/+285
| | | | | | | | | | | When emitting CodeView debug information, compiler-generated thunk routines should be emitted using S_THUNK32 symbols instead of S_GPROC32_ID symbols so Visual Studio can properly step into the user code. This initial support only handles standard thunk ordinals. Differential Revision: https://reviews.llvm.org/D43838 llvm-svn: 330132
* [mips] Prevent PIC to be set to level 2Aleksandar Beserminji2018-04-162-8/+13
| | | | | | | | | | MIPS does not use PIC level 2 for historical reasons, even with -fPIC/-mxgot/multigot options. This patch prevents PIC to be set to level 2 for MIPS. Differential Revision: https://reviews.llvm.org/D44381 llvm-svn: 330118
* Clean carriage returns from lib/ and include/. NFC.Malcolm Parsons2018-04-168-445/+445
| | | | | | | | | | | | | | | | | | | | | | | | Summary: Clean carriage returns from lib/ and include/. NFC. (I have to make this change locally in order for `git diff` to show sane output after I edit a file, so I might as well ask for it to be committed. I don't have commit privs myself.) (Without this patch, `git rebase`ing any change involving SemaDeclCXX.cpp is a real nightmare. :( So while I have no right to ask for this to be committed, geez would it make my workflow easier if it were.) Here's the command I used to reformat things. (Requires bash and OSX/FreeBSD sed.) git grep -l $'\r' lib include | xargs sed -i -e $'s/\r//' find lib include -name '*-e' -delete Reviewers: malcolm.parsons Reviewed By: malcolm.parsons Subscribers: emaste, krytarowski, cfe-commits Differential Revision: https://reviews.llvm.org/D45591 Patch by Arthur O'Dwyer. llvm-svn: 330112
* [X86] Introduce archs: goldmont-plus & tremontGabor Buella2018-04-165-2/+168
| | | | | | | | | | | | Reviewers: craig.topper Reviewed By: craig.topper Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D45613 llvm-svn: 330110
* [analyzer] Do not invalidate the `this` pointer.Henry Wong2018-04-153-0/+103
| | | | | | | | | | | | | | | | | Summary: `this` pointer is not an l-value, although we have modeled `CXXThisRegion` for `this` pointer, we can only bind it once, which is when we start to inline method. And this patch fixes https://bugs.llvm.org/show_bug.cgi?id=35506. In addition, I didn't find any other cases other than loop-widen that could invalidate `this` pointer. Reviewers: NoQ, george.karpenkov, a.sidorin, seaneveson, szepet Reviewed By: NoQ Subscribers: xazax.hun, rnkovacs, cfe-commits, MTC Differential Revision: https://reviews.llvm.org/D45491 llvm-svn: 330095
* Revert "[Serialization] Fix some Clang-tidy modernize and Include What You ↵Vedant Kumar2018-04-141-265/+317
| | | | | | | | | | | | | Use warnings; other minor fixes (NFC)." This reverts commit r330068. It breaks the lldb bots due to assertion failures (more details on cfe-commits). http://lab.llvm.org:8080/green/view/LLDB/job/lldb-cmake/ http://lab.llvm.org:8080/green/view/LLDB/job/lldb-cmake/6341/ stderr: Assertion failed: (M && "imported decl from no module file"), function loadPendingDeclChain, file /Users/vsk/src/llvm.org-lldbsan/llvm/tools/clang/lib/Serialization/ASTReaderDecl.cpp, line 3861. llvm-svn: 330080
* [Driver] Export profiling symbols for -exported_symbols_listVedant Kumar2018-04-132-0/+4
| | | | | | | | | When profiling is enabled and -exported_symbols_list is specified for the Darwin linker, export the requisite set of profiling symbols. rdar://39427167 llvm-svn: 330077
* [ODRHash] Support pointer and reference types.Richard Trieu2018-04-132-0/+139
| | | | | | | Recommit r328404 which was reverted in rL328404. r329869 fixed the issue that caused the revert. llvm-svn: 330074
* [Serialization] Fix some Clang-tidy modernize and Include What You Use ↵Eugene Zelenko2018-04-131-317/+265
| | | | | | warnings; other minor fixes (NFC). llvm-svn: 330068
* Use InitLLVM in clang as well.Rui Ueyama2018-04-132-26/+7
| | | | | | Differential Revision: https://reviews.llvm.org/D45634 llvm-svn: 330067
* [Analyzer] Fix for SValBuilder expressions rearrangementAdam Balogh2018-04-132-0/+7
| | | | | | | | Expression rearrangement in SValBuilder (see rL329780) crashes with an assert if the type of the integer is different from the type of the symbol. This fix adds a check that prevents rearrangement in such cases. Differential Revision: https://reviews.llvm.org/D45557 llvm-svn: 330064
OpenPOWER on IntegriCloud