OSDN Git Service

android-x86/external-llvm.git
6 years ago[SLPVectorizer] buildTree_rec replace cast<Instruction>(VL[0]) to VL0, NFCI.
Dinar Temirbulatov [Fri, 21 Jul 2017 15:31:54 +0000 (15:31 +0000)]
[SLPVectorizer] buildTree_rec replace cast<Instruction>(VL[0]) to VL0, NFCI.

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

6 years ago[mips] Enable IAS by default for Android MIPS64
Petar Jovanovic [Fri, 21 Jul 2017 14:25:42 +0000 (14:25 +0000)]
[mips] Enable IAS by default for Android MIPS64

Follow up to r306280 in Clang.
Enable IAS by default for Android MIPS64 (uses N64 ABI).

Differential Revision: https://reviews.llvm.org/D35482

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

6 years ago[AMDGPU][MC][GFX9] Added support of VOP3 'op_sel' modifier
Dmitry Preobrazhensky [Fri, 21 Jul 2017 13:54:11 +0000 (13:54 +0000)]
[AMDGPU][MC][GFX9] Added support of VOP3 'op_sel' modifier

See bug 33591: https://bugs.llvm.org//show_bug.cgi?id=33591

Reviewers: vpykhtin, artem.tamazov, SamWot, arsenm

Differential Revision: https://reviews.llvm.org/D35424

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

6 years ago[SLPVectorizer] Change canReuseExtract function parameter Opcode from unsigned to...
Dinar Temirbulatov [Fri, 21 Jul 2017 13:32:36 +0000 (13:32 +0000)]
[SLPVectorizer] Change canReuseExtract function parameter Opcode from unsigned to Value *, NFCI.

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

6 years ago[SystemZ] test update
Jonas Paulsson [Fri, 21 Jul 2017 13:14:17 +0000 (13:14 +0000)]
[SystemZ]  test update

test/CodeGen/SystemZ/loop-01.ll was incorrectly updated by r308729.

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

6 years ago[SystemZ, LoopStrengthReduce]
Jonas Paulsson [Fri, 21 Jul 2017 11:59:37 +0000 (11:59 +0000)]
[SystemZ, LoopStrengthReduce]

This patch makes LSR generate better code for SystemZ in the cases of memory
intrinsics, Load->Store pairs or comparison of immediate with memory.

In order to achieve this, the following common code changes were made:

 * New TTI hook: LSRWithInstrQueries(), which defaults to false. Controls if
 LSR should do instruction-based addressing evaluations by calling
 isLegalAddressingMode() with the Instruction pointers.
 * In LoopStrengthReduce: handle address operands of memset, memmove and memcpy
 as address uses, and call isFoldableMemAccessOffset() for any LSRUse::Address,
 not just loads or stores.

SystemZ changes:

 * isLSRCostLess() implemented with Insns first, and without ImmCost.
 * New function supportedAddressingMode() that is a helper for TTI methods
 looking at Instructions passed via pointers.

Review: Ulrich Weigand, Quentin Colombet
https://reviews.llvm.org/D35262
https://reviews.llvm.org/D35049

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

6 years ago[X86][SSE] Add extra (sra (sra x, c1), c2) -> (sra x, (add c1, c2)) test case
Simon Pilgrim [Fri, 21 Jul 2017 10:22:49 +0000 (10:22 +0000)]
[X86][SSE] Add extra (sra (sra x, c1), c2) -> (sra x, (add c1, c2)) test case

We should be able to handle the case where some c1+c2 elements exceed max shift and some don't by performing a clamp after the sum

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

6 years ago[X86][SSE] Add pre-AVX2 support for (i32 bitcast(v32i1)) -> 2xMOVMSK
Simon Pilgrim [Fri, 21 Jul 2017 09:58:50 +0000 (09:58 +0000)]
[X86][SSE] Add pre-AVX2 support for (i32 bitcast(v32i1)) -> 2xMOVMSK

Currently we only support (i32 bitcast(v32i1)) using the AVX2 VPMOVMSKB ymm instruction.

This patch adds support for splitting pre-AVX2 targets into 2 x (V)PMOVMSKB xmm instructions and merging the integer results.

In future we could probably generalize this to handle more cases.

Differential Revision: https://reviews.llvm.org/D35303

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

6 years agoCommit access test
Philipp Schaad [Fri, 21 Jul 2017 03:51:01 +0000 (03:51 +0000)]
Commit access test

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

6 years agoOnly use xml if iconv is found, which is a prerequisite.
Eric Beckmann [Fri, 21 Jul 2017 02:13:02 +0000 (02:13 +0000)]
Only use xml if iconv is found, which is a prerequisite.

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

6 years agodsymutil: strip unused types from imported DW_TAG_modules
Adrian Prantl [Fri, 21 Jul 2017 02:07:33 +0000 (02:07 +0000)]
dsymutil: strip unused types from imported DW_TAG_modules

This patch teaches dsymutil to strip types from the imported
DW_TAG_module inside of an object file (not inside the PCM) if they
can be resolved to the full definition inside the PCM. This reduces
the size of the .dSYM from WebCore from webkit.org by almost 2/3.

<rdar://problem/33047213>

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

