summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* clang-format-diff: add an example with hgSylvestre Ledru2019-01-011-0/+6
| | | | llvm-svn: 350191
* [BDCE] Regenerate test checks; NFCNikita Popov2019-01-011-11/+12
| | | | llvm-svn: 350190
* [BDCE] Remove -instsimplify from BDCE test; NFCNikita Popov2019-01-011-56/+19
| | | | | | | | | To make it more obvious which part of the transformation is carried out by BDCE. Also drop the CHECK-IO lines which only run -instsimplify as they don't really seem meaningful if the main check doesn't run -instsimplify either. llvm-svn: 350189
* Reapply "[BDCE][DemandedBits] Detect dead uses of undead instructions"Nikita Popov2019-01-014-19/+92
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This (mostly) fixes https://bugs.llvm.org/show_bug.cgi?id=39771. BDCE currently detects instructions that don't have any demanded bits and replaces their uses with zero. However, if an instruction has multiple uses, then some of the uses may be dead (have no demanded bits) even though the instruction itself is still live. This patch extends DemandedBits/BDCE to detect such uses and replace them with zero. While this will not immediately render any instructions dead, it may lead to simplifications (in the motivating case, by converting a rotate into a simple shift), break dependencies, etc. The implementation tries to strike a balance between analysis power and complexity/memory usage. Originally I wanted to track demanded bits on a per-use level, but ultimately we're only really interested in whether a use is entirely dead or not. I'm using an extra set to track which uses are dead. However, as initially all uses are dead, I'm not storing uses those user is also dead. This case is checked separately instead. The previous attempt to land this lead to miscompiles, because cases where uses were initially dead but were later found to be live during further analysis were not always correctly removed from the DeadUses set. This is fixed now and the added test case demanstrates such an instance. Differential Revision: https://reviews.llvm.org/D55563 llvm-svn: 350188
* Reversing the commit in revision 350186. Revision causes regression in 4Ayonam Ray2019-01-013-95/+53
| | | | | | tests. llvm-svn: 350187
* Omit range checks from jump tables when lowering switches with unreachableAyonam Ray2019-01-013-53/+95
| | | | | | | | | | | | | | | default During the lowering of a switch that would result in the generation of a jump table, a range check is performed before indexing into the jump table, for the switch value being outside the jump table range and a conditional branch is inserted to jump to the default block. In case the default block is unreachable, this conditional jump can be omitted. This patch implements omitting this conditional branch for unreachable defaults. Review Reference: D52002 llvm-svn: 350186
* [InstCombine] canonicalize MUL with NEG operandChen Zheng2019-01-013-18/+23
| | | | | | | | | -X * Y --> -(X * Y) X * -Y --> -(X * Y) Differential Revision: https://reviews.llvm.org/D55961 llvm-svn: 350185
* [gn build] Add some llvm/tools: llvm-exegesis, llvm-extract, llvm-linkNico Weber2018-12-317-0/+122
| | | | | | | | | | | | | | | | Also add build file for dependency llvm/lib/ExecutionEngine/MCJIT. The exegesis stuff is pretty hairy and knows a lot about Target internals (in general, not specifically in the GN build). I put the llvm-tblgen -gen-exegesis call in llvm/tools/llvm-exegesis/lib/X86, instead of in llvm/lib/Target/X86 where it is in CMake land, and asked on D52932 why it's in that place in the CMake build. Needed for check-llvm. Differential Revision: https://reviews.llvm.org/D56167 llvm-svn: 350184
* [gn build] Add some llvm/tools: llvm-rc, llvm-rtdyldNico Weber2018-12-315-0/+78
| | | | | | | | | | | Also add build file for dependencies llvm/lib/ExecutionEngine, llvm/lib/ExecutionEngine/RuntimeDyld. Needed for check-llvm. Differential Revision: https://reviews.llvm.org/D56165 llvm-svn: 350183
* Make clearer which clang::type subclasses have visualizersMike Spertus2018-12-311-1/+1
| | | | llvm-svn: 350182
* [X86] Add PR34641 masked shld/shrd test casesSimon Pilgrim2018-12-311-0/+64
| | | | llvm-svn: 350181
* [X86] Add additional RUN lines to prepare for D56156. NFCCraig Topper2018-12-311-63/+126
| | | | llvm-svn: 350180
* [SelectionDAG] Add SIGN_EXTEND_VECTOR_INREG support to computeKnownBits.Craig Topper2018-12-312-11/+13
| | | | | | Differential Revision: https://reviews.llvm.org/D56168 llvm-svn: 350179
* [X86] Add X86ISD::VSRAI to computeKnownBitsForTargetNode.Craig Topper2018-12-312-7/+9
| | | | | | Differential Revision: https://reviews.llvm.org/D56169 llvm-svn: 350178
* [DWARFUnit] Remove commented out code. NFCI.Davide Italiano2018-12-311-7/+0
| | | | llvm-svn: 350177
* Keep tablegen commands in alphabetical order. NFCI.Simon Pilgrim2018-12-311-1/+1
| | | | | | Mentioned on D56167. llvm-svn: 350176
* [test] Fix propagating HOME envvar to unittestsMichal Gorny2018-12-311-0/+5
| | | | | | | | | | | | | Propagate HOME environment variable to unittests. This is necessary to fix test failures resulting from pw_home pointing to a non-existing directory while being overriden with HOME. Apparently Gentoo users hit this sometimes when they override build directory for Portage. Original bug report: https://bugs.gentoo.org/674088 Differential Revision: https://reviews.llvm.org/D56162 llvm-svn: 350175
* [AArch64] Accept "sve" as arch feature in assemblerMartin Storsjo2018-12-312-0/+7
| | | | | | Differential Revision: https://reviews.llvm.org/D56128 llvm-svn: 350174
* [MSan] Handle llvm.is.constant intrinsicAlexander Potapenko2018-12-312-0/+27
| | | | | | | | | | MSan used to report false positives in the case the argument of llvm.is.constant intrinsic was uninitialized. In fact checking this argument is unnecessary, as the intrinsic is only used at compile time, and its value doesn't depend on the value of the argument. llvm-svn: 350173
* [DAGCombiner] Add missing one use check on the shuffle in the ↵Craig Topper2018-12-311-1/+1
| | | | | | | | bitcast(shuffle(bitcast(s0),bitcast(s1))) -> shuffle(s0,s1) transform. Found while trying out some other changes so I don't really have a test case. llvm-svn: 350172
* [gn build] Make `ninja check-clang` also run Clang's unit testsNico Weber2018-12-3126-19/+540
| | | | | | | | | | | | | | | | | | | | Also add a build file for clang/lib/ASTMatchers/Dynamic, which is only needed by tests (and clang/tools/extra). Also make llvm/utils/gn/build/sync_source_lists_from_cmake.py check that every CMakeLists.txt file below {lld,clang}/unittests has a corresponding BUILD.gn file, so we notice if new test binaries get added (since the failure mode for missing GN build files for tests is just the tests silently not running in the GN build). Also add a unittest() macro for defining unit test targets, and add a lengthy comment there about where the unit test binaries go and why. With this, the build files for //clang are complete. Differential Revision: https://reviews.llvm.org/D56116 llvm-svn: 350171
* More tolerance for flaky tests in libc++ on NetBSDKamil Rytarowski2018-12-301-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Tests marked with the flaky attribute ("FLAKY_TEST.") can still report false positives in local tests and on the NetBSD buildbot. Additionally a number of tests (probably all threaded ones) unmarked with the flaky attribute is flaky on NetBSD. An ideal solution on the libcxx side would be to raise max retries for NetBSD and mark failing tests with the flaky flag, however this adds more maintenance burden and constant monitoring of flaky tests. Reduce the work and handle flaky tests as more flaky on NetBSD and allow flakiness of other tests on NetBSD. Reviewers: mgorny, EricWF Reviewed By: mgorny Subscribers: christof, llvm-commits, libcxx-commits Differential Revision: https://reviews.llvm.org/D56064 llvm-svn: 350170
* [AArch64] Implement the .arch_extension directiveMartin Storsjo2018-12-303-0/+59
| | | | | | Differential Revision: https://reviews.llvm.org/D56131 llvm-svn: 350169
* [llvm-objcopy] [COFF] Use Error/Expected returns instead of calling ↵Martin Storsjo2018-12-305-56/+63
| | | | | | | | reportError. NFC. Differential Revision: https://reviews.llvm.org/D55922 llvm-svn: 350168
* DeclAccessPair visualizer should be expandableMike Spertus2018-12-301-0/+4
| | | | llvm-svn: 350167
* [CommandInterpreter] Simplify PreprocessCommand. (NFCI)Jonas Devlieghere2018-12-301-117/+127
| | | | | | | | Simplify some code in PreprocessCommand. This change improves consistency, reduces the indentation and makes the code easier to follow overall. llvm-svn: 350166
* [PowerPC] Fix machine verify pass error for PATCHPOINT pseudo instruction ↵Kang Zhang2018-12-305-10/+15
| | | | | | | | | | | | | | | | | | that bad machine code Summary: For SDAG, we pretend patchpoints aren't special at all until we emit the code for the pseudo. Then the verifier runs and it seems like we have a use of an undefined register (the register will be reserved later, but the verifier doesn't know that). So this patch call setUsesTOCBasePtr before emit the code for the pseudo, so verifier can know X2 is a reserved register. Reviewed By: nemanjai Differential Revision: https://reviews.llvm.org/D56148 llvm-svn: 350165
* [Type] Simplify operator!=. NFC.Davide Italiano2018-12-301-2/+1
| | | | llvm-svn: 350164
* [TypeName] Simplify operator!=. NFCI.Davide Italiano2018-12-301-5/+1
| | | | llvm-svn: 350163
* [NFC] Fixed extra semicolon warningDavid Bolvansky2018-12-301-1/+1
| | | | | | | | -This line, and those below, will be ignored-- M lib/Support/Error.cpp llvm-svn: 350162
* [PowerPC] Fix ADDE, SUBE do not know how to promote operatorKang Zhang2018-12-302-0/+36
| | | | | | | | | | | | | | Summary: This patch is created to fix the Bugzilla bug 39815: https://bugs.llvm.org/show_bug.cgi?id=39815 This patch is to support promotion integer result for the instruction ADDE, SUBE. Reviewed By: hfinkel Differential Revision: https://reviews.llvm.org/D56119 llvm-svn: 350161
* [test] Remove flakiness decorator from TestObjCDynamicSBTypeJonas Devlieghere2018-12-301-2/+0
| | | | | | The quoted bug report (llvm.org/PR20270) was closed in 2014. llvm-svn: 350160
* [X86] Don't mark SEXTLOAD from v4i8/v4i16/v8i8 as Custom on pre-sse4.1.Craig Topper2018-12-307-347/+230
| | | | | | | | This seems to be getting in the way more than its helping. This does mean we stop scalarizing some cases, but I'm not convinced the scalarization was really better. Some of the changes to vsel-cmp-load.ll are a regression but D56156 should fix it. llvm-svn: 350159
* [X86] Add custom type legalization for SIGN_EXTEND_VECTOR_INREG from ↵Craig Topper2018-12-303-235/+205
| | | | | | | | | | 16i16/v32i8 to v4i64 when v4i64 needs splitting. This allows us to sign extend to v4i32 first. And then share that extension to implement the final steps to v4i64 using a pcmpgt and punpckl and punpckh. We already do something similar for SIGN_EXTEND with -x86-experimental-vector-widening-legalization. llvm-svn: 350158
* [CodeGen] Replace '@' characters in block descriptors' symbol names withAkira Hatanaka2018-12-293-2/+19
| | | | | | | | | | | | | | '\1'. '@' can't be used in block descriptors' symbol names since it is reserved on ELF platforms as a separator between symbol names and symbol versions. See the discussion here: https://reviews.llvm.org/D50783. Differential Revision: https://reviews.llvm.org/D54539 llvm-svn: 350157
* [PowerPC][NFC] Macro for register set defs for the Asm ParserNemanja Ivanovic2018-12-293-355/+79
| | | | | | | | | | | We have some unfortunate code in the back end that defines a bunch of register sets for the Asm Parser. Every time another class is needed in the parser, we have to add another one of those definitions with explicit lists of registers. This NFC patch simply provides macros to use to condense that code a little bit. Differential revision: https://reviews.llvm.org/D54433 llvm-svn: 350156
* [PowerPC] Complete the custom legalization of vector int to fp conversionNemanja Ivanovic2018-12-298-4093/+1710
| | | | | | | | | | | | | | | A recent patch has added custom legalization of vector conversions of v2i16 -> v2f64. This just rounds it out for other types where the input vector has an illegal (narrower) type than the result vector. Specifically, this will handle the following conversions: v2i8 -> v2f64 v4i8 -> v4f32 v4i16 -> v4f32 Differential revision: https://reviews.llvm.org/D54663 llvm-svn: 350155
* [InstCombine] [NFC] update testcases for canonicalize MUL with NEG operandChen Zheng2018-12-291-5/+20
| | | | llvm-svn: 350154
* [PowerPC] Fix CR Bit spill pseudo expansionNemanja Ivanovic2018-12-292-5/+129
| | | | | | | | | | | | | | | | The current CRBIT spill pseudo-op expansion creates a KILL instruction that kills the CRBIT and defines the enclosing CR field. However, this paints a false picture to the register allocator that all bits in the CR field are killed so copies of other bits out of the field become dead and removable. This changes the expansion to preserve the KILL flag on the CRBIT as an implicit use and to treat the CR field as an undef input. Thanks to Hal Finkel for the review and Uli Weigand for implementation input. Differential revision: https://reviews.llvm.org/D55996 llvm-svn: 350153
* [mips] Show an error on attempt to use 64-bit PC-relative relocationSimon Atanasyan2018-12-292-0/+6
| | | | | | | | | | | | The following code requests 64-bit PC-relative relocations unsupported by MIPS ABI. Now it triggers an assertion. It's better to show an error message. ``` foo: .quad bar - foo ``` llvm-svn: 350152
* [mips] Show a regular error message on attempt to use one byte relocationSimon Atanasyan2018-12-292-5/+8
| | | | llvm-svn: 350151
* [X86] Add test case from PR38217. NFCCraig Topper2018-12-291-0/+79
| | | | llvm-svn: 350150
* [RegisterValue] Rewrite operator!= in terms of operator==. NFCI.Davide Italiano2018-12-291-26/+1
| | | | llvm-svn: 350149
* [CompilerType] Simplify operator!=. NFCI.Davide Italiano2018-12-291-2/+1
| | | | llvm-svn: 350148
* [CompilerType] Remove dead code. NFCI.Davide Italiano2018-12-291-10/+0
| | | | llvm-svn: 350147
* [SymbolContext] Rewrite operator== to be more concise.Davide Italiano2018-12-291-6/+1
| | | | | | And probably, less error prone. NFCI. llvm-svn: 350146
* Drop SE cache early because loop parent can change in LoopSimplifyCFGMax Kazantsev2018-12-291-3/+7
| | | | llvm-svn: 350145
* [WebAssembly] Fix comments in ExplicitLocals (NFC)Heejin Ahn2018-12-291-3/+4
| | | | llvm-svn: 350144
* Add vtable anchor to classes.Richard Trieu2018-12-296-0/+10
| | | | llvm-svn: 350143
* Add vtable anchor to classes.Richard Trieu2018-12-2916-0/+44
| | | | llvm-svn: 350142
OpenPOWER on IntegriCloud