OSDN Git Service

android-x86/external-llvm.git
8 years agocmake: Fix grammar
Tobias Grosser [Fri, 29 Apr 2016 13:03:40 +0000 (13:03 +0000)]
cmake: Fix grammar

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

8 years ago[mips][ias] Make section sizes a multiple of the alignment.
Daniel Sanders [Fri, 29 Apr 2016 12:44:07 +0000 (12:44 +0000)]
[mips][ias] Make section sizes a multiple of the alignment.

Reviewers: sdardis

Subscribers: dsanders, llvm-commits, sdardis

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

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

8 years agoRevert "cmake: Set LINK_POLLY_INTO_TOOLS to ON"
Tobias Grosser [Fri, 29 Apr 2016 12:38:24 +0000 (12:38 +0000)]
Revert "cmake: Set LINK_POLLY_INTO_TOOLS to ON"

This reverts commit r268033 as it breaks some buildbots.

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

8 years agocmake: Set LINK_POLLY_INTO_TOOLS to ON
Tobias Grosser [Fri, 29 Apr 2016 12:23:11 +0000 (12:23 +0000)]
cmake: Set LINK_POLLY_INTO_TOOLS to ON

With Polly checked into LLVM it was since a long time possible to compile
clang/opt/bugpoint with Polly support directly linked in, instead of only
providing Polly as a separate loadable module. This commit switches the
default from providing Polly as a module to linking Polly into tools, such
that it becomes unnecessary to load the Polly module when playing with Polly.
Such configuration has shown a lot more convenient for day-to-day Polly use.

This change does not impact the default behavior of any tool, if Polly is not
explicitly enabled when calling clang/opt/bugpoint Polly does not affect
compilation.

This change also does not impact normal LLVM/clang checkouts that do not
contain Polly.

Reviewers: jdoerfert, Meinersbur, sebpop, etherzhhb, zinob, hiraditya

Subscribers: pollydev, llvm-commits

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

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

8 years ago[InstCombine][SSE] Added x86 pshufb undef mask tests
Simon Pilgrim [Fri, 29 Apr 2016 09:13:53 +0000 (09:13 +0000)]
[InstCombine][SSE] Added x86 pshufb undef mask tests

FIXME: We currently don't support folding constant pshufb shuffle masks containing undef elements.

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

8 years agoAMDGPU/SI: Assembler: Unify parsing/printing of operands.
Nikolay Haustov [Fri, 29 Apr 2016 09:02:30 +0000 (09:02 +0000)]
AMDGPU/SI: Assembler: Unify parsing/printing of operands.

Summary:
The goal is for each operand type to have its own parse function and
at the same time share common code for tracking state as different
instruction types share operand types (e.g. glc/glc_flat, etc).

Introduce parseAMDGPUOperand which can parse any optional operand.
DPP and Clamp/OMod have custom handling for now. Sam also suggested
to have class hierarchy for operand types instead of table. This
can be done in separate change.

Remove parseVOP3OptionalOps, parseDS*OptionalOps, parseFlatOptionalOps,
parseMubufOptionalOps, parseDPPOptionalOps.
Reduce number of definitions of AsmOperand's and MatchClasses' by using common base class.
Rename AsmMatcher/InstPrinter methods accordingly.
Print immediate type when printing parsed immediate operand.
Use 'off' if offset/index register is unused instead of skipping it to make it more readable (also agreed with SP3).
Update tests.

Reviewers: tstellarAMD, SamWot, artem.tamazov

Subscribers: qcolombet, arsenm, llvm-commits

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

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

8 years ago[InstCombine][SSE] Regenerated x86 pshufb tests
Simon Pilgrim [Fri, 29 Apr 2016 08:53:35 +0000 (08:53 +0000)]
[InstCombine][SSE] Regenerated x86 pshufb tests

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

8 years ago[mips][microMIPS] Fix offsets for LLE, LWE, SBE, SCE and SHE instructions
Zlatko Buljan [Fri, 29 Apr 2016 08:36:54 +0000 (08:36 +0000)]
[mips][microMIPS] Fix offsets for LLE, LWE, SBE, SCE and SHE instructions
Differential Revision: http://reviews.llvm.org/D18645

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

8 years ago[GlobalOpt] Propagate operand bundles
David Majnemer [Fri, 29 Apr 2016 08:07:22 +0000 (08:07 +0000)]
[GlobalOpt] Propagate operand bundles

We neglected to transfer operand bundles for some transforms.  These
were found via inspection, I'll try to come up with some test cases.

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

8 years ago[InstCombine] Propagate operand bundles
David Majnemer [Fri, 29 Apr 2016 08:07:20 +0000 (08:07 +0000)]
[InstCombine] Propagate operand bundles

We neglected to transfer operand bundles for some transforms.  These
were found via inspection, I'll try to come up with some test cases.

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

8 years ago[DeadArgumentElimination] Propagate operand bundles to promoted call sites
David Majnemer [Fri, 29 Apr 2016 07:22:36 +0000 (07:22 +0000)]
[DeadArgumentElimination] Propagate operand bundles to promoted call sites

We neglected to transfer operand bundles when performing argument
promotion.

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