6 years agoDebug Info: Don't strip clang module skeleton CUs.
Adrian Prantl [Fri, 21 Jul 2017 01:24:05 +0000 (01:24 +0000)]
Debug Info: Don't strip clang module skeleton CUs.

This corrects a (hopefully :-) accidental side-effect of r304020.

rdar://problem/33442618

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

6 years ago[DWARF] Generalized verification of .debug_abbrev to be applicable to both .debug_abb...
Spyridoula Gravani [Fri, 21 Jul 2017 00:51:32 +0000 (00:51 +0000)]
[DWARF] Generalized verification of .debug_abbrev to be applicable to both .debug_abbrev and .debug_abbrev.dwo sections.

Differential Revision: https://reviews.llvm.org/D35698

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

6 years ago[AVX-512] Fix a bug that prevented some non-temporal loads from using the movntdqa...
Craig Topper [Fri, 21 Jul 2017 00:40:42 +0000 (00:40 +0000)]
[AVX-512] Fix a bug that prevented some non-temporal loads from using the movntdqa instruction.

The bitconverts here had an input type of 128-bits and an output type of 256 bits. The input type should also have been 256 bits.

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

6 years agoExplicitly disable libxml2 on android.
Eric Beckmann [Thu, 20 Jul 2017 23:54:51 +0000 (23:54 +0000)]
Explicitly disable libxml2 on android.

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

6 years agoGenerate a compile_commands.json DB for external projects.
George Karpenkov [Thu, 20 Jul 2017 23:46:46 +0000 (23:46 +0000)]
Generate a compile_commands.json DB for external projects.

compile_commands.json file is very useful both for tooling and for
reproducible builds.
For files generated from recursive CMake invocation this information was
not previously generated.

Differential Review: https://reviews.llvm.org/D35219

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

6 years ago[AArch64] Adjust the cost model for Exynos M1 and M2
Evandro Menezes [Thu, 20 Jul 2017 23:41:50 +0000 (23:41 +0000)]
[AArch64] Adjust the cost model for Exynos M1 and M2

Add the cost for the EXT instructions and explicitly add the cost for a few
instructions that were implied by the coarse model.

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

6 years agoOnly defined CombinedRoot if libxml2 is used.
Eric Beckmann [Thu, 20 Jul 2017 23:14:12 +0000 (23:14 +0000)]
Only defined CombinedRoot if libxml2 is used.

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

6 years agoAdd error handling to the dyld compact export entries in libObject.
Kevin Enderby [Thu, 20 Jul 2017 23:08:41 +0000 (23:08 +0000)]
Add error handling to the dyld compact export entries in libObject.

lld needs a matching change for this will be my next commit.
Expect it to fail build until that matching commit is picked up by the bots.

Like the changes in r296527 for dyld bind entires and the changes in
r298883 for lazy bind, weak bind and rebase entries the export
entries are the last of the dyld compact info to have error handling added.

This follows the model of iterators that can fail that Lang Hanes
designed when fixing the problem for bad archives r275316 (or r275361).

So that iterating through the exports now terminates if there is an error
and returns an llvm::Error with an error message in all cases for malformed
input.

This change provides the plumbing for the error handling, all the needed
testing of error conditions and test cases for all of the unique error messages.

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

6 years agoOnly enable libxml2 on linux, because systems like android lack libiconv
Eric Beckmann [Thu, 20 Jul 2017 23:02:49 +0000 (23:02 +0000)]
Only enable libxml2 on linux, because systems like android lack libiconv

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

6 years agoRecommit: GlobalISel: select G_EXTRACT and G_INSERT instructions on AArch64.
Tim Northover [Thu, 20 Jul 2017 22:58:38 +0000 (22:58 +0000)]
Recommit: GlobalISel: select G_EXTRACT and G_INSERT instructions on AArch64.

It revealed a bug in the Localizer pass which has now been fixed.

This includes the fix for SUBREG_TO_REG committed separately last time.

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

6 years agoGlobalISel: stop localizer putting constants before EH_LABELs
Tim Northover [Thu, 20 Jul 2017 22:58:26 +0000 (22:58 +0000)]
GlobalISel: stop localizer putting constants before EH_LABELs

If the localizer pass puts one of its constants before the label that tells the
unwinder "jump here to handle your exception" then control-flow will skip it,
leaving uninitialized registers at runtime. That's bad.

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

6 years agoMake a file end with n and remove trailing whitespace.
Rui Ueyama [Thu, 20 Jul 2017 22:39:20 +0000 (22:39 +0000)]
Make a file end with n and remove trailing whitespace.

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

6 years agoMake tests always depend on llvm-mt, because some tests are run even w/o
Eric Beckmann [Thu, 20 Jul 2017 22:13:16 +0000 (22:13 +0000)]
Make tests always depend on llvm-mt, because some tests are run even w/o
xml2.

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

6 years agoImplement parsing and writing of a single xml manifest file.
Eric Beckmann [Thu, 20 Jul 2017 21:42:04 +0000 (21:42 +0000)]
Implement parsing and writing of a single xml manifest file.

Summary: Implement parsing and writing of a single xml manifest file.

Subscribers: mgorny, llvm-commits, hiraditya

Differential Revision: https://reviews.llvm.org/D35425

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

