OSDN Git Service

android-x86/external-llvm.git
7 years agoxray-extract.cc: Quick fix for mingw, to avoid errc::protocol_error.
NAKAMURA Takumi [Thu, 27 Oct 2016 00:34:24 +0000 (00:34 +0000)]
xray-extract.cc: Quick fix for mingw, to avoid errc::protocol_error.

errc::protocol_error is winsock-oriented and mingw doesn't include it. (MS does, though)

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

7 years ago[libFuzzer] revert 285259 -- hit commit too soon
Kostya Serebryany [Thu, 27 Oct 2016 00:24:34 +0000 (00:24 +0000)]
[libFuzzer] revert 285259 -- hit commit too soon

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

7 years ago[libFuzzer] speculatively trying to fix the Mac build
Kostya Serebryany [Thu, 27 Oct 2016 00:22:39 +0000 (00:22 +0000)]
[libFuzzer] speculatively trying to fix the Mac build

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

7 years ago[IR] Retire unused getGEPReturnType overload. NFCI.
Davide Italiano [Wed, 26 Oct 2016 23:46:16 +0000 (23:46 +0000)]
[IR] Retire unused getGEPReturnType overload. NFCI.

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

7 years ago[APFloat] Fix APFloat::getExactInverse when the input is nullptr. This is a regressio...
Tim Shen [Wed, 26 Oct 2016 23:31:41 +0000 (23:31 +0000)]
[APFloat] Fix APFloat::getExactInverse when the input is nullptr. This is a regression introduced by r285105.

Reviewers: kbarton, echristo, iteratee, eugenis

Subscribers: llvm-commits, mehdi_amini

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

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

7 years agollvm-objdump: Make some error messages more consistent
Justin Bogner [Wed, 26 Oct 2016 22:37:52 +0000 (22:37 +0000)]
llvm-objdump: Make some error messages more consistent

Most of the version of report_error were quoting the filename and
printing a colon between the file name and the error message, but this
one wasn't doing either of those. Fix the output to be more
consistent.

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

7 years ago[utils] Add a '--unified-report' option to the code coverage prep script
Vedant Kumar [Wed, 26 Oct 2016 22:07:39 +0000 (22:07 +0000)]
[utils] Add a '--unified-report' option to the code coverage prep script

In --unified-report mode, a single coverage report is prepared for all
specified binaries and written to *report_dir*. This mode is compatible
with all existing script options, including the --restrict mode which is
used to limit coverage reporting to certain files or directories.

This should not break any existing users of the script.

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

7 years ago[utils] Use print_function in the code coverage prep script, NFC.
Vedant Kumar [Wed, 26 Oct 2016 22:07:37 +0000 (22:07 +0000)]
[utils] Use print_function in the code coverage prep script, NFC.

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

7 years ago[utils] Add an '--only-merge' option to the code coverage prep script
Vedant Kumar [Wed, 26 Oct 2016 22:07:35 +0000 (22:07 +0000)]
[utils] Add an '--only-merge' option to the code coverage prep script

In --only-merge mode, the script terminates after the profile merging
step.  This makes the script less stateful: it's more natural to split
the merge out into a separate step instead of relying on the first
invocation of the script to do it.

This should not break any existing users of the script.

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

7 years ago[AArch64] Create feature set for Samsung Exynos-M2
Evandro Menezes [Wed, 26 Oct 2016 22:06:20 +0000 (22:06 +0000)]
[AArch64] Create feature set for Samsung Exynos-M2

Since Exynos-M2 improved the FP square root unit a bit over the one in
Exynos-M1, it does not benefit from using the Newton series for such
operations.

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

7 years agoDebugInfo: fix incorrect alignment type (NFC)
Victor Leschuk [Wed, 26 Oct 2016 21:32:29 +0000 (21:32 +0000)]
DebugInfo: fix incorrect alignment type (NFC)

Change type of some missed DebugInfo-related alignment variables,
that are still uint64_t, to uint32_t.

Original change introduced in r284482.

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

7 years ago[lit] Work around Windows MSys command line tokenization bug
Reid Kleckner [Wed, 26 Oct 2016 20:29:27 +0000 (20:29 +0000)]
[lit] Work around Windows MSys command line tokenization bug

Summary:
This will allow us to revert LLD r284768, which added spaces to get MSys
echo to print what we want.

Reviewers: ruiu, inglorion, rafael

Subscribers: modocache, llvm-commits

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

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

7 years ago[PPC] Remove testcase from incorrect directory
Ehsan Amiri [Wed, 26 Oct 2016 20:16:59 +0000 (20:16 +0000)]
[PPC] Remove testcase from incorrect directory

During my last commit this testcase was put in an incorrect directory. Removing
it. Will put it in the right directory when I can verify everything is correct.

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

7 years agoARM: don't rely on push/pop reglists being in order when folding SP adjust.
Tim Northover [Wed, 26 Oct 2016 20:01:00 +0000 (20:01 +0000)]
ARM: don't rely on push/pop reglists being in order when folding SP adjust.