8 years ago[LoopDist] Add missing RUN line in test from r268006
Adam Nemet [Fri, 29 Apr 2016 07:16:00 +0000 (07:16 +0000)]
[LoopDist] Add missing RUN line in test from r268006

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

8 years ago[LoopDist] Also emit optimization remark on success (-Rpass=)
Adam Nemet [Fri, 29 Apr 2016 07:10:46 +0000 (07:10 +0000)]
[LoopDist] Also emit optimization remark on success (-Rpass=)

The option -Rpass=loop-distribute now reports the loops that were
distributed.

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

8 years ago[LoopDist] Pass 'Function' to main class. NFC
Adam Nemet [Fri, 29 Apr 2016 07:10:39 +0000 (07:10 +0000)]
[LoopDist] Pass 'Function' to main class. NFC

Next patch will add another use for 'Function' inside the class.

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

8 years ago[SLPVectorizer] Add operand bundles to vectorized functions
David Majnemer [Fri, 29 Apr 2016 07:09:51 +0000 (07:09 +0000)]
[SLPVectorizer] Add operand bundles to vectorized functions

SLPVectorizing a call site should result in further propagation of its
bundles.

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

8 years ago[LoopVectorize] Add operand bundles to vectorized functions
David Majnemer [Fri, 29 Apr 2016 07:09:48 +0000 (07:09 +0000)]
[LoopVectorize] Add operand bundles to vectorized functions

Also, do not crash when calculating a cost model for loop-invariant
token values.

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

8 years agoAMDGPU: Stop reporting an addressing mode for unknown addrspace
Matt Arsenault [Fri, 29 Apr 2016 06:25:10 +0000 (06:25 +0000)]
AMDGPU: Stop reporting an addressing mode for unknown addrspace

This was being treated the same as private, which has an immediate
offset. For unknown, it probably means it's for a computation not
actually being used for accessing memory, so it should not have a
nontrivial addressing mode.

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

8 years agoDivergenceAnalysis: Fix crash with unreachable blocks
Matt Arsenault [Fri, 29 Apr 2016 06:17:47 +0000 (06:17 +0000)]
DivergenceAnalysis: Fix crash with unreachable blocks

Unreachable blocks may not be in the dominator tree,
so don't crash on them.

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

8 years ago[ArgumentPromotion] Propagate operand bundles to promoted call sites
David Majnemer [Fri, 29 Apr 2016 04:56:12 +0000 (04:56 +0000)]
[ArgumentPromotion] Propagate operand bundles to promoted call sites

We neglected to transfer operand bundles when performing argument
promotion.

This fixes PR27568.

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

8 years ago[X86] Remove unnecessary header file containing a small class. It was only included...
Craig Topper [Fri, 29 Apr 2016 04:22:28 +0000 (04:22 +0000)]
[X86] Remove unnecessary header file containing a small class. It was only included in one place. Just define the class directly in the cpp file. NFC

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

8 years ago[X86] Include X86MCTargetDesc.h directly in X86Disassembler.cpp instead of duplicatin...
Craig Topper [Fri, 29 Apr 2016 04:22:26 +0000 (04:22 +0000)]
[X86] Include X86MCTargetDesc.h directly in X86Disassembler.cpp instead of duplicating parts of it. NFC

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

8 years ago[PR25281] Remove AAResultsWrapper from preserved analyses of loop vectorizer.
Michael Zolotukhin [Fri, 29 Apr 2016 03:31:25 +0000 (03:31 +0000)]
[PR25281] Remove AAResultsWrapper from preserved analyses of loop vectorizer.

We don't preserve AAResults, because, for one, we don't preserve SCEV-AA.
That fixes PR25281.

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

8 years agoRemove stale documentation on -no-aa
Sanjoy Das [Fri, 29 Apr 2016 03:01:49 +0000 (03:01 +0000)]
Remove stale documentation on -no-aa

The pass itself was removed in rL247167.

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

8 years agoRegisterPressure: Fix default lanemask for missing regunit intervals
Matthias Braun [Fri, 29 Apr 2016 02:44:54 +0000 (02:44 +0000)]
RegisterPressure: Fix default lanemask for missing regunit intervals

In case of missing live intervals for a physical registers
getLanesWithProperty() would report 0 which was not a safe default in
all situations. Add a parameter to pass in a safe default.
No testcase because in-tree targets do not skip computing register unit
live intervals.

Also cleanup the getXXX() functions to not perform the
RequireLiveIntervals checks anymore so we do not even need to return
safe defaults.

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

8 years agoRegisterPressure: Cannot produce dead (subregister) defs anymore
Matthias Braun [Fri, 29 Apr 2016 02:44:48 +0000 (02:44 +0000)]
RegisterPressure: Cannot produce dead (subregister) defs anymore

With the DetectDeadLanes pass in place we cannot run into situations
anymore where defs suddenly become dead.
Also add a missing check so we do not try to add an undef flag to a
physreg (found by visual inspection, no failing test).

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

8 years agoFix build by casting to the proper int type.
Ivan Krasin [Fri, 29 Apr 2016 02:09:57 +0000 (02:09 +0000)]
Fix build by casting to the proper int type.

