summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* [AsmParser] Fix preserve-comments-crlf.s on FreeBSDFangrui Song2018-07-261-1/+1
| | | | | | | | --strip-trailing-cr is a diffutils option which is also available on BSD-licensed diff introduced in FreeBSD 11.2, however, it has a bug comparing files mixing \r and \r\n. Use -b (POSIX) instead. llvm-svn: 338008
* [X86] Don't use CombineTo to skip adding new nodes to the DAGCombiner ↵Craig Topper2018-07-262-14/+10
| | | | | | | | | | | | worklist in combineMul. I'm not sure if this was trying to avoid optimizing the new nodes further or what. Or maybe to prevent a cycle if something tried to reform the multiply? But I don't think its a reliable way to do that. If the user of the expanded multiply is visited by the DAGCombiner after this conversion happens, the DAGCombiner will check its operands, see that they haven't been visited by the DAGCombiner before and it will then add the first node to the worklist. This process will repeat until all the new nodes are visited. So this seems like an unreliable prevention at best. So this patch just returns the new nodes like any other combine. If this starts causing problems we can try to add target specific nodes or something to more directly prevent optimizations. Now that we handle the combine normally, we can combine any negates the mul expansion creates into their users since those will be visited now. llvm-svn: 338007
* [CMake] Don't generate linker script only when shared library isn't ↵Petr Hosek2018-07-261-2/+2
| | | | | | | | | | | | | statically linked Since r337668, we support statically linking dependencies only to shared or static library. However, that change hasn't updated the check whether to generate a linker script. We shouldn't generate linker script only in the case when we aren't statically linked ABI into the shared library. Differential Revision: https://reviews.llvm.org/D49834 llvm-svn: 338006
* Copy LLVM CMake configuration for CMake Policy CMP0068Eric Fiselier2018-07-261-0/+4
| | | | llvm-svn: 338005
* [sanitizer] Include signal.h instead of sys/signal.hFangrui Song2018-07-261-5/+1
| | | | llvm-svn: 338004
* [Docs] Update of Xray pageDavid Carlier2018-07-261-2/+3
| | | | | | | | | | | | Update of supported oses. Reviewers: dberris Reviewed By: dberris Differential Revision: https://reviews.llvm.org/D49789 llvm-svn: 338003
* Be more consistent about which bool value means an error occurredEric Fiselier2018-07-261-6/+6
| | | | llvm-svn: 338002
* Cleanup the last_write_time internalsEric Fiselier2018-07-262-17/+26
| | | | llvm-svn: 338001
* Correct comment about stat truncating st_mtimespec to secondsEric Fiselier2018-07-261-19/+6
| | | | llvm-svn: 338000
* Fix attribute placement WRT extern CEric Fiselier2018-07-261-2/+2
| | | | llvm-svn: 337999
* Workaround OS X 10.11 behavior where stat truncates st_mtimespec to seconds.Eric Fiselier2018-07-261-11/+38
| | | | llvm-svn: 337998
* Revert r337981: it breaks the debuginfo-testsAlex Lorenz2018-07-266-191/+51
| | | | | | | This commit caused a regression in the debuginfo-tests: FAIL: debuginfo-tests :: apple-accel.cpp (40748 of 46595) llvm-svn: 337997
* [X86] Remove some unnecessary explicit calls to DCI.AddToWorkList.Craig Topper2018-07-261-10/+0
| | | | | | These calls were making sure some newly created nodes were added to worklist, but the DAGCombiner has internal support for ensuring it has visited all nodes. Any time it visits a node it ensures the operands have been queued to be visited as well. This means if we only need to return the last new node. The DAGCombiner will take care of adding its inputs thus walking backwards through all the new nodes. llvm-svn: 337996
* [Support] Introduce createStringError helper functionVictor Leschuk2018-07-263-0/+40
| | | | | | | | | | | The function in question is copy-pasted lots of times in DWARF-related classes. Thus it will make sense to place its implementation into the Support library. Reviewed by: lhames Differential Revision: https://reviews.llvm.org/D49824 llvm-svn: 337995
* [GlobalISel] Fall back to SDISel for swifterror/swiftself attributes.Amara Emerson2018-07-263-0/+41
| | | | | | We don't currently support these, fall back until we do. llvm-svn: 337994
* [DWARF v5] Don't report an error when the .debug_rnglists section is empty ↵Wolfgang Pieb2018-07-262-17/+24
| | | | | | | | | | | or non-existent. Fixes PR38297. Reviewer: JDevlieghere Differential Revision: https://reviews.llvm.org/D49815 llvm-svn: 337993
* [LoadStoreVectorizer] Use const referenceFangrui Song2018-07-261-4/+6
| | | | llvm-svn: 337992
* Add print statements to help debuggingEric Fiselier2018-07-261-11/+21
| | | | llvm-svn: 337991
* [libc++] Add hack to allow ubsan to work w/o compiler-rt (__muloti4 is ↵Eric Fiselier2018-07-261-0/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | undefined) Summary: Using int128_t with UBSAN causes link errors unless compiler-rt is providing the runtime library. Specifically ubsan generates calls to __muloti4 but libgcc doesn't provide a definition. In order to avoid this, and allow users to continue using sanitized versions of libc++, this patch introduces a hack. It adds a cribbed version of the compiler-rt builtin to the libc++ filesystem sources. I don't think this approach will work in the long run, but it seems OK for now. Also see: https://bugs.llvm.org/show_bug.cgi?id=30643 https://bugs.llvm.org/show_bug.cgi?id=16404 Reviewers: mclow.lists, ldionne, rsmith, jyknight, echristo Reviewed By: echristo Subscribers: dberris, cfe-commits Differential Revision: https://reviews.llvm.org/D49828 llvm-svn: 337990
* RegUsageInfo: Cleanup; NFCMatthias Braun2018-07-266-86/+79
| | | | | | | | | - Remove unnecessary anchor function - Remove unnecessary override of getAnalysisUsage - Use reference instead of pointers where things cannot be nullptr - Use ArrayRef instead of std::vector where possible llvm-svn: 337989
* CodeGen.cpp: Sort initializers; NFCMatthias Braun2018-07-261-2/+2
| | | | llvm-svn: 337988
* InitializePasses: Sort declarations; NFCMatthias Braun2018-07-261-15/+15
| | | | llvm-svn: 337987
* CodeGen: Cleanup regmask construction; NFCMatthias Braun2018-07-267-18/+21
| | | | | | | | | - Avoid duplication of regmask size calculation. - Simplify allocateRegisterMask() call. - Rename allocateRegisterMask() to allocateRegMask() to be consistent with naming in MachineOperand. llvm-svn: 337986
* [MCA] Avoid an InstrDesc copy in mca::LSUnit::reserve.Dean Michael Berris2018-07-261-1/+1
| | | | | | | | | | | | | | | | | | Summary: InstrDesc contains 4 vectors (as well as some other data), so it's expensive to copy. Authored By: orodley Reviewers: andreadb, mattd, dberris Reviewed By: mattd, dberris Subscribers: dberris, gbedwell, llvm-commits Differential Revision: https://reviews.llvm.org/D49775 llvm-svn: 337985
* [libc++] Follow-up to r337968: use an explicit cast as suggested by EricAlex Lorenz2018-07-251-2/+4
| | | | llvm-svn: 337984
* [ELF] Fix linker-script-in-search-path.sFangrui Song2018-07-251-3/+3
| | | | llvm-svn: 337983
* [CMake] Don't use LIBCXXABI_ENABLE_STATIC option before its declaredSam Clegg2018-07-251-7/+7
| | | | | | | | | | | | | | | | | Summary: rL337867 introduced two new cmake_dependent_option options: - LIBCXXABI_INSTALL_STATIC_LIBRARY - LIBCXXABI_INSTALL_SHARED_LIBRARY They depend on LIBCXXABI_ENABLE_STATIC and LIBCXXABI_ENABLE_SHARED and so therefore need to (it seems) come after the declaration of these two options. Subscribers: mgorny, aheejin, christof, ldionne, cfe-commits Differential Revision: https://reviews.llvm.org/D49825 llvm-svn: 337982
* [DWARF v5] Don't emit multiple DW_AT_rnglists_base attributes. Some ↵Wolfgang Pieb2018-07-256-51/+191
| | | | | | | | | | | | refactoring of range lists emissions and added test cases. Reviewer: dblaikie Differential Revision: https://reviews.llvm.org/D49522 llvm-svn: 337981
* [dsymutil] Add support for generating DWARF5 accelerator tables.Jonas Devlieghere2018-07-258-23/+204
| | | | | | | | | | | | | | | | | | This patch add support for emitting DWARF5 accelerator tables (.debug_names) from dsymutil. Just as with the Apple style accelerator tables, it's possible to update existing dSYMs. This patch includes a test that show how you can convert back and forth between the two types. If no kind of table is specified, dsymutil will default to generating Apple-style accelerator tables whenever it finds those in its input. The same is true when there are no accelerator tables at all. Finally, in the remaining case, where there's at least one DWARF v5 table and no Apple ones, the output will contains a DWARF accelerator tables (.debug_names). Differential revision: https://reviews.llvm.org/D49137 llvm-svn: 337980
* [CMake] Don't install c++abi headers in standalone libc++ buildPetr Hosek2018-07-253-3/+2
| | | | | | | | | | | This is a refinement on r337833. Previously we were installing two copies of c++abi headers in libc++ build directory, one in include/c++build and another one in include/c++/v1. However, the second copy is unnecessary when building libc++ standalone. Differential Revision: https://reviews.llvm.org/D49752 llvm-svn: 337979
* [ODRHash] Support hashing enums.Richard Trieu2018-07-2510-4/+471
| | | | llvm-svn: 337978
* bpf: new option -bpf-expand-memcpy-in-order to expand memcpy in orderYonghong Song2018-07-2510-8/+371
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Some BPF JIT backends would want to optimize memcpy in their own architecture specific way. However, at the moment, there is no way for JIT backends to see memcpy semantics in a reliable way. This is due to LLVM BPF backend is expanding memcpy into load/store sequences and could possibly schedule them apart from each other further. So, BPF JIT backends inside kernel can't reliably recognize memcpy semantics by peephole BPF sequence. This patch introduce new intrinsic expand infrastructure to memcpy. To get stable in-order load/store sequence from memcpy, we first lower memcpy into BPF::MEMCPY node which then expanded into in-order load/store sequences in expandPostRAPseudo pass which will happen after instruction scheduling. By this way, kernel JIT backends could reliably recognize memcpy through scanning BPF sequence. This new memcpy expand infrastructure is gated by a new option: -bpf-expand-memcpy-in-order Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: Jiong Wang <jiong.wang@netronome.com> Signed-off-by: Yonghong Song <yhs@fb.com> llvm-svn: 337977
* Work around GCC bug in constexpr functionEric Fiselier2018-07-251-3/+4
| | | | llvm-svn: 337976
* [ELF] Make linker-script-in-search-path.s robust per r337972Fangrui Song2018-07-251-2/+2
| | | | llvm-svn: 337975
* Fix GCC build in C++14 w/o c++14 constexprEric Fiselier2018-07-251-1/+1
| | | | llvm-svn: 337974
* [GlobalMerge] Handle llvm.compiler.used correctly.Eli Friedman2018-07-252-4/+34
| | | | | | | | Reuse the handling for llvm.used, and don't transform such globals. Fixes a failure on the asan buildbot caused by my previous commit. llvm-svn: 337973
* Make a test more robust.Rui Ueyama2018-07-251-3/+3
| | | | | | | Previously, this test fails if there's other test that happens to create "t.script" in the current directory. llvm-svn: 337972
* Remove test which shouldn't have been committedEric Fiselier2018-07-251-19/+0
| | | | llvm-svn: 337971
* Fix failing test under C++14Eric Fiselier2018-07-251-2/+2
| | | | llvm-svn: 337970
* [ELF] Use search paths for --version-script=Fangrui Song2018-07-255-9/+23
| | | | | | | | | | | | Summary: This behavior matches ld.bfd -Ld --version-script=t.script a.o Reviewers: ruiu, espindola Subscribers: emaste, arichardson, llvm-commits Differential Revision: https://reviews.llvm.org/D49820 llvm-svn: 337969
* [libc++] Follow-up to r337960: specify lambda's return type to avoidAlex Lorenz2018-07-251-1/+1
| | | | | | | | | | | -Wc++11-narrowing warning on Darwin The internal CI produced the following diagnostic: error: non-constant-expression cannot be narrowed from type 'long long' to '__darwin_suseconds_t' (aka 'int') in initializer list [-Wc++11-narrowing] struct ::timeval ConvertedTS[2] = {{TS[0].tv_sec, Convert(TS[0].tv_nsec)}, ^~~~~~~~~~~~~~~~~~~~~~ llvm-svn: 337968
* ELF: Do not ICF SHF_LINK_ORDER sections.Peter Collingbourne2018-07-252-0/+23
| | | | | | | | | | | | | | | | | | We are already ICF'ing these sections as a unit with their dependent sections, so they don't need to be considered for ICF individually. This change also "fixes" slowness caused by our quadratic-in-group-size relocation segregation algorithm on 32-bit ARM platforms with unwind data and ICF on rodata. In this scenario almost every function's .ARM.exidx is identical except for the targets of the relocations that refer to the function and its .ARM.extab, which causes almost all of the program's .ARM.exidx sections to be initially added to the same class, which causes us to compare every such section with every other such section. Differential Revision: https://reviews.llvm.org/D49716 llvm-svn: 337967
* [SelectionDAG] try to convert funnel shift directly to rotate if legalSanjay Patel2018-07-255-13/+18
| | | | | | | | | | | If the DAGCombiner's rotate matching was working as expected, I don't think we'd see any test diffs here. This sidesteps the issue of custom lowering for rotates raised in PR38243: https://bugs.llvm.org/show_bug.cgi?id=38243 ...by only dealing with legal operations. llvm-svn: 337966
* [LSV] Look through selects for consecutive addressesRoman Tereshin2018-07-252-15/+157
| | | | | | | | | | | | | | | | | | | | | | | | In some cases LSV sees (load/store _ (select _ <pointer expression> <pointer expression>)) patterns in input IR, often due to sinking and other forms of CFG simplification, sometimes interspersed with bitcasts and all-constant-indices GEPs. With this patch`areConsecutivePointers` method would attempt to handle select instructions. This leads to an increased number of successful vectorizations. Technically, select instructions could appear in index arithmetic as well, however, we don't see those in our test suites / benchmarks. Also, there is a lot more freedom in IR shapes computing integral indices in general than in what's common in pointer computations, and it appears that it's quite unreliable to do anything short of making select instructions first class citizens of Scalar Evolution, which for the purposes of this patch is most definitely an overkill. Reviewed By: rampitec Differential Revision: https://reviews.llvm.org/D49428 llvm-svn: 337965
* [AArch, PowerPC] add more tests for legal rotate ops; NFCSanjay Patel2018-07-252-4/+47
| | | | llvm-svn: 337964
* Revert "[DataFormatters] Add formatter for C++17 std::optional."Davide Italiano2018-07-254-178/+0
| | | | | | | I forgot to git add some files. I'm going to recommit the correct version at once soon. llvm-svn: 337963
* Make <experimental/filesystem> compile with gcc 4.8.5Eric Fiselier2018-07-251-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | Patch by Victor Zverovich. This fixes an error when compiling `<experimental/filesystem>` with gcc 4.8.5: ``` .../libcxx/src/experimental/filesystem/filesystem_common.h:137:34: error: redeclaration ‘T std::experimental::filesystem::v1::detail::{anonymous}::error_value() [with T = bool]’ d iffers in ‘constexpr’ constexpr bool error_value<bool>() { ^ .../libcxx/src/experimental/filesystem/filesystem_common.h:133:3: error: from previous declaration ‘T std::experimental::filesystem::v1::detail::{anonymous}::error_value() [with T = bool]’ T error_value(); ^ ``` Reviewed as https://reviews.llvm.org/D49813 llvm-svn: 337962
* [GlobalMerge] Allow merging globals with arbitrary alignment.Eli Friedman2018-07-255-24/+74
| | | | | | | | | Instead of depending on implicit padding from the structure layout code, use a packed struct and emit the padding explicitly. Differential Revision: https://reviews.llvm.org/D49710 llvm-svn: 337961
* [libc++] Use __int128_t to represent file_time_type.Eric Fiselier2018-07-259-407/+762
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: The ``file_time_type`` time point is used to represent the write times for files. Its job is to act as part of a C++ wrapper for less ideal system interfaces. The underlying filesystem uses the ``timespec`` struct for the same purpose. However, the initial implementation of ``file_time_type`` could not represent either the range or resolution of ``timespec``, making it unsuitable. Fixing this requires an implementation which uses more than 64 bits to store the time point. I primarily considered two solutions: Using ``__int128_t`` and using a arithmetic emulation of ``timespec``. Each has its pros and cons, and both come with more than one complication. However, after a lot of consideration, I decided on using `__int128_t`. This patch implements that change. Please see the [FileTimeType Design Document](http://libcxx.llvm.org/docs/DesignDocs/FileTimeType.html) for more information. Reviewers: mclow.lists, ldionne, joerg, arthur.j.odwyer, EricWF Reviewed By: EricWF Subscribers: christof, K-ballo, cfe-commits, BillyONeal Differential Revision: https://reviews.llvm.org/D49774 llvm-svn: 337960
* [DataFormatters] Add formatter for C++17 std::optional.Davide Italiano2018-07-254-0/+178
| | | | | | | | | | <rdar://problem/41471112> Patch by Shafik Yaghmour. Differential Revision: https://reviews.llvm.org/D49271 llvm-svn: 337959
OpenPOWER on IntegriCloud