It would be a very nice invariant to rely on, but unfortunately it doesn't
necessarily hold (and the causes of mis-sorted reglists appear to be quite
varied) so to be robust the frame lowering code can't assume that the first
register in the list is also the first one that actually gets pushed.

Should fix an issue where we were turning something like:

    push {r8, r4, r7, lr}
    sub sp, #24

into nonsense like:

    push {r2, r3, r4, r5, r6, r7, r8, r4, r7, lr}

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

7 years agoDo not assume that FP vector operands are never legalized by expanding
Nemanja Ivanovic [Wed, 26 Oct 2016 19:51:35 +0000 (19:51 +0000)]
Do not assume that FP vector operands are never legalized by expanding

This patch ensures that if a floating point vector operand is legalized by
expanding, it is legalized through the stack rather than by calling
DAGTypeLegalizer::IntegerToVector which will cause a failure since the operand
is a non-integer type.

This fixes PR 30715.

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

7 years agoSimplify `x >=u x >> y` and `x >=u x udiv y`
Sanjoy Das [Wed, 26 Oct 2016 19:18:43 +0000 (19:18 +0000)]
Simplify `x >=u x >> y` and `x >=u x udiv y`

Summary:
Extends InstSimplify to handle both `x >=u x >> y` and `x >=u x udiv y`.

This is a folloup of rL258422 and
https://github.com/rust-lang/rust/pull/30917 where llvm failed to
optimize away the bounds checking in a binary search.

Patch by Arthur Silva!

Reviewers: sanjoy

Subscribers: llvm-commits

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

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

7 years agoRevert "[AliasSetTracker] Make AST smarter about intrinsics that don't actually affec...
Chad Rosier [Wed, 26 Oct 2016 19:18:19 +0000 (19:18 +0000)]
Revert "[AliasSetTracker] Make AST smarter about intrinsics that don't actually affect memory."

This reverts commit r285191.

LICM appears to rely on the Alias Set Tracker hitting lifetime markers to prevent
code from being moved outside of the original scope.

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

7 years ago[PowerPC] Implement vec_insert_exp builtins - llvm portion
Nemanja Ivanovic [Wed, 26 Oct 2016 19:03:40 +0000 (19:03 +0000)]
[PowerPC] Implement vec_insert_exp builtins - llvm portion

This revision corresponds to review: https://reviews.llvm.org/D25957.
Committing on behalf of Zaara Syeda.

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

7 years ago[libFuzzer] simplify TracePC::HandleTrace even further. Also, when dealing with ...
Kostya Serebryany [Wed, 26 Oct 2016 18:52:04 +0000 (18:52 +0000)]
[libFuzzer] simplify TracePC::HandleTrace even further. Also, when dealing with -exit_on_src_pos, symbolize every PC only once

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

7 years agoFix test from r285217.
Chad Rosier [Wed, 26 Oct 2016 18:49:16 +0000 (18:49 +0000)]
Fix test from r285217.

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

7 years ago[AArch64] Avoid materializing constant 1 when generating cneg instructions.
Chad Rosier [Wed, 26 Oct 2016 18:15:32 +0000 (18:15 +0000)]
[AArch64] Avoid materializing constant 1 when generating cneg instructions.

Instead of

 cmp w0, #1
 orr w8, wzr, #0x1
 cneg w0, w8, ne

we now generate

 cmp w0, #1
 csinv w0, w0, wzr, eq

PR28965

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

7 years ago[WebAssembly] Update the README.txt.
Dan Gohman [Wed, 26 Oct 2016 17:44:09 +0000 (17:44 +0000)]
[WebAssembly] Update the README.txt.

Update the README.txt with newer information, add a link to the Emscripten
page explaining the current easiest way to use the LLVM wasm backend, and
mention that other ways of using the LLVM wasm backend are in development.

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

7 years ago[MC] Fix comma typo in .loc parsing
Nirav Dave [Wed, 26 Oct 2016 17:28:58 +0000 (17:28 +0000)]
[MC] Fix comma typo in .loc parsing

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

7 years agoReapply: "Remove debug location from common tail when tail-merging"
Robert Lougher [Wed, 26 Oct 2016 17:01:47 +0000 (17:01 +0000)]
Reapply: "Remove debug location from common tail when tail-merging"

This reapplies revision 285093.  Original commit message:

The branch folding pass tail merges blocks into a common-tail.  However, the
tail retains the debug information from one of the original inputs to the
merge (chosen randomly).  This is a problem for sampled-based PGO, as hits
on the common-tail will be attributed to whichever block was chosen,
irrespective of which path was actually taken to the common-tail.

This patch fixes the issue by nulling the debug location for the common-tail.

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

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

7 years agoAMDGPU: Refactor processor definition to use ISA version features
Yaxun Liu [Wed, 26 Oct 2016 16:37:56 +0000 (16:37 +0000)]
AMDGPU: Refactor processor definition to use ISA version features

Add missing ISA versions 7.0.2/8.0.4/8.1.0. to backend.

Refactor processor definition to use ISA version features.

Fixed ISA version for stoney.

Based on Laurent Morichetti's patch.

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

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

