Commit Graph

219201 Commits

Author SHA1 Message Date
Krzysztof Parzyszek f4467cd1cd [Hexagon] Use back_inserter as target iterator in std::copy
llvm-svn: 256934
2016-01-06 14:13:11 +00:00
Samuel Antao ee8fb302f5 [OpenMP] Reapply rL256842: [OpenMP] Offloading descriptor registration and device codegen.
This patch attempts to fix the regressions identified when the patch was committed initially. 

Thanks to Michael Liao for identifying the fix in the offloading metadata generation 
related with side effects in evaluation of function arguments. 
 

llvm-svn: 256933
2016-01-06 13:42:12 +00:00
Amaury Sechet 457cc4db9e Revert "GlobalsAA: Take advantage of ArgMemOnly, InaccessibleMemOnly and InaccessibleMemOrArgMemOnly attributes"
Summary:
This reverts commit 5a9e526f29cf8510ab5c3d566fbdcf47ac24e1e9.

As per discussion in D15665

This also add a test case so that regression introduced by that diff are not reintroduced.

Reviewers: vaivaswatha, jmolloy, hfinkel, reames

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D15919

llvm-svn: 256932
2016-01-06 13:23:52 +00:00
Johannes Doerfert f9711ef922 Extract constant parts of the schedule generation [NFC]
llvm-svn: 256931
2016-01-06 12:59:23 +00:00
Matthew Simpson bf894faa15 [LV] Avoid creating empty reduction entries (NFC)
This patch prevents us from unintentionally creating entries in the reductions
map for PHIs that are not actually reductions. This is currently not an issue
since we bail out if we encounter PHIs other than inductions or reductions.
However the behavior could become problematic as we add support for additional
recurrence types.

llvm-svn: 256930
2016-01-06 12:50:29 +00:00
Bhushan D. Attarde 6fd916cd0c Fix build warnings after rL256915
llvm-svn: 256929
2016-01-06 12:08:22 +00:00
Pavel Labath e5c9808efd Fix a bug in lldbutil.expect_state_changes
The logic for skipping over the stop-and-restart events was incorrect as it was also skipping the
expectations. Implement it properly. No test is affected by this as they were not encountering
these events, but I encountered this issue when trying to use this function in a new test.

llvm-svn: 256928
2016-01-06 11:40:06 +00:00
Ewan Crawford 070fac02c3 Add LogDump methods to lldb_private::StringList.
This patch eases the printing of iterable string containers.

Author: Luke Drummond <luke.drummond@codeplay.com>
Differential Revision: http://reviews.llvm.org/D15773

llvm-svn: 256927
2016-01-06 11:06:30 +00:00
Sean Eveson b38c32be18 [Analyzer] Change the default SA checkers for PS4
Summary: This patch removes security.*, unix.API and unix.Vfork from the default checkers for PS4.

Reviewers: dcoughlin, zaks.anna

Subscribers: cfe-commits

Differential Revision: http://reviews.llvm.org/D15888

llvm-svn: 256926
2016-01-06 10:03:58 +00:00
Pavel Labath 876ae59cf6 XFAIL TestMiSymbol on linux
new test introduced in r256863 fails on linux.

llvm-svn: 256925
2016-01-06 09:48:54 +00:00
Artyom Skrobov 51f2d11be9 PR25754: avoid generating UDIVREM8_ZEXT_HREG nodes with i64 result
Reviewers: spatel, srking

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D15331

llvm-svn: 256924
2016-01-06 09:41:10 +00:00
Amaury Sechet d3b2c0fd94 Improve load/store to memcpy for aggregate
Summary: It turns out that if we don't try to do it at the store location, we can do it before any operation that alias the load, as long as no operation alias the store.

Reviewers: craig.topper, spatel, dexonsmith, Prazek, chandlerc, joker.eph

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D15903

llvm-svn: 256923
2016-01-06 09:30:39 +00:00
Simon Pilgrim 267163e713 [X86][SSE] There is no zmm addsubpd/addsubps instruction.
Replace the assert in combineShuffleToAddSub with an early out.

