summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* [DAGCombiner] try repeated fdiv divisor transform before building estimate ↵Sanjay Patel2019-05-022-43/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | (2nd try) The original patch was committed at rL359398 and reverted at rL359695 because of infinite looping. This includes a fix to check for a vector splat of "1.0" to avoid the infinite loop. Original commit message: This was originally part of D61028, but it's an independent diff. If we try the repeated divisor reciprocal transform before producing an estimate sequence, then we have an opportunity to use scalar fdiv. On x86, the trade-off is 1 divss vs. 5 vector FP ops in the default estimate sequence. On recent chips (Skylake, Ryzen), the full-precision division is only 3 cycle throughput, so that's probably the better perf default option and avoids problems from x86's inaccurate estimates. The last 2 tests show that users still have the option to override the defaults by using the function attributes for reciprocal estimates, but those patterns are potentially made faster by converting the vector ops (including ymm ops) to scalar math. Differential Revision: https://reviews.llvm.org/D61149 llvm-svn: 359793
* [OPENMP][NVPTX]Improve omp_get_max_threads() function.Alexey Bataev2019-05-022-5/+48
| | | | | | | | | | | | | | | | Summary: Function omp_get_max_threads() can always return 1 if current execution mode is SPMD. Reviewers: grokos, gtbercea, kkwli0 Subscribers: guansong, jdoerfert, caomhin, openmp-commits Tags: #openmp Differential Revision: https://reviews.llvm.org/D61379 llvm-svn: 359792
* [SelectionDAG] remove constant folding limitations based on FP exceptionsSanjay Patel2019-05-026-69/+24
| | | | | | | | | | | | | | | | | We don't have FP exception limits in the IR constant folder for the binops (apart from strict ops), so it does not make sense to have them here in the DAG either. Nothing else in the backend tries to preserve exceptions (again outside of strict ops), so I don't see how this could have ever worked for real code that cares about FP exceptions. There are still cases (examples: unary opcodes in SDAG, FMA in IR) where we are trying (at least partially) to preserve exceptions without even asking if the target supports FP exceptions. Those should be corrected in subsequent patches. Real support for FP exceptions requires several changes to handle the constrained/strict FP ops. Differential Revision: https://reviews.llvm.org/D61331 llvm-svn: 359791
* [OPENMP][NVPTX]Improved omp_get_thread_limit() function.Alexey Bataev2019-05-022-6/+75
| | | | | | | | | | | | | | | | Summary: Function omp_get_thread_limit() in SPMD mode can return the maximum available number of threads as a result. Reviewers: grokos, gtbercea, kkwli0 Subscribers: guansong, jdoerfert, openmp-commits, caomhin Tags: #openmp Differential Revision: https://reviews.llvm.org/D61378 llvm-svn: 359790
* [OpenCL] Deduce static data members to __global addr space.Anastasia Stulova2019-05-022-2/+16
| | | | | | | | | Similarly to static variables in OpenCL, static class data members should be deduced to __global addr space. Differential Revision: https://reviews.llvm.org/D61304 llvm-svn: 359789
* [ELF] --plugin-opt=thinlto-index-only: create empty index files even if all ↵Fangrui Song2019-05-024-19/+31
| | | | | | | | | | | | | | | | | | | bitcode files are lazy Summary: The gold plugin behavior (creating empty index files for lazy bitcode files) was added in D46034, but it missed the case when there is no non-lazy bitcode files, e.g. ld.lld -shared crti.o crtbeginS.o --start-lib bitcode.o --end-lib ... crti.o crtbeginS.o are not bitcode, but our distributed build system wants bitcode.o.thinlto.bc to confirm all expected outputs are created based on all of the modules provided to the linker. Differential Revision: https://reviews.llvm.org/D61420 llvm-svn: 359788
* [lldb] [lit] Mark x86-64-ymm-write XFAIL on DarwinMichal Gorny2019-05-021-0/+1
| | | | llvm-svn: 359787
* [X86][SSE] lowerAddSubToHorizontalOp - enable ymm extraction+foldSimon Pilgrim2019-05-023-61/+91
| | | | | | | | | | | Limiting scalar hadd/hsub generation to the lowest xmm looks to be unnecessary - we will be extracting one upper xmm whatever, and we can remove a shuffle by using the hop which is inline with what shouldUseHorizontalOp expects to happen anyway. Testing on btver2 (the main target for fast-hops) shows this is beneficial even for float ops where we have a 'shuffle' to extract the float result: https://godbolt.org/z/0R-U-K Differential Revision: https://reviews.llvm.org/D61426 llvm-svn: 359786
* Attempt to fix flaky tests.Eric Fiselier2019-05-021-188/+149
| | | | | | | | | | | The threaded cxa guard test attempted to test multithreaded waiting by lining up a bunch of threads at a held init lock and releasing them. The test initially wanted each thread to observe the lock being held, but some threads may arive too late. This patch cleans up the test and relaxes the restrictions. llvm-svn: 359785
* [lldb] [lit] Use LLDB-like output for XMM registers in write testsMichal Gorny2019-05-024-26/+40
| | | | llvm-svn: 359784
* [lldb] [lit] Introduce tests for writing YMM registersMichal Gorny2019-05-023-0/+149
| | | | | | Differential Revision: https://reviews.llvm.org/D61431 llvm-svn: 359783
* [X86][SSE] Move shouldUseHorizontalOp inside isHorizontalBinOp. NFCI.Simon Pilgrim2019-05-021-13/+15
| | | | | | Matches what we do for lowerAddSubToHorizontalOp and will make it easier to peek through subvectors to help fix PR39921 llvm-svn: 359782
* [llvm-strip]Add --no-strip-all to disable --strip-all behaviour (including ↵James Henderson2019-05-029-23/+66
| | | | | | | | | | | | | | | | | default stripping) If certain switches are not specified, llvm-strip behaves as if --strip-all were specified. This means that for testing, when we don't want the stripping behaviour, we have to specify one of these switches, which can be confusing. This change adds --no-strip-all to allow an alternative way of suppressing the default stripping, in a less confusing manner. Reviewed by: jakehehrlich, MaskRay Differential Revision: https://reviews.llvm.org/D61377 llvm-svn: 359781
* [lldb] [lit] Split 'register read' tests between zmm*, xmm16+, ymm16+Michal Gorny2019-05-023-65/+60
| | | | | | | | | | | | Since Darwin target implements support for zmm* registers without matching support for the respectively added xmm* and ymm* registers, split the tests for each register group. To reduce code duplication, the tests are using the same source file (which sets more registers than necessary but that should not cause any harm). Differential Revision: https://reviews.llvm.org/D61376 llvm-svn: 359780
* Add std::stack and std::queue support to CxxModuleHandlerRaphael Isemann2019-05-027-0/+141
| | | | | | | | | | | | | | Reviewers: aprantl, shafik Reviewed By: aprantl, shafik Subscribers: lldb-commits Tags: #c_modules_in_lldb, #lldb Differential Revision: https://reviews.llvm.org/D61305 llvm-svn: 359779
* [clangd] Fix code completion of macros defined in the preamble region of the ↵Sam McCall2019-05-025-13/+97
| | | | | | | | | | | | | | | | | | | | main file. Summary: This is a tricky case (we baked the assumption that symbols come from the preamble xor mainfile pretty deeply) and the fix is a bit of a hack: We look at the code to guess the macro names, and deserialize them from the preamble "by hand". Reviewers: ilya-biryukov Subscribers: ioeric, MaskRay, jkorous, arphaman, kadircet, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D60937 llvm-svn: 359778
* Rename Minion to ASTImporterDelegateRaphael Isemann2019-05-022-78/+97
| | | | | | | | | | | | | | | | | | Summary: I think there universal agreement that Minion isn't the best name for this class. This patch renames the class to ASTImporterDelegate to better reflect it's goal of monitoring and extending the ASTImporter. Reviewers: aprantl, shafik, martong, a.sidorin, davide Reviewed By: aprantl, shafik, davide Subscribers: rnkovacs, davide, abidh, lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D61299 llvm-svn: 359777
* [LTO] Migrate typedef to usingFangrui Song2019-05-023-12/+11
| | | | | | using has been used in several places in the file. Migrate the rest for consistency. llvm-svn: 359776
* [llvm-readobj] Delete and inline relocAddressLessFangrui Song2019-05-023-7/+3
| | | | | | | It is used only once in COFFDumper.cpp. Deleting it from the public interface seems better. llvm-svn: 359775
* [Object] Change getSectionName() to return Expected<StringRef>Fangrui Song2019-05-0219-111/+91
| | | | | | | | | | Summary: It currently receives an output parameter and returns std::error_code. Expected<StringRef> fits for this purpose perfectly. Differential Revision: https://reviews.llvm.org/D61421 llvm-svn: 359774
* Inject only relevant local variables in the expression evaluation contextRaphael Isemann2019-05-025-18/+100
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: In r259902, LLDB started injecting all the locals in every expression evaluation. This fixed a bunch of issues, but also caused others, mostly performance regressions on some codebases. The regressions were bad enough that we added a setting in r274783 to control the behavior and we have been shipping with the setting off to avoid the perf regressions. This patch changes the logic injecting the local variables to only inject the ones present in the expression typed by the user. The approach is fairly simple and just scans the typed expression for every local name. Hopefully this gives us the best of both world as it just realizes the types of the variables really used by the expression. Landing this requires the 2 other issues I pointed out today to be addressed but I wanted to gather comments right away. Original patch by Frédéric Riss! Reviewers: jingham, clayborg, friss, shafik Reviewed By: jingham, clayborg Subscribers: teemperor, labath, lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D46551 llvm-svn: 359773
* [ARM GlobalISel] Fixup r359768Diana Picus2019-05-021-2/+1
| | | | | | Get rid of local variable used only in assertion. llvm-svn: 359772
* [clangd] Improvements to header mapping: more precise parsing of ↵Sam McCall2019-05-023-15/+105
| | | | | | | | | | | | | | | | | | | | | | cppreference symbol pages. Summary: Previously we were just jumping from the symbol index to the symbol page, and grabbing all the headers mentioned there. But the page often lists multiple symbols, and so we got false positives and thus ambiguities (which were dropped). Now we look at which declarations are for the symbol we want, and prefer headers listed above that symbol. If there are none, we fall back to the old behavior. Reviewers: kadircet Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D61316 llvm-svn: 359771
* [clangd] Standard library mapping: prefer "primary" versions of functions ↵Sam McCall2019-05-023-9/+54
| | | | | | | | | | | | | | over variants. Reviewers: kadircet Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D61349 llvm-svn: 359770
* [ELF] Delete a cant-write test from test/lto/thinlto-index-only.llFangrui Song2019-05-021-10/+0
| | | | | | The test is performed by thinlto-cant-write-index.ll llvm-svn: 359769
* [ARM GlobalISel] Select extensions to < 32 bitsDiana Picus2019-05-023-5/+648
| | | | | | | | | Select G_SEXT and G_ZEXT with destination types smaller than 32 bits in the exact same way as 32 bits. This overwrites the higher bits, but that should be ok since all legal users of types smaller than 32 bits ignore those bits anyway. llvm-svn: 359768
* [ARM GlobalISel] Rename some inst selector tests. NFCDiana Picus2019-05-022-45/+45
| | | | | | Prepare to add support for extensions to types smaller than 32 bits. llvm-svn: 359767
* [ARM GlobalISel] Legalize extensions to < 32 bitsDiana Picus2019-05-022-10/+132
| | | | | | Make it legal to extend from e.g. s1 to s8 or s16. llvm-svn: 359766
* Fix MSVC buildPavel Labath2019-05-022-2/+2
| | | | | | | | Address an ambiguity between lldb_private::Thread and llvm::minidump::Thread. Follow-up to llvm r359762 (which introduced the second type). llvm-svn: 359765
* [NFC][PowerPC] Return early if the element type is not byte-sized in ↵Kang Zhang2019-05-021-0/+5
| | | | | | | | | | | | combineBVOfConsecutiveLoads Summary: Based on the Eli Friedman's comments in https://reviews.llvm.org/D60811 , we'd better return early if the element type is not byte-sized in `combineBVOfConsecutiveLoads`. Reviewed By: efriedma Differential Revision: https://reviews.llvm.org/D61076 llvm-svn: 359764
* [clangd] Restore conventional names for lit configs, and .in/.py split. Fix ↵Sam McCall2019-05-027-40/+76
| | | | | | build_mode indirection. llvm-svn: 359763
* Object/Minidump: Add support for the ThreadList streamPavel Labath2019-05-024-9/+118
| | | | | | | | | | | | | | | | | | Summary: The stream contains the list of threads belonging to the process described by the minidump. Its structure is the same as the ModuleList stream, and in fact, I have generalized the ModuleList reading code to handle this stream too. Reviewers: amccarth, jhenderson, clayborg Subscribers: llvm-commits, lldb-commits, markmentovai, zturner Tags: #llvm Differential Revision: https://reviews.llvm.org/D61064 llvm-svn: 359762
* Fix typo in test case.Akira Hatanaka2019-05-021-1/+1
| | | | llvm-svn: 359761
* Fix for WindowsStephan Bergmann2019-05-021-2/+1
| | | | | | | ...after 5745eccef54ddd3caca278d1d292a88b2281528b "Adapt -fsanitize=function to SANITIZER_NON_UNIQUE_TYPEINFO" llvm-svn: 359760
* Adapt -fsanitize=function to SANITIZER_NON_UNIQUE_TYPEINFOStephan Bergmann2019-05-028-49/+81
| | | | | | | | | | | | | | | | | | | | | | | | This follows up after b7692bc3e9ad2691fc07261904b88fb15f30696b "[UBSan] Fix isDerivedFromAtOffset on iOS ARM64" fixed the RTTI comparison in isDerivedFromAtOffset on just one platform and then a25a2c7c9a7e1e328a5bd8274d2d86b1fadc4692 "Always compare C++ typeinfo (based on libstdc++ implementation)" extended that fix to more platforms. But there is another RTTI comparison for -fsanitize=function generated in clang's CodeGenFunction::EmitCall as just a pointer comparison. For SANITIZER_NON_UNIQUE_TYPEINFO platforms this needs to be extended to also do string comparison. For that, __ubsan_handle_function_type_mismatch[_abort] takes the two std::type_info pointers as additional parameters now, checks them internally for potential equivalence, and returns without reporting failure if they turn out to be equivalent after all. (NORETURN needed to be dropped from the _abort variant for that.) Also these functions depend on ABI-specific RTTI now, so needed to be moved from plain UBSAN_SOURCES (ubsan_handlers.h/cc) to UBSAN_CXXABI_SOURCES (ubsan_handlers_cxx.h/cc), but as -fsanitize=function is only supported in C++ mode that's not a problem. Differential Revision: https://reviews.llvm.org/D60760 llvm-svn: 359759
* [Support] Don't check MAP_ANONYMOUS, just use MAP_ANONFangrui Song2019-05-021-8/+1
| | | | | | | | | Though being marked "deprecated" by the Linux man-pages project (MAP_ANON is a synonym of MAP_ANONYMOUS), it is the mostly widely available macro - many systems that don't provide MAP_ANONYMOUS have MAP_ANON. MAP_ANON is also used here and there in compiler-rt. llvm-svn: 359758
* [AMDGPU] gfx1010 lost VOP2 forms of some add/subStanislav Mekhanoshin2019-05-023-19/+88
| | | | | | | | Add legalization of V_ADD_I32, V_SUB_I32, V_SUBREV_I32. Differential Revision: llvm-svn: 359757
* [AMDGPU] gfx1010 allows VOP3 to have a literalStanislav Mekhanoshin2019-05-0218-120/+629
| | | | | | Differential Revision: https://reviews.llvm.org/D61413 llvm-svn: 359756
* [libcxx] cmake - guard list removeBrian Cain2019-05-021-4/+6
| | | | | | | REMOVE_ITEM fails if CMAKE_REQUIRED_LIBRARIES is empty on some versions of cmake. llvm-svn: 359755
* [AMDGPU] gfx1010 constant bus limitStanislav Mekhanoshin2019-05-024-24/+136
| | | | | | | | Constant bus limit has increased to 2 with GFX10. Differential Revision: https://reviews.llvm.org/D61404 llvm-svn: 359754
* [X86] Remove the redundant suffix in vfpclassp[d,s]'s broadcasting variantCraig Topper2019-05-023-129/+129
| | | | | | | | | | The broadcasting variant for instruction vfpclassp[d,s] shouldn't use suffix q/l. So remove them from the template. Patch by Pengfei Wang Differential Revision: https://reviews.llvm.org/D61295 llvm-svn: 359753
* Mention the thread-format & frame-format settings in help.Jim Ingham2019-05-022-3/+10
| | | | | | | | | You can only find out about this useful customization by browsing the settings list output or the llvm.org web pages. Mention it in the help for thread list, thread backtrace & _regex_bt commands to make it more discoverable. llvm-svn: 359752
* [test] Convert TestWatchpointSetErrorCases.py to litJonas Devlieghere2019-05-023-74/+41
| | | | | | | | | | This test is flaky on GreenDragon. Since it was a pexpect test and straightforward enough to convert, I went ahead and converted it to a lit test. Differential revision: https://reviews.llvm.org/D61414 llvm-svn: 359751
* [CommandObjectCommands] Honor stop-command-source-on-errorJonas Devlieghere2019-05-022-2/+19
| | | | | | | | | | | | This patch ensures that we honor the stop-command-source-on-error setting from `command source`. The problem is that we didn't differentiate between the boolean value being true or false, or not being set. For the latter scenario, we should calculate the value in the command interpreter based on the global options. Differential revision: https://reviews.llvm.org/D61406 llvm-svn: 359750
* lld-link: Make "duplicate resource" error message a bit more conciseNico Weber2019-05-023-5/+8
| | | | | | | | | | | | | | | | Reduces the error message from: lld-link: error: failed to parse .res file: duplicate resource: type STRINGTABLE (ID 6)/name ID 3/language 1033, in test1.res and in test2.res To: lld-link: error: duplicate resource: type STRINGTABLE (ID 6)/name ID 3/language 1033, in test1.res and in test2.res Make sure every error message emitted by cvtres contains the name of at least one ".res" file, so that removing the "failed to parse .res file" string doesn't lose information. Differential Revision: https://reviews.llvm.org/D61388 llvm-svn: 359749
* [CMake] Remove EmulateInstructionMIPS dependency on InterpreterAlex Langford2019-05-022-2/+4
| | | | llvm-svn: 359748
* Replace ad-hoc tracking of pattern for an instantiated class-scopeRichard Smith2019-05-0216-203/+316
| | | | | | | | | | explicit function specialization with the MemberSpecializationInfo used everywhere else. Not NFC: the ad-hoc pattern tracking was not being serialized / deserialized properly. That's fixed here. llvm-svn: 359747
* Diagnose non-dependent qualified friend function template declarationsRichard Smith2019-05-024-12/+23
| | | | | | | that don't match any existing declaration. Don't get confused and treat such declarations as template *specializations*. llvm-svn: 359746
* Delete trailing \r. NFCFangrui Song2019-05-027-398/+398
| | | | llvm-svn: 359745
* [COFF, ARM64] Align global symbol by size for ARM64 MSVC ABITom Tan2019-05-026-5/+56
| | | | | | | | | | | | | | | | | According to alignment section in below ARM64 ABI document, MSVC could increase alignment of global data based on its total size. Clang doesn't do this. Compile the same symbol into different alignments by Clang and MSVC could cause link error because some instruction encodings, like 64-bit LDR/STR with immediate, require the target to be 8 bytes aligned, and linker could choose code stream with such LDR/STR instruction from MSVC and 4 bytes aligned data from Clang into final image, which actually cannot be linked together (see https://bugs.llvm.org/show_bug.cgi?id=41506 for more details). https://docs.microsoft.com/en-us/cpp/build/arm64-windows-abi-conventions?view=vs-2019#alignment Differential Revision: https://reviews.llvm.org/D61225 llvm-svn: 359744
OpenPOWER on IntegriCloud