7 years agoIntroduce updateDiscriminator interface to DILocation to make it cleaner assigning...
Dehao Chen [Wed, 26 Oct 2016 15:48:45 +0000 (15:48 +0000)]
Introduce updateDiscriminator interface to DILocation to make it cleaner assigning discriminators.

Summary: This patch introduces updateDiscriminator to DILocation so that it can be directly called by AddDiscriminator. It also makes it easier to update the discriminator later.

Reviewers: dnovillo, dblaikie, aprantl, echristo

Subscribers: mehdi_amini, llvm-commits

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

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

7 years agoReapply "AMDGPU: Don't use offen if it is 0"
Matt Arsenault [Wed, 26 Oct 2016 15:08:16 +0000 (15:08 +0000)]
Reapply "AMDGPU: Don't use offen if it is 0"

This reverts r283003

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

7 years agoAMDGPU: Fix counting si_mask_branch as 4 bytes
Matt Arsenault [Wed, 26 Oct 2016 14:53:54 +0000 (14:53 +0000)]
AMDGPU: Fix counting si_mask_branch as 4 bytes

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

7 years agoFix nondeterministic output in local stack slot alloc pass
Matt Arsenault [Wed, 26 Oct 2016 14:53:50 +0000 (14:53 +0000)]
Fix nondeterministic output in local stack slot alloc pass

This finds all of the references to a frame index in a function, and
sorts by the offset. If multiple instructions use the same offset,
nothing was breaking the tie for sorting.

This avoids the test failures the reverted r282999 introduced.

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

7 years ago[InstCombine] clean up commonCastTransforms; NFC
Sanjay Patel [Wed, 26 Oct 2016 14:52:35 +0000 (14:52 +0000)]
[InstCombine] clean up commonCastTransforms; NFC

1. Use 'auto' with dyn_cast.
2. Variables start with a capital letter.
3. Use proper punctuation in comments.

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

7 years agoLegalizeDAG: Support promoting [US]DIV and [US]REM operations
Tom Stellard [Wed, 26 Oct 2016 14:52:25 +0000 (14:52 +0000)]
LegalizeDAG: Support promoting [US]DIV and [US]REM operations

Summary:
AMDGPU will need this one i16 is added as a legal type.  This is tested by:

test/CodeGen/AMDGPU/sdiv.ll
test/CodeGen/AMDGPU/sdivrem24.ll
test/CodeGen/AMDGPU/udiv.ll
test/CodeGen/AMDGPU/udivrem24.ll

Reviewers: bogner, efriedma

Subscribers: efriedma, wdng, llvm-commits

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

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

7 years agoAMDGPU/SI: Don't emit multi-dword flat memory ops when they might access scratch
Tom Stellard [Wed, 26 Oct 2016 14:38:47 +0000 (14:38 +0000)]
AMDGPU/SI: Don't emit multi-dword flat memory ops when they might access scratch

Summary:
A single flat memory operations that might access the scratch buffer
can only access MaxPrivateElementSize bytes.

Reviewers: arsenm

Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, tony-tye, llvm-commits

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

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

7 years agoAMDGPU/SI: Remove unnecessary run lines from test
Tom Stellard [Wed, 26 Oct 2016 14:21:09 +0000 (14:21 +0000)]
AMDGPU/SI: Remove unnecessary run lines from test

Summary:
This test had run lines disabling/enabling the promote alloca pass, but
enabling/disabling promote alloca had no impact on the output.

Reviewers: arsenm

Subscribers: mgrang, kzhuravl, wdng, nhaehnle, yaxunl, llvm-commits, tony-tye

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

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

7 years ago[X86] AVX512 fallback for floating-point scalar selects
Zvi Rackover [Wed, 26 Oct 2016 14:12:46 +0000 (14:12 +0000)]
[X86] AVX512 fallback for floating-point scalar selects

Summary:
In the case where of 'select i1 , f32, f32' or select i1, f64, f64 prefer lowering to masked-moves over branches.

Fixes pr30561

Reviewers: igorb, aymanmus, delena

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

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

7 years ago[InstCombine] consolidate zext tests and auto-generate checks; NFC
Sanjay Patel [Wed, 26 Oct 2016 14:08:49 +0000 (14:08 +0000)]
[InstCombine] consolidate zext tests and auto-generate checks; NFC

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

7 years ago[InstCombine] auto-generate better checks; NFC
Sanjay Patel [Wed, 26 Oct 2016 13:58:22 +0000 (13:58 +0000)]
[InstCombine] auto-generate better checks; NFC

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

7 years ago[AliasSetTracker] Make AST smarter about intrinsics that don't actually affect memory.
Chad Rosier [Wed, 26 Oct 2016 12:42:11 +0000 (12:42 +0000)]
[AliasSetTracker] Make AST smarter about intrinsics that don't actually affect memory.

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

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

7 years agoDebugInfo: support for DWARFv5 DW_AT_alignment attribute
Victor Leschuk [Wed, 26 Oct 2016 11:59:03 +0000 (11:59 +0000)]
DebugInfo: support for DWARFv5 DW_AT_alignment attribute