6 years ago[NVPTX] Add lowering of i128 params.
Artem Belevich [Thu, 20 Jul 2017 21:16:03 +0000 (21:16 +0000)]
[NVPTX] Add lowering of i128 params.

The patch adds support of i128 params lowering. The changes are quite trivial to
support i128 as a "special case" of integer type. With this patch, we lower i128
params the same way as aggregates of size 16 bytes: .param .b8 _ [16].

Currently, NVPTX can't deal with the 128 bit integers:
* in some cases because of failed assertions like
  ValVTs.size() == OutVals.size() && "Bad return value decomposition"
* in other cases emitting PTX with .i128 or .u128 types (which are not valid [1])
  [1] http://docs.nvidia.com/cuda/parallel-thread-execution/index.html#fundamental-types

Differential Revision: https://reviews.llvm.org/D34555
Patch by: Denys Zariaiev (denys.zariaiev@gmail.com)

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

6 years agoAMDGPU: Rename _RTN atomic instructions
Matt Arsenault [Thu, 20 Jul 2017 21:06:04 +0000 (21:06 +0000)]
AMDGPU: Rename _RTN atomic instructions

Move the _RTN to the end of the name. It reads
better if the other addressing mode components
line up with the non-RTN version. It is also
more convenient to define saddr variants of
FLAT atomics to have the RTN last, and it is
good to have a consistent naming scheme.

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

6 years agoAdd an ID field to StackObjects
Matt Arsenault [Thu, 20 Jul 2017 21:03:45 +0000 (21:03 +0000)]
Add an ID field to StackObjects

On AMDGPU SGPR spills are really spilled to another register.
The spiller creates the spills to new frame index objects,
which is used as a placeholder.

This will eventually be replaced with a reference to a position
in a VGPR to write to and the frame index deleted. It is
most likely not a real stack location that can be shared
with another stack object.

This is a problem when StackSlotColoring decides it should
combine a frame index used for a normal VGPR spill with
a real stack location and a frame index used for an SGPR.

Add an ID field so that StackSlotColoring has a way
of knowing the different frame index types are
incompatible.

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

6 years ago[X86] Adding ISel tests for strided-shuffles with non-zero offset. NFC.
Zvi Rackover [Thu, 20 Jul 2017 21:03:36 +0000 (21:03 +0000)]
[X86] Adding ISel tests for strided-shuffles with non-zero offset. NFC.

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

6 years agoChanged EOL back to LF. NFC.
Artem Belevich [Thu, 20 Jul 2017 20:57:51 +0000 (20:57 +0000)]
Changed EOL back to LF. NFC.

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

6 years agoGenerate error reports when a fuzz target exits.
Matt Morehouse [Thu, 20 Jul 2017 20:43:39 +0000 (20:43 +0000)]
Generate error reports when a fuzz target exits.

Summary:
Implements https://github.com/google/sanitizers/issues/835.

Flush stdout before exiting in test cases.

Since the atexit hook is used for exit reports, pending prints to
stdout can be lost if they aren't flushed before calling exit().

Expect tests to have non-zero exit code if exit() is called.

Reviewers: vitalybuka, kcc

Reviewed By: kcc

Subscribers: eraman, llvm-commits, hiraditya

Differential Revision: https://reviews.llvm.org/D35602

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

6 years ago[PGO] Move the PGOInstrumentation pass to new OptRemark API.
Davide Italiano [Thu, 20 Jul 2017 20:43:05 +0000 (20:43 +0000)]
[PGO] Move the PGOInstrumentation pass to new OptRemark API.

This fixes PR33791.

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

6 years ago[PEI] Fix refactoring from r308664
Francis Visoiu Mistrih [Thu, 20 Jul 2017 20:31:44 +0000 (20:31 +0000)]
[PEI] Fix refactoring from r308664

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

6 years ago[COFF, ARM64, CodeView] Add support to emit CodeView debug info for ARM64 COFF
Mandeep Singh Grang [Thu, 20 Jul 2017 20:20:00 +0000 (20:20 +0000)]
[COFF, ARM64, CodeView] Add support to emit CodeView debug info for ARM64 COFF

Reviewers: compnerd, ruiu, rnk, zturner

Reviewed By: rnk

Subscribers: majnemer, aemerson, aprantl, javed.absar, kristof.beyls, llvm-commits

Differential Revision: https://reviews.llvm.org/D35518

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

6 years ago[PEI] Separate saving and restoring CSRs into different functions. NFC
Francis Visoiu Mistrih [Thu, 20 Jul 2017 20:17:17 +0000 (20:17 +0000)]
[PEI] Separate saving and restoring CSRs into different functions. NFC

Split insertCSRSpillsAndRestores into insertCSRSaves + insertCSRRestores.

This is mostly useful for future shrink-wrapping improvements where we
want to save / restore a specific part of the CSRs in a specific block.

Differential Revision: https://reviews.llvm.org/D35644

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

6 years ago[libFuzzer] delete stale code
Kostya Serebryany [Thu, 20 Jul 2017 20:15:13 +0000 (20:15 +0000)]
[libFuzzer] delete stale code

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

