summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [lld] Prevent duplicate files in debug line header in dwarf 5.Ali Tamur2019-03-252-9/+7
| | | | | | | | | | | | | | | | | Summary: Changes to a couple of tests that will start failing after https://reviews.llvm.org/D59515 is submitted. Reviewers: echristo, ruiu, espindola Reviewed By: echristo, ruiu Subscribers: emaste, arichardson, MaskRay, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D59671 llvm-svn: 356943
* [ScriptInterpreterPython] Move SWIG initialization into the Python plugin (NFC)Jonas Devlieghere2019-03-253-207/+203
| | | | | | Abstract initialization of the Python SWIG support in the Python plugin. llvm-svn: 356942
* [llvm] Prevent duplicate files in debug line header in dwarf 5.Ali Tamur2019-03-2514-26/+70
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Motivation: In previous dwarf versions, file name indexes started from 1, and the primary source file was not explicit. Dwarf 5 standard (6.2.4) prescribes the primary source file to be explicitly given an entry with an index number 0. The current implementation honors the specification by just duplicating the main source file, once with index number 0, and later maybe with another index number. While this is compliant with the letter of the standard, the duplication causes problems for consumers of this information such as lldb. (Some files are duplicated, where only some of them have a line table although all refer to the same file) With this change, dwarf 5 debug line section files always start from 0, and the zeroth entry is not duplicated whenever possible. This requires different handling of dwarf 4 and dwarf 5 during generation (e.g. when a function returns an index zero for a file name, it signals an error in dwarf 4, but not in dwarf 5) However, I think the minor complication is worth it, because it enables all consumers (lldb, gdb, dwarfdump, objdump, and so on) to treat all files in the file name list homogenously. Reviewers: dblaikie, probinson, aprantl, espindola Reviewed By: probinson Subscribers: emaste, jvesely, nhaehnle, aprantl, javed.absar, arichardson, hiraditya, MaskRay, rupprecht, jdoerfert, llvm-commits Tags: #llvm, #debug-info Differential Revision: https://reviews.llvm.org/D59515 llvm-svn: 356941
* Thread Safety: also look at ObjC methodsJF Bastien2019-03-254-25/+46
| | | | | | | | | | | | | | | | | Summary: SExprBuilder::translateDeclRefExpr was only looking at FunctionDecl and not also looking at ObjCMethodDecl. It should consider both because the attributes can be used on Objective-C as well. <rdar://problem/48941331> Reviewers: dexonsmith, erik.pilkington Subscribers: jkorous, jdoerfert, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D59523 llvm-svn: 356940
* [SLPVectorizer] Merge reorderAltShuffleOperands into ↵Simon Pilgrim2019-03-252-87/+37
| | | | | | | | | | reorderInputsAccordingToOpcode As discussed on D59738, this generalizes reorderInputsAccordingToOpcode to handle multiple + non-commutative instructions so we can get rid of reorderAltShuffleOperands and make use of the extra canonicalizations that reorderInputsAccordingToOpcode brings. Differential Revision: https://reviews.llvm.org/D59784 llvm-svn: 356939
* [SelectionDAG] Add icmp UNDEF handling to SelectionDAG::FoldSetCCSimon Pilgrim2019-03-2510-266/+129
| | | | | | | | | | First half of PR40800, this patch adds DAG undef handling to icmp instructions to match the behaviour in llvm::ConstantFoldCompareInstruction and SimplifyICmpInst, this permits constant folding of vector comparisons where some elements had been reduced to UNDEF (by SimplifyDemandedVectorElts etc.). This involved a lot of tweaking to reduced tests as bugpoint loves to reduce icmp arguments to undef........ Differential Revision: https://reviews.llvm.org/D59363 llvm-svn: 356938
* [CGP] Build the DominatorTree lazilyTeresa Johnson2019-03-251-34/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: In r355512 CGP was changed to build the DominatorTree only once per function traversal, to avoid repeatedly building it each time it was accessed. This solved one compile time issue but introduced another. In the second case, we now were building the DT unnecessarily many times when we performed many function traversals (i.e. more than once per function when running CGP because of changes made each time). Change to saving the DT in the CodeGenPrepare object, and building it lazily when needed. It is reset whenever we need to rebuild it. The case that exposed the issue there are 617 functions, and we walk them (i.e. execute the "while (MadeChange)" loop in runOnFunction) a total of 12083 times (so previously we were building the DT 12083 times). With this patch we only build the DT 844 times (average of 1.37 times per function). We dropped the total time to compile this file from 538.11s without this patch to 339.63s with it. There is still an issue as CGP is taking much longer than all other passes even with this patch, and before a recent compiler release cut at r355392 the total time to this compile was only 97 sec with a huge reduction in CGP time. I suspect that one of the other recent changes to CGP led to iterating each function many more times on average, but I need to do some more investigation. Reviewers: spatel Subscribers: jdoerfert, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D59696 llvm-svn: 356937
* Fix interoperability test compilation on FreeBSDDimitry Andric2019-03-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: While building the 8.0 releases on FreeBSD, I encountered the following error in the regression tests, where ompt/misc/interoperability.cpp failed to compile, with: ``` projects/openmp/runtime/test/ompt/misc/interoperability.cpp:7:10: fatal error: 'alloca.h' file not found #include <alloca.h> ^~~~~~~~~~ ``` Like on NetBSD, alloca(3) is defined in <stdlib.h> instead. Reviewers: emaste, jlpeyton, krytarowski, mgorny, protze.joachim Reviewed By: jlpeyton Subscribers: jdoerfert, openmp-commits Tags: #openmp Differential Revision: https://reviews.llvm.org/D59736 llvm-svn: 356936
* [pstl] Gate usage of TBB in test on whether TBB is used as a backendLouis Dionne2019-03-251-1/+1
| | | | | | | __PSTL_USE_PAR_POLICIES is the wrong macro to use there, since the PSTL could conceivably be using parallel policies but not TBB as a backend. llvm-svn: 356935
* Fix gettid warnings on FreeBSDDimitry Andric2019-03-251-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: [Split off from D59451 to get this fix in separately] While building the 8.0 releases on FreeBSD, I encountered the following warnings in openmp quite a few times: ``` In file included from projects/openmp/runtime/src/kmp_settings.cpp:27: projects/openmp/runtime/src/kmp_wrapper_getpid.h:35:2: warning: #warning is a language extension [-Wpedantic] #warning No gettid found, use getpid instead ^ projects/openmp/runtime/src/kmp_wrapper_getpid.h:35:2: warning: No gettid found, use getpid instead [-W#warnings] 2 warnings generated. ``` I added a gettid wrapper that uses FreeBSD's pthread_getthreadid_np(3) function for this. Reviewers: emaste, jlpeyton, krytarowski, mgorny, protze.joachim Reviewed By: jlpeyton Subscribers: jfb, jdoerfert, openmp-commits Tags: #openmp Differential Revision: https://reviews.llvm.org/D59735 llvm-svn: 356934
* [OpenMP] Fix pause check with version infoJonathan Peyton2019-03-251-9/+6
| | | | | | | | | | Add 5.0 guard to pause code for now. Patch by Terry Wilmarth Differential Revision: https://reviews.llvm.org/D59428 llvm-svn: 356933
* Revert "[WebAssembly] Add linker options to control feature checking"Thomas Lively2019-03-258-200/+7
| | | | | | This reverts commit 5991328c96b6146999cfa74ede42901f8c01f2fa. llvm-svn: 356932
* clang -dumpversion returns 4.2.1 for legacy reason, update itSylvestre Ledru2019-03-252-6/+2
| | | | | | | | | | | | | | | | | | | | | | Summary: It has been introduced in 2011 for gcc compat: https://github.com/llvm-mirror/clang/commit/95a907fc0f2f717dca38a379c1d2353bfea06d4f it is probably time to remove it to remove the confusion. reported: https://bugs.llvm.org/show_bug.cgi?id=38836 https://bugs.launchpad.net/ubuntu/+source/llvm-defaults/+bug/1810860 Reviewers: ddunbar, rnk Reviewed By: rnk Subscribers: jdoerfert, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D56803 llvm-svn: 356931
* [x86] add another vector zext test; NFCSanjay Patel2019-03-251-7/+63
| | | | | | Goes with the proposal in D59777 llvm-svn: 356930
* Moved everything SMT-related to LLVM and updated the cmake scripts.Mikhail R. Gadelha2019-03-2517-246/+331
| | | | | | Differential Revision: https://reviews.llvm.org/D54978 llvm-svn: 356929
* [clang-format] Refine structured binding detectionKrasimir Georgiev2019-03-252-8/+32
| | | | | | | | | | | | | | | | | | | | | Summary: Revision r356575 had the unfortunate consequence that now clang-format never detects an ObjC call expression after `&&`. This patch tries harder to distinguish between C++17 structured bindings and ObjC call expressions and adds a few regression tests. Reviewers: klimek Reviewed By: klimek Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D59774 llvm-svn: 356928
* [Args] Handle backticks to prevent crash.Jonas Devlieghere2019-03-252-3/+30
| | | | | | | | | | Currently LLDB crashes when autocompleting a command that ends with a backtick because the quote character wasn't handled. This fixes that and adds a unit test for this function. Differential revision: https://reviews.llvm.org/D59779 llvm-svn: 356927
* MISched: Don't schedule regions with 0 instructionsMatt Arsenault2019-03-252-2/+121
| | | | | | | | | | | | | | | | | I think this is correct, but may not necessarily be the correct fix for the assertion I'm really trying to solve. If a scheduling region was found that only has dbg_value instructions, the RegPressure tracker would end up in an inconsistent state because it would skip over any debug instructions and point to an instruction outside of the scheduling region. It may still be possible for this to happen if there are some real schedulable instructions between dbg_values, but I haven't managed to break this. The testcase is extremely sensitive and I'm not sure how to make it more resistent to future scheduler changes that would avoid stressing this situation. llvm-svn: 356926
* [Sema][NFCI] Don't allocate storage for the various ↵Bruno Ricci2019-03-2525-212/+312
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | CorrectionCandidateCallback unless we are going to do some typo correction The various CorrectionCandidateCallbacks are currently heap-allocated unconditionally. This was needed because of delayed typo correction. However these allocations represent currently 15.4% of all allocations (number of allocations) when parsing all of Boost (!), mostly because of ParseCastExpression, ParseStatementOrDeclarationAfterAttrtibutes and isCXXDeclarationSpecifier. Note that all of these callback objects are small. Let's not do this. Instead initially allocate the callback on the stack, and only do a heap allocation if we are going to do some typo correction. Do this by: 1. Adding a clone function to each callback, which will do a polymorphic clone of the callback. This clone function is required to be implemented by every callback (of which there is a fair amount). Make sure this is the case by making it pure virtual. 2. Use this clone function when we are going to try to correct a typo. This additionally cut the time of -fsyntax-only on all of Boost by 0.5% (not that much, but still something). No functional changes intended. Differential Revision: https://reviews.llvm.org/D58827 Reviewed By: rnk llvm-svn: 356925
* merge-request.sh: Update 8.0 metabug for 8.0.1Tom Stellard2019-03-251-1/+1
| | | | llvm-svn: 356924
* Attempt to fix sphinx bot after r356897Nico Weber2019-03-251-1/+1
| | | | llvm-svn: 356923
* AMDGPU: Preserve LiveIntervals in WQMMatt Arsenault2019-03-251-0/+2
| | | | | | This seems to already be done, but wasn't marked. llvm-svn: 356922
* [pstl] Make sure unit tests exit with a non-zero error code when they failLouis Dionne2019-03-251-16/+15
| | | | | | | | The previous test system would only print errors to stderr, however CMake (and lit) detect failure via the program returning a non-zero error code. So all the tests would always pretend they passed. llvm-svn: 356921
* [clang] Remove cmake warning message (NFC)Evandro Menezes2019-03-251-1/+2
| | | | | | Recognize an empty string for CLANG_DEFAULT_UNWINDLIB as a valid option. llvm-svn: 356920
* [llvm-objcopy]Preserve data in segments not covered by sectionsJames Henderson2019-03-254-5/+727
| | | | | | | | | | | | | | | | llvm-objcopy previously knew nothing about data in segments that wasn't covered by section headers, meaning that it wrote zeroes instead of what was there. As it is possible for this data to be useful to the loader, this patch causes llvm-objcopy to start preserving this data. Data in sections that are explicitly removed continues to be written as zeroes. This fixes https://bugs.llvm.org/show_bug.cgi?id=41005. Reviewed by: jakehehrlich, rupprecht Differential Revision: https://reviews.llvm.org/D59483 llvm-svn: 356919
* Cleaup of requirements for optional. While researching LWG3196, I realized ↵Marshall Clow2019-03-252-1/+50
| | | | | | that optional did not reject 'const in_place_t' like it should. Added a test as well, and a check for arrays (which were already disallowed, but now we get a better error message). Should not affect anyone's code. llvm-svn: 356918
* [PSTL][NFC] Add missing #includeLouis Dionne2019-03-251-0/+1
| | | | llvm-svn: 356917
* [clangd] Add .cu files to VSCode extensionIlya Biryukov2019-03-251-1/+11
| | | | | | | | | | | | | | | | | | | | | | Summary: clangd should be able to handle those with a proper compilation database. However, users using 'nvcc' might start seeing spurious errors in '.cu' files after this change. My plan is to land and release this, but be ready to revert in case of negative user feedback. Reviewers: hokein Reviewed By: hokein Subscribers: ioeric, MaskRay, jkorous, arphaman, kadircet, jdoerfert, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D59759 llvm-svn: 356916
* [SLPVectorizer] Update file missed in rL356913Simon Pilgrim2019-03-251-5/+5
| | | | | | Differential Revision: https://reviews.llvm.org/D59738 llvm-svn: 356915
* [x86] add tests for vector zext; NFCSanjay Patel2019-03-251-0/+157
| | | | | | The AVX1 lowering is poor. llvm-svn: 356914
* [SLPVectorizer] reorderInputsAccordingToOpcode - remove non-Instruction ↵Simon Pilgrim2019-03-2545-167/+162
| | | | | | | | | | | | | | canonicalization Remove attempts to commute non-Instructions to the LHS - the codegen changes appear to rely on chance more than anything else and also have a tendency to fight existing instcombine canonicalization which moves constants to the RHS of commutable binary ops. This is prep work towards: (a) reusing reorderInputsAccordingToOpcode for alt-shuffles and removing the similar reorderAltShuffleOperands (b) improving reordering to optimized cases with commutable and non-commutable instructions to still find splat/consecutive ops. Differential Revision: https://reviews.llvm.org/D59738 llvm-svn: 356913
* Revert "[clang-format] Keep protobuf "package" statement on one line"Haojian Wu2019-03-252-9/+3
| | | | | | | | | | | | | This reverts commit r356835. This patch causes a regression, see the test below: verifyFormat("// Detached comment\n\n" "// Leading comment\n" "syntax = \"proto2\"; // trailing comment\n\n" "// in foo.bar package\n" "package foo.bar; // foo.bar package\n"); llvm-svn: 356912
* Update the lldb driver to support the -O and -S options when passing --replAdrian Prantl2019-03-252-125/+144
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | At the moment when --repl is passed to lldb it silently ignores any commands passed via the options below: --one-line-before-file <command> Tells the debugger to execute this one-line lldb command before any file provided on the command line has been loaded. --one-line <command> Tells the debugger to execute this one-line lldb command after any file provided on the command line has been loaded. --source-before-file <file> Tells the debugger to read in and execute the lldb commands in the given file, before any file has been loaded. --source <file> Tells the debugger to read in and execute the lldb commands in the given file, after any file has been loaded. -O <value> Alias for --one-line-before-file -o <value> Alias for --one-line -S <value> Alias for --source-before-file -s <value> Alias for --source The -O and -S options are quite useful when writing tests for the REPL though, e.g. to change settings prior to entering REPL mode. This patch updates the driver to still respect the commands supplied via -O and -S when passing --repl instead of silently ignoring them. As -s and -o don't really make sense in REPL mode, commands supplied via those options are still ignored, but the driver now emits a warning to make that clear to the user. Patch by Nathan Hawes! Differential Revision: https://reviews.llvm.org/D59681 llvm-svn: 356911
* Python 2/3 compat: StringIOSerge Guelton2019-03-258-21/+18
| | | | | | Differential Revision: https://reviews.llvm.org/D59582 llvm-svn: 356910
* Python 2/3 compat: tkinterSerge Guelton2019-03-251-2/+7
| | | | | | Differential Revision: https://reviews.llvm.org/D59586 llvm-svn: 356909
* Python 2/3 compat: str vs basestringSerge Guelton2019-03-258-0/+40
| | | | | | Differential Revision: https://reviews.llvm.org/D59589 llvm-svn: 356908
* Revert 356905Serge Guelton2019-03-251-12/+6
| | | | | | Commited from wrong directory... llvm-svn: 356907
* Python 2/3 compat: queue vs QueueSerge Guelton2019-03-252-4/+10
| | | | | | Differential Revision: https://reviews.llvm.org/D59590 llvm-svn: 356906
* Python 2/3 compat: queue vs QueueSerge Guelton2019-03-251-6/+12
| | | | | | Differential Revision: https://reviews.llvm.org/D59590 llvm-svn: 356905
* Python 2/3 compat: unichr vs chrSerge Guelton2019-03-251-0/+4
| | | | llvm-svn: 356904
* [libc++][CMake] Allow merging libc++abi.a into libc++ even on Apple platformsLouis Dionne2019-03-253-11/+12
| | | | | | | | | | | | | | | | | | | | Summary: I can't see a good reason to disallow this, even though it isn't the standard way we build libc++ for Apple platforms. Making this work on Apple platforms requires using different flags for --whole-archive and removing the -D flag when running `ar` to merge archives because that flag isn't supported by the `ar` shipped on Apple platforms. This shouldn't be an issue since the -D option appears to be enabled by default in GNU `ar`. Reviewers: phosek, EricWF, serge-sans-paille Subscribers: mgorny, christof, jkorous, dexonsmith, libcxx-commits Differential Revision: https://reviews.llvm.org/D59513 llvm-svn: 356903
* [clang-tidy] ClangTidy.h -> ClangTidyCheck.hAlexander Kornienko2019-03-251-1/+1
| | | | llvm-svn: 356902
* MinidumpYAML.cpp: Fix some code standard violations missed during reviewPavel Labath2019-03-251-12/+12
| | | | | | functions should begin with lower case letters. NFC. llvm-svn: 356901
* [pstl][CMake] Move include() closer to its point of useLouis Dionne2019-03-251-2/+1
| | | | llvm-svn: 356900
* [RegAlloc] Simplify MIR testJonas Paulsson2019-03-251-378/+80
| | | | | | | | | | Remove the IR part from test/CodeGen/X86/regalloc-copy-hints.mir (added by r355854). To make the test remain functional, the parts of the MBB names referring to BB names have been removed, as well as all machine memory operands. llvm-svn: 356899
* Minidump: Use minidump constants defined in llvmPavel Labath2019-03-258-195/+64
| | | | | | | | | | | | | | | This patch begins the process of migrating the "minidump" plugin to the minidump parser in llvm. The llvm parser is not fully finished yet, but even now, a lot of things can be switched over. The gradual migration process will allow us to easier detect if things break than doing a big one-step migration. Doing it early will allow us to make sure that the llvm parser fits the use case that we need in lldb. In this patch I start with the various minidump constants, which have their llvm equivalent. It doesn't contain any functional changes. The diff just reflects the different naming of things in llvm. llvm-svn: 356898
* Rename directory housing clang-include-fixer to be eponymousNico Weber2019-03-2573-70/+73
| | | | | | | | | | | Makes the name of this directory consistent with the names of the other directories in clang-tools-extra. Similar to r356254. No intended behavior change. Differential Revision: https://reviews.llvm.org/D59750 llvm-svn: 356897
* Reapply minidump changes reverted in r356806Pavel Labath2019-03-2510-24/+185
| | | | | | | | | The changes were reverted due to ubsan errors (unaligned accesses). Here I fix those errors by first copying the data into aligned storage. Besides fixing alignment issues, this also fixes reading of minidump strings on big-endian systems. llvm-svn: 356896
* [DebugInfo] IntelJitEventListener follow up for "add SectionedAddress ..."Brock Wyma2019-03-251-3/+13
| | | | | | | | | | | | Following r354972 the Intel JIT Listener would not report line table information because the section indices did not match. There was a similar issue with the PerfJitEventListener. This change performs the section index lookup when building the object address used to query the line table information. Differential Revision: https://reviews.llvm.org/D59490 llvm-svn: 356895
* [clangd] Add std subnamespace symbols to the symbol map.Haojian Wu2019-03-252-34/+291
| | | | | | | | | | | | | | Reviewers: ioeric, serge-sans-paille Reviewed By: ioeric Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, kadircet, jdoerfert, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D59364 llvm-svn: 356894
OpenPOWER on IntegriCloud