* Assume that clang passes non-zero alignment value to DIBuilder
only in case when it was forced by C++11 'alignas', C11 '_Alignas'
or compiler attribute '__attribute__((aligned (N)))'.

* Emit DW_AT_alignment if alignment is specified for type/object.

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

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

7 years ago[IndVarSimplify][DebugLoc] When widening the exit loop condition, correctly reuse...
Andrea Di Biagio [Wed, 26 Oct 2016 10:28:32 +0000 (10:28 +0000)]
[IndVarSimplify][DebugLoc] When widening the exit loop condition, correctly reuse the debug location of the original comparison.

When the loop exit condition is canonicalized as a != compaison, reuse the
debug location of the original (non canonical) comparison.

Before this patch, the debug location of the new icmp was obtained from the
loop latch terminator. This patch fixes the issue by correctly setting the
IRBuilder's "current debug location" to the location of the original compare.

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

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

7 years agoRevert r285181 "DebugInfo: support for DWARFv5 DW_AT_alignment attribute".
Vassil Vassilev [Wed, 26 Oct 2016 10:13:47 +0000 (10:13 +0000)]
Revert r285181 "DebugInfo: support for DWARFv5 DW_AT_alignment attribute".

The commit broke the builds.

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

7 years agoDebugInfo: support for DWARFv5 DW_AT_alignment attribute
Victor Leschuk [Wed, 26 Oct 2016 08:55:27 +0000 (08:55 +0000)]
DebugInfo: support for DWARFv5 DW_AT_alignment attribute

* Assume that clang passes non-zero alignment value to DIBuilder
only in case when it was forced by C++11 'alignas', C11 '_Alignas'
or compiler attribute '__attribute__((aligned (N)))'.

* Emit DW_AT_alignment if alignment is specified for type/object.

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

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

7 years agoDebugInfo: add bitcode upgrade test for alignment
Victor Leschuk [Wed, 26 Oct 2016 08:34:19 +0000 (08:34 +0000)]
DebugInfo: add bitcode upgrade test for alignment

Bitcode format was changed in D25073, this adds bitcode upgrade test.

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

7 years ago[XRay] Be case-insensitive for error strings
Dean Michael Berris [Wed, 26 Oct 2016 05:10:39 +0000 (05:10 +0000)]
[XRay] Be case-insensitive for error strings

On Windows, "no such file or directory" is the default error translation
as opposed to the capitalized form on Linux.

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

7 years ago[AVX-512] Add scalar vfmsub/vfnmsub mask3 intrinsics
Craig Topper [Wed, 26 Oct 2016 04:59:58 +0000 (04:59 +0000)]
[AVX-512] Add scalar vfmsub/vfnmsub mask3 intrinsics

Summary: Clang's intrinsic header currently tries to negate the third operand of a vfmadd mask3 in order to create vfmsub, but this fails isel. This patch adds scalar vfmsub and vfnmsub mask3 that we can use instead to avoid the negate. This is consistent with the packed instructions.

Reviewers: igorb, delena

Subscribers: llvm-commits

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

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

7 years ago[XRay] Remove unnecessary include of <unistd.h>
Dean Michael Berris [Wed, 26 Oct 2016 04:46:50 +0000 (04:46 +0000)]
[XRay] Remove unnecessary include of <unistd.h>

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

7 years ago[XRay] Remove unnecessary include of <unistd.h>
Dean Michael Berris [Wed, 26 Oct 2016 04:36:31 +0000 (04:36 +0000)]
[XRay] Remove unnecessary include of <unistd.h>

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

7 years ago[XRay] Move specialisations into correct namespace
Dean Michael Berris [Wed, 26 Oct 2016 04:26:53 +0000 (04:26 +0000)]
[XRay] Move specialisations into correct namespace

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

7 years ago[XRay] Remove extra `;` to make -wpedantic happy
Dean Michael Berris [Wed, 26 Oct 2016 04:21:17 +0000 (04:21 +0000)]
[XRay] Remove extra `;` to make -wpedantic happy

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

7 years ago[XRay] Add llvm-xray as a dependency to test/CMakeLists.txt
Dean Michael Berris [Wed, 26 Oct 2016 04:16:05 +0000 (04:16 +0000)]
[XRay] Add llvm-xray as a dependency to test/CMakeLists.txt

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

7 years ago[XRay] Implement `llvm-xray extract`, start of the llvm-xray tool
Dean Michael Berris [Wed, 26 Oct 2016 04:14:34 +0000 (04:14 +0000)]
[XRay] Implement `llvm-xray extract`, start of the llvm-xray tool

Usage:

  llvm-xray extract <object file> [-o <filename or '-'>]

The tool gets the XRay instrumentation map from an object file and turns
it into YAML.  We first support ELF64 sleds on x86_64 binaries, with
provision for supporting other supported platforms and formats later.

This is the first of a many-part change to fully implement the
`llvm-xray` tool.

We also define a subcommand registration and dispatch mechanism to be
used by other further subcommand implementations for llvm-xray.

Diffusion Revision: https://reviews.llvm.org/D21987

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

