Commit Graph

209309 Commits

Author SHA1 Message Date
Oleksiy Vyalov e7eabbb550 Make remote-android platform to use dynamic local tcp ports when forwarding device ports.
http://reviews.llvm.org/D12510

llvm-svn: 246574
2015-09-01 19:02:14 +00:00
Eli Bendersky 8ea8b343c4 Fix typo in test
llvm-svn: 246573
2015-09-01 18:56:19 +00:00
Benjamin Kramer cbf9bc35d2 Remove OutputBuffer.
This was last used by the pre-MC object emitter and has been dead for
quite a while. We have better ways to emit endian-dependent stuff now.

llvm-svn: 246571
2015-09-01 18:25:34 +00:00
Zachary Turner 81ab77d424 Un-XFAIL a couple tests that are now passing.
llvm-svn: 246570
2015-09-01 18:25:05 +00:00
Zachary Turner bc556d382b XFAIL TestHelloWorld on Windows.
https://llvm.org/pr24600

llvm-svn: 246569
2015-09-01 18:24:49 +00:00
Enrico Granata 980c0484c5 Add support for language plugins to provide data formatters (second attempt)
Historically, data formatters all exist in a global repository (the category map)
On top of that, some formatters can be "hardcoded" when the conditions under which they apply are not expressible as a typename (or typename regex)

This change paves the way to move formatters into per-language buckets such that the C++ plugin is responsible for ownership of the C++ formatters, and so on
The advantages of this are:
a) language formatters only get created when they might apply
b) formatters for a language are clearly owned by the matching language plugin

The current model is one of static instantiation, that is a language knows the full set of formatters it vends and that is only asked-for once, and then handed off to the FormatManager
In a future revision it might be interesting to add similar ability to the language runtimes, and monitor for certain shared library events to add even more library-specific formatters

No formatters are moved as part of this change, so practically speaking this is NFC

llvm-svn: 246568
2015-09-01 18:22:39 +00:00
Tobias Grosser 2df884f95a ScopInfo: use project_out instead of remove_dims
By just removing dimensions (and the constraints they are involved in) we
may loose information about the dimensions we do not remove. By instead
using project_out, we are sure all constraints on the outer dimensions are
preserved.

No test case, as this error condition is very unlikely to be triggered by
isl's current code. We still 'fix' this, as isl gives little guarantees
regarding the behavior of remove_divs.

llvm-svn: 246567
2015-09-01 18:17:41 +00:00
Reid Kleckner a71dabd591 Mark the log_path ubsan test as requiring a shell. It uses globs.
llvm-svn: 246566
2015-09-01 18:17:21 +00:00
Eric Christopher e9cdcaee7b Pull initFeatureMap out of line now that it's used in multiple places.
llvm-svn: 246565
2015-09-01 18:13:20 +00:00
Hans Wennborg dada1d20ba DeadArgElim: don't eliminate arguments from naked functions
Differential Revision: http://reviews.llvm.org/D12534

llvm-svn: 246564
2015-09-01 18:06:46 +00:00
Sean Callanan 761844be66 When looking up types, find the first type we can import rather than just taking
the first type we find and failing if it can't be imported.

llvm-svn: 246563
2015-09-01 18:00:35 +00:00
Sean Callanan 77bc4d12c7 Add a predicate to allow a ClangASTContext to identify Clang types.
llvm-svn: 246562
2015-09-01 17:58:03 +00:00
Artem Belevich 020d4fb17f New bitcode linker flags:
-only-needed -- link in only symbols needed by destination module
-internalize -- internalize linked symbols

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

llvm-svn: 246561
2015-09-01 17:55:55 +00:00
Ed Maste 6194363b31 Exclude COFF/export-exe.test on non-Windows
llvm-svn: 246559
2015-09-01 17:26:33 +00:00
Adrian McCarthy 6c3d03c468 Implement DoReadMemory for Windows mini dumps.
Differential Revision: http://reviews.llvm.org/D12507

llvm-svn: 246558
2015-09-01 16:59:31 +00:00
Chaoren Lin c963a222f1 Make ProcessGDBRemote get a //copy// of platform Unix signals.
Summary: Update to http://reviews.llvm.org/rL243618.

Reviewers: jaydeep, clayborg

Subscribers: labath, tberghammer, lldb-commits

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

