summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [TestVLA] Fix a python decorator.Davide Italiano2018-11-061-1/+2
| | | | llvm-svn: 346186
* Specify REQUIRES: default_triple in two debuginfo testsJustin Bogner2018-11-062-1/+3
| | | | | | These were failing when specifying LLVM_DEFAULT_TARGET_TRIPLE='' llvm-svn: 346185
* TargetMachine: Move lib/CodeGen specific callbacks to LLVMTargetMachine; NFCMatthias Braun2018-11-051-12/+12
| | | | llvm-svn: 346184
* MachineFunction: Store more specific reference to LLVMTargetMachine; NFCMatthias Braun2018-11-057-14/+15
| | | | | | | | | | MachineFunction can only be used in code using lib/CodeGen, hence we can keep a more specific reference to LLVMTargetMachine rather than just TargetMachine around. Do the same for references in ScheduleDAG and RegUsageInfoCollector. llvm-svn: 346183
* MachineModuleInfo: Store more specific reference to LLVMTargetMachine; NFCMatthias Braun2018-11-059-42/+50
| | | | | | | | MachineModuleInfo can only be used in code using lib/CodeGen, hence we can keep a more specific reference to LLVMTargetMachine rather than just TargetMachine around. llvm-svn: 346182
* [DWARF] Support types CU list in .gdb_index dumpingFangrui Song2018-11-052-3/+29
| | | | | | Some executables have non-empty types CU list and -gdb-index would report "<error reporting>" before. llvm-svn: 346181
* [TargetLowering] Change TargetLoweringBase::getPreferredVectorAction to take ↵Craig Topper2018-11-0514-19/+18
| | | | | | | | an MVT instead of an EVT. NFC The main caller of this already has an MVT and several targets called getSimpleVT inside without checking isSimple. This makes the simpleness explicit. llvm-svn: 346180
* Adjust the comment section of CreateSource to account for lines longer than 60Nathan Lanza2018-11-051-2/+6
| | | | | | | | | | | | | | | | | | Summary: On rare occasions, the address, instruction and arguments of a line of assembly in the CreateSource printout would reach > 60 characters. The function would integer overflow and try to indent a line by `0xfff...`. Change the calculated offset to be the maximum of 60 or `line_strm.str().size()` Reviewers: clayborg, xiaobai Reviewed By: clayborg Differential Revision: https://reviews.llvm.org/D52745 llvm-svn: 346179
* AMDGPU: Add sram-ecc feature optionsKonstantin Zhuravlyov2018-11-052-0/+10
| | | | | | Differential Revision: https://reviews.llvm.org/D53223 llvm-svn: 346178
* AMDGPU: Add sram-ecc featureKonstantin Zhuravlyov2018-11-0514-44/+182
| | | | | | Differential Revision: https://reviews.llvm.org/D53222 llvm-svn: 346177
* [clang-tidy] fix example code-blocks indendationJonas Toth2018-11-052-3/+3
| | | | llvm-svn: 346176
* Revert "[GlobalISel] Refactor the artifact combiner a bit by using ↵Volkan Keles2018-11-051-54/+36
| | | | | | | | | MIPatternMatch" This reverts r346166 as it breaks test-suite-verify-machineinstrs-aarch64-globalisel-O0-g. llvm-svn: 346175
* Set stdout/stdin to binary mode on WindowsNathan Lanza2018-11-051-0/+12
| | | | | | | | | | | | | | | | | Summary: A file opened in text mode on Windows will have `\n` automatically changed to `13,10` while Darwin and Linux leave it as `10`. Set the file to binary mode to avoid this automatic conversion so that Darwin, Linux and Windows have equivalent treatment of `\r`. Reviewers: clayborg, xiaobai Reviewed By: clayborg Subscribers: emaste, ki.stfu, mgorny, eraman, JDevlieghere, mgrang Differential Revision: https://reviews.llvm.org/D52672 llvm-svn: 346174
* [clang-tidy] doc removew hitespace in front of code-block-lineJonas Toth2018-11-0511-30/+30
| | | | llvm-svn: 346173
* Skip this test on older versions of clang.Adrian Prantl2018-11-051-0/+1
| | | | llvm-svn: 346172
* Add a relocation to ObjectFileELF::ApplyRelocations and a testNathan Lanza2018-11-054-3/+252
| | | | | | | | | | | | | | | | | | | | | Summary: pcm files can end up being processed by lldb with relocations to be made for the .debug_info section. When a R_AARCH64_ABS64 relocation was required lldb would hit an `assert(false)` and die. Add R_AARCH64_ABS64 relocations to the S+A 64 bit width code path. Add a test for R_AARCH64_ABS64 and R_AARCH64_ABS32 .rela.debug_info relocations in a pcm file. Reviewers: sas, xiaobai, davide, javed.absar, espindola Reviewed By: davide Subscribers: labath, zturner, emaste, mgorny, arichardson, kristof.beyls Differential Revision: https://reviews.llvm.org/D51566 llvm-svn: 346171
* [X86] Don't turn any_extend from a mask register into a sign_extend during ↵Craig Topper2018-11-052-2/+14
| | | | | | | | | | lowering. Add patterns to match any_extend during isel instead. SimplifyDemandedBits can turn a sign_extend back into an any_extend and trigger an infinite loop. So instead legalize it the same way as a sign_extend, but preserve the opcode. Then just pattern match it the same as sign_extend during isel. I don't have a reduced test case for such an infinite loop yet. llvm-svn: 346170
* [InstSimplify] fold select (fcmp X, Y), X, YSanjay Patel2018-11-053-62/+35
| | | | | | | | | This is NFCI for InstCombine because it calls InstSimplify, so I left the tests for this transform there. As noted in the code comment, we can allow this fold more often by using FMF and/or value tracking. llvm-svn: 346169
* [InstSimplify] add tests for select+fcmp; NFCSanjay Patel2018-11-051-0/+102
| | | | | | | These are translated from InstCombine's test file with the same name. We should move the transform from InstCombine to InstSimplify. llvm-svn: 346168
* [Driver] Reland again again: Default Android toolchains to libc++.Dan Albert2018-11-054-65/+62
| | | | | | | | Landed more fixes to the compiler-rt Android tests. Original review was https://reviews.llvm.org/D53109. llvm-svn: 346167
* [GlobalISel] Refactor the artifact combiner a bit by using MIPatternMatchVolkan Keles2018-11-051-36/+54
| | | | | | | | | | | | Reviewers: aditya_nandakumar Reviewed By: aditya_nandakumar Subscribers: rovka, kristof.beyls, llvm-commits Differential Revision: https://reviews.llvm.org/D54116 llvm-svn: 346166
* Fix (and improve) the support for C99 variable length array typesAdrian Prantl2018-11-0533-51/+231
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Clang recently improved its DWARF support for C VLA types. The DWARF now looks like this: 0x00000051: DW_TAG_variable [4] DW_AT_location( fbreg -32 ) DW_AT_name( "__vla_expr" ) DW_AT_type( {0x000000d3} ( long unsigned int ) ) DW_AT_artificial( true ) ... 0x000000da: DW_TAG_array_type [10] * DW_AT_type( {0x000000cc} ( int ) ) 0x000000df: DW_TAG_subrange_type [11] DW_AT_type( {0x000000e9} ( __ARRAY_SIZE_TYPE__ ) ) DW_AT_count( {0x00000051} ) Without this patch LLDB will naively interpret the DIE offset 0x51 as the static size of the array, which is clearly wrong. This patch extends ValueObject::GetNumChildren to query the dynamic properties of incomplete array types. See the testcase for an example: 4 int foo(int a) { 5 int vla[a]; 6 for (int i = 0; i < a; ++i) 7 vla[i] = i; 8 -> 9 pause(); // break here 10 return vla[a-1]; 11 } (lldb) fr v vla (int []) vla = ([0] = 0, [1] = 1, [2] = 2, [3] = 3) (lldb) quit rdar://problem/21814005 Differential Revision: https://reviews.llvm.org/D53530 llvm-svn: 346165
* [lld][NFC] Update tests to use -S instead of -s when using llvm-readelf.Jordan Rupprecht2018-11-0513-15/+15
| | | | | | | | | | | | | | Summary: llvm-readobj/readelf accepts both -s and -S as aliases for --sections. However with GNU readelf only -S means --section, and -s means --symbols. I would like to make llvm-readelf more compatible. Reviewers: MaskRay, espindola Reviewed By: MaskRay Subscribers: emaste, arichardson, steven_wu, dexonsmith, llvm-commits Differential Revision: https://reviews.llvm.org/D54118 llvm-svn: 346164
* Disable precomp test on Linux until I fix it.Alexandre Ganea2018-11-051-0/+2
| | | | llvm-svn: 346163
* Fix the Xcode project for the removal of the Go, Java & OCamlJim Ingham2018-11-051-186/+0
| | | | | | plugins. llvm-svn: 346162
* [X86] Regenerate test checks in preparation for a patch. NFCCraig Topper2018-11-057-235/+456
| | | | | | I'm preparing a patch to avoid creating critical edges in cmov expansion. Updating these tests to make the changes by the next patch easier to see. llvm-svn: 346161
* Fix build breakerage on GCC 5.4:Alexandre Ganea2018-11-051-1/+1
| | | | | | | | | | /home/buildslave/slave_as-bldslv8/lld-perf-testsuite/llvm/tools/lld/COFF/PDB.cpp:365:51: error: 'auto' not allowed in lambda parameter auto DbgIt = find_if(File->getDebugChunks(), [](auto &C) { ^~~~ http://lab.llvm.org:8011/builders/lld-perf-testsuite/builds/8717/steps/build-bin%2Flld/logs/stdio llvm-svn: 346160
* Remove OCaml debugger pluginJonas Devlieghere2018-11-0515-1410/+0
| | | | | | | | | | | | | | | | | | | In January Davide sent an e-mail to the mailing list to suggest removing unmaintained language plugins such as Go and Java. The plan was to have some cool down period to allow users to speak up, however after that the plugins were never actually removed. This patch removes the OCaml debugger plugin. The plugin can be added again in the future if it is mature enough both in terms of testing and maintenance commitment. Discussion on the mailing list: http://lists.llvm.org/pipermail/lldb-dev/2018-January/013171.html Differential revision: https://reviews.llvm.org/D54060 llvm-svn: 346159
* Remove Java debugger pluginJonas Devlieghere2018-11-0522-2906/+0
| | | | | | | | | | | | | | | | | | | In January Davide sent an e-mail to the mailing list to suggest removing unmaintained language plugins such as Go and Java. The plan was to have some cool down period to allow users to speak up, however after that the plugins were never actually removed. This patch removes the Java debugger plugin. The plugin can be added again in the future if it is mature enough both in terms of testing and maintenance commitment. Discussion on the mailing list: http://lists.llvm.org/pipermail/lldb-dev/2018-January/013171.html Differential revision: https://reviews.llvm.org/D54059 llvm-svn: 346158
* Remove Go debugger pluginJonas Devlieghere2018-11-0552-9892/+4
| | | | | | | | | | | | | | | | | | | In January Davide sent an e-mail to the mailing list to suggest removing unmaintained language plugins such as Go and Java. The plan was to have some cool down period to allow users to speak up, however after that the plugins were never actually removed. This patch removes the Go debugger plugin. The plugin can be added again in the future if it is mature enough both in terms of testing and maintenance commitment. Discussion on the mailing list: http://lists.llvm.org/pipermail/lldb-dev/2018-January/013171.html Differential revision: https://reviews.llvm.org/D54057 llvm-svn: 346157
* Properly cast from DeclContext to Decl.Zachary Turner2018-11-052-5/+4
| | | | | | | Apparently there's a special procedure for doing this. Not following this silently breaks builds. llvm-svn: 346156
* [Sanitizers] Disable SANITIZER_CAN_FAST_UNWIND on all SPARC targetsRainer Orth2018-11-052-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | While testing my to-be-submitted Solaris sanitizer support on gcc mainline, I ran into an issue on Solaris/SPARC (sparc-sun-solaris2.11). Initially libasan.so failed to link: Undefined first referenced symbol in file __sanitizer::BufferedStackTrace::FastUnwindStack(unsigned long, unsigned long, unsigned long, unsigned long, unsigned int) /var/gcc/gcc-9.0.0-20181024/11.5-gcc-gas/sparc-sun-solaris2.11/./libsanitizer/asan/.libs/libasan.so This happens because SANITIZER_CAN_FAST_UNWIND is enabled on non-Linux SPARC targets (cf. sanitizer_stacktrace.h), but the guard around the SPARCv8-only definition in sanitizer_stacktrace_sparc.cc only works with clang: clang predefines __sparcv8__ on non-Solaris, and __sparcv8 only on Solaris gcc predefines __sparcv8 on Solaris, but __sparc_v8__ on non-Solaris The attached patch allows for all three variants. However, disabling SANITIZER_CAN_FAST_UNWIND on all SPARC targets fixes a couple of testsuite failures in the Solaris asan testsuite, so for now it's better to keep it disabled everywhere. This allowed the libsanitizer build to complete and gave reasonable (though slightly worse than on Solaris/x86) testsuite results. Differential Revision: https://reviews.llvm.org/D54099 llvm-svn: 346155
* [COFF][LLD] Add link support for Microsoft precompiled headers OBJsAlexandre Ganea2018-11-0514-85/+400
| | | | | | | | | | | This change allows for link-time merging of debugging information from Microsoft precompiled types OBJs compiled with cl.exe /Z7 /Yc and /Yu. This fixes llvm.org/PR34278 Differential Revision: https://reviews.llvm.org/D45213 llvm-svn: 346154
* [Sanitizers] Solaris largefile fixesRainer Orth2018-11-054-19/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | While testing the Solaris libsanitizer port on GCC mainline, I found that I'd messed up the largefile checks in various ways, some of which showed as compile failures (wrong structure sizes and member offsets), others at runtime, some of those only on sparc as a big-endian target. This patch fixes all of them: - OFF_T is now correctly defined for 32-bit largefile and traditional environments, and 64-bit. - The definition of __sanitizer_dirent now checks the correct conditionals. - sanitizer_procmaps_solaris.cc undefines _FILE_OFFSET_BITS: before Solaris 11.4 <procfs.h> doesn't even compile with largefile support enabled, but the use at hand doesn't need it anyway while g++ 9 will define _FILE_OFFSET_BITS=64 out of the box. - With full largefile support enabled, one needs to use e.g. mmap64 instead of mmap; this is hidden behind macros. With this patch I could bootstrap gcc mainline on both sparc-sun-solaris2.11 and i386-pc-solaris2.11. In addition, I've successfully built llvm on i386-pc-solaris2.11. Differential Revision: https://reviews.llvm.org/D54101 llvm-svn: 346153
* Only call FlushFileBuffers() when writing executables on WindowsAlexandre Ganea2018-11-052-1/+57
| | | | | | | | | | | | This is a follow-up for "r325274: Call FlushFileBuffers on output files." Previously, FlushFileBuffers() was called in all cases when writing a file. The objective was to go around a bug in the Windows kernel (as described here: https://randomascii.wordpress.com/2018/02/25/compiler-bug-linker-bug-windows-kernel-bug/). However that is required only when writing EXEs, any other file type doesn't need flushing. This patch calls FlushFileBuffers() only for EXEs. In addition, we completly disable FlushFileBuffers() for known Windows 10 versions that do not exhibit the original kernel bug. Differential Revision: https://reviews.llvm.org/D53727 llvm-svn: 346152
* [MergeICmps] Do not perform the transformation if GEP is used outside of blockTaewook Oh2018-11-053-1/+38
| | | | | | | | | | | | | | | | | Summary: This patch prevents MergeICmps to performn the transformation if the address operand GEP of the load instruction has a use outside of the load's parent block. Without this patch, compiler crashes with the given test case because the use of `%first.i` is still around when the basic block is erased from https://github.com/llvm-mirror/llvm/blob/master/lib/Transforms/Scalar/MergeICmps.cpp#L620. I think checking `isUsedOutsideOfBlock` with `GEP` is the original intention of the code, as the checking for `LoadI` is already performed in the same function. This patch is incomplete though, as this makes the pass overly conservative and fails the test `tuple-four-int8.ll`. I believe what needs to be done is checking if GEP has a use outside of block that is not the part of "Comparisons" chain. Submit the patch as of now to prevent compiler crash. Reviewers: courbet, trentxintong Reviewed By: courbet Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D54089 llvm-svn: 346151
* [InstCombine] add/adjust tests for fcmp+select substitution; NFCSanjay Patel2018-11-051-28/+91
| | | | | | | | There was no coverage for at least 2 out of the 4 patterns because of fcmp canonicalization. The tests and code should be moved to InstSimplify in a follow-up because this doesn't create any new values. llvm-svn: 346150
* Add a target modules dump ast command.Zachary Turner2018-11-0513-10/+140
| | | | | | | | | | This is useful for investigating the clang ast as you reconstruct it via by parsing debug info. It can also be used to write tests against. Differential Revision: https://reviews.llvm.org/D54072 llvm-svn: 346149
* [Power9] Add support for stxvw4x.be and stxvd2x.be intrinsicsZaara Syeda2018-11-053-52/+60
| | | | | | | | | | | | On Power9, we don't have patterns to select the following intrinsics: llvm.ppc.vsx.stxvw4x.be llvm.ppc.vsx.stxvd2x.be This patch adds support for these. Differential Revision: https://reviews.llvm.org/D53581 llvm-svn: 346148
* [InstCombine] canonicalize -0.0 to +0.0 in fcmpSanjay Patel2018-11-055-25/+32
| | | | | | | | | | | | | | | | | As stated in IEEE-754 and discussed in: https://bugs.llvm.org/show_bug.cgi?id=38086 ...the sign of zero does not affect any FP compare predicate. Known regressions were fixed with: rL346097 (D54001) rL346143 The transform will help reduce pattern-matching complexity to solve: https://bugs.llvm.org/show_bug.cgi?id=39475 ...as well as improve CSE and codegen (a zero constant is almost always easier to produce than 0x80..00). llvm-svn: 346147
* [AST] Get aliased type info from an aliased TemplateSpecialization.Matt Davis2018-11-052-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: Previously the TemplateSpecialization instance for 'template_alias', in the example below, returned the type info of the canonical type (int). This ignored the type alias if the template type happen to be aliased. Before this patch, the assert would trigger with an alignment of 4: ``` typedef int __attribute__(( aligned( 16 ) )) aligned_int; template < typename > using template_alias = aligned_int; static_assert( alignof( template_alias<void>) == 16, "" ); ``` This patch checks if the TemplateSpecialization type has an alias, and if so will return the type information for the aliased type, else the canonical type's info is returned (original behavior). I believe that this is the desired behavior. Reviewers: aaron.ballman, rjmccall Reviewed By: rjmccall Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D54048 llvm-svn: 346146
* [UBsan] disable few tests for FreeBSDDavid Carlier2018-11-052-0/+4
| | | | | | | | | | Reviewers: krytarowsky, vitalybuka Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D54103 llvm-svn: 346145
* [Format] Add debugging to ObjC language guesserBen Hamilton2018-11-051-4/+13
| | | | | | | | | | | | | | | | | Summary: To handle diagnosing bugs where ObjCHeaderStyleGuesser guesses wrong, this diff adds a bit more debug logging to the Objective-C language guesser. Reviewers: krasimir Reviewed By: krasimir Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D54110 llvm-svn: 346144
* [InstCombine] loosen FP 0.0 constraint for fcmp+select substitutionSanjay Patel2018-11-052-25/+27
| | | | | | | | | | | | | | It looks like we correctly removed edge cases with 0.0 from D50714, but we were a bit conservative because getBinOpIdentity() doesn't distinguish between +0.0 and -0.0 and 'nsz' is effectively always true for fcmp (see discussion in: https://bugs.llvm.org/show_bug.cgi?id=38086 Without this change, we would get regressions by canonicalizing to +0.0 in all fcmp, and that's a step towards solving: https://bugs.llvm.org/show_bug.cgi?id=39475 llvm-svn: 346143
* [InstCombine] adjust tests for select with FP identity op; NFCSanjay Patel2018-11-051-30/+32
| | | | | | These are mislabeled as negative tests. llvm-svn: 346142
* [FPEnv] Add constrained CEIL/FLOOR/ROUND/TRUNC intrinsicsCameron McInally2018-11-0515-1/+659
| | | | | | Differential Revision: https://reviews.llvm.org/D53411 llvm-svn: 346141
* [ThinLTO] Add an option to disable (thin)lto internalization.Xin Tong2018-11-054-3/+75
| | | | | | | | | | | | | | | | | | | | | | Summary: LTO and ThinLTO optimizes the IR differently. One source of differences is the amount of internalizations that can happen. Add an option to enable/disable internalization so that other differences can be studied in isolation. e.g. inlining. There are other things lto and thinlto do differently, I will add flags to enable/disable them as needed. Reviewers: tejohnson, pcc, steven_wu Subscribers: mehdi_amini, inglorion, steven_wu, dexonsmith, dang, llvm-commits Differential Revision: https://reviews.llvm.org/D53294 llvm-svn: 346140
* [TargetLowering] Begin generalizing TargetLowering::expandFP_TO_SINT ↵Simon Pilgrim2018-11-051-26/+26
| | | | | | | | support. NFCI. Prior to initial work to add vector expansion support, remove assumptions that we're working on scalar types. llvm-svn: 346139
* [InstCombine] add/adjust tests for select with fsub identity op; NFCSanjay Patel2018-11-051-4/+22
| | | | llvm-svn: 346138
* [NFCI][FPEnv] Split constrained intrinsic testsCameron McInally2018-11-052-3260/+1650
| | | | | | | | | The constrained intrinsic tests have grown in number. Split off the FMA tests into their own file to reduce double coverage. Differential Revision: https://reviews.llvm.org/D53932 llvm-svn: 346137
OpenPOWER on IntegriCloud