7 years agoCloning: Also clone global variable attached metadata.
Peter Collingbourne [Wed, 26 Oct 2016 02:57:33 +0000 (02:57 +0000)]
Cloning: Also clone global variable attached metadata.

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

7 years ago[libFuzzer] refresh docs
Kostya Serebryany [Wed, 26 Oct 2016 01:55:17 +0000 (01:55 +0000)]
[libFuzzer] refresh docs

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

7 years agoRevert "[XRay] Implement `llvm-xray extract`, start of the llvm-xray tool"
Dean Michael Berris [Wed, 26 Oct 2016 01:50:59 +0000 (01:50 +0000)]
Revert "[XRay] Implement `llvm-xray extract`, start of the llvm-xray tool"

Reverts r285155 -- misconfigured tests.

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

7 years ago[XRay] Implement `llvm-xray extract`, start of the llvm-xray tool
Dean Michael Berris [Wed, 26 Oct 2016 01:42:59 +0000 (01:42 +0000)]
[XRay] Implement `llvm-xray extract`, start of the llvm-xray tool

Usage:

  llvm-xray extract <object file> [-o <filename or '-'>]

The tool gets the XRay instrumentation map from an object file and turns
it into YAML.  We first support ELF64 sleds on x86_64 binaries, with
provision for supporting other supported platforms and formats later.

This is the first of a many-part change to fully implement the
`llvm-xray` tool.

We also define a subcommand registration and dispatch mechanism to be
used by other further subcommand implementations for llvm-xray.

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

7 years agoUse printf instead of "echo -e" or "echo -n".
Rui Ueyama [Wed, 26 Oct 2016 01:07:26 +0000 (01:07 +0000)]
Use printf instead of "echo -e" or "echo -n".

Not all echo commands support "-e". On the other hand, printf
command is in POSIX, so it's more portable than "echo -e".

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

7 years ago[libFuzzer] simplify the code in TracePC::HandleTrace a bit more
Kostya Serebryany [Wed, 26 Oct 2016 00:42:52 +0000 (00:42 +0000)]
[libFuzzer] simplify the code in TracePC::HandleTrace a bit more

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

7 years ago[libFuzzer] simplify the code to print new PCs
Kostya Serebryany [Wed, 26 Oct 2016 00:20:51 +0000 (00:20 +0000)]
[libFuzzer] simplify the code to print new PCs

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

7 years agoUtility functions for appending to llvm.used/llvm.compiler.used.
Evgeniy Stepanov [Tue, 25 Oct 2016 23:53:31 +0000 (23:53 +0000)]
Utility functions for appending to llvm.used/llvm.compiler.used.

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

7 years ago[libFuzzer] simplify the code in TracePC::HandleTrace
Kostya Serebryany [Tue, 25 Oct 2016 23:52:25 +0000 (23:52 +0000)]
[libFuzzer] simplify the code in TracePC::HandleTrace

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

7 years ago[docs] Avoid repetition of 'considerable' in Error docs.
Lang Hames [Tue, 25 Oct 2016 23:08:32 +0000 (23:08 +0000)]
[docs] Avoid repetition of 'considerable' in Error docs.

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

7 years ago[docs] Use consistent style for "do more stuff" in Error docs examples.
Lang Hames [Tue, 25 Oct 2016 22:41:54 +0000 (22:41 +0000)]
[docs] Use consistent style for "do more stuff" in Error docs examples.

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

7 years ago[docs] Fix yet another Error docs formatting issue...
Lang Hames [Tue, 25 Oct 2016 22:38:50 +0000 (22:38 +0000)]
[docs] Fix yet another Error docs formatting issue...

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

7 years ago[docs] Fix a few more Error docs formatting issues.
Lang Hames [Tue, 25 Oct 2016 22:35:55 +0000 (22:35 +0000)]
[docs] Fix a few more Error docs formatting issues.

Thanks to Pete Cooper for the review.

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

7 years ago[libFuzzer] add StandaloneFuzzTargetMain.c and a test for it
Kostya Serebryany [Tue, 25 Oct 2016 22:30:34 +0000 (22:30 +0000)]
[libFuzzer] add StandaloneFuzzTargetMain.c and a test for it

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

7 years ago[docs] Fix a missing code-block in the new Error docs.
Lang Hames [Tue, 25 Oct 2016 22:25:07 +0000 (22:25 +0000)]
[docs] Fix a missing code-block in the new Error docs.

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

7 years ago[docs] Fix a couple of typos in the new Error docs.
Lang Hames [Tue, 25 Oct 2016 22:22:48 +0000 (22:22 +0000)]
[docs] Fix a couple of typos in the new Error docs.

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

7 years ago[Sparc] Don't overlap variable-sized allocas with other stack variables.
James Y Knight [Tue, 25 Oct 2016 22:13:28 +0000 (22:13 +0000)]
[Sparc] Don't overlap variable-sized allocas with other stack variables.

On SparcV8, it was previously the case that a variable-sized alloca
might overlap by 4-bytes the last fixed stack variable, effectively
because 92 (the number of bytes reserved for the register spill area) !=
96 (the offset added to SP for where to start a DYNAMIC_STACKALLOC).