Reviewers: eugenis

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

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

8 years ago[llvm-cov] Don't emit 'nan%' in reports
Vedant Kumar [Fri, 29 Apr 2016 01:31:49 +0000 (01:31 +0000)]
[llvm-cov] Don't emit 'nan%' in reports

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

8 years ago[LoopVectorize] Keep hints from original loop on the vector loop
Hal Finkel [Fri, 29 Apr 2016 01:27:40 +0000 (01:27 +0000)]
[LoopVectorize] Keep hints from original loop on the vector loop

We need to keep loop hints from the original loop on the new vector loop.
Failure to do this meant that, for example:

  void foo(int *b) {
  #pragma clang loop unroll(disable)
    for (int i = 0; i < 16; ++i)
      b[i] = 1;
  }

this loop would be unrolled. Why? Because we'd vectorize it, thus dropping the
hints that unrolling should be disabled, and then we'd unroll it.

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

8 years ago[msan] Handle vector compare x86 intrinsics.
Evgeniy Stepanov [Fri, 29 Apr 2016 01:19:52 +0000 (01:19 +0000)]
[msan] Handle vector compare x86 intrinsics.

This handles SSE and SSE2 cmp_* and comiXX_* intrinsics.

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

8 years ago[llvm-pdbdump] Try to appease the ASan bot
David Majnemer [Fri, 29 Apr 2016 01:00:17 +0000 (01:00 +0000)]
[llvm-pdbdump] Try to appease the ASan bot

We didn't check that the file was large enough to hold a super block.

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

8 years ago[X86] Use nested switches to vary the operand to helper functions that were previousl...
Craig Topper [Fri, 29 Apr 2016 00:51:30 +0000 (00:51 +0000)]
[X86] Use nested switches to vary the operand to helper functions that were previously called in multiple cases. This seems to help the inliner reduce code. NFC

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

8 years ago[llvm-pdbdump] Restore error messages, handle bad block sizes
David Majnemer [Thu, 28 Apr 2016 23:47:27 +0000 (23:47 +0000)]
[llvm-pdbdump] Restore error messages, handle bad block sizes

We lost the ability to report errors, bring it back.  Also, correctly
validate the block size.

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

8 years agoLiveIntervalAnalysis: Remove LiveVariables requirement
Matthias Braun [Thu, 28 Apr 2016 23:42:51 +0000 (23:42 +0000)]
LiveIntervalAnalysis: Remove LiveVariables requirement

This requirement was a huge hack to keep LiveVariables alive because it
was optionally used by TwoAddressInstructionPass and PHIElimination.
However we have AnalysisUsage::addUsedIfAvailable() which we can use in
those passes.

This re-applies r260806 with LiveVariables manually added to PowerPC to
hopefully not break the stage 2 bots this time.

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

8 years ago[llvm-pdbdump] Correctly read data larger than a block
David Majnemer [Thu, 28 Apr 2016 23:24:23 +0000 (23:24 +0000)]
[llvm-pdbdump] Correctly read data larger than a block

A bug was introduced when the code was refactored which resulted in a
bad memory access.

This fixes PR27565.

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

8 years ago[LoopDist] Emit optimization remarks (-Rpass*)
Adam Nemet [Thu, 28 Apr 2016 23:08:32 +0000 (23:08 +0000)]
[LoopDist] Emit optimization remarks (-Rpass*)

I closely followed the precedents set by the vectorizer:

* With -Rpass-missed, the loop is reported with further details pointing
to -Rpass--analysis.

* -Rpass-analysis reports the details why distribution has failed.

* Regardless of -Rpass*, when distribution fails for a loop where
distribution was forced with the pragma, a warning is produced according
to -Wpass-failed.  In this case the analysis info is also printed even
without -Rpass-analysis.

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

8 years ago[LoopDist] Improve debug messages
Adam Nemet [Thu, 28 Apr 2016 23:08:30 +0000 (23:08 +0000)]
[LoopDist] Improve debug messages

The next patch will start using these for -Rpass-analysis so they won't
be internal-only anymore.

Move the 'Skipping; ' prefix that some of the message are using into the
'fail' function.  We don't want to include this prefix in
the -Rpass-analysis report.

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

8 years ago[LoopDist] Add helper to print debug message when distribution fails. NFC
Adam Nemet [Thu, 28 Apr 2016 23:08:27 +0000 (23:08 +0000)]
[LoopDist] Add helper to print debug message when distribution fails.  NFC

This will form the basis to emit optimization remarks (-Rpass*).

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

8 years ago[Inliner] Preserve llvm.mem.parallel_loop_access metadata
Hal Finkel [Thu, 28 Apr 2016 23:00:04 +0000 (23:00 +0000)]
[Inliner] Preserve llvm.mem.parallel_loop_access metadata

When inlining a call site with llvm.mem.parallel_loop_access metadata, this
metadata needs to be propagated to all cloned memory-accessing instructions.
Otherwise, inlining parts of the loop body will invalidate the annotation.

