summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* fix unnamed fiefield issue and add tests for __builtin_preserve_access_index ↵Yonghong Song2019-07-164-2/+212
| | | | | | | | | | | | | | | | | | | | | | | | intrinsic The original commit is r366076. It is temporarily reverted (r366155) due to test failure. This resubmit makes test more robust by accepting regex instead of hardcoded names/references in several places. This is a followup patch for https://reviews.llvm.org/D61809. Handle unnamed bitfield properly and add more test cases. Fixed the unnamed bitfield issue. The unnamed bitfield is ignored by debug info, so we need to ignore such a struct/union member when we try to get the member index in the debug info. D61809 contains two test cases but not enough as it does not checking generated IRs in the fine grain level, and also it does not have semantics checking tests. This patch added unit tests for both code gen and semantics checking for the new intrinsic. Signed-off-by: Yonghong Song <yhs@fb.com> llvm-svn: 366231
* AMDGPU: Fix missing immarg for mfma intrinsicsMatt Arsenault2019-07-162-20/+63
| | | | llvm-svn: 366230
* [OpenMP] Move header inclusion out of 'extern "C"'Jonas Hahnfeld2019-07-161-2/+3
| | | | | | | | | | This leads to problems when compiling C++ code with libc++ for Nvidia GPUs because Clang now uses wrappers for math functions that might include C++ templates not allowed in 'extern "C"'. Differentiel Revision: https://reviews.llvm.org/D64625 llvm-svn: 366229
* Removed -mno-omit-leaf-frame-pointer from flags.Mitch Phillips2019-07-162-6/+0
| | | | | | | Removes -mno-omit-leaf-frame-pointer from Scudo and GWP-ASan's CFlags. Attempt to fix the sanitizer buildbots. llvm-svn: 366228
* [CMake] Add Apple-lldb-Xcode.cmake cache that avoids install optionsStefan Granitz2019-07-161-0/+4
| | | | llvm-svn: 366226
* [TSan] Improve handling of stack pointer mangling in {set,long}jmp, pt.10Julian Lettner2019-07-162-64/+0
| | | | | | | Remove now-unused assembly code for determining xor key on Linux/AArch64. This is the final commit of this refactoring. llvm-svn: 366225
* [OPENMP][NVPTX]Fixed checks for cuda versions.Alexey Bataev2019-07-161-2/+4
| | | | | | | | | | | | | | | | | | | | | Summary: We used CUDART_VERSION macro to check for the installed cuda version but this macro is defined in cuda_runtime_api.h, which is not used by project. Better to use CUDA_VERSION macro, which is defined in cuda.h. Also, added the check if this macro is defined. If macro is undefined, there is something wrong with the cuda configuration and we should not continue the compilation. This also fixes problems with runtime building in cuda 10+. Reviewers: grokos Subscribers: guansong, jdoerfert, caomhin, kkwli0, openmp-commits Tags: #openmp Differential Revision: https://reviews.llvm.org/D64648 llvm-svn: 366224
* [AMDGPU] Add the adjusted FP as a livein register.Michael Liao2019-07-164-34/+91
| | | | | | | | | | | | Reviewers: arsenm, rampitec Subscribers: kzhuravl, jvesely, wdng, nhaehnle, yaxunl, dstuttard, tpr, t-tye, hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D64145 llvm-svn: 366223
* [Strict FP] Allow more relaxed schedulingUlrich Weigand2019-07-163-97/+186
| | | | | | | | | | | | | | Reimplement scheduling constraints for strict FP instructions in ScheduleDAGInstrs::buildSchedGraph to allow for more relaxed scheduling. Specifially, allow one strict FP instruction to be scheduled across another, as long as it is not moved across any global barrier. Differential Revision: https://reviews.llvm.org/D64412 Reviewed By: cameron.mcinally llvm-svn: 366222
* Revert "[swig] Add workaround for old swig"Jonas Devlieghere2019-07-161-5/+0
| | | | | | | With the deprecation of swig 1.x (r366213), this workaround should no longer be necessary. llvm-svn: 366221
* [OPENMP]Fix threadid in __kmpc_omp_taskwait call for dependent target calls.Alexey Bataev2019-07-162-5/+67
| | | | | | | | | | | | | | | | | Summary: We used to call __kmpc_omp_taskwait function with global threadid set to 0. It may crash the application at the runtime if the thread executing target region is not a master thread. Reviewers: grokos, kkwli0 Subscribers: guansong, jdoerfert, caomhin, openmp-commits Tags: #openmp Differential Revision: https://reviews.llvm.org/D64571 llvm-svn: 366220
* Revert [tools] [llvm-nm] Default to reading from stdin not a.outAlex Brachet2019-07-163-43/+4
| | | | | | This reverts r365889 (git commit 60c81354b1d3fced1bd284d334f118d2d792ab4b) llvm-svn: 366219
* Add missing test for r366215Amara Emerson2019-07-161-0/+71
| | | | llvm-svn: 366218
* [Remarks] Simplify and refactor the RemarkParser interfaceFrancis Visoiu Mistrih2019-07-1615-493/+485
| | | | | | | | | | | | | | | | | | | | Before, everything was based on some kind of type erased parser implementation which container a lot of boilerplate code when multiple formats were to be supported. This simplifies it by: * the remark now owns its arguments * *always* returning an error from the implementation side * working around the way the YAML parser reports errors: catch them through callbacks and re-insert them in a proper llvm::Error * add a CParser wrapper that is used when implementing the C API to avoid cluttering the C++ API with useless state * LLVMRemarkParserGetNext now returns an object that needs to be released to avoid leaking resources * add a new API to dispose of a remark entry: LLVMRemarkEntryDispose llvm-svn: 366217
* [Remarks][NFC] Combine ParserFormat and SerializerFormatFrancis Visoiu Mistrih2019-07-1613-52/+100
| | | | | | It's useless to have both. llvm-svn: 366216
* [ADCE] Fix non-deterministic behaviour due to iterating over a pointer set.Amara Emerson2019-07-161-3/+8
| | | | | | | | Original patch by Yann Laigle-Chapuy Differential Revision: https://reviews.llvm.org/D64785 llvm-svn: 366215
* [DAGCombiner] fold (addcarry (xor a, -1), b, c) -> (subcarry b, a, !c) and ↵Amaury Sechet2019-07-163-38/+41
| | | | | | | | | | | | | | | | | | | flip carry. Summary: As per title. DAGCombiner only mathes the special case where b = 0, this patches extends the pattern to match any value of b. Depends on D57302 Reviewers: hfinkel, RKSimon, craig.topper Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D59208 llvm-svn: 366214
* [SWIG] Deprecate SWIG 1.xJonas Devlieghere2019-07-161-0/+5
| | | | | | | | | | | | | | The last swig 1.x release dates from 2009, now 10 years ago. Recently, I fixed an issue that prevented us from using swig 4 (r364974), which turned out to be not backward compatible with swig 1.x (r365718). This patch deprecates this (really old) version of swig and makes swig 2 the minimum supported version in LLDB . This should be fine for the build bots, which are all running swig 3 or later. Differential revision: https://reviews.llvm.org/D64782 llvm-svn: 366213
* [OpenCL] Fixing sampler initialisations for C++ mode.Neil Hickey2019-07-163-12/+17
| | | | | | | | Allow conversions between integer and sampler type. Differential Revision: https://reviews.llvm.org/D64791 llvm-svn: 366212
* [OPENMP]Add support for analysis of if clauses.Alexey Bataev2019-07-1628-241/+497
| | | | | | | | | | | | | | | | Summary: Added support for analysis of if clauses in the OpenMP directives to be able to check for the use of uninitialized variables. Reviewers: NoQ Subscribers: guansong, jfb, jdoerfert, caomhin, kkwli0, cfe-commits Tags: clang Differential Revision: https://reviews.llvm.org/D64646 llvm-svn: 366211
* AMDGPU/GlobalISel: Fix test failures in release buildMatt Arsenault2019-07-1615-466/+406
| | | | | | | | | | | | Apparently the check for legal instructions during instruction select does not happen without an asserts build, so these would successfully select in release, and fail in debug. Make s16 and/or/xor legal. These can just be selected directly to the 32-bit operation, as is already done in SelectionDAG, so just make them legal. llvm-svn: 366210
* [llvm-ar][test] Add to llvm-ar test coverageOwen Reynolds2019-07-163-0/+252
| | | | | | | | | This change adds tests to cover existing llvm-ar functionality. print.test is omitted due to failing on Darwin. Differential Revision: https://reviews.llvm.org/D64330 llvm-svn: 366209
* [pstl] Fix compilation with TBB backendLouis Dionne2019-07-161-8/+8
| | | | | | Some types were not using the right namespace qualification. llvm-svn: 366208
* [clangd] Added highlighting for the targets in typedefs and using.Johan Vikstrom2019-07-162-4/+27
| | | | | | | | | | | | | | | | | | Summary: In `typedef int A` the `A` was not highlighted previously. This patch gives `A` the same kind of highlighting that the underlying type has (class/enum) (which in this example is no special highlighting because builtins are not handled yet) Will add highlightings for built ins in another patch. Reviewers: hokein, sammccall, ilya-biryukov Subscribers: MaskRay, jkorous, arphaman, kadircet, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D64754 llvm-svn: 366207
* Reapply [llvm-ar][test] Increase llvm-ar test coverageOwen Reynolds2019-07-169-18/+413
| | | | | | | | This reapplies 365316 without extract.test due to failing on Darwin. Differential Revision: https://reviews.llvm.org/D63935 llvm-svn: 366206
* remove a duplicate declarationSylvestre Ledru2019-07-161-3/+0
| | | | llvm-svn: 366205
* Document the LLVM_ENABLE_BINDINGS optionSylvestre Ledru2019-07-161-0/+6
| | | | llvm-svn: 366204
* [Object/llvm-readelf/llvm-readobj] - Improve error reporting when e_shstrndx ↵George Rimar2019-07-166-12/+65
| | | | | | | | | | | | | | | | | | is broken. When e_shstrndx is broken, it is impossible to get a section name. In this patch I improved the error message we show and added tests for Object and for llvm-readelf/llvm-readobj Message was changed in two places: 1) llvm-readelf/llvm-readobj previously used a code from Object/ELF.h, now they have a modified version of it (it has less checks and allows dumping broken things). 2) Code in Object/ELF.h is still used for generic cases. Differential revision: https://reviews.llvm.org/D64714 llvm-svn: 366203
* [Driver] Don't pass --dynamic-linker to ld on SolarisRainer Orth2019-07-166-8/+0
| | | | | | | | | | | | | | | | | I noticed that clang currently passes --dynamic-linker to ld. This has been the case since Solaris 11 support was added initially back in 2012 by David Chisnall (r150580). I couldn't find any patch submission, let alone a justification, for this, and it seems completely useless: --dynamic-linker is a gld compatibility form of the option, the native option being -I. First of all, however, the dynamic linker passed is simply the default, so there's no reason at all to specify it in the first place. This patch removes passing the option and adjusts the affected testcase accordingly. Tested on x86_64-pc-solaris2.11 and sparcv9-sun-solaris2.11. Differential Revision: https://reviews.llvm.org/D64493 llvm-svn: 366202
* Reapply [llvm-ar][test] Add to MRI test coverageOwen Reynolds2019-07-164-0/+139
| | | | | | | | This reapplies 363232 without mri-utf8.test due to failing on Darwin. Differential Revision: https://reviews.llvm.org/D63197 llvm-svn: 366201
* [SemaTemplate] Fix uncorrected typos after pack expansionSam McCall2019-07-162-0/+3
| | | | | | | | | | | | | | | | Summary: This case is particularly important for clangd, as it is triggered after inserting the snippet for variadic functions. Reviewers: kadircet, ilya-biryukov Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D64677 llvm-svn: 366200
* [clangd] Don't rebuild background index until we indexed one TU per thread.Sam McCall2019-07-163-12/+14
| | | | | | | | | | | | | | | | | Summary: This increases the odds that the boosted file (cpp file matching header) will be ready. (It always enqueues first, so it'll be present unless another thread indexes *two* files before the first thread indexes one.) Reviewers: kadircet Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D64682 llvm-svn: 366199
* Remove username from git-llvm script, erroneously added in 366197Sam McCall2019-07-161-1/+1
| | | | llvm-svn: 366198
* [AArch64] Implement __jcvt intrinsic from Armv8.3-AKyrylo Tkachov2019-07-1611-2/+94
| | | | | | | | | | | | | | | | The jcvt intrinsic defined in ACLE [1] is available when ARM_FEATURE_JCVT is defined. This change introduces the AArch64 intrinsic, wires it up to the instruction and a new clang builtin function. The __ARM_FEATURE_JCVT macro is now defined when an Armv8.3-A or higher target is used. I've implemented the target detection logic in Clang so that this feature is enabled for architectures from armv8.3-a onwards (so -march=armv8.4-a also enables this, for example). make check-all didn't show any new failures. [1] https://developer.arm.com/docs/101028/latest/data-processing-intrinsics Differential Revision: https://reviews.llvm.org/D64495 llvm-svn: 366197
* [lldb] Rename Options.inc to CommandOptions.inc [NFC]Raphael Isemann2019-07-165-7/+7
| | | | | | | | It seems having two Options.inc files in the same project is giving our custom Xcode project a hard time. This patch renames the new Options.inc to CommandOptions.inc to prevent this conflict. llvm-svn: 366196
* [NFC] Test commit: add full stop at end of commentKyrylo Tkachov2019-07-161-1/+1
| | | | llvm-svn: 366195
* [clang-scan-view] Force utf-8 when handling report (python2 only)Serge Guelton2019-07-161-2/+2
| | | | | | | | Original patch by random human <random.bored.human@gmail.com> Differential Revision: https://reviews.llvm.org/D64129 llvm-svn: 366194
* [COFF] Rename variale references in comments after VariableName -> ↵Fangrui Song2019-07-1611-24/+24
| | | | | | variableName change llvm-svn: 366193
* [WebAssembly] Rename variale references in comments after VariableName -> ↵Fangrui Song2019-07-165-7/+7
| | | | | | variableName change llvm-svn: 366192
* [NFC][PowerPC] Add test case for D64195Zi Xuan Wu2019-07-161-0/+106
| | | | llvm-svn: 366191
* [DWARF] Fix the reserved values for unit length in DWARFDebugLine.Igor Kudrin2019-07-162-8/+8
| | | | | | | | | The DWARF3 documentation had inconsistency concerning the reserved range for unit length values. The issue was fixed in DWARF4. Differential Revision: https://reviews.llvm.org/D64622 llvm-svn: 366190
* [DWARF] Fix an incorrect format specifier.Igor Kudrin2019-07-161-1/+1
| | | | | | | | This adjusts the format specifier because PCOffset is uint16_t. Differential Revision: https://reviews.llvm.org/D64620 llvm-svn: 366189
* [DWARF] Simplify DWARFAttribute. NFC.Igor Kudrin2019-07-162-13/+3
| | | | | | | | | The first argument in the constructor was ignored, and the remaining arguments were always passed as their defaults. Differential Revision: https://reviews.llvm.org/D64407 llvm-svn: 366188
* [lldb] Handle EOF from `lldb-vscode`Jan Kratochvil2019-07-161-0/+5
| | | | | | | | | | | | | | | | | | | | | | | Sometimes (when running lldb-vscode under strace) I get: read(0, "", 16) = 0 read(0, "", 16) = 0 read(0, "", 16) = 0 ... With this patch testcases finish properly even with strace: read(0, "", 16) = 0 futex(0x1346508, FUTEX_WAKE_PRIVATE, 2147483647) = 0 stat("", 0x7ffe8f2634c8) = -1 ENOENT (No such file or directory) --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_KILLED, si_pid=9124, si_uid=1001, si_status=SIGINT, si_utime=1, si_stime=0} --- close(4) = 0 exit_group(0) = ? +++ exited with 0 +++ Differential Revision: https://reviews.llvm.org/D64698 llvm-svn: 366187
* Finish "Adapt -fsanitize=function to SANITIZER_NON_UNIQUE_TYPEINFO"Stephan Bergmann2019-07-1610-26/+113
| | | | | | | | | | | | | | | | | | | | | i.e., recent 5745eccef54ddd3caca278d1d292a88b2281528b: * Bump the function_type_mismatch handler version, as its signature has changed. * The function_type_mismatch handler can return successfully now, so SanitizerKind::Function must be AlwaysRecoverable (like for SanitizerKind::Vptr). * But the minimal runtime would still unconditionally treat a call to the function_type_mismatch handler as failure, so disallow -fsanitize=function in combination with -fsanitize-minimal-runtime (like it was already done for -fsanitize=vptr). * Add tests. Differential Revision: https://reviews.llvm.org/D61479 llvm-svn: 366186
* [NFC][test] Fix for riscv tests.Puyan Lotfi2019-07-164-16/+16
| | | | | | Following tests need updating for: https://reviews.llvm.org/D55277 llvm-svn: 366183
* [X86] In combineStore, don't convert v2f32 load/store pairs to f64 loads/stores.Craig Topper2019-07-161-3/+2
| | | | | | | Type legalization can take care of this. This gives DAG combine a little more time with the original types. llvm-svn: 366182
* [ELF] Fix variable names in comments after VariableName -> variableName changeFangrui Song2019-07-1625-106/+104
| | | | | | Also fix some typos. llvm-svn: 366181
* [RISCV] Match GNU tools canonical JALR and add aliasesAlex Bradbury2019-07-169-36/+60
| | | | | | | | | | | | The canonical GNU form of JALR resembles a load/store instruction rather than placing the immediate offset as a separate argument, so match this behaviour. Also add parser-only aliases for the three-operand form, and add other shorter aliases also emitted by GNU tools. Differential Revision: https://reviews.llvm.org/D55277 Patch by James Clarke. llvm-svn: 366179
* Fix parameter name comments using clang-tidy. NFC.Rui Ueyama2019-07-16140-372/+372
| | | | | | | | | | | | | | | | | | | | | This patch applies clang-tidy's bugprone-argument-comment tool to LLVM, clang and lld source trees. Here is how I created this patch: $ git clone https://github.com/llvm/llvm-project.git $ cd llvm-project $ mkdir build $ cd build $ cmake -GNinja -DCMAKE_BUILD_TYPE=Debug \ -DLLVM_ENABLE_PROJECTS='clang;lld;clang-tools-extra' \ -DCMAKE_EXPORT_COMPILE_COMMANDS=On -DLLVM_ENABLE_LLD=On \ -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ ../llvm $ ninja $ parallel clang-tidy -checks='-*,bugprone-argument-comment' \ -config='{CheckOptions: [{key: StrictMode, value: 1}]}' -fix \ ::: ../llvm/lib/**/*.{cpp,h} ../clang/lib/**/*.{cpp,h} ../lld/**/*.{cpp,h} llvm-svn: 366177
OpenPOWER on IntegriCloud