6 years ago[SPARC] Clean up the support for disabling fsmuld and fmuls instructions.
James Y Knight [Thu, 20 Jul 2017 20:09:11 +0000 (20:09 +0000)]
[SPARC] Clean up the support for disabling fsmuld and fmuls instructions.

Summary:
Also enable no-fsmuld for sparcv7 (which doesn't have the
instruction).

The previous code which used a post-processing pass to do this was
unnecessary; disabling the instruction is entirely sufficient.

Reviewers: jacob_hansen, ekedaigle

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D35576

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

6 years agoImplement LaneBitmask::getNumLanes and LaneBitmask::getHighestLane
Krzysztof Parzyszek [Thu, 20 Jul 2017 19:43:19 +0000 (19:43 +0000)]
Implement LaneBitmask::getNumLanes and LaneBitmask::getHighestLane

This should eliminate most uses of countPopulation and Log2_32 on
the lane mask values.

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

6 years ago[X86] Allow masks with more than 6 bits set on the x << (y & mask) optimization for...
Craig Topper [Thu, 20 Jul 2017 19:29:58 +0000 (19:29 +0000)]
[X86] Allow masks with more than 6 bits set on the x << (y & mask) optimization for the 64-bit memory shifts.

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

6 years ago[X86] Add test case to demonstrate that we don't allow masks wider than 6 bits in...
Craig Topper [Thu, 20 Jul 2017 19:29:56 +0000 (19:29 +0000)]
[X86] Add test case to demonstrate that we don't allow masks wider than 6 bits in the (shift x, (and y, mask)) patterns for the 64-bit memory form.

We allow wider than 5 bits in the 16 and 32 bit store forms. And we allow wider than 6 bits on the 64-bit regsiter form.:w

I'm assuming this was a mistake made back in r148024.

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

6 years agoUse LaneBitmask::getLane in a few more places
Krzysztof Parzyszek [Thu, 20 Jul 2017 19:15:56 +0000 (19:15 +0000)]
Use LaneBitmask::getLane in a few more places

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

6 years ago[libFuzzer] make sure CheckExitOnSrcPosOrItem is called after the new input is saved...
Kostya Serebryany [Thu, 20 Jul 2017 18:53:25 +0000 (18:53 +0000)]
[libFuzzer] make sure CheckExitOnSrcPosOrItem is called after the new input is saved to the corpus

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

6 years ago[DAG] Commit missed nit cleanup from r308617. NFC.
Nirav Dave [Thu, 20 Jul 2017 18:07:57 +0000 (18:07 +0000)]
[DAG] Commit missed nit cleanup from r308617. NFC.

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

6 years agoLowerTypeTests: Drop function type metadata only if we're going to replace it.
Peter Collingbourne [Thu, 20 Jul 2017 18:02:05 +0000 (18:02 +0000)]
LowerTypeTests: Drop function type metadata only if we're going to replace it.

Previously we were (mis)handling jump table members with a prevailing
definition in a full LTO module and a non-prevailing definition in a
ThinLTO module by dropping type metadata on those functions entirely,
which would cause type tests involving such functions to fail.

This patch causes us to drop metadata only if we are about to replace
it with metadata from cfi.functions.

We also want to replace metadata for available_externally functions,
which can arise in the opposite scenario (prevailing ThinLTO
definition, non-prevailing full LTO definition). The simplest way
to handle that is to remove the definition; there's little value in
keeping it around at this point (i.e. after most optimization passes
have already run) and later code will try to use the function's linkage
to create an alias, which would result in invalid IR if the function
is available_externally.

Fixes PR33832.

Differential Revision: https://reviews.llvm.org/D35604

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

6 years agoAMDGPU: Add encoding for carryless add/sub instructions
Matt Arsenault [Thu, 20 Jul 2017 17:42:47 +0000 (17:42 +0000)]
AMDGPU: Add encoding for carryless add/sub instructions

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

6 years agoAMDGPU: Add encodings for global atomics
Matt Arsenault [Thu, 20 Jul 2017 17:31:56 +0000 (17:31 +0000)]
AMDGPU: Add encodings for global atomics

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

6 years agoRemove unnecessary prefix from comment lines in a .test file.
David Blaikie [Thu, 20 Jul 2017 17:20:36 +0000 (17:20 +0000)]
Remove unnecessary prefix from comment lines in a .test file.

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

6 years agorevert: [llvm] r308609 - This patch added some test cases to demonsrate the issues...
Simon Pilgrim [Thu, 20 Jul 2017 15:17:15 +0000 (15:17 +0000)]
revert: [llvm] r308609 - This patch added some test cases to demonsrate the issues described in Bug 33848 - X86 Asm does not support symbolic names inside address calculation.

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

6 years ago[DAG] Handle missing transform in fold of value extension case.
Nirav Dave [Thu, 20 Jul 2017 13:57:32 +0000 (13:57 +0000)]
[DAG] Handle missing transform in fold of value extension case.

Summary:
When pushing an extension of a constant bitwise operator on a load
into the load, change other uses of the load value if they exist to
prevent the old load from persisting.

Reviewers: spatel, RKSimon, efriedma

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D35030

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

6 years ago[DAG] Optimize away degenerate INSERT_VECTOR_ELT nodes.
Nirav Dave [Thu, 20 Jul 2017 13:48:17 +0000 (13:48 +0000)]
[DAG] Optimize away degenerate INSERT_VECTOR_ELT nodes.