With this functionality, we now vectorize the following as expected:

  void Body(int *res, int *c, int *d, int *p, int i) {
    res[i] = (p[i] == 0) ? res[i] : res[i] + d[i];
  }

  void Test(int *res, int *c, int *d, int *p, int n) {
    int i;

  #pragma clang loop vectorize(assume_safety)
    for (i = 0; i < 1600; i++) {
      Body(res, c, d, p, i);
    }
  }

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

8 years agoRead discriminators correctly from object file.
Dehao Chen [Thu, 28 Apr 2016 22:09:37 +0000 (22:09 +0000)]
Read discriminators correctly from object file.

Summary:
This is the follow-up patch for http://reviews.llvm.org/D19436
* Update the discriminator reading algorithm to match the assignment algorithm.
* Add test to cover the new algorithm.

Reviewers: dnovillo, echristo, dblaikie

Subscribers: danielcdh, dblaikie, echristo, llvm-commits, joker.eph

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

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

8 years ago[CodeGen] Remove extra ';'
Marcin Koscielnicki [Thu, 28 Apr 2016 21:49:46 +0000 (21:49 +0000)]
[CodeGen] Remove extra ';'

Squashes a -Wpedantic warning.

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

8 years ago[PowerPC] Fix the EH_SjLj_Setup pseudo.
Marcin Koscielnicki [Thu, 28 Apr 2016 21:24:37 +0000 (21:24 +0000)]
[PowerPC] Fix the EH_SjLj_Setup pseudo.

This instruction is just a control flow marker - it should not
actually exist in the object file.  Unfortunately, nothing catches
it before it gets to AsmPrinter.  If integrated assembler is used,
it's considered to be a normal 4-byte instruction, and emitted as
an all-0 word, crashing the program.  With external assembler,
a comment is emitted.

Fixed by setting Size to 0 and handling it in MCCodeEmitter - this
means the comment will still be emitted if integrated assembler
is not used.

This broke an ASan test, which has been disabled for a long time
as a result (see the discussion on D19657).  We can reenable it
once this lands.

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

8 years agoFix a bug in llvm-objdump for -private-headers printing the LC_CODE_SIGNATURE Mach...
Kevin Enderby [Thu, 28 Apr 2016 21:07:20 +0000 (21:07 +0000)]
Fix a bug in llvm-objdump for -private-headers printing the LC_CODE_SIGNATURE Mach-O load command.

rdar://25985653

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

8 years ago[RDF] Recognize tail calls in graph creation
Krzysztof Parzyszek [Thu, 28 Apr 2016 20:40:08 +0000 (20:40 +0000)]
[RDF] Recognize tail calls in graph creation

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

8 years agoFix warning in PDB code. NFC
Amaury Sechet [Thu, 28 Apr 2016 20:39:39 +0000 (20:39 +0000)]
Fix warning in PDB code. NFC

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

8 years agoLiveIntervalAnalysis: No need to deal with dead subregister defs anymore.
Matthias Braun [Thu, 28 Apr 2016 20:35:26 +0000 (20:35 +0000)]
LiveIntervalAnalysis: No need to deal with dead subregister defs anymore.

The DetectDeadLaneMask already ensures that we have no dead subregister
definitions making the special handling in LiveIntervalAnalysis
unnecessary. This reverts most of r248335.

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

8 years ago[RDF] Improve handling of inline-asm
Krzysztof Parzyszek [Thu, 28 Apr 2016 20:33:33 +0000 (20:33 +0000)]
[RDF] Improve handling of inline-asm

- Keep implicit defs from inline-asm instructions.
- Treat register references from inline-asm as fixed.

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

8 years agoAdd parentheses to silence -Wparentheses warnings.
Zachary Turner [Thu, 28 Apr 2016 20:26:30 +0000 (20:26 +0000)]
Add parentheses to silence -Wparentheses warnings.

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

8 years ago[RDF] Add option to keep dead phi nodes in DFG
Krzysztof Parzyszek [Thu, 28 Apr 2016 20:17:06 +0000 (20:17 +0000)]
[RDF] Add option to keep dead phi nodes in DFG

Dead phi nodes are needed for code motion (such as copy propagation),
where a new use would be placed in a location that would be dominated
by a dead phi. Such a transformation is not legal for copy propagation,
and the existence of the phi would prevent it, but if the phi is not
there, it may appear to be valid.

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

8 years ago[CMake] [Darwin] Use libtool instead of ar && ranlib
Chris Bieneman [Thu, 28 Apr 2016 20:14:19 +0000 (20:14 +0000)]
[CMake] [Darwin] Use libtool instead of ar && ranlib

Summary: Using libtool instead of ar and ranlib on Darwin shaves a minute off my clang build. This is because on Darwin libtool is optimized to give hints to the kernel about filesystem interactions that allow it to be faster.

Reviewers: bogner, pete

Subscribers: llvm-commits

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

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

8 years agoUpdate llvm-objdump for disassembly of ARM Mach-O files to always include the opcode...
Kevin Enderby [Thu, 28 Apr 2016 20:14:13 +0000 (20:14 +0000)]
Update llvm-objdump for disassembly of ARM Mach-O files to always include the opcode bytes.