It's not as simple as changing 96 to 92, because variables that should
be 8-byte aligned would then be misaligned.

For now, simply increase the allocation size by 8 bytes for each dynamic
allocation -- wastes space, but at least doesn't overlap. As the large
comment says, doing this more efficiently will require larger changes in
llvm.

Also adds some test cases showing that we continue to not support
dynamic stack allocation and over-alignment in the same function.

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

7 years ago[codeview] support emitting indirect virtual base class information
Bob Haarman [Tue, 25 Oct 2016 22:11:52 +0000 (22:11 +0000)]
[codeview] support emitting indirect virtual base class information

Summary:
Fixes PR28281.

MSVC lists indirect virtual base classes in the field list of a class,
using LF_IVBCLASS records. This change makes LLVM emit such records
when processing DW_TAG_inheritance tags with the DIFlagVirtual and
(newly introduced) DIFlagIndirect tags.

Reviewers: rnk, ruiu, zturner

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

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

7 years ago[DAGCombiner] Enable (urem x, (shl pow2, y)) -> (and x, (add (shl pow2, y), -1))...
Simon Pilgrim [Tue, 25 Oct 2016 22:01:09 +0000 (22:01 +0000)]
[DAGCombiner] Enable (urem x, (shl pow2, y)) -> (and x, (add (shl pow2, y), -1)) combine for splatted vectors

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

7 years ago[PGO] Fix select instruction annotation
Rong Xu [Tue, 25 Oct 2016 21:47:24 +0000 (21:47 +0000)]
[PGO] Fix select instruction annotation

Summary:
Select instruction annotation in IR PGO uses the edge count to infer the
branch count. It's currently placed in setInstrumentedCounts() where
no all the BB counts have been computed. This leads to wrong branch weights.
Move the annotation after all BB counts are populated.

Reviewers: davidxl

Subscribers: llvm-commits

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

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

7 years ago[X86][SSE] Regenerated known-bits test with srem->urem fix
Simon Pilgrim [Tue, 25 Oct 2016 21:24:33 +0000 (21:24 +0000)]
[X86][SSE] Regenerated known-bits test with srem->urem fix

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

7 years ago[DAGCombiner] Enable srem(x.y) -> urem(x,y) combine for vectors
Simon Pilgrim [Tue, 25 Oct 2016 21:20:18 +0000 (21:20 +0000)]
[DAGCombiner] Enable srem(x.y) -> urem(x,y) combine for vectors

SelectionDAG::SignBitIsZero (via SelectionDAG::computeKnownBits) has supported vectors since rL280927

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

7 years ago[docs] Add more Error documentation to the Programmer's Manual.
Lang Hames [Tue, 25 Oct 2016 21:19:30 +0000 (21:19 +0000)]
[docs] Add more Error documentation to the Programmer's Manual.

This patch updates some of the existing Error examples, expands on the
documentation for handleErrors, and includes new sections that cover
a number of helpful utilities and common error usage idioms.

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

7 years ago[X86][SSE] Added vector srem combine tests
Simon Pilgrim [Tue, 25 Oct 2016 21:14:11 +0000 (21:14 +0000)]
[X86][SSE] Added vector srem combine tests

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

7 years ago[X86][SSE] Added vector urem combine tests
Simon Pilgrim [Tue, 25 Oct 2016 21:10:12 +0000 (21:10 +0000)]
[X86][SSE] Added vector urem combine tests

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

7 years ago[DAGCombiner] Enable sdiv(x.y) -> udiv(x,y) combine for vectors
Simon Pilgrim [Tue, 25 Oct 2016 20:56:42 +0000 (20:56 +0000)]
[DAGCombiner] Enable sdiv(x.y) -> udiv(x,y) combine for vectors

SelectionDAG::SignBitIsZero (via SelectionDAG::computeKnownBits) has supported vectors since rL280927

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

7 years ago[InstCombine] Resubmit the combine of A->B->A BitCast and fix for pr27996
Guozhi Wei [Tue, 25 Oct 2016 20:43:42 +0000 (20:43 +0000)]
[InstCombine] Resubmit the combine of A->B->A BitCast and fix for pr27996

The original patch of the A->B->A BitCast optimization was reverted by r274094 because it may cause infinite loop inside compiler https://llvm.org/bugs/show_bug.cgi?id=27996.

The problem is with following code

xB = load (type B);
xA = load (type A);
+yA = (A)xB; B -> A
+zAn = PHI[yA, xA]; PHI
+zBn = (B)zAn; // A -> B
store zAn;
store zBn;

optimizeBitCastFromPhi generates

+zBn = (B)zAn; // A -> B

and expects it will be combined with the following store instruction to another

store zAn

Unfortunately before combineStoreToValueType is called on the store instruction, optimizeBitCastFromPhi is called on the new BitCast again, and this pattern repeats indefinitely.