Summary:
Add missing vector write of vector read reduction, i.e.:

(insert_vector_elt x (extract_vector_elt x idx) idx) to x

Reviewers: spatel, RKSimon, efriedma

Reviewed By: RKSimon

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D35563

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

6 years ago[globalisel][tablegen] Fix an unintended fallthrough that is currently unreachable...
Daniel Sanders [Thu, 20 Jul 2017 13:10:17 +0000 (13:10 +0000)]
[globalisel][tablegen] Fix an unintended fallthrough that is currently unreachable. NFC

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

6 years agoReland r308585
Stefan Maksimovic [Thu, 20 Jul 2017 13:08:18 +0000 (13:08 +0000)]
Reland r308585

Builder clang-x86_64-linux-abi-test apparently failed due
to a spurious error unrelated to the changes r308585
introduced.

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

6 years ago[X86][AVX512] Improve vector rotation constant folding tests
Simon Pilgrim [Thu, 20 Jul 2017 13:07:37 +0000 (13:07 +0000)]
[X86][AVX512] Improve vector rotation constant folding tests

Test constant folding both on node creation (which already works) and once the input nodes have been folded themselves (not working yet).

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

6 years agoThis patch added some test cases to demonsrate the issues described in Bug 33848...
Andrew V. Tischenko [Thu, 20 Jul 2017 12:46:02 +0000 (12:46 +0000)]
This patch added some test cases to demonsrate the issues described in Bug 33848 - X86 Asm does not support symbolic names inside address calculation.

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

6 years ago[ARM] Simplify ExpandPseudoInst. NFC.
Javed Absar [Thu, 20 Jul 2017 12:35:37 +0000 (12:35 +0000)]
[ARM] Simplify ExpandPseudoInst. NFC.

Remove headers not required and convert to range-loop

Reviewed by: @mcrosier
Differential Revision: https://reviews.llvm.org/D35626

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

6 years ago[mips] Support `long_call/far/near` attributes passed by front-end
Simon Atanasyan [Thu, 20 Jul 2017 12:19:26 +0000 (12:19 +0000)]
[mips] Support `long_call/far/near` attributes passed by front-end

This patch adds handling of the `long_call`, `far`, and `near`
attributes passed by front-end. The patch depends on D35479.

Differential revision: https://reviews.llvm.org/D35480.

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

6 years agoRevert "GlobalISel: select G_EXTRACT and G_INSERT instructions on AArch64."
Diana Picus [Thu, 20 Jul 2017 11:36:03 +0000 (11:36 +0000)]
Revert "GlobalISel: select G_EXTRACT and G_INSERT instructions on AArch64."

This reverts commit 36c6a2ea9669bc3bb695928529a85d12d1d3e3f9 because it
broke the test-suite on the GlobalISel bot.

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

6 years ago[DAGCombiner] Match ISD::SRL non-uniform constant vectors patterns using predicates.
Simon Pilgrim [Thu, 20 Jul 2017 11:03:30 +0000 (11:03 +0000)]
[DAGCombiner] Match ISD::SRL non-uniform constant vectors patterns using predicates.

Use predicate matchers introduced in D35492 to match more ISD::SRL constant folds

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

6 years agoRemove trailing whitespace. NFCI.
Simon Pilgrim [Thu, 20 Jul 2017 10:43:52 +0000 (10:43 +0000)]
Remove trailing whitespace. NFCI.

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

6 years ago[DAGCombiner] Match ISD::SRA non-uniform constant vectors patterns using predicates.
Simon Pilgrim [Thu, 20 Jul 2017 10:43:05 +0000 (10:43 +0000)]
[DAGCombiner] Match ISD::SRA non-uniform constant vectors patterns using predicates.

Use predicate matchers introduced in D35492 to match more ISD::SRA constant folds

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

6 years ago[globalisel][tablegen] Fix an issue with lambdas when compiling with older GCC's
Daniel Sanders [Thu, 20 Jul 2017 10:25:00 +0000 (10:25 +0000)]
[globalisel][tablegen] Fix an issue with lambdas when compiling with older GCC's

It seems that G++ 4.8 doesn't accept the 'enum A' in code of the form:
  enum A { ... };
  const auto &F = []() -> enum A { ... };
However, it does accept:
  typedef enum { ... } A;
  const auto &F = []() -> A { ... };

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

6 years ago[DAGCombiner] Match non-uniform constant vectors using predicates.
Simon Pilgrim [Thu, 20 Jul 2017 10:13:40 +0000 (10:13 +0000)]
[DAGCombiner] Match non-uniform constant vectors using predicates.

Most combines currently recognise scalar and splat-vector constants, but not non-uniform vector constants.

This patch introduces a matching mechanism that uses predicates to check against BUILD_VECTOR of ConstantSDNode, as well as scalar ConstantSDNode cases.

I've changed a couple of predicates to demonstrate - the combine-shl changes add currently unsupported cases, while the MatchRotate replaces an existing mechanism.

Differential Revision: https://reviews.llvm.org/D35492

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

