summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Tweak some atomics functions in preparation for larger changes; NFC.James Y Knight2016-03-1617-56/+58
| | | | | | | | | | | | | | | | - Rename getATOMIC to getSYNC, as llvm will soon be able to emit both '__sync' libcalls and '__atomic' libcalls, and this function is for the '__sync' ones. - getInsertFencesForAtomic() has been replaced with shouldInsertFencesForAtomic(Instruction), so that the decision can be made per-instruction. This functionality will be used soon. - emitLeadingFence/emitTrailingFence are no longer called if shouldInsertFencesForAtomic returns false, and thus don't need to check the condition themselves. llvm-svn: 263665
* [ELF] SHF_MERGE section with 0 entsize is not fatalEd Maste2016-03-164-5/+7
| | | | | | | | | | For now just treat such sections as non-mergeable. Resubmit r263660 with test fix. Differential Revision: http://reviews.llvm.org/D18225 llvm-svn: 263664
* [SelectionDAG] Extract out populateCallLoweringInfo; NFCSanjoy Das2016-03-163-30/+31
| | | | | | | | | SelectionDAGBuilder::populateCallLoweringInfo is now used instead of SelectionDAGBuilder::lowerCallOperands. The populateCallLoweringInfo interface is more composable in face of design changes like http://reviews.llvm.org/D18106 llvm-svn: 263663
* [ProfileData] Make a utility method public, NFCVedant Kumar2016-03-162-2/+8
| | | | | | | | | | | The swift frontend needs to be able to look up PGO function name variables based on the original raw function name. That's because it's not possible to create PGO function name variables while emitting swift IR. Instead, we have to create the name variables while lowering swift IR to llvm IR, at which point we fix up all calls to the increment intrinsic to point to the right name variable. llvm-svn: 263662
* Revert r263660 as one of the tests is broken.Ed Maste2016-03-161-3/+1
| | | | llvm-svn: 263661
* [ELF] SHF_MERGE section with 0 entsize is not fatalEd Maste2016-03-161-1/+3
| | | | | | | | For now just treat such sections as non-mergeable. Differential Revision: http://reviews.llvm.org/D18222 llvm-svn: 263660
* Add __unconstref for future useEric Fiselier2016-03-161-0/+5
| | | | llvm-svn: 263659
* AMDGPU: Prevent uniform loops from becoming infiniteNicolai Haehnle2016-03-162-0/+34
| | | | | | | | | | | | | | Summary: Uniform loops where the branch leaving the loop is predicated on VCCNZ must be skipped if EXEC = 0, otherwise they will be infinite. Reviewers: tstellarAMD, arsenm Subscribers: arsenm, llvm-commits Differential Revision: http://reviews.llvm.org/D18137 llvm-svn: 263658
* [Hexagon] Adding missing break in switch statement. Extra operands would ↵Colin LeMahieu2016-03-161-0/+1
| | | | | | have been appended to the end. llvm-svn: 263657
* [SLP] Make DataLayout a member variable.Chad Rosier2016-03-161-38/+35
| | | | llvm-svn: 263656
* Revert "[LSR] Create fewer redundant instructions."Geoff Berry2016-03-162-56/+20
| | | | | | This reverts commit r263644. Investigating bootstrap failures. llvm-svn: 263655
* [OPENMP] Support for codegen of private clause of target, host sideCarlo Bertolli2016-03-162-1/+269
| | | | | | | | This patch adds support for codegen of private clause of target and a regression test for host code generation, when the host is used as target device. I believe that code generation for nvptx backend would not require anything additional or different to what is done for the host. http://reviews.llvm.org/D18105 llvm-svn: 263654
* Split relaxTls into one per relaxation type.Rafael Espindola2016-03-162-186/+187
| | | | | | This reduces code duplication in each target. llvm-svn: 263653
* Add an optional string argument to DeprecatedAttr for Fix-It.Manman Ren2016-03-168-6/+116
| | | | | | | | We only add this to __attribute__((deprecated)). Differential Revision: http://reviews.llvm.org/D17865 llvm-svn: 263652
* [CMake] Fix Windows build problem for CMake versions < 3.3Jonathan Peyton2016-03-161-4/+5
| | | | | | | | | | | | Building libomp using CMake versions < 3.3 caused a link time error. These errors occurred because when assembling z_Windows_NT-586_asm.asm, the definitions: OMPT_SUPPORT, _M_AMD64|_M_IA32 weren't defined on the command line. To fix the problem, the COMPILE_FLAGS property for the assembly file is appended to instead of the COMPILE_DEFINITIONS property being set. For whatever reason, the COMPILE_DEFINITIONS property doesn't pick up the definitions for assembly files for the older CMake versions. llvm-svn: 263651
* Removed trailing whitespaceSimon Pilgrim2016-03-161-12/+12
| | | | llvm-svn: 263650
* [X86] Reduced alignment of widened vector load/stores to better match ↵Simon Pilgrim2016-03-162-28/+76
| | | | | | PR26953 cases llvm-svn: 263649
* add checks for 'unpredictable' metadata preservationSanjay Patel2016-03-161-8/+11
| | | | llvm-svn: 263648
* Add attributes for preserve_mostcc/preserve_allcc calling conventions to the ↵Roman Levenstein2016-03-1615-3/+194
| | | | | | | | | | | | | | | C/C++ front-end Till now, preserve_mostcc/preserve_allcc calling convention attributes were only available at the LLVM IR level. This patch adds attributes for preserve_mostcc/preserve_allcc calling conventions to the C/C++ front-end. The code was mostly written by Juergen Ributzka. I just added support for the AArch64 target and tests. Differential Revision: http://reviews.llvm.org/D18025 llvm-svn: 263647
* fix function names; NFCSanjay Patel2016-03-161-58/+60
| | | | llvm-svn: 263646
* [msan] Add a comment with a bug link.Evgeniy Stepanov2016-03-161-0/+3
| | | | llvm-svn: 263645
* [LSR] Create fewer redundant instructions.Geoff Berry2016-03-162-20/+56
| | | | | | | | | | | | | | | | | Summary: Fix LSRInstance::HoistInsertPosition() to check the original insert position block first for a canonical insertion point that is dominated by all inputs. This leads to SCEV being able to reuse more instructions since it currently tracks the instructions it creates for reuse by keeping a table of <Value, insert point> pairs. Reviewers: atrick Subscribers: mcrosier, mzolotukhin, llvm-commits Differential Revision: http://reviews.llvm.org/D18001 llvm-svn: 263644
* [tsan] Detect uses of uninitialized, destroyed and invalid mutexesKuba Brecka2016-03-169-1/+54
| | | | | | | | This patch adds a new TSan report type, ReportTypeMutexInvalidAccess, which is triggered when pthread_mutex_lock or pthread_mutex_unlock returns EINVAL (this means the mutex is invalid, uninitialized or already destroyed). Differential Revision: http://reviews.llvm.org/D18132 llvm-svn: 263641
* [X86] Regenerated + extended widened vector conversion testsSimon Pilgrim2016-03-164-15/+339
| | | | | | | - Ensure we test X86 + X64 - sitopfp / uitofp requires testing for SSE2 and SSE42 as well (part of the fix for PR26953) llvm-svn: 263640
* Fix destructor definition of invalid classesOlivier Goffart2016-03-162-9/+19
| | | | | | | | | | | | The declaration of the destructor of an invalid class was not properly marked as noexcept. As a result, the definition of the same destructor, which was properly implicitly marked as noexcept, would not match the definition. This would cause the definition CXXDestructorDecl to be matked as invalid and omited from the AST. Differential Revision: http://reviews.llvm.org/D17988 llvm-svn: 263639
* Add visualizers for more clang types. Create more C++-like visualizations ↵Mike Spertus2016-03-161-20/+85
| | | | | | | | | | | | | | | | | for existing Clang types Created visualizer for PointerType, LValueReferenceType, RValueReferenceType, and TemplateParmType. In addition, cleaned up the display of existing types to be more C++-like. For example, instead of SubstTemplateTypeParmType: {Identifier (("T"))} => Record (25), {Identifier (("A"))} it now displays more readably as SubstTemplateTypeParmType: {typename T <= struct A} The <expand> sections still can be used for all the gory details if necessary. llvm-svn: 263638
* Fix null pointer "dereference" in DomainSocketPavel Labath2016-03-161-1/+1
| | | | | | offsetof is the official way to get the offset of a field in a structure. llvm-svn: 263637
* Revert r263617, "Reapply: [VFS] Add support for handling path traversals"NAKAMURA Takumi2016-03-164-269/+24
| | | | | | It broke standalone clang build. llvm-svn: 263636
* Directly get the canonical Type instead of going around through a ↵Yaron Keren2016-03-161-1/+1
| | | | | | CanQualType temporary, NFC. llvm-svn: 263635
* [modules] Fix adding a templated friend functions to a namespace from ↵Vassil Vassilev2016-03-165-2/+66
| | | | | | | | | | | | | | another module. When clang adds argument dependent lookup candidates, it can perform template instantiation. For example, it can instantiate a templated friend function and register it in the enclosing namespace's lookup table. Fixes https://llvm.org/bugs/show_bug.cgi?id=24954 Reviewed by Richard Smith. llvm-svn: 263634
* Switch from unittest2.expectedFailure to our own decorator on TestSTLPavel Labath2016-03-161-2/+1
| | | | | | | the main reason is that our decorator contains extra fluff to "expect" crashes (which seem to happen occasionaly on the android buildbot). llvm-svn: 263633
* Add more ARM Cortex-R8 regression tests to Clang.Pablo Barrio2016-03-164-10/+19
| | | | | | | | | | | | | | Summary: This patch adds Clang tests for Cortex-R8 related to FP capabilities and hardware integer divide. Reviewers: rengolin, bsmith Subscribers: aemerson, cfe-commits, rengolin Differential Revision: http://reviews.llvm.org/D18193 llvm-svn: 263632
* Mark an LLGS test as flakyPavel Labath2016-03-161-0/+1
| | | | | cause: Async output arrival over pty llvm-svn: 263631
* Avoid using LookupResult's implicit copy ctor and assignment operator to ↵Marina Yatsina2016-03-162-11/+24
| | | | | | | | | | | | | avoid warnings The purpose of this patch is to keep the same functionality without using LookupResult's implicit copy ctor and assignment operator, because they cause warnings when -Wdeprecated is passed. This patch is meant to help the following review: http://reviews.llvm.org/D18123. The functionality is covered by the tests in my original commit (255890) The test case in this patch was added to test a bug caught in the review of the first version of this fix. Differential Revision: http://reviews.llvm.org/D18175 llvm-svn: 263630
* [test] Persist packets between expect_gdbremote_sequence invocationsPavel Labath2016-03-163-30/+41
| | | | | | | | | | | | | | | | | | | | | | Summary: Some tests (Hc_then_Csignal_signals_correct_thread, at least) were sending a "continue" packet in one expect_gdbremote_sequence invocation, and "expecting" the stop-reply in another call. This posed a problem, because the were packets were not persisted between the two invocations, and if the stub was exceptionally fast to respond, the packet would be received in the first invocation (where it would be ignored) and then the second invocation would fail because it could not find the packet. Since doing matching in two invocations seems like a reasonable use of the packet pump, instead of fixing the test, I make sure the packet_pump supports this usage by making the list of captured packets persistent. Reviewers: tfiala Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D18140 llvm-svn: 263629
* Fix thread/process ID reading from linux core filesPavel Labath2016-03-168-2/+96
| | | | | | | | | | | | | | | | | Summary: This also adds a basic smoke test for linux core file reading. I'm checking in the core files as well, so that the tests can run on all platforms. With some tricks I was able to produce reasonably-sized core files (~40K). This fixes the first part of pr26322. Reviewers: zturner Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D18176 llvm-svn: 263628
* AMDGPU: Verify instructions in non-debug builds as wellMichel Danzer2016-03-161-3/+3
| | | | | | | | | | | | And emit an error if it fails. This prevents illegal instructions from getting sent to the GPU, which would potentially result in a hang. This is a candidate for the stable branch(es). Reviewed-by: Marek Olšák <marek.olsak@amd.com> llvm-svn: 263627
* AMDGPU/SI: Clean up indentation in SIInstrInfo::getDefaultRsrcDataFormatMichel Danzer2016-03-161-3/+3
| | | | | Reviewed-by: Tom Stellard <thomas.stellard@amd.com> llvm-svn: 263626
* Move OperatingSystem plugins to SystemInitializerFullPavel Labath2016-03-162-11/+12
| | | | | | | | | | | | Summary: These are not needed in lldb-server. Removing them shrinks the server size by about 1.5%. Reviewers: zturner Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D18188 llvm-svn: 263625
* AVX512BW: Fix SRA v64i8 lowering. Use PCMPGTM (cmp result in k register) for ↵Igor Breger2016-03-162-0/+23
| | | | | | | | 512bit vector because PCMPGT supported only for 128/256bit. Differential Revision: http://reviews.llvm.org/D18204 llvm-svn: 263624
* Revert r263622, "clang/lib/Frontend/ModuleDependencyCollector.cpp: Use ↵NAKAMURA Takumi2016-03-161-1/+1
| | | | | | | | clang/Config/config.h instead of llvm's." I'll commit better fix(es) later. "llvm/Config/config.h" shouldn't be available here. llvm-svn: 263623
* clang/lib/Frontend/ModuleDependencyCollector.cpp: Use clang/Config/config.h ↵NAKAMURA Takumi2016-03-161-1/+1
| | | | | | instead of llvm's. llvm-svn: 263622
* [ASAN] Add support for mips/mips64 androidMohit K. Bhakkad2016-03-165-28/+50
| | | | | | | | | | | | Patch by Duane Sand Reviewers: samsonov Subscribers: duanesand, jaydeep, sagar, llvm-commits, filcab. Differential Revision: http://reviews.llvm.org/D17883 llvm-svn: 263621
* [Bitcode] Add compatibility test for the 3.8 releaseVedant Kumar2016-03-162-0/+1590
| | | | | | | Fork off compatibility.ll for the 3.8 release. The *.bc file in this commit was produced using a Release build of the release_38 branch. llvm-svn: 263620
* [JumpThreading] See through Cast InstructionsHaicheng Wu2016-03-162-0/+53
| | | | | | To capture more jump-thread opportunity. llvm-svn: 263618
* Reapply: [VFS] Add support for handling path traversalsBruno Cardoso Lopes2016-03-164-24/+269
| | | | | | | | | | | | | | | | | | | | | | | | | | This is originally r261551, reverted because of windows bots failing on unittests. Change the current behavior to do not handle path traversals on windows. Handle ".", ".." and "./" with trailing slashes while collecting files to be dumped into the vfs overlay directory. Include the support for symlinks into components. Given the path: /install-dir/bin/../lib/clang/3.8.0/include/altivec.h, if "bin" component is a symlink, it's not safe to use `path::remove_dots` here, and `realpath` is used to get the right answer. Since `realpath` is expensive, we only do it at collecting time (which only happens during the crash reproducer) and cache the base directory for fast lookups. Overall, this makes the input to the VFS YAML file to be canonicalized to never contain traversal components. Differential Revision: http://reviews.llvm.org/D17104 rdar://problem/24499339 llvm-svn: 263617
* Add clang thread safety annotations to mutex and lock_guard. Patch by ↵Eric Fiselier2016-03-168-8/+154
| | | | | | | | | | | | | | | jamesr@google.com. This adds clang thread safety annotations to std::mutex and std::lock_guard so code using these types can use these types directly instead of having to wrap the types to provide annotations. These checks when enabled by -Wthread-safety provide simple but useful static checking to detect potential race conditions. See http://clang.llvm.org/docs/ThreadSafetyAnalysis.html for details. This patch was reviewed in http://reviews.llvm.org/D14731. llvm-svn: 263611
* [Support] Update Error unit test to remove implementation specific behaviour.Lang Hames2016-03-161-2/+1
| | | | llvm-svn: 263610
* [Support] Add the 'Error' class for structured error handling.Lang Hames2016-03-165-0/+1378
| | | | | | | | | | | | | | | | | This patch introduces the Error classs for lightweight, structured, recoverable error handling. It includes utilities for creating, manipulating and handling errors. The scheme is similar to exceptions, in that errors are described with user-defined types. Unlike exceptions however, errors are represented as ordinary return types in the API (similar to the way std::error_code is used). For usage notes see the LLVM programmer's manual, and the Error.h header. Usage examples can be found in unittests/Support/ErrorTest.cpp. Many thanks to David Blaikie, Mehdi Amini, Kevin Enderby and others on the llvm-dev and llvm-commits lists for lots of discussion and review. llvm-svn: 263609
* [X86] Regenerated widen load testsSimon Pilgrim2016-03-161-94/+127
| | | | llvm-svn: 263608
OpenPOWER on IntegriCloud