Support for reading program counts in llvm-cov.

llvm-cov will now be able to read program counts from the GCDA file and
output it in the same format as gcov. The program summary tag was
identified from gcov-io.h as "\0\0\0\a3".

There is currently a bug in GCOVProfiling.cpp which does not generate
the
run- or program-counting IR, so this change was tested manually by
modifying the GCDA file and comparing the gcov and llvm-cov outputs.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193389 91177308-0d34-0410-b5e6-96231b3b80d8
llvm-cov dump to dbgs() instead of outs().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193390 91177308-0d34-0410-b5e6-96231b3b80d8
Fix ODR violation.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193391 91177308-0d34-0410-b5e6-96231b3b80d8
Optimize concat_vectors(X, undef) -> scalar_to_vector(X).
This optimization is not SSE specific so I am moving it to DAGco.
The new scalar_to_vector dag node exposed a missing pattern in the AArch64 target that I needed to add.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193393 91177308-0d34-0410-b5e6-96231b3b80d8
ARM: tweak test to pass on all platforms

A TableGen indeterminacy means that the reason for the failure can
vary, and Windows gets the other option.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193394 91177308-0d34-0410-b5e6-96231b3b80d8
LegalizeDAG: allow libcalls for max/min atomic operations

ARM processors without ldrex/strex need to be able to make libcalls for all
atomic operations, including the newer min/max versions.

The alternative would probably be expanding these operations in terms of
cmpxchg (as x86 does always), but in the configurations where this matters
code-size tends to be paramount so the libcall is more desirable.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193398 91177308-0d34-0410-b5e6-96231b3b80d8
ARM: don't expand atomicrmw inline on Cortex-M0

There's a barrier instruction so that should still be used, but most actual
atomic operations are going to need a platform decision on the correct
behaviour (either nop if single-threaded or OS-support otherwise).

rdar://problem/15287210

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193399 91177308-0d34-0410-b5e6-96231b3b80d8
The FIXME was indeed fixed in the linker, comment removed.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193402 91177308-0d34-0410-b5e6-96231b3b80d8
ARM: allow .thumb_func to be separated from symbol definition

When assembling, a .thumb_func directive is supposed to be applicable to the
next symbol definition, even if there are intervening directives. We were
racing ahead to try and find it, and this commit should fix the issue.

Patch by Gabor Ballabas

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193403 91177308-0d34-0410-b5e6-96231b3b80d8
Use c comments.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193404 91177308-0d34-0410-b5e6-96231b3b80d8
Call destroy from ~BasicCallGraph.

This fix a memory leak found by valgrind.

Calling it from the base class destructor would not destroy the BasicCallGraph
bits.

FIXME: BasicCallGraph is the only thing that inherits from CallGraph. Can
we merge the two?

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193412 91177308-0d34-0410-b5e6-96231b3b80d8
Try to fix the openbsd bot.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193413 91177308-0d34-0410-b5e6-96231b3b80d8
llvm-c-test: Don't leak memory buffers.

Detected by valgrind.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193416 91177308-0d34-0410-b5e6-96231b3b80d8
[bugpoint] Increase the default memory limit for subprocesses to 300MB.

Summary:
Currently shared library builds (BUILD_SHARED_LIBS=ON in cmake) fail three
bugpoint tests (BugPoint/remove_arguments_test.ll,
BugPoint/crash-narrowfunctiontest.ll, and BugPoint/metadata.ll).

If I run the bugpoint commands that llvm-lit runs with without -silence-passes
I see errors such as this:
    opt: error while loading shared libraries: libLLVMSystemZInfo.so: failed to
    map segment from shared object: Cannot allocate memory

It seems that the increased size of the binaries in a shared library build is
causing the subprocess to exceed the 100MB memory limit. This patch therefore
increases the default limit to a level at which these tests pass.

Reviewers: dsanders

Reviewed By: dsanders

CC: llvm-commits, rafael

Differential Revision: http://llvm-reviews.chandlerc.com/D2013

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193420 91177308-0d34-0410-b5e6-96231b3b80d8
[X86][AVX512] Add patterns that match the AVX512 floating point vbroadcast intrinsics.

Patch by Cameron McInally <cameron.mcinally@nyu.edu>


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193421 91177308-0d34-0410-b5e6-96231b3b80d8
[X86][AVX512] Add patterns that match the AVX512 floating point register vbroadcast intrinsics.

Patch by Cameron McInally <cameron.mcinally@nyu.edu>


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193422 91177308-0d34-0410-b5e6-96231b3b80d8
DIEHash: Summary hashing of nested types

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193427 91177308-0d34-0410-b5e6-96231b3b80d8
Change MemoryBuffer::getFile to take a Twine.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193429 91177308-0d34-0410-b5e6-96231b3b80d8
Try to fix the build on windows.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193431 91177308-0d34-0410-b5e6-96231b3b80d8
DIEHash: Summary hashing of member functions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193432 91177308-0d34-0410-b5e6-96231b3b80d8