optimizeBitCastFromPhi only generates BitCast for load/store instructions, only the BitCast before store can cause the reexecution of optimizeBitCastFromPhi, and BitCast before store can easily be handled by InstCombineLoadStoreAlloca.cpp. So the solution to the problem is if all users of a CI are store instructions, we should not do optimizeBitCastFromPhi on it. Then optimizeBitCastFromPhi will not be called on the new BitCast instructions.

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

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

7 years ago[X86][SSE] Added vector sdiv combine tests
Simon Pilgrim [Tue, 25 Oct 2016 20:25:47 +0000 (20:25 +0000)]
[X86][SSE] Added vector sdiv combine tests

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

7 years agorevert: "Remove debug location from common tail when tail-merging"
Robert Lougher [Tue, 25 Oct 2016 20:17:58 +0000 (20:17 +0000)]
revert: "Remove debug location from common tail when tail-merging"

This reverts r285093, as it caused unexpected buildbot failures on
clang-ppc64le-linux, clang-ppc64be-linux, clang-ppc64be-linux-multistage
and clang-ppc64be-linux-lnt.  Failing test ubsan/TestCases/TypeCheck/vptr.cpp.

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

7 years ago[libFuzzer] when mutating based on CMP traces also try adding +/- 1 to the desired...
Kostya Serebryany [Tue, 25 Oct 2016 20:15:15 +0000 (20:15 +0000)]
[libFuzzer] when mutating based on CMP traces also try adding +/- 1 to the desired bytes. Add another test for use_cmp

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

7 years ago[InstCombine] Ensure that truncated int types are legal.
Sanjay Patel [Tue, 25 Oct 2016 20:11:47 +0000 (20:11 +0000)]
[InstCombine] Ensure that truncated int types are legal.

Fixes the FIXMEs in D25952 and rL285075.

Patch by bryant!

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

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

7 years ago[AArch64] Adjust the cost model for Exynos M1.
Evandro Menezes [Tue, 25 Oct 2016 20:05:42 +0000 (20:05 +0000)]
[AArch64] Adjust the cost model for Exynos M1.

Modify the maximum jump table size.

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

7 years ago[APFloat] Make APFloat an interface class to the internal IEEEFloat. NFC.
Tim Shen [Tue, 25 Oct 2016 19:55:59 +0000 (19:55 +0000)]
[APFloat] Make APFloat an interface class to the internal IEEEFloat. NFC.