llvm-svn: 256922
2016-01-06 09:08:49 +00:00
Simon Pilgrim eaabd64a11 [X86][SSE] An empty target shuffle mask is always a failure.
As discussed on D15378, move the mask.empty() tests to after the switch statement and consider any shuffle decode where the extracted target shuffle mask is empty as a failure.

llvm-svn: 256921
2016-01-06 08:59:32 +00:00
Dimitry Andric 0810739d4c Add -fno-movt frontend option, to disable movt/movw on ARM
Summary:
In rL256641, @davide turned off movt generation by default for FreeBSD.
This was because our ld is very old, and did not support the relocations
for it.  However, Ian Lepore added the support very recently, so we
would like to revert rL256641, and replace it with a new `-fno-movt`
frontend option.  This way, it can be turned off when needed.

Reviewers: dexonsmith, echristo, emaste, davide

Subscribers: andrew, aemerson, rengolin, davide, cfe-commits, ahatanak, emaste

Differential Revision: http://reviews.llvm.org/D15899

llvm-svn: 256920
2016-01-06 07:42:18 +00:00
Eric Christopher 29a50bccb9 Change the set of actions built for external gcc tools.
A gcc tool has an "integrated" assembler (usually gas) that it
will call to produce an object. Let it use that assembler so
that we don't have to deal with assembly syntax incompatibilities.

llvm-svn: 256919
2016-01-06 07:24:45 +00:00
Craig Topper 1b94d9a3cc [X86] Use PS instead of TB for instructions that have PD/XS/XD variations. Use OpSize32 on an instruction that has an OpSize16 variant.
llvm-svn: 256918
2016-01-06 06:18:41 +00:00
Craig Topper 275600390f [X86] Fix an incorrect usage of In32BitMode that should have been Not64BitMode.
llvm-svn: 256917
2016-01-06 06:18:37 +00:00
Philip Reames 2d2fc4adf1 Fix a warning [NFC]
llvm-svn: 256916
2016-01-06 05:53:09 +00:00
Bhushan D. Attarde f2be8df54b [LLDB][MIPS32]Merge emulation of similar instructions
SUMMARY:
    This patch merges emulation of similar instructions into a single function (wherever possible) to remove code duplication.
    
    Reviewers: clayborg
    Subscribers: mohit.bhakkad, sagar, jaydeep, lldb-commits
    Differential Revision: http://reviews.llvm.org/D15886

llvm-svn: 256915
2016-01-06 05:44:02 +00:00
Tobias Grosser 05e71b9f61 ScopInfo: use getStmtForRegionNode to simplify code slightly
llvm-svn: 256914
2016-01-06 05:18:20 +00:00
Jordan Rose 2110f9b135 Add != to YAMLParser's basic_collection_iterator.
...and mark it as merely an input_iterator rather than a forward_iterator,
since it is destructive. And then rewrite == to take advantage of that.

Patch by Alex Denisov!

llvm-svn: 256913
2016-01-06 05:17:12 +00:00
David Majnemer b70e23c390 [SimplifyLibCalls] Teach SimplifyLibCalls about operand bundles
If we replace one call-site with another, be sure to move over any
operand bundles that lingered on the old call-site.

This fixes PR26036.

llvm-svn: 256912
2016-01-06 05:01:34 +00:00
Philip Reames ae050a5703 [BasicAA] Remove special casing of memset_pattern16 in favor of generic attribute inference
Most of the properties of memset_pattern16 can be now covered by the generic attributes and inferred by InferFunctionAttrs.  The only exceptions are:
- We don't yet have a writeonly attribute for the first argument.
- We don't have an attribute for modeling the access size facts encoded in MemoryLocation.cpp.  

Differential Revision: http://reviews.llvm.org/D15879

llvm-svn: 256911
2016-01-06 04:53:16 +00:00
Philip Reames cdf46d1b52 [BasicAA] Delete dead code related to memset/memcpy/memmove intrinsics [NFCI]
We only need to describe the writeonly property of one of the arguments. All of the rest of the semantics are nicely described by existing attributes in Intrinsics.td.

