summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* AMDGPU/GlobalISel: Fix placeholder value used for addrspacecastMatt Arsenault2019-09-052-38/+88
| | | | llvm-svn: 371007
* AMDGPU/GlobalISel: Fix assert on load from constant addressMatt Arsenault2019-09-052-4/+31
| | | | llvm-svn: 371006
* [mir-canon][NFC] Adding -verify-machineinstrs to mir-canon tests.Puyan Lotfi2019-09-052-9/+10
| | | | | | | In the review process for some of the refactoring of MIRCanonicalizationPass it was noted that some of the tests didn't have verifier enabled. Enabling here. llvm-svn: 371005
* [c++20] Fix some ambiguities in our mangling of lambdas with explicitRichard Smith2019-09-056-49/+200
| | | | | | | | | | | | | template parameters. This finishes the implementation of the proposal described in https://github.com/itanium-cxx-abi/cxx-abi/issues/31. (We already implemented the <lambda-sig> extensions, but didn't take them into account when computing mangling numbers, and didn't deal properly with expanded parameter packs, and didn't disambiguate between different levels of template parameters in manglings.) llvm-svn: 371004
* Revert "Revert "[builtins] Rounding mode support for addxf3/subxf3""Yi Kong2019-09-0514-17/+261
| | | | | | | | Test failure fixed. This reverts commit e204d244badb2e9765a1020f41c773f63da208f4. llvm-svn: 371003
* [analyzer] scan-build: handle --sysroot=/path in addition to --sysroot /path.Artem Dergachev2019-09-051-5/+8
| | | | | | | | | | | Current code assumes flags in CompilerLinkerOptionMap don't use =, which isn't always true. Patch by Chris Laplante! Differential Revision: https://reviews.llvm.org/D66569 llvm-svn: 371002
* Reformat the beginning of the testing doc to make clear how to run all the ↵Marshall Clow2019-09-051-5/+8
| | | | | | tests. llvm-svn: 371001
* Use -mtriple to fix AMDGPU test sensitive to object file formatReid Kleckner2019-09-051-3/+3
| | | | | | | GOTPCREL32 doesn't exist on COFF, so it isn't used when this test runs on Windows. llvm-svn: 371000
* [Disassembler] Simplify a few methods (2/2) (NFC)Jonas Devlieghere2019-09-041-52/+62
| | | | | | | Use early returns to highlight preconditions and make the code easier to follow. llvm-svn: 370998
* [AArch64][GlobalISel] Teach AArch64CallLowering to handle basic sibling callsJessica Paquette2019-09-047-9/+321
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for basic sibling call lowering in AArch64. The intent here is to only handle tail calls which do not change the ABI (hence, sibling calls.) At this point, it is very restricted. It does not handle - Vararg calls. - Calls with outgoing arguments. - Calls whose calling conventions differ from the caller's calling convention. - Tail/sibling calls with BTI enabled. This patch adds - `AArch64CallLowering::isEligibleForTailCallOptimization`, which is equivalent to the same function in AArch64ISelLowering.cpp (albeit with the restrictions above.) - `mayTailCallThisCC` and `canGuaranteeTCO`, which are identical to those in AArch64ISelLowering.cpp. - `getCallOpcode`, which is exactly what it sounds like. Tail/sibling calls are lowered by checking if they pass target-independent tail call positioning checks, and checking if they satisfy `isEligibleForTailCallOptimization`. If they do, then a tail call instruction is emitted instead of a normal call. If we have a sibling call (which is always the case in this patch), then we do not emit any stack adjustment operations. When we go to lower a return, we check if we've already emitted a tail call. If so, then we skip the return lowering. For testing, this patch - Adds call-translator-tail-call.ll to test which tail calls we currently lower, which ones we don't, and which ones we shouldn't. - Updates branch-target-enforcement-indirect-calls.ll to show that we fall back as expected. Differential Revision: https://reviews.llvm.org/D67189 llvm-svn: 370996
* [Disassembler] Simplify a few methods (NFC)Jonas Devlieghere2019-09-043-122/+132
| | | | | | | Use early returns to highlight preconditions and make the code easier to follow. llvm-svn: 370994
* For PR43213, track whether template parameters are implicit throughRichard Smith2019-09-042-0/+10
| | | | | | | template instantiation so we know whether to mangle them in lambda-expressions. llvm-svn: 370991
* gn build: Merge r370985Nico Weber2019-09-041-0/+1
| | | | llvm-svn: 370988
* [www] Fix hyperlink syntax in attribute reference.Richard Smith2019-09-041-1/+1
| | | | llvm-svn: 370987
* [www] Update attribute reference for 'constinit'.Richard Smith2019-09-042-3/+11
| | | | llvm-svn: 370986
* [mir-canon][NFC] Move MIR vreg renaming code to separate file for better reuse.Puyan Lotfi2019-09-044-337/+436
| | | | | | | | | | | | | Moving MIRCanonicalizerPass vreg renaming code to MIRVRegNamerUtils so that it can be reused in another pass (ie planing to write a standalone mir-namer pass). I'm going to write a mir-namer pass so that next time someone has to author a test in MIR, they can use it to cleanup the naming and make it more readable by having the numbered vregs swapped out with named vregs. Differential Revision: https://reviews.llvm.org/D67114 llvm-svn: 370985
* [test] Escape path to match the literal stringJonas Devlieghere2019-09-041-1/+1
| | | | | | This test was failing when you had things like `+` in your build path. llvm-svn: 370983
* Diagnose _Atomic as a C11 extension.Aaron Ballman2019-09-044-65/+86
| | | | llvm-svn: 370982
* [DebugInfo] Emit DW_TAG_enumeration_type for referenced global enumerator.Yuanfang Chen2019-09-042-10/+25
| | | | | | | | | | | | | | | | | This essentially reverts changes from r361400 while keeping behavior for CodeView. Reviewers: akhuang, rnk, probinson Reviewed by: rnk Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D67141 llvm-svn: 370981
* AMDGPU/GlobalISel: Select G_BITREVERSEMatt Arsenault2019-09-044-1/+86
| | | | llvm-svn: 370980
* GlobalISel: Add basic legalization for G_BITREVERSEMatt Arsenault2019-09-043-1/+177
| | | | llvm-svn: 370979
* [Attributor][Stats] Use the right statistics macroJohannes Doerfert2019-09-041-2/+2
| | | | llvm-svn: 370976
* [Attributor][Fix] Make sure we do not delete live codeJohannes Doerfert2019-09-044-10/+78
| | | | | | | | | | | | | | Summary: Liveness needs to mark edges, not blocks as dead. Reviewers: sstefan1, uenoku Subscribers: hiraditya, bollu, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D67191 llvm-svn: 370975
* [LLD] [COFF] Implement MinGW default manifest handlingMartin Storsjo2019-09-0410-7/+229
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In mingw environments, resources are normally compiled to resource object files directly, instead of letting the linker convert them to COFF format. Since some time, GCC supports the notion of a default manifest object. When invoking the linker, GCC looks for the default manifest object file, and if found in the expected path, it is added to linker commands. The default manifest is one that indicates support for the latest known versions of windows, to implicitly unlock the modern behaviours of certain APIs. Not all mingw/gcc distributions include this file, but e.g. in msys2, the default manifest object is distributed in a separate package (which can be but might not always be installed). This means that even if user projects only use one single resource object file, the linker can end up with two resource object files, and thus needs to support merging them. The default manifest has a language id of zero, and GNU ld has got logic for dropping a manifest with a zero language id, if there's another manifest present with a nonzero language id. If there are multiple manifests with a nonzero language id, the merging process errors out. Differential Revision: https://reviews.llvm.org/D66825 llvm-svn: 370974
* [c++20] P1143R2: Add support for the C++20 'constinit' keyword.Richard Smith2019-09-0427-77/+385
| | | | | | | | | | | | | This is mostly the same as the [[clang::require_constant_initialization]] attribute, but has a couple of additional syntactic and semantic restrictions. In passing, I added a warning for the attribute form being added after we have already seen the initialization of the variable (but before we see the definition); that case previously slipped between the cracks and the attribute was silently ignored. llvm-svn: 370972
* [NewPM][Sancov] Make Sancov a Module Pass instead of 2 PassesLeonard Chan2019-09-0437-300/+176
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch merges the sancov module and funciton passes into one module pass. The reason for this is because we ran into an out of memory error when attempting to run asan fuzzer on some protobufs (pc.cc files). I traced the OOM error to the destructor of SanitizerCoverage where we only call appendTo[Compiler]Used which calls appendToUsedList. I'm not sure where precisely in appendToUsedList causes the OOM, but I am able to confirm that it's calling this function *repeatedly* that causes the OOM. (I hacked sancov a bit such that I can still create and destroy a new sancov on every function run, but only call appendToUsedList after all functions in the module have finished. This passes, but when I make it such that appendToUsedList is called on every sancov destruction, we hit OOM.) I don't think the OOM is from just adding to the SmallSet and SmallVector inside appendToUsedList since in either case for a given module, they'll have the same max size. I suspect that when the existing llvm.compiler.used global is erased, the memory behind it isn't freed. I could be wrong on this though. This patch works around the OOM issue by just calling appendToUsedList at the end of every module run instead of function run. The same amount of constants still get added to llvm.compiler.used, abd we make the pass usage and logic simpler by not having any inter-pass dependencies. Differential Revision: https://reviews.llvm.org/D66988 llvm-svn: 370971
* Generate parent context id from Decl* instead of DeclContext*.Aaron Ballman2019-09-045-7/+298
| | | | | | | | | | | | | Because of multiple inheritance, a DeclContext pointer does not produce the same pointer representation as a Decl pointer that references the same AST Node. When dumping the parentDeclContextId field of a node, convert the pointer to Decl* first, so the id can be used to find the AST node it references. Patch by Bert Belder. llvm-svn: 370970
* [llvm-rtdyld][llvm-jitlink] Rename struct member to remove ambiguity.Lang Hames2019-09-042-11/+8
| | | | | | | This ambiguity (struct member name matching struct name) was causing errors on a few of the MSVC bots. Hopefully this should fix it. llvm-svn: 370969
* [llvm-rtdyld] Add timers to match llvm-jitlink.Lang Hames2019-09-042-33/+71
| | | | | | | | When using llvm-rtdyld to execute code, -show-times will now show the time taken to load the object files, apply relocations, and execute the rtdyld-linked code. llvm-svn: 370968
* [InstCombine] Add more test cases (NFC)Evandro Menezes2019-09-041-40/+99
| | | | | | Add more test cases simplifying `log()`. llvm-svn: 370966
* [WebAssembly] Initialize memory in start functionThomas Lively2019-09-0421-147/+264
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: - `__wasm_init_memory` is now the WebAssembly start function instead of being called from `__wasm_call_ctors` or called directly by the runtime. - Adds a new synthetic data symbol `__wasm_init_memory_flag` that is atomically incremented from zero to one by the thread responsible for initializing memory. - All threads now unconditionally perform data.drop on all passive segments. - Removes --passive-segments and --active-segments flags and controls segment type based on --shared-memory instead. The deleted flags were only present to ameliorate the upgrade path in Emscripten. Reviewers: sbc100, aheejin Subscribers: dschuff, jgravelle-google, sunfish, jfb, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D65783 llvm-svn: 370965
* Revert "[test] Address TestConcurrentMany*.py flakiness on macOS"Jonas Devlieghere2019-09-041-9/+16
| | | | | | | This reverts my change to pseudo_barrier.h which isn't necessary anymore after Fred's fix to debugserver and caused TestThreadStepOut to fail. llvm-svn: 370963
* [MemorySSA] Re-enable MemorySSA use.Alina Sbirlea2019-09-046-38/+53
| | | | | | Differential Revision: https://reviews.llvm.org/D58311 llvm-svn: 370957
* [Attributor][Fix] Ensure the attribute names are created properlyJohannes Doerfert2019-09-041-1/+3
| | | | | | | The names of the attributes were not always created properly which caused problems with the yaml output. llvm-svn: 370956
* [globalisel] Support trivial COPY in GISelKnownBitsDaniel Sanders2019-09-042-0/+19
| | | | | | | | | | | | | | Summary: Allow GISelKnownBits to look through the trivial case of TargetOpcode::COPY Reviewers: aditya_nandakumar Subscribers: rovka, hiraditya, volkan, Petar.Avramovic, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D67131 llvm-svn: 370955
* [Python] Implement __next__ for value_iterJonas Devlieghere2019-09-042-1/+11
| | | | | | | | | Python 3 iteration calls the next() method instead of next() and value_iter only implemented the Python 2 version. Differential revision: https://reviews.llvm.org/D67184 llvm-svn: 370954
* [Python] Implement truth testing for lldb.valueJonas Devlieghere2019-09-042-0/+7
| | | | | | | | | Python 3 calls __bool__() instead of __len__() and lldb.value only implemented the __len__ method. This adds the __bool__() implementation. Differential revision: https://reviews.llvm.org/D67183 llvm-svn: 370953
* [Python] Fix whitespace before making changes (NFC)Jonas Devlieghere2019-09-041-164/+164
| | | | llvm-svn: 370952
* [JITLink] Fix the show-timers option on llvm-jitlink.Lang Hames2019-09-041-15/+16
| | | | | | | No longer constantly shows times (even when -show-times=false). When shown, times are now correctly grouped. llvm-svn: 370951
* [docs] Add some comments to the inline LLJIT example.Lang Hames2019-09-041-0/+2
| | | | llvm-svn: 370950
* [NFC] Switch last couple of invariant_load checks to use hasMetadataPhilip Reames2019-09-044-4/+4
| | | | llvm-svn: 370948
* [TargetLibraryInfo] Define enumerator for no library function (NFC)Evandro Menezes2019-09-042-2/+4
| | | | | | Add a null enumerator do designate no library function. llvm-svn: 370947
* [InstCombine] sub(xor(x, y), or(x, y)) -> neg(and(x, y))David Bolvansky2019-09-042-20/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: ``` Name: sub(xor(x, y), or(x, y)) -> neg(and(x, y)) %or = or i32 %y, %x %xor = xor i32 %x, %y %sub = sub i32 %xor, %or => %sub1 = and i32 %x, %y %sub = sub i32 0, %sub1 Optimization: sub(xor(x, y), or(x, y)) -> neg(and(x, y)) Done: 1 Optimization is correct! ``` https://rise4fun.com/Alive/8OI Reviewers: lebedev.ri Reviewed By: lebedev.ri Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D67188 llvm-svn: 370945
* [OpenMP] Change initialization of __kmp_globalJonas Hahnfeld2019-09-043-3/+1
| | | | | | | | | | | | | | There's no need to initialize variables with static storage duration because they're implicitly initialized to zero. See https://en.cppreference.com/w/c/language/initialization#Implicit_initialization I think that's already relied upon because the supplied 0 only sets 'kmp_time_global_t g_time;' in 'struct kmp_base_global'. The other fields are not set in the code, but implicitly initialized by the compiler. Differential Revision: https://reviews.llvm.org/D66292 llvm-svn: 370943
* Update CodeGen to use hasMetadata as appropriate [NFC]Philip Reames2019-09-042-12/+11
| | | | | | My intial grepping for rL370933 missed a directory worth of cases. llvm-svn: 370942
* [NFC] Added tests for new foldDavid Bolvansky2019-09-041-0/+120
| | | | llvm-svn: 370941
* [NFC] Adjust test filenameDavid Bolvansky2019-09-041-0/+0
| | | | llvm-svn: 370939
* [X86] Pre-commit test cases and test run line changes for D67087Craig Topper2019-09-045-3/+284
| | | | llvm-svn: 370937
* Add encode and decode methods to InlineInfo and document encoding format to ↵Greg Clayton2019-09-045-0/+305
| | | | | | | | | | the GSYM file format. This patch adds the ability to encode and decode InlineInfo objects and adds test coverage. Error handling is introduced in the encoding and decoding which will be used from here on out for remaining patches. Differential Revision: https://reviews.llvm.org/D66600 llvm-svn: 370936
* [InstCombine] Fold sub (and A, B) (or A, B)) to neg (xor A, B)David Bolvansky2019-09-042-20/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: ``` Name: sub(and(x, y), or(x, y)) -> neg(xor(x, y)) %or = or i32 %y, %x %and = and i32 %x, %y %sub = sub i32 %and, %or => %sub1 = xor i32 %x, %y %sub = sub i32 0, %sub1 Optimization: sub(and(x, y), or(x, y)) -> neg(xor(x, y)) Done: 1 Optimization is correct! ``` https://rise4fun.com/Alive/VI6 Found by @lebedev.ri. Also author of the proof. Reviewers: lebedev.ri, spatel Reviewed By: lebedev.ri Subscribers: llvm-commits, lebedev.ri Tags: #llvm Differential Revision: https://reviews.llvm.org/D67155 llvm-svn: 370934
OpenPOWER on IntegriCloud