As this is the expected behavior of the old darwin otool(1) for ARM Mach-O files.

rdar://25896249

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

8 years agoRead the rest of the DBI substreams, and parse source info.
Zachary Turner [Thu, 28 Apr 2016 20:05:18 +0000 (20:05 +0000)]
Read the rest of the DBI substreams, and parse source info.

We now read out the rest of the substreams from the DBI streams.  One of
these substreams, the FileInfo substream, contains information about which
source files contribute to each module (aka compiland).  This patch
additionally parses out the file information from that substream, and
dumps it in llvm-pdbdump.

Differential Revision: http://reviews.llvm.org/D19634
Reviewed by: ruiu

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

8 years agoThis reverts commit r265505.
Kit Barton [Thu, 28 Apr 2016 20:00:42 +0000 (20:00 +0000)]
This reverts commit r265505.

Revert "[Power9] Implement add-pc, multiply-add, modulo, extend-sign-shift, random number, set bool, and dfp test significance".
This patch has caused a functional regression in SPEC2k6 namd, and a performance regression in mesa-pipe.

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

8 years ago[Hexagon] Add instruction aliases for vector unsigned compare-equal
Krzysztof Parzyszek [Thu, 28 Apr 2016 19:49:18 +0000 (19:49 +0000)]
[Hexagon] Add instruction aliases for vector unsigned compare-equal

Unsigned compare-equal instructions are mapped to signed compare-equal.

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

8 years agoAMDGPU: Emit error if too much LDS is used
Matt Arsenault [Thu, 28 Apr 2016 19:37:35 +0000 (19:37 +0000)]
AMDGPU: Emit error if too much LDS is used

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

8 years agoRemove doInitialization() and doFinalization() member declarations without definitions.
Yaron Keren [Thu, 28 Apr 2016 19:21:30 +0000 (19:21 +0000)]
Remove doInitialization() and doFinalization() member declarations without definitions.
Visual C++ 2015 flags this in the IDE.

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

8 years agoReset the TopRPTracker's position in ScheduleDAGMILive::initQueues
Krzysztof Parzyszek [Thu, 28 Apr 2016 19:17:44 +0000 (19:17 +0000)]
Reset the TopRPTracker's position in ScheduleDAGMILive::initQueues

ScheduleDAGMI::initQueues changes the RegionBegin to the first non-debug
instruction. Since it does not track register pressure, it does not affect
any RP trackers. ScheduleDAGMILive inherits initQueues from ScheduleDAGMI,
and it does reset the TopTPTracker in its schedule method. Any derived,
target-specific scheduler will need to do it as well, but the TopRPTracker
is only exposed as a "const" object to derived classes. Without the ability
to modify the tracker directly, this leaves a derived scheduler with a
potential of having the TopRPTracker out-of-sync with the CurrentTop.