llvm-svn: 246557
2015-09-01 16:58:45 +00:00
Davide Italiano 0ca250853c [llvm-readobj] MachO -- correctly dump section field 'Reserved3'
Before we incorrectly ignored it.

llvm-svn: 246556
2015-09-01 16:29:02 +00:00
Ahmed Bougacha b0ff6437cb [AArch64] Lower READCYCLECOUNTER using MRS PMCCTNR_EL0.
This matches the ARM behavior. In both cases, the register is part
of the optional Performance Monitors extension, so, add the feature,
and enable it for the A-class processors we support.

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

llvm-svn: 246555
2015-09-01 16:23:45 +00:00
David Majnemer abdb2d2aba [MC] Allow MCObjectWriter's output stream to be swapped out
There are occasions where it is useful to consider the entirety of the
contents of a section.  For example, compressed debug info needs the
entire section available before it can compress it and write it out.
The compressed debug info scenario was previously implemented by
mirroring the implementation of writeSectionData in the ELFObjectWriter.

Instead, allow the output stream to be swapped on demand.  This lets
callers redirect the output stream to a more convenient location before
it hits the object file.

No functionality change is intended.

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

llvm-svn: 246554
2015-09-01 16:19:03 +00:00
Davide Italiano 491d3bfd43 [COFF] Remove dead private field. Also fixes build with -Werror.
llvm-svn: 246553
2015-09-01 16:05:53 +00:00
Tobias Grosser f560ca90ef Update isl to isl-0.15-129-gb086c90
llvm-svn: 246552
2015-09-01 15:42:13 +00:00
Igor Breger f6f1bb6ddc AVX512: Implemented intrinsics for valign.
Differential Revision: http://reviews.llvm.org/D12526

llvm-svn: 246551
2015-09-01 15:27:18 +00:00
Angel Garcia Gomez 692cbb5bb0 Fix several corner cases for loop-convert check.
Summary: Reduced the amount of wrong conversions of this check.

Reviewers: klimek

Subscribers: alexfh, cfe-commits

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

llvm-svn: 246550
2015-09-01 15:05:15 +00:00
Pavel Labath 7a9495bcd5 [NativeProcessLinux] Fix detach of multithreaded inferiors
When detaching, we need to detach from all threads of the inferior and not just the main one.
Without this, a multi-threaded inferior would usually crash once the server exits.

llvm-svn: 246549
2015-09-01 15:00:51 +00:00
Aaron Ballman 6924dcdf6f Add a new frontend warning for referencing members from the handler of a constructor or destructor function-try-block, which is UB in C++.
This corresponds to the CERT secure coding rule ERR53-CPP.

llvm-svn: 246548
2015-09-01 14:49:24 +00:00
Sanjay Patel c413558842 use CHECK-LABEL for more precision
llvm-svn: 246547
2015-09-01 14:35:05 +00:00
Aaron Ballman 6a4a210126 Reverting r246497 (which requires also reverting r246524 and r246521 to avoid merge conflicts). It broke the build on MSVC 2015. It also broke an MSVC 2013 bot with testing issues.
llvm\tools\clang\lib\serialization\MultiOnDiskHashTable.h(117):
error C2065: 'Files': undeclared identifier

http://bb.pgr.jp/builders/ninja-clang-i686-msc18-R/builds/2917

llvm-svn: 246546
2015-09-01 13:24:39 +00:00
Andrew Wilkins 3b138079c9 [llgo] drop debug/DIBuilder.Declare
Summary:
Companion to D11864, which updates the
DIBuilder bindings to match a recent
change in the underlying API.

We drop the debug/DIBuilder.Declare method
for now, which is unused, as otherwise it will
be broken with the new DIBuilder API in the
Go bindings.

Reviewers: pcc

Subscribers: llvm-commits

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

llvm-svn: 246545
2015-09-01 11:52:37 +00:00
Tobias Grosser 1dcfb7a1e6 ScopInfo: Add test case for two loops following right after each other
This case probably does not happen for LLVM generated code that is in loop
simplify form, but Polly does support such kind of loops. This commit ensures we
have test coverage as well.

llvm-svn: 246543
2015-09-01 11:33:13 +00:00
Silviu Baranga 755ec0e027 [AArch64] Turn on by default interleaved access vectorization
Summary:
This change turns on by default interleaved access vectorization
for AArch64.

We also clean up some tests which were spedifically enabling this
behaviour.