Differential Revision: http://reviews.llvm.org/D15880

llvm-svn: 256910
2016-01-06 04:43:03 +00:00
Philip Reames c86ed0055d Extract helper function to merge MemoryOperand lists [NFC]
In the discussion on http://reviews.llvm.org/D15730, Andy pointed out we had a utility function for merging MMO lists. Since it turned we actually had two copies and there's another review in progress (http://reviews.llvm.org/D15230) which needs the same, extract it into a utility function and clean up the interfaces to make it easier to use with a MachineInstBuilder.

I introduced a pair here to track size and allocation together. I think we should probably move in the direction of the MachineOperandsRef helper class, but I'm leaving that for further work. I want to get the poison state introduced before I make major changes to the interface.

Differential Revision: http://reviews.llvm.org/D15757

llvm-svn: 256909
2016-01-06 04:39:03 +00:00
Junmo Park 3a40237c03 Delete trailing whitespace; NFC
llvm-svn: 256908
2016-01-06 03:53:36 +00:00
Richard Smith 26dfbace82 [modules] When a tag type that was imported from a module is referenced via an
elaborated-type-specifier, create a declaration of it to track that the current
module makes it visible too.

llvm-svn: 256907
2016-01-06 03:52:10 +00:00
Junmo Park 3ec882feed Delete trailing whitespace; NFC
llvm-svn: 256906
2016-01-06 03:41:30 +00:00
Rui Ueyama 5a32c7647e Add comments.
llvm-svn: 256905
2016-01-06 03:16:23 +00:00
Yunzhong Gao 34c0199378 Do not define NOGDI. Mingw defines LOGFONTW type in wingdi.h and the mingw
version of shlobj.h includes shobjidl.h and the latter uses the LOGFONTW type.

llvm-svn: 256904
2016-01-06 03:01:10 +00:00
Rui Ueyama ad87ff7235 Simplify. NFC.
llvm-svn: 256903
2016-01-06 02:52:24 +00:00
Yunzhong Gao d84c13cdb8 Another attempt at fixing the i686-mingw32-RA-on-linux buildbot. I am getting
confused with what version of mingw is actually installed on the buildbot, and
for now I will just assume this is an unknown version which does not ship with
VersionHelpers.h.

llvm-svn: 256902
2016-01-06 02:48:42 +00:00
Yunzhong Gao b15585f0ea Another attempt at fixing the i686-mingw32-RA-on-linux buildbot.
llvm-svn: 256901
2016-01-06 02:32:31 +00:00
Kostya Serebryany 80eb76abf4 [libFuzzer] extend the dictionary mutator to optionally overwrite data with the dict entry
llvm-svn: 256900
2016-01-06 02:13:04 +00:00
Rui Ueyama 52d3b67c1d Rename Comdats -> ComdatGroups.
I usually prefer short names, but in this case the new descriptive
name should improve readability a bit.

llvm-svn: 256899
2016-01-06 02:06:33 +00:00
Rui Ueyama 7c713319b9 Rename SharedFile::parse -> SharedFile::parseRest.
Unlike ObjectFile or ArchiveFile, SharedFile had two parse functions,
parseSoName() and parse(). parse must have been called after parseSoName,
but that requirement was not obvious from their names. (So it looked
like you could call parse() on a shared object file right away.)

This patch rename parseRest. It is now obvious that there's no single
parse function for the shared object file.

llvm-svn: 256898
2016-01-06 01:56:36 +00:00
Douglas Katzman a2ef81fde5 Avoid assert failure on some invalid cc1 options.
Addressing review comment in D13221.

Differential Revision: http://reviews.llvm.org/D15882

llvm-svn: 256897
2016-01-06 01:37:57 +00:00
Yunzhong Gao d7009f31a1 Hopefully fix a mingw32 buildbot (i686-mingw32-RA-on-linux) which does not have
the VersionHelpers.h header.