The symptom of the problem:
  void llvm::ScheduleDAGMILive::scheduleMI(llvm::SUnit *, bool):
  Assertion `TopRPTracker.getPos() == CurrentTop && "out of sync"' failed.

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

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

8 years agoAMDGPU: Fix mishandling array allocations when promoting alloca
Matt Arsenault [Thu, 28 Apr 2016 18:38:48 +0000 (18:38 +0000)]
AMDGPU: Fix mishandling array allocations when promoting alloca

The canonical form for allocas is a single allocation of the array type.
In case we see a non-canonical array alloca, make sure we aren't
replacing this with an array N times smaller.

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

8 years agoFix builds broken in r267910.
Eugene Zelenko [Thu, 28 Apr 2016 18:27:35 +0000 (18:27 +0000)]
Fix builds broken in r267910.

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

8 years agoAdd "PIE Level" metadata to module flags.
Sriraman Tallam [Thu, 28 Apr 2016 18:15:44 +0000 (18:15 +0000)]
Add "PIE Level" metadata to module flags.

http://reviews.llvm.org/D19671

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

8 years agoFix some Clang-tidy modernize and Include What You Use warnings.
Eugene Zelenko [Thu, 28 Apr 2016 18:04:41 +0000 (18:04 +0000)]
Fix some Clang-tidy modernize and Include What You Use warnings.

Differential revision: http://reviews.llvm.org/D19673

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

8 years ago[PGO] Fix incorrect Twine usage in emitting optimization remarks.
Rong Xu [Thu, 28 Apr 2016 17:49:56 +0000 (17:49 +0000)]
[PGO] Fix incorrect Twine usage in emitting optimization remarks.

Should not store Twine objects to local variables. This is fixed the test
failures with r267815 in VS2015 X64 build.

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

8 years agoMinor format change and fixing typos in the comments. NFC.
Rong Xu [Thu, 28 Apr 2016 17:31:22 +0000 (17:31 +0000)]
Minor format change and fixing typos in the comments. NFC.

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

8 years ago[Hexagon] Define certain aliases for vector instructions
Krzysztof Parzyszek [Thu, 28 Apr 2016 16:43:16 +0000 (16:43 +0000)]
[Hexagon] Define certain aliases for vector instructions

Specifically:
  Vd = #0   -> Vd = vxor(Vd, Vd)
  Vdd = #0  -> Vdd.w = vsub(Vdd.w, Vdd.w)
  Vdd = Vss -> Vdd = vcombine(Vss.H, Vss.L)

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

8 years ago[mips][atomics] Fix partword atomic binary operation implementation
Simon Dardis [Thu, 28 Apr 2016 16:26:43 +0000 (16:26 +0000)]
[mips][atomics] Fix partword atomic binary operation implementation

Currently Mips::emitAtomicBinaryPartword() does not properly respect the
width of pointers. For MIPS64 this causes the memory address that the ll/sc
sequence uses to be truncated. At runtime this causes a segmentation fault.

This can be fixed by applying similar changes as r266204, so that a full 64bit
pointer is loaded.

Reviewers: dsanders

Differential Review: http://reviews.llvm.org/D19651

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

8 years ago[SLPVectorizer] Extend SLP Vectorizer to deal with aggregates.
Arch D. Robison [Thu, 28 Apr 2016 16:11:45 +0000 (16:11 +0000)]
[SLPVectorizer] Extend SLP Vectorizer to deal with aggregates.

The refactoring portion part was done as r267748.

http://reviews.llvm.org/D14185

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

8 years ago[GVN] Minor code cleanup. NFC.
Chad Rosier [Thu, 28 Apr 2016 16:00:15 +0000 (16:00 +0000)]
[GVN] Minor code cleanup. NFC.

Differential Revision: http://reviews.llvm.org/D18828
Patch by Aditya Kumar!

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

8 years ago[Hexagon] Handle double-vector registers as new-value producers
Krzysztof Parzyszek [Thu, 28 Apr 2016 15:54:48 +0000 (15:54 +0000)]
[Hexagon] Handle double-vector registers as new-value producers

Patch by Colin LeMahieu.

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

8 years agoDebug Info: Restore the pre-r240853 behavior for DWARF2 bitfields.
Adrian Prantl [Thu, 28 Apr 2016 15:37:52 +0000 (15:37 +0000)]
Debug Info: Restore the pre-r240853 behavior for DWARF2 bitfields.

The DWARF2 specification of DW_AT_bit_offset is ambiguous for
little-endian machines, but by restoring to the old behavior
we match what debuggers expect and what other popular compilers
generate.

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

8 years agoDebug info: Support DWARF4 bitfields via DW_AT_data_bit_offset.
Adrian Prantl [Thu, 28 Apr 2016 15:37:48 +0000 (15:37 +0000)]
Debug info: Support DWARF4 bitfields via DW_AT_data_bit_offset.

The DWARF2 specification of DW_AT_bit_offset was written from the perspective of
a big-endian machine with unclear semantics for other systems.  DWARF4
deprecated DW_AT_bit_offset and introduced a new attribute DW_AT_data_bit_offset
that simply counts the number of bits from the beginning of the containing
entity regardless of endianness.

After this patch LLVM emits DW_AT_bit_offset for DWARF 2 or 3 and
DW_AT_data_bit_offset when DWARF 4 or later is requested.

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

8 years ago[EarlyCSE] Change LoadValue field Value *Data to Instruction *Inst. NFC.
Geoff Berry [Thu, 28 Apr 2016 15:22:37 +0000 (15:22 +0000)]
[EarlyCSE] Change LoadValue field Value *Data to Instruction *Inst. NFC.

Made in preparation for adding MemorySSA support to EarlyCSE.

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

8 years ago[libFuzzer] Improve documentation
Kostya Serebryany [Thu, 28 Apr 2016 15:19:05 +0000 (15:19 +0000)]
[libFuzzer] Improve documentation

Reviewers: kcc

Subscribers: llvm-commits

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

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

8 years ago[RDF] Handle undefined registers in RDF copy propagation
Krzysztof Parzyszek [Thu, 28 Apr 2016 15:09:19 +0000 (15:09 +0000)]
[RDF] Handle undefined registers in RDF copy propagation

When updating the graph, make sure that new uses without reaching defs
are handled correctly.

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

8 years ago[EarlyCSE] Sort includes. NFC.
Geoff Berry [Thu, 28 Apr 2016 14:59:27 +0000 (14:59 +0000)]
[EarlyCSE] Sort includes.  NFC.

Reviewers: mcrosier

Subscribers: mcrosier, llvm-commits

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

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

8 years agoRangify for loops, NFC.
Yaron Keren [Thu, 28 Apr 2016 14:49:44 +0000 (14:49 +0000)]
Rangify for loops, NFC.

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

8 years ago[Inliner] Formatting. NFC.
Chad Rosier [Thu, 28 Apr 2016 14:47:23 +0000 (14:47 +0000)]
[Inliner] Formatting. NFC.

Patch by Aditya Kumar!
Differential Revision: http://reviews.llvm.org/D19047

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

8 years ago[InstCombine] Remove trailing whitespace. NFC.
Ahmed Bougacha [Thu, 28 Apr 2016 14:36:07 +0000 (14:36 +0000)]
[InstCombine] Remove trailing whitespace. NFC.

r267873.

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

8 years ago[InstCombine][SSE] Add MOVMSK support to SimplifyDemandedUseBits
Simon Pilgrim [Thu, 28 Apr 2016 12:22:53 +0000 (12:22 +0000)]
[InstCombine][SSE] Add MOVMSK support to SimplifyDemandedUseBits

The MOVMSK instructions copies a vector elements' sign bits to the low bits of a scalar register and zeros the high bits.

This patch adds MOVMSK support to SimplifyDemandedUseBits so that its aware that the upper bits are known to be zero. It also removes the call to MOVMSK if none of the lower bits are actually required and just returns zero.

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

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

8 years ago[X86] Remove unused operand from a function and all its callers. NFC
Craig Topper [Thu, 28 Apr 2016 05:58:46 +0000 (05:58 +0000)]
[X86] Remove unused operand from a function and all its callers. NFC

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

8 years ago[CodeGen] Default CTTZ_ZERO_UNDEF/CTLZ_ZERO_UNDEF to Expand in TargetLoweringBase...
Craig Topper [Thu, 28 Apr 2016 03:34:31 +0000 (03:34 +0000)]
[CodeGen] Default CTTZ_ZERO_UNDEF/CTLZ_ZERO_UNDEF to Expand in TargetLoweringBase. This is what the majority of the targets want and removes a bunch of code. Set it to Legal explicitly in the few cases where that's the desired behavior.

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

8 years agoCodeGen: Add DetectDeadLanes pass.
Matthias Braun [Thu, 28 Apr 2016 03:07:16 +0000 (03:07 +0000)]
CodeGen: Add DetectDeadLanes pass.

The DetectDeadLanes pass performs a dataflow analysis of used/defined
subregister lanes across COPY instructions and instructions that will
get lowered to copies. It detects dead definitions and uses reading
undefined values which are obscured by COPY and subregister usage.

These dead definitions cause trouble in the register coalescer which
cannot deal with definitions suddenly becoming dead after coalescing
COPY instructions.

For now the pass only adds dead and undef flags to machine operands. It
should be possible to extend it in the future to remove the dead
instructions and redo the analysis for the affected virtual
registers.

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

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

8 years agoTableGen: Produce CoveredBySubRegs summary for register classes
Matthias Braun [Thu, 28 Apr 2016 03:07:11 +0000 (03:07 +0000)]
TableGen: Produce CoveredBySubRegs summary for register classes

This will be used in the upcoming "DetectDeadLanes" pass.

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

8 years agoTargetRegisterInfo: Introduce reverseComposeSubRegIndexLaneMask()
Matthias Braun [Thu, 28 Apr 2016 03:07:07 +0000 (03:07 +0000)]
TargetRegisterInfo: Introduce reverseComposeSubRegIndexLaneMask()

This function performs the reverse computation of
composeSubRegIndexLaneMask().

It will be used in the upcoming "DetectDeadLanes" pass.

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

8 years agoTableGen: Support lanemasks for classes without subregisters
Matthias Braun [Thu, 28 Apr 2016 03:07:04 +0000 (03:07 +0000)]
TableGen: Support lanemasks for classes without subregisters

Previously using lanemasks on registers without any subregisters was not
well defined. This commit extends TargetRegisterInfo/tablegen to:
- Report a lanemask of 1 for regclasses without subregisters
- Do the right thing when mapping a 0/1 lanemask from a class without
  subregisters into a class with subregisters in
  TargetRegisterInfo::composeSubRegIndexLaneMasks().

This will be used in the upcoming "DetectDeadLanes" patch.

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

8 years agoLiveIntervalAnalysis: Fix handleMove() using wrong value numbers
Matthias Braun [Thu, 28 Apr 2016 02:11:49 +0000 (02:11 +0000)]
LiveIntervalAnalysis: Fix handleMove() using wrong value numbers

handleMove() was incorrectly swapping two value numbers. This was missed
before because the problem only occured when moving subregister definitions
and needed -verify-machineinstrs to be detected.

I cannot add a testcase as long as I cannot reapply r260905/r260806.

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

8 years ago[AArch64] Expand CTTZ for all vector types.
Craig Topper [Thu, 28 Apr 2016 01:58:21 +0000 (01:58 +0000)]
[AArch64] Expand CTTZ for all vector types.

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

8 years agoFix bogus documentation for StringRef::slice in the End < Start case.
Richard Smith [Thu, 28 Apr 2016 00:57:14 +0000 (00:57 +0000)]
Fix bogus documentation for StringRef::slice in the End < Start case.

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

8 years agoUse llvm:Twine instead of std::to_string.
Chaoren Lin [Thu, 28 Apr 2016 00:49:37 +0000 (00:49 +0000)]
Use llvm:Twine instead of std::to_string.

std::to_string is not available from the Android NDK.

Reviewers: lhames, ovyalov, chandlerc

Subscribers: llvm-commits

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

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

8 years agoUpdate test to use FileCheck
Sanjay Patel [Thu, 28 Apr 2016 00:29:27 +0000 (00:29 +0000)]
Update test to use FileCheck

Also, add some metadata to show what that currently looks like.

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

8 years ago[SystemZ] Support Swift Calling Convention
Bryan Chan [Thu, 28 Apr 2016 00:17:23 +0000 (00:17 +0000)]
[SystemZ] Support Swift Calling Convention

Summary:
Port rL265480, rL264754, rL265997 and rL266252 to SystemZ, in order to enable the Swift port on the architecture. SwiftSelf and SwiftError are assigned to R10 and R9, respectively, which are normally callee-saved registers. For more information, see:

RFC: Implementing the Swift calling convention in LLVM and Clang
https://groups.google.com/forum/#!topic/llvm-dev/epDd2w93kZ0

Reviewers: kbarton, manmanren, rjmccall, uweigand

Subscribers: llvm-commits

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

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

8 years agoLTO: Don't bother trying to mangle unnamed globals, as they can't be preserved with...
Peter Collingbourne [Wed, 27 Apr 2016 23:48:11 +0000 (23:48 +0000)]
LTO: Don't bother trying to mangle unnamed globals, as they can't be preserved with MustPreserveSymbols.

Summary: Should fix sanitizer-windows bot.

Reviewers: joker.eph

Subscribers: llvm-commits, joker.eph

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

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

8 years agoFix bugs in llvm-objdump printing the last word for -section in non i386 and x86...
Kevin Enderby [Wed, 27 Apr 2016 23:43:00 +0000 (23:43 +0000)]
Fix bugs in llvm-objdump printing the last word for -section in non i386 and x86 files.
Two problems, 1) for the last 4 bytes it would print them as separate bytes not a word
and 2) it would print the same last byte for those bytes less than a word.

rdar://25938224

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

8 years agoParse module information from DBI stream.
Zachary Turner [Wed, 27 Apr 2016 23:41:42 +0000 (23:41 +0000)]
Parse module information from DBI stream.

This gets more data out of the DBI strema of the PDB.  In
particular it extracts the metadata for the list of modules
(compilands) that this PDB contains info about, and adds support
for dumping these fields to llvm-pdbdump.

Differential Revision: http://reviews.llvm.org/D19570
Reviewed By: ruiu

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

8 years ago[ImplicitNullChecks] Properly update the live-in of the block of the memory operation.
Quentin Colombet [Wed, 27 Apr 2016 23:26:40 +0000 (23:26 +0000)]
[ImplicitNullChecks] Properly update the live-in of the block of the memory operation.

We basically replace:
HoistBB:
cond_br NullBB, NotNullBB

NullBB:
  ...

NotNullBB:
  <reg> = load

into
HoistBB
<reg> = load_faulting_op NullBB
uncond_br NotNullBB

NullBB:
  ...

NotNullBB: ## <reg> is now live-in of NotNullBB
  ...

This partially fixes the machine verifier error for
test/CodeGen/X86/implicit-null-check.ll, but it still fails because
of the implicit CFG structure.

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

8 years agomore buildbot failure fix to r267792
Rong Xu [Wed, 27 Apr 2016 23:23:53 +0000 (23:23 +0000)]
more buildbot failure fix to r267792

__llvm_prf_nm length is embedded in llvm_used. Relax llvm_used check.

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

8 years ago[PGO] Promote indirect calls to conditional direct calls with value-profile
Rong Xu [Wed, 27 Apr 2016 23:20:27 +0000 (23:20 +0000)]
[PGO] Promote indirect calls to conditional direct calls with value-profile

This patch implements the transformation that promotes indirect calls to
conditional direct calls when the indirect-call value profile meta-data is
available.

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

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

8 years ago[SimplifyCFG] propagate branch metadata when creating select
Sanjay Patel [Wed, 27 Apr 2016 23:14:12 +0000 (23:14 +0000)]
[SimplifyCFG] propagate branch metadata when creating select

There's no existing test for this path, and I don't know how to expose
it in a regression test, but I'm assuming there's some reason this
path exists.

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

8 years ago[RuntimeDyld] Propagate another dropped error in RuntimeDyldELF.
Lang Hames [Wed, 27 Apr 2016 22:54:03 +0000 (22:54 +0000)]
[RuntimeDyld] Propagate another dropped error in RuntimeDyldELF.

This should fix the PPC64 bots.

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

8 years ago[X86] Enable the post-RA-scheduler for clang's default 32-bit cpu.
Mitch Bodart [Wed, 27 Apr 2016 22:52:35 +0000 (22:52 +0000)]
[X86] Enable the post-RA-scheduler for clang's default 32-bit cpu.

For compilations with no explicit cpu specified, this exhibits
nice gains on Silvermont, with neutral performance on big cores.

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

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

8 years agoFix a bug in llvm-objdump printing of 32-bit addresses for -section in non i386 and...
Kevin Enderby [Wed, 27 Apr 2016 22:36:18 +0000 (22:36 +0000)]
Fix a bug in llvm-objdump printing of 32-bit addresses for -section in non i386 and x86 files.

rdar://25896202

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

8 years ago[X86][FastISel] Make sure we use the right register class when we select stores.
Quentin Colombet [Wed, 27 Apr 2016 22:33:42 +0000 (22:33 +0000)]
[X86][FastISel] Make sure we use the right register class when we select stores.

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