6 years agoRevert r308585
Stefan Maksimovic [Thu, 20 Jul 2017 09:57:14 +0000 (09:57 +0000)]
Revert r308585

Builder clang-x86_64-linux-abi-test seems to fail after this change

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

6 years ago[globalisel][tablegen] Add control-flow to the MatchTable.
Daniel Sanders [Thu, 20 Jul 2017 09:25:44 +0000 (09:25 +0000)]
[globalisel][tablegen] Add control-flow to the MatchTable.

Summary:
This will allow us to merge the various sub-tables into a single table. This is a
compile-time saving at this point. However, this will also enable the optimization
of a table so that similar instructions can be tested together, reducing the time
spent on the matching the code.

The bulk of this patch is a mechanical conversion to the new MatchTable object
which is responsible for tracking label definitions and filling in the index of
the jump targets. It is also responsible for nicely formatting the table.

This was necessary to support the new GIM_Try opcode which takes the index to
jump to if the match should fail. This value is unknown during table
construction and is filled in during emission. To support nesting try-blocks
(although we currently don't emit tables with nested try-blocks), GIM_Reject
has been re-introduced to explicitly exit a try-block or fail the overall match
if there are no active try-blocks.

Reviewers: ab, t.p.northover, qcolombet, rovka, aditya_nandakumar

Reviewed By: rovka

Subscribers: kristof.beyls, igorb, llvm-commits

Differential Revision: https://reviews.llvm.org/D35117

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

6 years ago[mips] Fix fp select machine verifier errors
Stefan Maksimovic [Thu, 20 Jul 2017 09:21:10 +0000 (09:21 +0000)]
[mips] Fix fp select machine verifier errors

Introduced FSELECT node necesary when lowering ISD::SELECT
which has i32, f64, f64 as its operands.
SEL_D instruction required that its output and first operand
of a SELECT node, which it used, have matching types.
MTC1_D64 node introduced to aid FSELECT lowering.

This fixes machine verifier errors on following tests:
CodeGen/Mips/llvm-ir/select-dbl.ll
CodeGen/Mips/llvm-ir/select-flt.ll
CodeGen/Mips/select.ll

Differential Revision: https://reviews.llvm.org/D35408

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

6 years agoHandle clang-tools-extra project in docker scripts.
Ilya Biryukov [Thu, 20 Jul 2017 08:30:44 +0000 (08:30 +0000)]
Handle clang-tools-extra project in docker scripts.

Reviewers: klimek, mehdi_amini

Reviewed By: mehdi_amini

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D35418

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

6 years ago[X86] Use SARX/SHLX/SHLX instructions for (shift x (and y, (BitWidth-1)))
Craig Topper [Thu, 20 Jul 2017 06:19:55 +0000 (06:19 +0000)]
[X86] Use SARX/SHLX/SHLX instructions for (shift x (and y, (BitWidth-1)))

Fixes PR33841.

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

6 years ago[X86] Add test cases for (shift x (and y, (BitWidth-1))) to the BMI2 shift test.
Craig Topper [Thu, 20 Jul 2017 06:19:54 +0000 (06:19 +0000)]
[X86] Add test cases for (shift x (and y, (BitWidth-1))) to the BMI2 shift test.

We should use SHLX and similar instructions for these patterns, but we currently don't.

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

6 years ago[X86] Regenerate shift-and.ll and shift-bmi2.ll using update_llc_test_checks.py.
Craig Topper [Thu, 20 Jul 2017 06:19:53 +0000 (06:19 +0000)]
[X86] Regenerate shift-and.ll and shift-bmi2.ll using update_llc_test_checks.py.

I've stripped the checks for 64-bit types in 32-bit mode to match the existing tests.

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

6 years ago[X86] Remove outdated bug comment from a test.
Craig Topper [Thu, 20 Jul 2017 06:19:52 +0000 (06:19 +0000)]
[X86] Remove outdated bug comment from a test.

The test issue was fixed and the test was updated in r244577, but the comment wasn't removed.

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

6 years agoAMDGPU: Correct encoding for global instructions
Matt Arsenault [Thu, 20 Jul 2017 05:17:54 +0000 (05:17 +0000)]
AMDGPU: Correct encoding for global instructions

The soffset field needs to be be set to 0x7f to disable it,
not 0. 0 is interpreted as an SGPR offset.

This should be enough to get basic usage of the global instructions
working. Technically it is possible to use an SGPR_32 offset,
but I'm not sure if it's correct with 64-bit pointers, but
that is not handled now. This should also be cleaned up
to be more similar to how different MUBUF modes are handled,
and to have InstrMappings between the different types.

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

6 years ago[LICM] Make sinkRegion and hoistRegion non-recursive
David Majnemer [Thu, 20 Jul 2017 03:27:02 +0000 (03:27 +0000)]
[LICM] Make sinkRegion and hoistRegion non-recursive

Large CFGs can cause us to blow up the stack because we would have a
recursive step for each basic block in a region.

Instead, create a worklist and iterate it. This limits the stack usage
to something more manageable.

Differential Revision: https://reviews.llvm.org/D35609

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

6 years agoRevert "[PEI] Simplify handling of targets with no phys regs. NFC"
Francis Visoiu Mistrih [Thu, 20 Jul 2017 02:47:05 +0000 (02:47 +0000)]
Revert "[PEI] Simplify handling of targets with no phys regs. NFC"

This reverts commit ce30ab6e5598f3c24f59ad016dc9526bc9a1d450.

sanitizer-ppc64le-linux seems to segfault when testing the sanitizers.

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

6 years agoRevert "[PEI] Separate saving and restoring CSRs into different functions. NFC"
Francis Visoiu Mistrih [Thu, 20 Jul 2017 02:47:04 +0000 (02:47 +0000)]
Revert "[PEI] Separate saving and restoring CSRs into different functions. NFC"

This reverts commit 540f6a26ae932469804a379ce9a8cbe715d59c23.

sanitizer-ppc64le-linux seems to segfault when testing the sanitizers.

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

6 years ago[DWARF] Added check that verifies that no abbreviation declaration has more than...
Spyridoula Gravani [Thu, 20 Jul 2017 02:06:52 +0000 (02:06 +0000)]
[DWARF] Added check that verifies that no abbreviation declaration has more than one attribute with the same name.

SUMMARY

This patch adds a verification check on the abbreviation declarations in the .debug_abbrev section.
The check makes sure that no abbreviation declaration has more than one attributes with the same name.

Differential Revision: https://reviews.llvm.org/D35643

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

6 years ago[libFuzzer] prototype implementation of recursion-depth coverage features (commented...
Kostya Serebryany [Thu, 20 Jul 2017 01:35:17 +0000 (01:35 +0000)]
[libFuzzer] prototype implementation of recursion-depth coverage features (commented out; real implementation needs to use inlined instrumentation)

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

6 years agoSupport, IR, ADT: Check nullptr after allocation with malloc/realloc or calloc
Matthias Braun [Thu, 20 Jul 2017 01:30:39 +0000 (01:30 +0000)]
Support, IR, ADT: Check nullptr after allocation with malloc/realloc or calloc

As a follow up of the bad alloc handler patch, this patch introduces nullptr checks on pointers returned from the
malloc/realloc/calloc functions.  In addition some memory size assignments  are moved behind the allocation
of the corresponding memory to fulfill exception safe memory management (RAII).

patch by Klaus Kretzschmar

Differential Revision: https://reviews.llvm.org/D35414

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

6 years ago[PEI] Separate saving and restoring CSRs into different functions. NFC
Francis Visoiu Mistrih [Thu, 20 Jul 2017 00:58:37 +0000 (00:58 +0000)]
[PEI] Separate saving and restoring CSRs into different functions. NFC

Split insertCSRSpillsAndRestores into insertCSRSaves + insertCSRRestores.

This is mostly useful for future shrink-wrapping improvements where we
want to save / restore a specific part of the CSRs in a specific block.

Differential Revision: https://reviews.llvm.org/D35644

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

6 years agoReplace -print-whole-regmask with a threshold.
Matt Arsenault [Thu, 20 Jul 2017 00:37:31 +0000 (00:37 +0000)]
Replace -print-whole-regmask with a threshold.

The previous flag/default of printing everything is
not helpful when there are thousands of registers
in the mask.

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

6 years ago[libFuzzer] add DeepRecursionTest, inspired by https://guidovranken.wordpress.com...
Kostya Serebryany [Thu, 20 Jul 2017 00:37:08 +0000 (00:37 +0000)]
[libFuzzer] add DeepRecursionTest, inspired by https://guidovranken.wordpress.com/2017/07/08/libfuzzer-gv-new-techniques-for-dramatically-faster-fuzzing/ (Stack-depth-guided fuzzing). libFuzzer does not solve it yet.

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

6 years agoRevert "[LLVM][llvm-objcopy] Added basic plumbing to get things started"
Petr Hosek [Thu, 20 Jul 2017 00:13:32 +0000 (00:13 +0000)]
Revert "[LLVM][llvm-objcopy] Added basic plumbing to get things started"

This reverts commit 98f9792e7ca5bbd9eb43bda72bf497957cfb6eb8.

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

6 years agoTry to deflake fuzzer-oom.test on Windows
Reid Kleckner [Thu, 20 Jul 2017 00:11:39 +0000 (00:11 +0000)]
Try to deflake fuzzer-oom.test on Windows

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

6 years agoRevert "[PEI] Separate saving and restoring CSRs into different functions. NFC"
Francis Visoiu Mistrih [Thu, 20 Jul 2017 00:08:02 +0000 (00:08 +0000)]
Revert "[PEI] Separate saving and restoring CSRs into different functions. NFC"

This reverts commit a84d1fa6847e70ebf63594d41a00b473c941bd72.

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

6 years ago[libFuzzer] simplify two more tests
Kostya Serebryany [Wed, 19 Jul 2017 23:52:54 +0000 (23:52 +0000)]
[libFuzzer] simplify two more tests

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

6 years ago[LLVM][llvm-objcopy] Added basic plumbing to get things started
Petr Hosek [Wed, 19 Jul 2017 23:51:13 +0000 (23:51 +0000)]
[LLVM][llvm-objcopy] Added basic plumbing to get things started

As discussed on llvm-dev I've implemented the first basic steps towards
llvm-objcopy/llvm-objtool (name pending).

This change adds the ability to copy (without modification) 64-bit
little endian ELF executables that have SHT_PROGBITS, SHT_NOBITS,
SHT_NULL and SHT_STRTAB sections.

Patch by Jake Ehrlich

Differential Revision: https://reviews.llvm.org/D33964

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

6 years ago[AsmPrinter] Constify needsCFIMoves. NFC
Francis Visoiu Mistrih [Wed, 19 Jul 2017 23:47:33 +0000 (23:47 +0000)]
[AsmPrinter] Constify needsCFIMoves. NFC

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

6 years ago[PEI] Add basic opt-remarks support
Francis Visoiu Mistrih [Wed, 19 Jul 2017 23:47:32 +0000 (23:47 +0000)]
[PEI] Add basic opt-remarks support

Add optimization remarks support to the PrologueEpilogueInserter. For
now, emit the stack size as an analysis remark, but more additions wrt
shrink-wrapping may be added.

https://reviews.llvm.org/D35645

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

6 years ago[PEI] Simplify handling of targets with no phys regs. NFC
Francis Visoiu Mistrih [Wed, 19 Jul 2017 23:47:32 +0000 (23:47 +0000)]
[PEI] Simplify handling of targets with no phys regs. NFC

Make doSpillCalleeSavedRegs a member function, instead of passing most
of the members of PEI as arguments.

Differential Revision: https://reviews.llvm.org/D35642

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

6 years ago[PEI] Separate saving and restoring CSRs into different functions. NFC
Francis Visoiu Mistrih [Wed, 19 Jul 2017 23:47:31 +0000 (23:47 +0000)]
[PEI] Separate saving and restoring CSRs into different functions. NFC

Split insertCSRSpillsAndRestores into insertCSRSaves + insertCSRRestores.

This is mostly useful for future shrink-wrapping improvements where we
want to save / restore a specific part of the CSRs in a specific block.

Differential Revision: https://reviews.llvm.org/D35644

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

6 years ago[libFuzzer] change several tests to not limit the max len: with reduce_inputs=1 they...
Kostya Serebryany [Wed, 19 Jul 2017 23:45:46 +0000 (23:45 +0000)]
[libFuzzer] change several tests to not limit the max len: with reduce_inputs=1 they are now fast enough even w/o this

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

6 years agoUse llvm::make_unique once more to avoid ADL ambiguity with std::make_unique
Reid Kleckner [Wed, 19 Jul 2017 23:42:53 +0000 (23:42 +0000)]
Use llvm::make_unique once more to avoid ADL ambiguity with std::make_unique

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

6 years agoUse llvm::make_unique to try to fix the windows build.
Rafael Espindola [Wed, 19 Jul 2017 23:38:54 +0000 (23:38 +0000)]
Use llvm::make_unique to try to fix the windows build.

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

6 years agoRemove some leftover DWARFContextInMemory.
Rafael Espindola [Wed, 19 Jul 2017 23:34:59 +0000 (23:34 +0000)]
Remove some leftover DWARFContextInMemory.

Not sure how I missed these on the previous commit.

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

6 years agoFix fuzzer-flags.test on Windows
Reid Kleckner [Wed, 19 Jul 2017 23:22:06 +0000 (23:22 +0000)]
Fix fuzzer-flags.test on Windows

The optional external function callbacks have to be exported in order
for them to be called. The test was failing because libFuzzer wasn't
calling LLVMFuzzerInitialize.

We can reconsider if this is the best way to mark these optional
callbacks exported later.

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

6 years agoUpdate module map for RuntimeLibcalls
Derek Schuff [Wed, 19 Jul 2017 23:15:29 +0000 (23:15 +0000)]
Update module map for RuntimeLibcalls

The def file was created in r308531

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

6 years ago[NFC] Fix typo in comment
Francis Visoiu Mistrih [Wed, 19 Jul 2017 22:28:08 +0000 (22:28 +0000)]
[NFC] Fix typo in comment

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

6 years agoUse delegation instead of inheritance.
Rafael Espindola [Wed, 19 Jul 2017 22:27:28 +0000 (22:27 +0000)]
Use delegation instead of inheritance.

This changes DwarfContext to delegate to DwarfObject instead of having
pure virtual methods.

With this DwarfContextInMemory is replaced with an implementation of
DwarfObject that is local to a .cpp file.

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

6 years agoGlobalISel: partially revert r308540.
Tim Northover [Wed, 19 Jul 2017 22:11:08 +0000 (22:11 +0000)]
GlobalISel: partially revert r308540.

An unfinished and untested implementation of ISel for G_UNMERGE_VALUES crept in
by mistake.

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

6 years ago[libFuzzer] enable reduce_inputs=1 by default (seems to be a big win usually)
Kostya Serebryany [Wed, 19 Jul 2017 22:10:30 +0000 (22:10 +0000)]
[libFuzzer] enable reduce_inputs=1 by default (seems to be a big win usually)

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

6 years agoGlobalISel: fix SUBREG_TO_REG implementation.
Tim Northover [Wed, 19 Jul 2017 22:08:08 +0000 (22:08 +0000)]
GlobalISel: fix SUBREG_TO_REG implementation.

The first argument needs to be an immediate rather than a register. Should fix
some crashes in the verifier bot.

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