Summary:
The intention is to make APFloat an interface class, so that later I can add a second implementation class DoubleAPFloat to correctly implement PPCDoubleDouble semantic. The interface of IEEEFloat is not public, and can be simplified (currently it's exactly the same as the old APFloat), but that belongs to a separate patch.

DoubleAPFloat should look like:
class DoubleAPFloat {
  const fltSemantics *Semantics;
  std::unique_ptr<APFloat> APFloats;  // Two heap-allocated APFloats.
};

There is no functional change, nor public interface change.

Reviewers: hfinkel, chandlerc, iteratee, echristo, kbarton

Subscribers: llvm-commits, mehdi_amini

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

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

7 years agoAdd option to specify minimum number of entries for jump tables
Evandro Menezes [Tue, 25 Oct 2016 19:53:51 +0000 (19:53 +0000)]
Add option to specify minimum number of entries for jump tables

Add an option to allow easier experimentation by target maintainers with the
minimum number of entries to create jump tables.  Also clarify the name of
the other existing option governing the creation of jump tables.

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

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

7 years ago[llvm-cov] Don't use colored output until we know it's supported
Vedant Kumar [Tue, 25 Oct 2016 19:52:57 +0000 (19:52 +0000)]
[llvm-cov] Don't use colored output until we know it's supported

CodeCoverageTool::error() depends on CoverageViewOptions::Colors being
initialized. Should fix:

  http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-fast/builds/56

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

7 years agoSwitch lowering: improve partitioning of jump tables
Evandro Menezes [Tue, 25 Oct 2016 19:11:43 +0000 (19:11 +0000)]
Switch lowering: improve partitioning of jump tables

When there's a tie between partitionings of jump tables, consider also cases
that result in no jump tables, but in one or a few cases.  The motivation is
that many contemporary processors typically perform case switches fairly
quickly.

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

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

7 years ago[LV] Sink scalar operands of predicated instructions
Matthew Simpson [Tue, 25 Oct 2016 18:59:45 +0000 (18:59 +0000)]
[LV] Sink scalar operands of predicated instructions

When we predicate an instruction (div, rem, store) we place the instruction in
its own basic block within the vectorized loop. If a predicated instruction has
scalar operands, it's possible to recursively sink these scalar expressions
into the predicated block so that they might avoid execution. This patch sinks
as much scalar computation as possible into predicated blocks. We previously
were able to sink such operands only if they were extractelement instructions.

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

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

7 years ago[InstCombine] add tests for missing icmp + shl nuw fold
Sanjay Patel [Tue, 25 Oct 2016 18:47:56 +0000 (18:47 +0000)]
[InstCombine] add tests for missing icmp + shl nuw fold

Patch by bryant!

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

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

7 years agoAdd -strip-nonlinetable-debuginfo capability
Michael Ilseman [Tue, 25 Oct 2016 18:44:13 +0000 (18:44 +0000)]
Add -strip-nonlinetable-debuginfo capability

This adds a new function to DebugInfo.cpp that takes an llvm::Module
as input and removes all debug info metadata that is not directly
needed for line tables, thus effectively stripping all type and
variable information from the module.

The primary motivation for this feature was the bitcode work flow
(cf. http://lists.llvm.org/pipermail/llvm-dev/2016-June/100643.html
for more background). This is not wired up yet, but will be in
subsequent patches.  For testing, the new functionality is exposed to
opt with a -strip-nonlinetable-debuginfo option.

The secondary use-case (and one that works right now!) is as a
reduction pass in bugpoint. I added two new bugpoint options
(-disable-strip-debuginfo and -disable-strip-debug-types) to control
the new features. By default it will first attempt to remove all debug
information, then only the type info, and then proceed to hack at any
remaining MDNodes.

Thanks to Adrian Prantl for stewarding this patch!

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

7 years agoRemove debug location from common tail when tail-merging
Robert Lougher [Tue, 25 Oct 2016 18:44:07 +0000 (18:44 +0000)]
Remove debug location from common tail when tail-merging

The branch folding pass tail merges blocks into a common-tail.  However, the
tail retains the debug information from one of the original inputs to the
merge (chosen randomly).  This is a problem for sampled-based PGO, as hits
on the common-tail will be attributed to whichever block was chosen,
irrespective of which path was actually taken to the common-tail.

This patch fixes the issue by nulling the debug location for the common-tail.

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

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

7 years agoFix 80-char violations. NFC.
Michael Kuperstein [Tue, 25 Oct 2016 18:31:23 +0000 (18:31 +0000)]
Fix 80-char violations. NFC.

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

7 years ago[unittests] STLExtrasTest: Remove an MSVC 2013 workaround, NFCI.
Vedant Kumar [Tue, 25 Oct 2016 18:11:17 +0000 (18:11 +0000)]
[unittests] STLExtrasTest: Remove an MSVC 2013 workaround, NFCI.

Let's see what the bots have to say about this...

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

7 years ago[unittests] Remove an MSVC 2013 workaround, NFCI.
Vedant Kumar [Tue, 25 Oct 2016 17:58:25 +0000 (17:58 +0000)]
[unittests] Remove an MSVC 2013 workaround, NFCI.

Let's see what the bots have to say about this...

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

7 years agoRevert 285087.
Nico Weber [Tue, 25 Oct 2016 17:46:29 +0000 (17:46 +0000)]
Revert 285087.

The sanitizer-windows bot turned red with:

FAILED: utils/TableGen/CMakeFiles/obj.llvm-tblgen.dir/IntrinsicEmitter.cpp.obj
C:\PROGRA~2\MICROS~1.0\VC\bin\AMD64_~2\cl.exe ... -c
    C:\...\llvm\utils\TableGen\IntrinsicEmitter.cpp
c:\...\llvm\utils\tablegen\intrinsicemitter.cpp(254) :
  fatal error C1001: An internal error has occurred in the compiler.
http://lab.llvm.org:8011/builders/sanitizer-windows/builds/114/steps/build%20clang%20lld/logs/stdio

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

7 years ago[llvm-cov] Add support for loading coverage from multiple objects
Vedant Kumar [Tue, 25 Oct 2016 17:40:55 +0000 (17:40 +0000)]
[llvm-cov] Add support for loading coverage from multiple objects

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

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

7 years agoTry removing an MSVC2010 workaround.
Nico Weber [Tue, 25 Oct 2016 17:35:00 +0000 (17:35 +0000)]
Try removing an MSVC2010 workaround.

Things seem to build fine locally without this, so let's
see what the bots think.

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

7 years ago[WebAssembly] Add immediate fields to call_indirect and memory operators.
Dan Gohman [Tue, 25 Oct 2016 16:55:52 +0000 (16:55 +0000)]
[WebAssembly] Add immediate fields to call_indirect and memory operators.

call_indirect, grow_memory, and current_memory now have immediate
operands in the 0xd binary encoding.

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

7 years agoMove discriminator assignment to where it is used. (NFC)
Dehao Chen [Tue, 25 Oct 2016 16:50:27 +0000 (16:50 +0000)]
Move discriminator assignment to where it is used. (NFC)

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

7 years ago[IndVarSimplify][Dwarf] When widening the IV increment, correctly set the debug loc.
Andrea Di Biagio [Tue, 25 Oct 2016 16:45:17 +0000 (16:45 +0000)]
[IndVarSimplify][Dwarf] When widening the IV increment, correctly set the debug loc.

When indvars widened an induction variable, the debug location for the loop
increment computation was incorrectly set equal to the debug loc of the loop
latch terminator.

This patch fixes the issue by propagating the correct location from the
original loop increment instruction to the new widened increment.

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

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

7 years agoReplace TimeValue by TimePoint in LegacyPassManager. NFC.
Pavel Labath [Tue, 25 Oct 2016 16:20:07 +0000 (16:20 +0000)]
Replace TimeValue by TimePoint in LegacyPassManager. NFC.

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