Reviewers: rengolin

Subscribers: aemerson, llvm-commits, rengolin

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

llvm-svn: 246542
2015-09-01 11:26:46 +00:00
Silviu Baranga e748c9ef55 [ARM] Turn on by default interleaved access vectorization
Summary:
This change turns on by default interleaved access vectorization on ARM,
as it has shown to be beneficial on ARM.

Reviewers: rengolin

Subscribers: aemerson, llvm-commits, rengolin

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

llvm-svn: 246541
2015-09-01 11:19:15 +00:00
Silviu Baranga 6d3f05c04b [ARM][AArch64] Turn on by default interleaved access lowering
Summary:
Interleaved access lowering removes a memory operation and a
sequence of vector shuffles and replaces it with a series of
memory operations. This should be always beneficial.

This pass in only enabled on ARM/AArch64.

Reviewers: rengolin

Subscribers: aemerson, llvm-commits, rengolin

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

llvm-svn: 246540
2015-09-01 11:12:35 +00:00
Pavel Labath 86852d3676 [NativeProcessLinux] Fix assertion failure when killing a process
Linux sometimes sends us a PTRACE_EVENT_EXIT when an inferior process gets a SIGKILL. This can be
confusing, since normally we don't expect any events when the inferior is stopped. This commit
adds code to handle this situation (resume the thread and let it exit normally) and avoid an
assertion failure in ResumeThread().

llvm-svn: 246539
2015-09-01 10:59:36 +00:00
Yaron Keren 55f5c3d43b Fix typo.
llvm-svn: 246538
2015-09-01 10:13:49 +00:00
Rui Ueyama 100ffacf2c COFF: .exe files should be able to export functions.
In r246424, I made a change that disables non-DLL to export
symbols. It turned out that the change was not correct. Both
DLLs and executables are able to export symbols (although the
latter is relatively rare). This change restores the feature.

llvm-svn: 246537
2015-09-01 09:15:58 +00:00
Pavel Labath f15a16704b Revert "Add support for language plugins to provide data formatters"
This reverts r246515 (and related cmake fixes) as it breaks all libcxx tests.

llvm-svn: 246536
2015-09-01 09:02:54 +00:00
Rui Ueyama dfff2542b8 COFF: Make import libraries compatible with MSVC link.
I have totally no idea why, but MSVC linker is sensitive about
file names of archive members. If we do not make import library
file names to the same as the DLL name, MSVC link *crashes*
when it is processing the library file. This patch is to set
the same name.

llvm-svn: 246535
2015-09-01 08:08:57 +00:00
Richard Smith 6307849666 [modules] When emitting line tables, only emit filenames that are actually referenced by the entries that we emit.
llvm-svn: 246534
2015-09-01 07:41:55 +00:00
Rui Ueyama 84f9218417 COFF: Set "Data" bit for data symbols in the import descriptor.
llvm-svn: 246533
2015-09-01 06:46:10 +00:00
Rui Ueyama b355fd0308 Object: Fix COFF import file's symbols.
If a symbol is marked as "data", the symbol should be exported
with __imp_ prefix. Previously, the symbol was exported as-is.

llvm-svn: 246532
2015-09-01 06:01:53 +00:00
Justin Bogner 1ded69870e cmake: Error instead of warning and dropping invalid LLVM_USE_SANITIZER
Currently, if you call cmake with a typo in an LLVM_USE_SANITIZER
value, there's a cmake warning and the build goes on with no
sanitizers at all. This isn't a good behaviour, since cmake warnings
are fairly easy to miss and the resulting behaviour is that it looks
like the build is sanitizer clean.

Upgrade these warnings to errors so misconfigurations are more
obvious.

llvm-svn: 246531
2015-09-01 05:45:07 +00:00
Jason Molenda bf67a30bdd A few small comment fixups with terminology "gcc" -> "eh_frame", "gdb" -> "stabs".
Just noticed these while reading through some code.

llvm-svn: 246530
2015-09-01 05:17:01 +00:00
Bruce Mitchener ee188ba20e [lldb-mi] Use find, not find_first_of, for "--".
Summary:
find_first_of will look for any of the characters, not the full
string passed in. When looking for "--" then, we must use find
and not find_first_of.

Reviewers: ki.stfu, abidh

Subscribers: lldb-commits

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