llvm-svn: 256896
2016-01-06 01:36:45 +00:00
Xinliang David Li a0da6408d6 More fix to coverage documentation
llvm-svn: 256895
2016-01-06 01:23:41 +00:00
Rui Ueyama e69ab10301 Remove redundant this->.
llvm-svn: 256894
2016-01-06 01:14:11 +00:00
Rui Ueyama 9b09369b3d Simplify --whole-archive handling.
Previously, we handle archive files with --whole-archive this way:
create instances of ArchiveFile, call getMembers to obtain memory
buffers of archive members, and create ObjectFiles for the members.
We didn't call anything except getMembers if --whole-archive was
specified.

I noticed that we didn't actually have to create ArchiveFile instaces
at all for that case. All we need is to get a list of memory buffers
for members, which can be done by a non-member function.

This patch removes getMembers member function from ArchiveFile.
Also removed unnecessary code for memory management.

llvm-svn: 256893
2016-01-06 00:51:35 +00:00
Yunzhong Gao fb2a9c4209 Fixing PR25717: fatal IO error writing large outputs to console on Windows.
This patch is similar to the Python issue#11395. We need to cap the output
size to 32767 on Windows to work around the size limit of WriteConsole().
Reference: https://bugs.python.org/issue11395

Writing a test for this bug turns out to be harder than I thought. I am
still working on it (see phabricator review D15705).

Differential Revision: http://reviews.llvm.org/D15553

llvm-svn: 256892
2016-01-06 00:50:06 +00:00
Sanjay Patel 3d07ec973f rangify; NFCI
llvm-svn: 256891
2016-01-06 00:45:42 +00:00
Dan Gohman 797f639e79 [SelectionDAGBuilder] Set NoUnsignedWrap for inbounds gep and load/store offsets.
In an inbounds getelementptr, when an index produces a constant non-negative
offset to add to the base, the add can be assumed to not have unsigned overflow.

This relies on the assumption that addresses can't occupy more than half the
address space, which isn't possible in C because it wouldn't be possible to
represent the difference between the start of the object and one-past-the-end
in a ptrdiff_t.

Setting the NoUnsignedWrap flag is theoretically useful in general, and is
specifically useful to the WebAssembly backend, since it permits stronger
constant offset folding.

Differential Revision: http://reviews.llvm.org/D15544

llvm-svn: 256890
2016-01-06 00:43:06 +00:00
Sanjay Patel 8260d0a9fa use std::max ; NFCI
llvm-svn: 256889
2016-01-06 00:36:59 +00:00
Kate Stone 0167e064f3 Addresses an unsigned underflow situation that can occur when dumping an empty command history.
One example where this occurs in practice is starting the Swift REPL and typing ":command history" since REPL commands aren't stored in the LLDB command prompt history.

llvm-svn: 256888
2016-01-06 00:33:07 +00:00
Anna Zaks 03f483353c [analyzer] Fix false warning about memory leak for QApplication::postEvent
According to Qt documentation Qt takes care of memory allocated for QEvent:
http://doc.qt.io/qt-4.8/qcoreapplication.html#postEvent

A patch by Evgeniy Dushistov!

Differential Revision: http://reviews.llvm.org/D14170

llvm-svn: 256887
2016-01-06 00:32:56 +00:00
Anna Zaks ac4c8a639c [analyzer] Suppress reports coming from std::__independent_bits_engine
The analyzer reports a shift by a negative value in the constructor. The bug can
be easily triggered by calling std::random_shuffle on a vector
(<rdar://problem/19658126>).

(The shift by a negative value is reported because __w0_ gets constrained to
63 by the conditions along the path:__w0_ < _WDt && __w0_ >= _WDt-1,
where _WDt is 64. In normal execution, __w0_ is not 63, it is 1 and there is
no overflow. The path is infeasible, but the analyzer does not know about that.)

llvm-svn: 256886
2016-01-06 00:32:52 +00:00
Anna Zaks c9f16fe48c [analyzer] Don't report null dereferences on address_space annotated memory
llvm-svn: 256885
2016-01-06 00:32:49 +00:00