summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [WebAssembly] Add Emscripten OS definition + small_printfAlon Zakai2019-04-037-3/+98
| | | | | | | | | | | | | | | The Emscripten OS provides a definition of __EMSCRIPTEN__, and also that it supports iprintf optimizations. Also define small_printf optimizations, which is a printf with float support but not long double (which in wasm can be useful since long doubles are 128 bit and force linking of float128 emulation code). This part is based on sunfish's https://reviews.llvm.org/D57620 (which can't land yet since the WASI integration isn't ready yet). Differential Revision: https://reviews.llvm.org/D60167 llvm-svn: 357552
* [libc++abi] Add LIBCXXABI_ENABLE_PIC cmake optionSam Clegg2019-04-032-1/+5
| | | | | | | | | | | | | | | This is on by default, since on many platforms and configurations libc++abi.a gets statically linked into shared libraries and/or PIE executables. This change is a followup to https://reviews.llvm.org/D60005 which allows us to default to PIC code, but disable this if needed (for example on WebAssembly where PIC code its currently compatible with static linking). Differential Revision: https://reviews.llvm.org/D60049 llvm-svn: 357551
* [libc++abi] Actually set POSITION_INDEPENDENT_CODE when building shared librarySam Clegg2019-04-031-1/+3
| | | | | | | | This is a bug fix from https://reviews.llvm.org/D60005. Differential Revision: https://reviews.llvm.org/D60158 llvm-svn: 357550
* InstSimplify: Fold round intrinsics from sitofp/uitofpMatt Arsenault2019-04-032-24/+28
| | | | | | https://godbolt.org/z/gEMRZb llvm-svn: 357549
* [WebAssembly] Remove unneeded target operand flagsSam Clegg2019-04-037-50/+32
| | | | | | | | | | | This change is in preparation for the addition of new target operand flags for new relocation types. Have a symbol type as part of the flag set makes it harder to use and AFAICT these are serving no purpose. Differential Revision: https://reviews.llvm.org/D60014 llvm-svn: 357548
* [libcxx] [test] Add missing <stdexcept> to name std::out_of_range to ↵Billy Robert O'Neal III2019-04-031-2/+3
| | | | | | string.conversions\stold.pass.cpp. llvm-svn: 357547
* [libcxx] [test] Use ptrdiff_t rather than int in splice_after_range.pass.cpp ↵Billy Robert O'Neal III2019-04-031-23/+24
| | | | | | | | to avoid narrowing from pointer subtraction to int warnings. Reviewed as https://reviews.llvm.org/D60104 llvm-svn: 357546
* [libcxx] [test] Fix test bugs in string.cons/copy_alloc.pass.cpp.Billy Robert O'Neal III2019-04-031-6/+7
| | | | | | | | | | | | | | Fixed the inability to properly rebind the testing allocator, by making the inner alloc_impl type a plain struct and making the operations templates. Before rebind failed to compile complaining that a alloc_impl<T>* was not convertible to an alloc_impl<U>*. This enables the test to pass for MSVC++ once we provide the strong guarantee for the copy assignment operator. Reviewed as https://reviews.llvm.org/D60023 llvm-svn: 357545
* [X86] Update the test case for v4i1 bitselect in combine-bitselect.ll to not ↵Craig Topper2019-04-031-62/+48
| | | | | | | | | | have an infinite loop in IR. In fact we don't even need a loop at all. I backed out the bug fix this was testing for and verified that this new case hit the same issue. This should stop D59626 from deleting some of this code by realizing it was dead due to the loop. llvm-svn: 357544
* [X86] Autogenerate complete checks. NFCCraig Topper2019-04-031-74/+81
| | | | llvm-svn: 357543
* AMDGPU: Remove unnecessary subtarget getMatt Arsenault2019-04-031-1/+0
| | | | llvm-svn: 357542
* AMDGPU: Fix names for generation featuresMatt Arsenault2019-04-034-10/+17
| | | | | | | | We should overall stop using these, but the uppercase name didn't work. Any feature string is converted to lowercase, so these could never be found in the table. llvm-svn: 357541
* Fix backwards test that I committed yesterday. SighMarshall Clow2019-04-031-2/+2
| | | | llvm-svn: 357540
* AMDGPU: Don't use the default cpu in a few testsMatt Arsenault2019-04-0311-1274/+1112
| | | | | | Avoids unnecessary test changes in a future commit. llvm-svn: 357539
* [GlobalISel] Add IRTranslator support for llvm.stacksave and llvm.stackrestoreJessica Paquette2019-04-022-0/+40
| | | | | | | | Also update arm64-irtranslator.ll. Differential Revision: https://reviews.llvm.org/D60140 llvm-svn: 357538
* X86: regenerate speculative-load-hardening-indirect.ll tests. NFC.Stanislav Mekhanoshin2019-04-021-31/+31
| | | | llvm-svn: 357537
* Revert "[libc++] Fix error flags and exceptions propagated from input stream ↵Louis Dionne2019-04-0242-2480/+533
| | | | | | | | | | operations" This reverts commits r357533 and r357531, which broke the LLDB data formatters. I'll hold off until we know how to fix the data formatters accordingly. llvm-svn: 357536
* [COFF] Reduce the size of Chunk and SectionChunk, NFCReid Kleckner2019-04-025-32/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Reorder the fields in both to use padding more efficiently, and add more comments on the purpose of the fields. Replace `std::vector<SectionChunk*> AssociativeChildren` with a singly-linked list. This avoids the separate vector allocation to list associative children, and shrinks the 3 pointers used for the typically empty vector down to 1. In the end, this reduces the sum of heap allocations used to link browser_tests.exe with NO PDB by 13.10%, going from 2,248,728 KB to 1,954,071 KB of heap. These numbers exclude memory mapped files, which are of course a significant factor in LLD's memory usage. Reviewers: ruiu, mstorsjo, aganea Subscribers: jdoerfert, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D59797 llvm-svn: 357535
* Revert r357504, r357491, r357482 because of bot breakage.Adrian Prantl2019-04-026-121/+8
| | | | | | | | | | | | | See discussion in https://reviews.llvm.org/D60001. Revert Clean up windows build bot. This reverts r357504 (git commit 380c2420ecb0c3e809b04f385d37b89800df1ecf) Revert Fix buildbot where paths were not matching up. This reverts r357491 (git commit 5050586860140b55a0cc68c77dd1438f44a23ca5) Revert Allow partial UUID matching in Minidump core file plug-in This reverts r357482 (git commit 838bba9c34bf1e5500c2e100327bc764afc8d367) llvm-svn: 357534
* [libc++] Fix build when exceptions are turned offLouis Dionne2019-04-021-1/+1
| | | | llvm-svn: 357533
* [HIP-Clang] Fat binary should not be produced for non GPU codeAaron Enye Shi2019-04-021-2/+2
| | | | | | | | | | clang-format the changes to CUDA and HIP fat binary. Reviewers: yaxunl, tra Differential Revision: https://reviews.llvm.org/D60141 llvm-svn: 357532
* [libc++] Fix error flags and exceptions propagated from input stream operationsLouis Dionne2019-04-0242-533/+2480
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Before this patch, we would only ever throw an exception if the badbit was set on the stream. The Standard is currently very unclear on how exceptions should be propagated and what error flags should be set by the input stream operations. This commit changes libc++ to behave under a different (but valid) interpretation of the Standard. This interpretation of the Standard matches what other implementations are doing. I will submit a paper in San Diego to clarify the Standard such that the interpretation used in this commit (and other implementations) is the only possible one. PR21586 PR15949 rdar://problem/15347558 Reviewers: mclow.lists, EricWF Subscribers: christof, dexonsmith, cfe-commits Differential Revision: https://reviews.llvm.org/D49863 llvm-svn: 357531
* [NFC][TSan][libdispatch] Cleanup testJulian Lettner2019-04-021-6/+6
| | | | llvm-svn: 357530
* [X86] Mark the default case of the X86InstrInfo::convertToThreeAddress ↵Craig Topper2019-04-021-1/+1
| | | | | | | | | switch as unreachable. This function should only be called with instructions that are really convertible. And all convertible instructions need to be handled by the switch. So nothing should use the default. llvm-svn: 357529
* [X86] Check MI.isConvertibleTo3Addr() before calling convertToThreeAddress ↵Craig Topper2019-04-021-0/+6
| | | | | | | | | | in X86FixupLEAs. X86FixupLEAs just assumes convertToThreeAddress will return nullptr for any instruction that isn't convertible. But the code in convertToThreeAddress for X86 assumes that any instruction coming in has at least 2 operands and that the second one is a register. But those properties aren't guaranteed of all instructions. We should check the instruction property first. llvm-svn: 357528
* [TableGen] Properly calculate the minimum size needed or ConvertFn in ↵Craig Topper2019-04-021-7/+11
| | | | | | | | | | GenAsmmatcher.inc files We were using the number of Matchables rather than the number of rows in the converter table. This only matters for a few of the targets where the number of matchables is more than 255, but the number of converters is less than 255. Many of the targets have more than 256 converters. So already required a uint16_t. llvm-svn: 357527
* [HIP-Clang] Fat binary should not be produced for non GPU code 2Aaron Enye Shi2019-04-022-12/+8
| | | | | | | | | | Also for CUDA, we need to disable producing these fat binary functions when there is no GPU code. Reviewers: yaxunl, tra Differential Revision: https://reviews.llvm.org/D60141 llvm-svn: 357526
* [LLD][COFF] Move type merging structures out of PDB.cpp. NFCAlexandre Ganea2019-04-022-54/+88
| | | | | | | | | | | | Introduce a new TypeMerger class, out of some type-merge-specific structures from PDB.cpp No changes intended / this is only moving code around. This patch is step 3. in "Proposed commit strategy" in D59226 Differential Revision: https://reviews.llvm.org/D60070 llvm-svn: 357525
* [NFC] Test is C++, not CJulian Lettner2019-04-021-0/+0
| | | | llvm-svn: 357524
* [x86] add more tests for FP scalarization; NFCSanjay Patel2019-04-021-0/+184
| | | | llvm-svn: 357523
* [InstCombine] Added tests for PR41337David Bolvansky2019-04-021-0/+53
| | | | llvm-svn: 357522
* [InstCombine] Simplify ctlz/cttz with bitreverseDavid Bolvansky2019-04-022-19/+21
| | | | | | | | | | | | | | | | Summary: Fixes PR41273 Reviewers: spatel Reviewed By: spatel Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D60096 llvm-svn: 357521
* [HIP-Clang] Fat binary should not be produced for non GPU codeAaron Enye Shi2019-04-022-5/+13
| | | | | | | | | | Skip producing the fat binary functions for HIP when no device code is present. Reviewers: yaxunl Differential Review: https://reviews.llvm.org/D60141 llvm-svn: 357520
* [TSan][libdispatch] We don't require any setup on DarwinJulian Lettner2019-04-021-1/+1
| | | | llvm-svn: 357519
* [AArch64][GlobalISel] Select llvm.aarch64.stlxr(i64, i64*)Jessica Paquette2019-04-023-8/+104
| | | | | | | | | | | | | This adds partial instruction selection support for llvm.aarch64.stlxr. It also factors out selection for G_INTRINSIC_W_SIDE_EFFECTS into its own function. The new function removes the restriction that the intrinsic ID on the G_INTRINSIC_W_SIDE_EFFECTS be on operand 0. Also add a test, and add a GISel line to arm64-ldxr-stxr.ll. Differential Revision: https://reviews.llvm.org/D60100 llvm-svn: 357518
* [libc++] Correctly handle Objective-C++ ARC qualifiers in std::is_pointerLouis Dionne2019-04-022-0/+61
| | | | | | | | | | | | | | | | Summary: Otherwise, std::is_pointer<id __strong> works, but std::is_pointer<id __weak> (and others) don't work as expected. rdar://problem/49126333 Reviewers: ahatanak, EricWF Subscribers: christof, jkorous, dexonsmith, libcxx-commits Differential Revision: https://reviews.llvm.org/D60087 llvm-svn: 357517
* [Sema] Fix a use-after-deallocate of a ParsedAttrErik Pilkington2019-04-023-2/+14
| | | | | | | | | | | | | | | moveAttrFromListToList only makes sense when moving an attribute to a list with a pool that's either equivalent, or has a shorter lifetime. Therefore, using it to move a ParsedAttr from a declarator to a declaration specifier doesn't make sense, since the declaration specifier's pool outlives the declarator's. The patch adds a new function, ParsedAttributes::takeOneFrom, which transfers the attribute from one pool to another, fixing the use-after-deallocate. rdar://49175426 Differential revision: https://reviews.llvm.org/D60101 llvm-svn: 357516
* [CodeGen] Fix a regression by emitting lambda expressions in EmitLValueErik Pilkington2019-04-022-0/+49
| | | | | | | | | | | This ability was removed in r351487, but it's needed when a lambda appears as an OpaqueValueExpr subexpression of a PseudoObjectExpr. rdar://49030379 Differential revision: https://reviews.llvm.org/D60099 llvm-svn: 357515
* [OPENMP]Add codegen for private vars with allocate clause.Alexey Bataev2019-04-022-8/+20
| | | | | | | Added codegen/test for the privatized variables with the allocate clause. llvm-svn: 357514
* [NativePDB] Don't fail on import modules.Zachary Turner2019-04-021-2/+11
| | | | | | | | | | | A recent patch to LLD started emitting information about import modules. These are represented as compile units in the PDB, but with no additional debug info. This was confusing the native pdb reader, who expected that the debug info stream be present. This should fix failing tests on the Windows bots. llvm-svn: 357513
* [libc++] Remove use of auto with actual typeLouis Dionne2019-04-021-2/+2
| | | | | | For compatibility with C++03. llvm-svn: 357512
* [libc++][NFC] Remove useless public: label at the end of classLouis Dionne2019-04-021-1/+0
| | | | llvm-svn: 357511
* [NFC][libdispatch] Improve a few testsJulian Lettner2019-04-023-6/+7
| | | | llvm-svn: 357510
* [FileCheck] Fix FileCheck.cpp compilation on SolarisRainer Orth2019-04-021-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Both LLVM 8.0.0 and current trunk fail to compile on Solaris with GCC 8.1.0: /vol/llvm/src/llvm/dist/utils/FileCheck/FileCheck.cpp: In function ‘void DumpAnnotatedInput(llvm::raw_ostream&, const llvm::FileCheckRequest&, llvm::StringRef, std::vector<InputAnnotation>&, unsigned int)’: /vol/llvm/src/llvm/dist/utils/FileCheck/FileCheck.cpp:408:41: error: call of overloaded ‘log10(unsigned int&)’ is ambiguous unsigned LineNoWidth = log10(LineCount) + 1; ^ In file included from /vol/gcc-8/lib/gcc/i386-pc-solaris2.11/8.1.0/include-fixed/math.h:24, from /vol/gcc-8/include/c++/8.1.0/cmath:45, from /vol/llvm/src/llvm/dist/include/llvm-c/DataTypes.h:28, from /vol/llvm/src/llvm/dist/include/llvm/Support/DataTypes.h:16, from /vol/llvm/src/llvm/dist/include/llvm/ADT/Hashing.h:47, from /vol/llvm/src/llvm/dist/include/llvm/ADT/ArrayRef.h:12, from /vol/llvm/src/llvm/dist/include/llvm/Support/CommandLine.h:22, from /vol/llvm/src/llvm/dist/utils/FileCheck/FileCheck.cpp:18: /vol/gcc-8/lib/gcc/i386-pc-solaris2.11/8.1.0/include-fixed/iso/math_iso.h:209:21: note: candidate: ‘long double std::log10(long double)’ inline long double log10(long double __X) { return __log10l(__X); } ^~~~~ /vol/gcc-8/lib/gcc/i386-pc-solaris2.11/8.1.0/include-fixed/iso/math_iso.h:170:15: note: candidate: ‘float std::log10(float)’ inline float log10(float __X) { return __log10f(__X); } ^~~~~ /vol/gcc-8/lib/gcc/i386-pc-solaris2.11/8.1.0/include-fixed/iso/math_iso.h:70:15: note: candidate: ‘double std::log10(double)’ extern double log10 __P((double)); ^~~~~ Fixed by using std::log10 instead, which allowed the compilation on i386-pc-solaris2.11 and sparc-sun-solaris2.11 to continue. Differential Revision: https://reviews.llvm.org/D60043 llvm-svn: 357509
* [InstCombine] Added tests for PR41273David Bolvansky2019-04-021-0/+75
| | | | llvm-svn: 357508
* [Reproducers] Print warning when generating the reproducer.Jonas Devlieghere2019-04-021-0/+3
| | | | | | | Encourage users to look at the directory so they know what data they'd be sharing by uploading the reproducer. llvm-svn: 357507
* [driver][mips] Check both `gnuabi64` and `gnu` suffixes in `getMultiarchTriple`Simon Atanasyan2019-04-022-14/+29
| | | | | | | | | | In case of N64 ABI toolchain paths migth have `mips-linux-gnuabi64` or `mips-linux-gnu` directory regardless of selected environment. Check both variants while detecting a multiarch triple. Fix for the bug https://bugs.llvm.org/show_bug.cgi?id=41204 llvm-svn: 357506
* [driver] clang-format. Fix indentation, split long lines. NFCSimon Atanasyan2019-04-023-18/+28
| | | | llvm-svn: 357505
* Clean up windows build bot. Greg Clayton2019-04-021-0/+2
| | | | llvm-svn: 357504
* [Remarks][NFCI] Remove useless includeFrancis Visoiu Mistrih2019-04-021-1/+0
| | | | | | | Remarks.h only uses LLVMBool, which comes from llvm-c/Types.h. Nothing from llvm-c/Core.h is used. llvm-svn: 357503
OpenPOWER on IntegriCloud