llvm-svn: 246529
2015-09-01 04:36:54 +00:00
Saleem Abdulrasool 520aaa2f7d unwind: cleanup -Wunused-parameter
Cleanup a number of `-Wunused-parameter` warnings.  NFC.

llvm-svn: 246528
2015-09-01 04:29:03 +00:00
Andrew Wilkins 9211396d82 Enable linking tools, shared libraries against libLLVM
Summary:
Three closely related changes, to have a mode in which we link all
executables and shared libraries against libLLVM. 

1. Add a new LLVM_LINK_LLVM_DYLIB cmake option, which, when ON, will link
   executables and shared libraries against libLLVM. For this to work, it
   is necessary to also set LLVM_BUILD_LLVM_DYLIB and LLVM_DYLIB_EXPORT_ALL.

   It is not strictly necessary to set LLVM_DISABLE_LLVM_DYLIB_ATEXIT, but
   we also default to OFF in this mode, or tools tend to misbehave (e.g.
   stdout may not flush on exit when output is buffered.)

   llvm-config and Tablegen do not use libLLVM, as they are dependencies of
   libLLVM.

2. Modify llvm-go to take a new flag, "linkmode=component-libs|dylib".
   Depending on which one is passed (default is component-libs), we link
   with the individual libraries or libLLVM respectively. We pass in dylib
   when LLVM_LINK_LLVM_DYLIB is ON.

3. Fix LLVM_DYLIB_EXPORT_ALL on Linux, and expand the symbols exported to
   actually export all. Don't strip leading underscore from symbols on Linux,
   and make sure we get all exported symbols and weak-with-default symbols
   ("W" in nm output). Without these changes, passes won't load because
   the "Annotate..." symbols defined in lib/Support/Valigrind.cpp are not
   found.

Testing:
 - Ran default build ("ninja") with LLVM, clang, compiler-rt, llgo, lldb.
 - Ran "check", "check-clang", "check-tsan", "check-libgo" targets. I've
   never had much success with LLDB tests, and llgoi is currently broken
   so check-llgo fails for an unrelated reason.
 - Ran "lldb" to ensure it loads.

Reviewers: chandlerc, beanz, pcc, rnk

Subscribers: rnk, chapuni, sylvestre.ledru, llvm-commits

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

llvm-svn: 246527
2015-09-01 03:14:31 +00:00
Richard Smith b5aaf5a57a Don't use fprintf to emit this diagnostic!
llvm-svn: 246526
2015-09-01 02:35:58 +00:00
Matt Arsenault 51d2d0f668 AMDGPU: Fix adding redundant implicit operands
These are already added during the MachineInstr construction,
so this was adding the implicit registers twice.

llvm-svn: 246525
2015-09-01 02:02:21 +00:00
Richard Smith 86f14e09a6 Use a more appropriate way of writing 1.
llvm-svn: 246524
2015-09-01 02:02:09 +00:00
David Majnemer 7f0674d6f0 [MS ABI] Cleanup get*ForUnnamedTagDecl
Use "lookup" instead of operator[], it will not perform unnecessary
insertions.  No functionality change is intended.

llvm-svn: 246523
2015-09-01 01:53:07 +00:00
Cong Hou 511298b919 Distribute the weight on the edge from switch to default statement to edges generated in lowering switch.
Currently, when edge weights are assigned to edges that are created when lowering switch statement, the weight on the edge to default statement (let's call it "default weight" here) is not considered. We need to distribute this weight properly. However, without value profiling, we have no idea how to distribute it. In this patch, I applied the heuristic that this weight is evenly distributed to successors.

For example, given a switch statement with cases 1,2,3,5,10,11,20, and every edge from switch to each successor has weight 10. If there is a binary search tree built to test if n < 10, then its two out-edges will have weight 4x10+10/2 = 45 and 3x10 + 10/2 = 35 respectively (currently they are 40 and 30 without considering the default weight). Each distribution (which is 5 here) will be stored in each SwitchWorkListItem for further distribution.

There are some exceptions:

For a jump table header which doesn't have any edge to default statement, we don't distribute the default weight to it.
For a bit test header which covers a contiguous range and hence has no edges to default statement, we don't distribute the default weight to it.
When the branch checks a single value or a contiguous range with no edge to default statement, we don't distribute the default weight to it.
In other cases, the default weight is evenly distributed to successors.

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

llvm-svn: 246522
2015-09-01 01:42:16 +00:00