oota-llvm.git
9 years agoRewrite SelectionDAGBuilder::Clusterify to run in linear time. NFC.
Hans Wennborg [Fri, 20 Mar 2015 00:41:03 +0000 (00:41 +0000)]
Rewrite SelectionDAGBuilder::Clusterify to run in linear time. NFC.

It was previously repeatedly erasing elements from the middle of a vector,
causing O(n^2) worst-case run-time.

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

9 years agotest: Make a start on a test suite for libLTO.
Peter Collingbourne [Thu, 19 Mar 2015 23:55:38 +0000 (23:55 +0000)]
test: Make a start on a test suite for libLTO.

This works in a similar way to the gold plugin tests. We search for a compatible
linker on $PATH and use it to run tests against our just-built libLTO. To start
with, test the just added opt level functionality.

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

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

9 years agoUse the cached subtarget on the MachineFunction when the AsmPrinter
Eric Christopher [Thu, 19 Mar 2015 23:27:42 +0000 (23:27 +0000)]
Use the cached subtarget on the MachineFunction when the AsmPrinter
will have a MachineFunction, i.e. in places other than the module
level doInitialize/doFinalize.

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

9 years agoUse the cached subtarget off of the machine function.
Eric Christopher [Thu, 19 Mar 2015 23:06:21 +0000 (23:06 +0000)]
Use the cached subtarget off of the machine function.

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

9 years agomove insert, extract, concat helper functions closer to related helper functions...
Sanjay Patel [Thu, 19 Mar 2015 23:04:25 +0000 (23:04 +0000)]
move insert, extract, concat helper functions closer to related helper functions; NFCI

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

9 years agoFix a nasty bug in DAGCombine of STORE nodes.
Owen Anderson [Thu, 19 Mar 2015 22:48:57 +0000 (22:48 +0000)]
Fix a nasty bug in DAGCombine of STORE nodes.

This is very related to the bug fixed in r174431.  The problem is that
SelectionDAG does not include alignment in the uniquing of loads and
stores.  When an otherwise no-op DAGCombine would increase the alignment
of a load or store, the original node would be returned (with the
alignment increased), which would cause the node not to be processed by
any further DAGCombines.

I don't have a direct testcase for this that manifests on an in-tree
target, but I did see some noise in the tests for other targets and have
updated them for it.

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

9 years agoRemove unused headers.
Eric Christopher [Thu, 19 Mar 2015 22:36:38 +0000 (22:36 +0000)]
Remove unused headers.

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

9 years agoAdd an MCSubtargetInfo variable to the TargetMachine.
Eric Christopher [Thu, 19 Mar 2015 22:36:37 +0000 (22:36 +0000)]
Add an MCSubtargetInfo variable to the TargetMachine.

This enables us to remove calls to the subtarget from the TargetMachine
and with a small hack for backends that require global subtarget
information for module level code generation, e.g. mips abi flags, as
mentioned in a fixme in the code.

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

9 years agoAdd a TargetMachine local MCRegisterInfo and MCInstrInfo so that
Eric Christopher [Thu, 19 Mar 2015 22:36:32 +0000 (22:36 +0000)]
Add a TargetMachine local MCRegisterInfo and MCInstrInfo so that
they can be used without a subtarget in constructing subtarget
independent passes.

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

9 years agoWinEH: Make llvm.eh.actions emission match the EH docs
Reid Kleckner [Thu, 19 Mar 2015 22:31:02 +0000 (22:31 +0000)]
WinEH: Make llvm.eh.actions emission match the EH docs

This switches the sense of the i32 values and updates the test cases.

We can also use CHECK-SAME to clean up some tests, and reduce the visual
noise from bitcasts.

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

9 years ago[X86, AVX] use blends instead of insert128 with index 0
Sanjay Patel [Thu, 19 Mar 2015 22:29:40 +0000 (22:29 +0000)]
[X86, AVX] use blends instead of insert128 with index 0

Another case of x86-specific shuffle strength reduction:
avoid generating insert*128 instructions with index 0 because
they are slower than their non-lane-changing blend equivalents.

Shuffle lowering already catches most of these cases, but
the zero vector case and some other paths such as in the
modified test in vector-shuffle-256-v32.ll were getting
through.

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

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

9 years agoVerifier: Remove the separate -verify-di pass
Duncan P. N. Exon Smith [Thu, 19 Mar 2015 22:24:17 +0000 (22:24 +0000)]
Verifier: Remove the separate -verify-di pass

Remove `DebugInfoVerifierLegacyPass` and the `-verify-di` pass.
Instead, call into the `DebugInfoVerifier` from inside
`VerifierLegacyPass::finalizeModule()`.  This better matches the logic
in `verifyModule()` (used by the new PassManager), avoids requiring two
separate passes to verify the IR, and makes the API for "add a pass to
verify the IR" simple.

Note: the `-verify-debug-info` flag still works (for now, at least;
eventually it might make sense to just remove it).

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

9 years agoFix build failure.
Peter Collingbourne [Thu, 19 Mar 2015 22:12:08 +0000 (22:12 +0000)]
Fix build failure.

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

9 years agoLowerBitSets: Avoid reusing byte set addresses.
Peter Collingbourne [Thu, 19 Mar 2015 22:02:10 +0000 (22:02 +0000)]
LowerBitSets: Avoid reusing byte set addresses.

Each use of the byte array uses a different alias. This makes the
backend less likely to reuse previously computed byte array addresses,
improving the security of the CFI mechanism based on this pass.

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

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

9 years agolibLTO, llvm-lto, gold: Introduce flag for controlling optimization level.
Peter Collingbourne [Thu, 19 Mar 2015 22:01:00 +0000 (22:01 +0000)]
libLTO, llvm-lto, gold: Introduce flag for controlling optimization level.

This change also introduces a link-time optimization level of 1. This
optimization level runs only the globaldce pass as well as cleanup passes for
passes that run at -O0, specifically simplifycfg which cleans up lowerbitsets.

http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20150316/266951.html

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

9 years agoPassManagerBuilder: Remove effectively dead 'StripDebug' option
Duncan P. N. Exon Smith [Thu, 19 Mar 2015 21:37:17 +0000 (21:37 +0000)]
PassManagerBuilder: Remove effectively dead 'StripDebug' option

`StripDebug` was only used by tools/opt/opt.cpp in
`AddStandardLinkPasses()`, but opt.cpp adds the same pass based on its
command-line flag before it calls `AddStandardLinkPasses()`.  Stripping
debug info twice isn't very useful.

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

9 years agoSwitch lowering: extract NextBlock function. NFC.
Hans Wennborg [Thu, 19 Mar 2015 20:41:48 +0000 (20:41 +0000)]
Switch lowering: extract NextBlock function. NFC.

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

9 years agoUnxfail test/CodeGen/Generic/vector.ll now passing on Hexagon
Krzysztof Parzyszek [Thu, 19 Mar 2015 20:22:17 +0000 (20:22 +0000)]
Unxfail test/CodeGen/Generic/vector.ll now passing on Hexagon

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

9 years agogold: Make powerpc support optional for the tests.
Peter Collingbourne [Thu, 19 Mar 2015 18:23:31 +0000 (18:23 +0000)]
gold: Make powerpc support optional for the tests.

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

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

9 years agoGlobalDCE: Improve performance for large modules containing comdats.
Peter Collingbourne [Thu, 19 Mar 2015 18:23:29 +0000 (18:23 +0000)]
GlobalDCE: Improve performance for large modules containing comdats.

When we encounter a global with a comdat, rather than iterating over
every global in the module to find globals in the same comdat, store the
members in a multimap. This effectively lowers the complexity to O(N log N),
improving performance significantly for large modules such as might be
encountered during LTO.

It looks like we used to do something like this until r219191.

No functional change.

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

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

9 years agodocs: Update llvm-cov docs for the -use-color flag
Justin Bogner [Thu, 19 Mar 2015 18:22:46 +0000 (18:22 +0000)]
docs: Update llvm-cov docs for the -use-color flag

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

9 years agoAdd support for __nvvm_reflect changes in libdevice in CUDA-7.0
Artem Belevich [Thu, 19 Mar 2015 17:05:35 +0000 (17:05 +0000)]
Add support for __nvvm_reflect changes in libdevice in CUDA-7.0

Summary:
CUDA 7.0's libdevice uses slightly different IR to call __nvvm_reflect
and that triggers an assertion in nvvm_reflect optimization pass. This
change allows nvvm_reflect pass to deal with both old and new ways to
pass an argument to __nvvm_reflect.

Test Plan: ninja check-all

Reviewers: eliben, echristo

Subscribers: jholewinski, llvm-commits

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

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

9 years agoFixing dependencies for native tablegen.
Chris Bieneman [Thu, 19 Mar 2015 16:49:44 +0000 (16:49 +0000)]
Fixing dependencies for native tablegen.

The dependencies for cross-built tablegen were a bit confused. This fixes that. The following dependencies are now enforced:

(1) Tablegen tasks depend on the native tablegen
(2) Native tablegen depends on the cross-compiled tablegen

Although the native tablegen doesn't actually require the cross tablegen, having this dependency forces the native tablegen to rebuild whenever the cross tablegen changes.

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

9 years agoSwitch lowering: remove unnecessary ConstantInt casts. NFC.
Hans Wennborg [Thu, 19 Mar 2015 16:42:21 +0000 (16:42 +0000)]
Switch lowering: remove unnecessary ConstantInt casts. NFC.

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

9 years ago[Hexagon] Add support for vector instructions
Krzysztof Parzyszek [Thu, 19 Mar 2015 16:33:08 +0000 (16:33 +0000)]
[Hexagon] Add support for vector instructions

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

9 years ago[CMake] Don't pass in MSVC warning flags as definitions.
Greg Bedwell [Thu, 19 Mar 2015 16:32:47 +0000 (16:32 +0000)]
[CMake] Don't pass in MSVC warning flags as definitions.

NFC currently but required as a prerequisite for using
the Microsoft resource compiler in conjunction with
CMake's ninja generator, which knows how to filter flags
appropriately, but not definitions.

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

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

9 years ago[Hexagon] ENDLOOP is a non-reversible conditional branch
Krzysztof Parzyszek [Thu, 19 Mar 2015 15:18:57 +0000 (15:18 +0000)]
[Hexagon] ENDLOOP is a non-reversible conditional branch

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

9 years agoInternalize PEI. NFC.
Benjamin Kramer [Thu, 19 Mar 2015 14:09:20 +0000 (14:09 +0000)]
Internalize PEI. NFC.

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

9 years ago[sparc] Small fix to r232719 to make 2007-12-17-InvokeAsm.ll pass on the buildbot.
Daniel Sanders [Thu, 19 Mar 2015 11:27:23 +0000 (11:27 +0000)]
[sparc] Small fix to r232719 to make 2007-12-17-InvokeAsm.ll pass on the buildbot.

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

9 years ago[sparc] Only support the 'm' inline assembly memory constraint. NFC.
Daniel Sanders [Thu, 19 Mar 2015 11:26:05 +0000 (11:26 +0000)]
[sparc] Only support the 'm' inline assembly memory constraint. NFC.

Summary:
SPARC doesn't seem to support any additional constraints. Therefore remove
the target hook.

No functional change intended.

Reviewers: venkatra

Subscribers: llvm-commits

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

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

9 years ago[InstCombine] Don't fold a GEP into itself through a PHI node
Daniel Jasper [Thu, 19 Mar 2015 11:05:08 +0000 (11:05 +0000)]
[InstCombine] Don't fold a GEP into itself through a PHI node

This can only occur (I think) through the back-edge of the loop.

However, folding a GEP into itself means that the value of the previous
iteration needs to be stored in the meantime, thus requiring an
additional register variable to be live, but not actually achieving
anything (the gep still needs to be executed once per loop iteration).

The attached test case is derived from:
  typedef unsigned uint32;
  typedef unsigned char uint8;
  inline uint8 *f(uint32 value, uint8 *target) {
    while (value >= 0x80) {
      value >>= 7;
      ++target;
    }
    ++target;
    return target;
  }
  uint8 *g(uint32 b, uint8 *target) {
    target = f(b, f(42, target));
    return target;
  }

What happens is that the GEP stored in incptr2 is folded into itself
through the loop's back-edge and the phi-node stored in loopptr,
effectively incrementing the ptr by "2" in each iteration instead of "1".

In this case, it is actually increasing the number of GEPs required as
the GEP before the loop can't be folded away anymore. For comparison:

With this patch:
  define i8* @test4(i32 %value, i8* %buffer) {
  entry:
    %cmp = icmp ugt i32 %value, 127
    br i1 %cmp, label %loop.header, label %exit

  loop.header:                                      ; preds = %entry
    br label %loop.body

  loop.body:                                        ; preds = %loop.body, %loop.header
    %buffer.pn = phi i8* [ %buffer, %loop.header ], [ %loopptr, %loop.body ]
    %newval = phi i32 [ %value, %loop.header ], [ %shr, %loop.body ]
    %loopptr = getelementptr inbounds i8, i8* %buffer.pn, i64 1
    %shr = lshr i32 %newval, 7
    %cmp2 = icmp ugt i32 %newval, 16383
    br i1 %cmp2, label %loop.body, label %loop.exit

  loop.exit:                                        ; preds = %loop.body
    br label %exit

  exit:                                             ; preds = %loop.exit, %entry
    %0 = phi i8* [ %loopptr, %loop.exit ], [ %buffer, %entry ]
    %incptr3 = getelementptr inbounds i8, i8* %0, i64 2
    ret i8* %incptr3
  }

Without this patch:
  define i8* @test4(i32 %value, i8* %buffer) {
  entry:
    %incptr = getelementptr inbounds i8, i8* %buffer, i64 1
    %cmp = icmp ugt i32 %value, 127
    br i1 %cmp, label %loop.header, label %exit

  loop.header:                                      ; preds = %entry
    br label %loop.body

  loop.body:                                        ; preds = %loop.body, %loop.header
    %0 = phi i8* [ %buffer, %loop.header ], [ %loopptr, %loop.body ]
    %loopptr = phi i8* [ %incptr, %loop.header ], [ %incptr2, %loop.body ]
    %newval = phi i32 [ %value, %loop.header ], [ %shr, %loop.body ]
    %shr = lshr i32 %newval, 7
    %incptr2 = getelementptr inbounds i8, i8* %0, i64 2
    %cmp2 = icmp ugt i32 %newval, 16383
    br i1 %cmp2, label %loop.body, label %loop.exit

  loop.exit:                                        ; preds = %loop.body
    br label %exit

  exit:                                             ; preds = %loop.exit, %entry
    %ptr2 = phi i8* [ %incptr2, %loop.exit ], [ %incptr, %entry ]
    %incptr3 = getelementptr inbounds i8, i8* %ptr2, i64 1
    ret i8* %incptr3
  }

Review: http://reviews.llvm.org/D8245

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

9 years agollvm-cov: Rename -color={always|never} to -use-color[=0]
Justin Bogner [Thu, 19 Mar 2015 04:45:16 +0000 (04:45 +0000)]
llvm-cov: Rename -color={always|never} to -use-color[=0]

This is an ugly hack to fix the configure --enable-shared build. It
turns out that *every cl::opt in LLVM* shows up in *every tool* in
that configuration, which is hopelessly broken. This skirts around the
issue by not colliding with another option's name, for now.

I've also simplified the option implementation - the other "color"
option used cl::boolOrDefault and was much nicer than what I'd written
before.

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

9 years agoNote that we don't support COFF on PPC.
Rafael Espindola [Thu, 19 Mar 2015 02:40:56 +0000 (02:40 +0000)]
Note that we don't support COFF on PPC.

Should bring back the windows bots.

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

9 years agollvm-cov: Continue trying to appease a bot
Justin Bogner [Thu, 19 Mar 2015 02:00:54 +0000 (02:00 +0000)]
llvm-cov: Continue trying to appease a bot

This bot doesn't like me. I don't know why:

    http://lab.llvm.org:8011/builders/clang-hexagon-elf/builds/24425

Move the color option enum's definition out of the function that
creates the cl::opt.

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

9 years agoSplit the object streamer callback in one per file format.
Rafael Espindola [Thu, 19 Mar 2015 01:50:16 +0000 (01:50 +0000)]
Split the object streamer callback in one per file format.

There are two main advantages to doing this

* Targets that only need to handle one of the formats specially don't have
  to worry about the others. For example, x86 now only registers a
  constructor for the COFF streamer.

* Changes to the arguments passed to one format constructor will not impact
  the other formats.

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

9 years agollvm-cov: Try to appease a bot
Justin Bogner [Thu, 19 Mar 2015 01:07:22 +0000 (01:07 +0000)]
llvm-cov: Try to appease a bot

The clang-hexagon elf bot was complaining that "Option 'color'
registered more than once!":

    http://lab.llvm.org:8011/builders/clang-hexagon-elf/builds/24425

I don't understand why this error is happening, and I don't see it on
any other bots or on my own machine, so I'm kind of grasping at
straws. Try using an unscoped enum and specifying a cl::init to see if
they help.

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

9 years agoSelectionDAGBuilder: update comment in HandlePHINodesInSuccessorBlocks.
Hans Wennborg [Thu, 19 Mar 2015 00:57:51 +0000 (00:57 +0000)]
SelectionDAGBuilder: update comment in HandlePHINodesInSuccessorBlocks.

From what I can tell, the code is checking for PHIs that expect any value from
this block, not just constants.

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

9 years agoDo not track subregister liveness when it brings no benefits
Matthias Braun [Thu, 19 Mar 2015 00:21:58 +0000 (00:21 +0000)]
Do not track subregister liveness when it brings no benefits

Some subregisters are only to indicate different access sizes, while not
providing any way to actually divide the register up into multiple
disjunct parts. Avoid tracking subregister liveness in these cases as it
is not beneficial.

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

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

9 years agollvm-cov: Only emit colour by default if the output is a tty
Justin Bogner [Thu, 19 Mar 2015 00:02:23 +0000 (00:02 +0000)]
llvm-cov: Only emit colour by default if the output is a tty

This replaces the -no-color flag with a -color={auto|always|never}
option, with auto as the default, which is much saner.

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

9 years agoSelectionDAGIsel: Fix comment about terminators being "handled below".
Hans Wennborg [Thu, 19 Mar 2015 00:02:22 +0000 (00:02 +0000)]
SelectionDAGIsel: Fix comment about terminators being "handled below".

That changed in r102128.

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

9 years ago[CodeGenPrepare] Remove broken, dead, code.
Quentin Colombet [Wed, 18 Mar 2015 23:17:28 +0000 (23:17 +0000)]
[CodeGenPrepare] Remove broken, dead, code.
NFC.

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

9 years agotwo or more, use a for.
Rafael Espindola [Wed, 18 Mar 2015 23:15:49 +0000 (23:15 +0000)]
two or more, use a for.

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

9 years agoFixed failing test due to missing target triple causing different results on differen...
Simon Pilgrim [Wed, 18 Mar 2015 22:51:45 +0000 (22:51 +0000)]
Fixed failing test due to missing target triple causing different results on different buildbots.

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

9 years agoTeach getDefaultFormat that we only support ELF on some architectures.
Rafael Espindola [Wed, 18 Mar 2015 22:19:16 +0000 (22:19 +0000)]
Teach getDefaultFormat that we only support ELF on some architectures.

This should bring the windows bots back.

It is a bit ugly, but it is better than what we had before: The triple would
say that the object format was COFF, but llc/llvm-mc would produce an ELF.

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

9 years ago[X86][SSE] Avoid scalarization of v2i64 vector shifts (REAPPLIED)
Simon Pilgrim [Wed, 18 Mar 2015 22:18:51 +0000 (22:18 +0000)]
[X86][SSE] Avoid scalarization of v2i64 vector shifts (REAPPLIED)

Fixed broken tests.

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

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

9 years ago[PowerPC] Correct typo in PPCInstrAltivec.td
Bill Schmidt [Wed, 18 Mar 2015 22:13:03 +0000 (22:13 +0000)]
[PowerPC] Correct typo in PPCInstrAltivec.td

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

9 years agoUpdate 3.7 Release Note mentionning the non-optionality of the DataLayout
Mehdi Amini [Wed, 18 Mar 2015 22:01:44 +0000 (22:01 +0000)]
Update 3.7 Release Note mentionning the non-optionality of the DataLayout

From: Mehdi Amini <mehdi.amini@apple.com>

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

9 years agoRevert "Generate targets for each lit suite."
Chris Bieneman [Wed, 18 Mar 2015 21:53:29 +0000 (21:53 +0000)]
Revert "Generate targets for each lit suite."

This change broke Polly. I'll track down the failure when I have a chance and re-apply the change.

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

9 years agoGenerate targets for each lit suite.
Chris Bieneman [Wed, 18 Mar 2015 21:19:06 +0000 (21:19 +0000)]
Generate targets for each lit suite.

Summary:
This change makes CMake scan for lit suites and generate a target for each lit test suite. The targets follow the format check-<project>-<suite path>.

For example:
check-llvm-unit - Runs the LLVM unit tests
check-llvm-codegen-arm - Runs the ARM codeine tests

Note: These targets are not generated during multi-configuration generators (i.e. Xcode and Visual Studio) because target clutter impacts UI usability.

Reviewers: chandlerc

Subscribers: aemerson, llvm-commits

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

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

9 years agoRevert "[X86][SSE] Avoid scalarization of v2i64 vector shifts" as it
Eric Christopher [Wed, 18 Mar 2015 21:01:00 +0000 (21:01 +0000)]
Revert "[X86][SSE] Avoid scalarization of v2i64 vector shifts" as it
appears to have broken tests/bots.

This reverts commit r232660.

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

9 years agoRevert "Add a TargetMachine local MCRegisterInfo and MCInstrInfo so that"
Eric Christopher [Wed, 18 Mar 2015 20:41:44 +0000 (20:41 +0000)]
Revert "Add a TargetMachine local MCRegisterInfo and MCInstrInfo so that"
Committed too early.

This reverts commit r232666.

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

9 years agoAdd a TargetMachine local MCRegisterInfo and MCInstrInfo so that
Eric Christopher [Wed, 18 Mar 2015 20:37:36 +0000 (20:37 +0000)]
Add a TargetMachine local MCRegisterInfo and MCInstrInfo so that
they can be used without a subtarget in constructing subtarget
independent passes.

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

9 years agoRevert "Migrate the AArch64 TargetRegisterInfo to its TargetMachine"
Eric Christopher [Wed, 18 Mar 2015 20:37:30 +0000 (20:37 +0000)]
Revert "Migrate the AArch64 TargetRegisterInfo to its TargetMachine"
as we don't necessarily need to do this yet - though we could move
the base class to the TargetMachine as it isn't subtarget dependent.

This reverts commit r232103.

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

9 years agoUse WinEHPrepare to outline SEH finally blocks
Reid Kleckner [Wed, 18 Mar 2015 20:26:53 +0000 (20:26 +0000)]
Use WinEHPrepare to outline SEH finally blocks

No outlining is necessary for SEH catch blocks. Use the blockaddr of the
handler in place of the usual outlined function.

Reviewers: majnemer, andrew.w.kaylor

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

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

9 years agoFix cmake build.
Rafael Espindola [Wed, 18 Mar 2015 20:21:06 +0000 (20:21 +0000)]
Fix cmake build.

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

9 years agoCMake: Disable ENABLE_EXPORTS for executables with MSVC
Reid Kleckner [Wed, 18 Mar 2015 20:09:13 +0000 (20:09 +0000)]
CMake: Disable ENABLE_EXPORTS for executables with MSVC

The MSVC linker won't produce a .lib file for an executable that doesn't
export anything, and LLVM doesn't maintain dllexport annotations or .def
files listing all C++ symbols. It also doesn't support exporting all
symbols, like binutils ld.

CMake 3.2 changed the Ninja generator to list both the .exe and .lib
files as outputs of executable build targets. Ninja would always re-link
executables with ENABLE_EXPORTS because the .lib output file was not
present, and therefore the target was out of date.

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

9 years agoFix use of uninitialized valued.
Rafael Espindola [Wed, 18 Mar 2015 19:49:29 +0000 (19:49 +0000)]
Fix use of uninitialized valued.

Should bring the bots back.

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

9 years ago[X86][SSE] Avoid scalarization of v2i64 vector shifts
Simon Pilgrim [Wed, 18 Mar 2015 19:35:31 +0000 (19:35 +0000)]
[X86][SSE] Avoid scalarization of v2i64 vector shifts

Currently v2i64 vectors shifts (non-equal shift amounts) are scalarized, costing 4 x extract, 2 x x86-shifts and 2 x insert instructions - and it gets even more awkward on 32-bit targets.

This patch separately shifts the vector by both shift amounts and then shuffles the partial results back together, costing 2 x shuffles and 2 x sse-shifts instructions (+ 2 movs on pre-AVX hardware).

Note - this patch only improves the SHL / LSHR logical shifts as only these are supported in SSE hardware.

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

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

9 years ago[Objdump] DumpBytes of uint8_t from ArrayRef<uint8_t> instead of char from StringRef...
Colin LeMahieu [Wed, 18 Mar 2015 19:27:31 +0000 (19:27 +0000)]
[Objdump] DumpBytes of uint8_t from ArrayRef<uint8_t> instead of char from StringRef.  Removing reinterpret_casts.

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

9 years agoAdd a default implementation of createObjectStreamer.
Rafael Espindola [Wed, 18 Mar 2015 19:08:20 +0000 (19:08 +0000)]
Add a default implementation of createObjectStreamer.

This removes duplicated code from backends that don't need to do anything
fancy.

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

9 years ago[Hexagon] Use pseudo-instructions for true/false predicate values
Krzysztof Parzyszek [Wed, 18 Mar 2015 19:07:53 +0000 (19:07 +0000)]
[Hexagon] Use pseudo-instructions for true/false predicate values

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

9 years agoRevert "[Hexagon] Use pseudo-instructions for true/false predicate values"
Krzysztof Parzyszek [Wed, 18 Mar 2015 18:50:06 +0000 (18:50 +0000)]
Revert "[Hexagon] Use pseudo-instructions for true/false predicate values"

This reverts r232650.

Missed a piece of code in the previous commit.

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

9 years ago[Objdump] Removing size limit on DumpBytes and changing to range based for loop.
Colin LeMahieu [Wed, 18 Mar 2015 18:41:23 +0000 (18:41 +0000)]
[Objdump] Removing size limit on DumpBytes and changing to range based for loop.

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

9 years agoTableGen: Fix register class lane masks being too conservative.
Matthias Braun [Wed, 18 Mar 2015 17:56:09 +0000 (17:56 +0000)]
TableGen: Fix register class lane masks being too conservative.

When calculating the lanemask of a register class we have to include the
masks of subregisters supported by any of the class members, not just
the ones supported by all class members.

This fixes problems when coalescing towards a subclass with additional
subregisters available.

The attached testcase works fine as is, but does crash if you enable
subregister liveness on x86 without this change applied.

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

9 years agoHandle X86::reloc_riprel_4byte in 32 bits mode.
Rafael Espindola [Wed, 18 Mar 2015 17:33:40 +0000 (17:33 +0000)]
Handle X86::reloc_riprel_4byte in 32 bits mode.

We can get there with .code64.

Fixes pr22349.

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

9 years ago[Hexagon] Use pseudo-instructions for true/false predicate values
Krzysztof Parzyszek [Wed, 18 Mar 2015 17:20:51 +0000 (17:20 +0000)]
[Hexagon] Use pseudo-instructions for true/false predicate values

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

9 years agoUse utils/update_llc_test_checks.py to update all CHECKs
Sanjay Patel [Wed, 18 Mar 2015 16:38:44 +0000 (16:38 +0000)]
Use utils/update_llc_test_checks.py to update all CHECKs

The checks here were so vague that we could nuke intrinsics
from existence and still pass the test because we'd match
the function name.

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

9 years ago[Hexagon] Intrinsics for circular and bit-reversed loads and stores
Krzysztof Parzyszek [Wed, 18 Mar 2015 16:23:44 +0000 (16:23 +0000)]
[Hexagon] Intrinsics for circular and bit-reversed loads and stores

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

9 years agofixed to test features, not CPU model
Sanjay Patel [Wed, 18 Mar 2015 16:07:10 +0000 (16:07 +0000)]
fixed to test features, not CPU model

The 'vmovntdq' was only passing due to a fluke in
SandyBridge codegen that splits 32-byte stores in half,
but that meant that the test was not correctly checking
for the 32-byte store that we thought we were generating.

The lax checking in this file will be addressed in
another commit. There are bigger problems here.

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

9 years ago[Hexagon] Handle ENDLOOP0 in InsertBranch and RemoveBranch
Krzysztof Parzyszek [Wed, 18 Mar 2015 15:56:43 +0000 (15:56 +0000)]
[Hexagon] Handle ENDLOOP0 in InsertBranch and RemoveBranch

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

9 years agoAdd support for .ifnes psuedo-op.
Sid Manning [Wed, 18 Mar 2015 14:20:54 +0000 (14:20 +0000)]
Add support for .ifnes psuedo-op.

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

9 years agoclang-format these lines to fix Visual C++ warning.
Yaron Keren [Wed, 18 Mar 2015 12:50:00 +0000 (12:50 +0000)]
clang-format these lines to fix Visual C++ warning.

Visual C++ 2013 complains "warning C4138: '*/' found outside of comment"
about the code

 CallInst */*CI*/

but compiles OK. clang-formatting these lines adds an extra space and
makes Visual C++ satisfied.

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

9 years agoChange test to accept an additional critical edge split.
Daniel Jasper [Wed, 18 Mar 2015 12:45:45 +0000 (12:45 +0000)]
Change test to accept an additional critical edge split.

The two hot blocks are right next to each other and I verified that
there is no performance regression by compressing/uncompressing some
files with a minigzip built with the different options.

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

9 years ago[ARM] Align stack objects passed to memory intrinsics
John Brawn [Wed, 18 Mar 2015 12:01:59 +0000 (12:01 +0000)]
[ARM] Align stack objects passed to memory intrinsics

Memcpy, and other memory intrinsics, typically tries to use LDM/STM if
the source and target addresses are 4-byte aligned. In CodeGenPrepare
look for calls to memory intrinsics and, if the object is on the
stack, 4-byte align it if it's large enough that we expect that memcpy
would want to use LDM/STM to copy it.

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

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

9 years agoAdd missing newline to end of test file.
John Brawn [Wed, 18 Mar 2015 10:45:12 +0000 (10:45 +0000)]
Add missing newline to end of test file.

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

9 years agoRemove many superfluous SmallString::str() calls.
Yaron Keren [Wed, 18 Mar 2015 10:17:07 +0000 (10:17 +0000)]
Remove many superfluous SmallString::str() calls.

Now that SmallString is a first-class citizen, most SmallString::str()
calls are not required. This patch removes a whole bunch of them, yet
there are lots more.

There are two use cases where str() is really needed:
1) To use one of StringRef member functions which is not available in
SmallString.
2) To convert to std::string, as StringRef implicitly converts while
SmallString do not. We may wish to change this, but it may introduce
ambiguity.

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

9 years ago[mips] Add itineraries for ext and ins instructions.
Kai Nacke [Wed, 18 Mar 2015 06:28:38 +0000 (06:28 +0000)]
[mips] Add itineraries for ext and ins instructions.

Currently, there are no itineraries defined for ext and ins instructions.
This patch adds these itineraries and uses them in the instruction definitions.

Reviewed By: dsanders

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

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

9 years agoSplit comma-separated \param(s). [-Wdocumentation]
NAKAMURA Takumi [Wed, 18 Mar 2015 02:09:25 +0000 (02:09 +0000)]
Split comma-separated \param(s). [-Wdocumentation]

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

9 years ago[bpf] fix build
Alexei Starovoitov [Wed, 18 Mar 2015 01:39:40 +0000 (01:39 +0000)]
[bpf] fix build

fix BPF backend build broken by r232429

Patch by Brenden Blanco

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

9 years agoAdd testcases for BEXTR.
Josh Magee [Wed, 18 Mar 2015 01:34:06 +0000 (01:34 +0000)]
Add testcases for BEXTR.

These BEXTR cases are a check for the 64-bit load form and two negative cases where the bitrange is non-contiguous.  From a private patch equivalent to r189742/PR17028.

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

9 years agoMissed testcase for r232577
Krzysztof Parzyszek [Wed, 18 Mar 2015 00:44:46 +0000 (00:44 +0000)]
Missed testcase for r232577

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

9 years agoGenerate bit manipulation instructions on Hexagon
Krzysztof Parzyszek [Wed, 18 Mar 2015 00:43:46 +0000 (00:43 +0000)]
Generate bit manipulation instructions on Hexagon

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

9 years ago[SCEV] Make isImpliedCond smarter.
Sanjoy Das [Wed, 18 Mar 2015 00:41:29 +0000 (00:41 +0000)]
[SCEV] Make isImpliedCond smarter.

Summary:
This change teaches isImpliedCond to infer things like "X sgt 0" => "X -
1 sgt -1".  The `ConstantRange` class has the logic to do the heavy
lifting, this change simply gets ScalarEvolution to exploit that when
reasonable.

Depends on D8345

Reviewers: atrick

Subscribers: llvm-commits

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

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

9 years ago[ConstantRange] Split makeICmpRegion in two.
Sanjoy Das [Wed, 18 Mar 2015 00:41:24 +0000 (00:41 +0000)]
[ConstantRange] Split makeICmpRegion in two.

Summary:
This change splits `makeICmpRegion` into `makeAllowedICmpRegion` and
`makeSatisfyingICmpRegion` with slightly different contracts.  The first
one is useful for determining what values some expression //may// take,
given that a certain `icmp` evaluates to true.  The second one is useful
for determining what values are guaranteed to //satisfy// a given
`icmp`.

Reviewers: nlewycky

Reviewed By: nlewycky

Subscribers: llvm-commits

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

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

9 years agoDAGCombiner: fold (xor (shl 1, x), -1) -> (rotl ~1, x)
David Majnemer [Wed, 18 Mar 2015 00:03:36 +0000 (00:03 +0000)]
DAGCombiner: fold (xor (shl 1, x), -1) -> (rotl ~1, x)

Targets which provide a rotate make it possible to replace a sequence of
(XOR (SHL 1, x), -1) with (ROTL ~1, x).  This saves an instruction on
architectures like X86 and POWER(64).

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

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

9 years agoCOFF: Let globals with private linkage reside in their own section
David Majnemer [Tue, 17 Mar 2015 23:54:51 +0000 (23:54 +0000)]
COFF: Let globals with private linkage reside in their own section

COFF COMDATs (for selection kinds other than 'select any') require at
least one non-section symbol in the symbol table.
Satisfy this by morally enhancing the linkage from private to internal.

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

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

9 years agoRemove unneeded selection functions from HexagonISelDAGToDAG
Krzysztof Parzyszek [Tue, 17 Mar 2015 23:54:48 +0000 (23:54 +0000)]
Remove unneeded selection functions from HexagonISelDAGToDAG

- SelectSelect, and
- SelectTruncate

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

9 years agodocs: Update LangRef and SourceLevelDebugging
Duncan P. N. Exon Smith [Tue, 17 Mar 2015 23:41:05 +0000 (23:41 +0000)]
docs: Update LangRef and SourceLevelDebugging

Cleanup some bitrot in SourceLevelDebugging.rst.

  - Pull the still-relevant details about individual descriptors into
    LangRef.rst.  Cut a lot of it to avoid over-describing the fields,
    as the C++ classes and assembly format are mostly self-describing
    now.  If there's anything specific that I shouldn't have cut, let me
    know and I'll add it back.
  - Rewrite the remaining sections to refer to the new debug info
    hierarchy in LangRef.rst.

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

9 years agoFix bug while building FP16 constant vectors for AArch64
Pirama Arumuga Nainar [Tue, 17 Mar 2015 23:10:29 +0000 (23:10 +0000)]
Fix bug while building FP16 constant vectors for AArch64

Summary: Building FP16 constant vectors caused the FP16 data to be bitcast to i64.  This patch creates a BITCAST node with the correct value, and adds a test to verify correct handling.

Reviewers: mcrosier

Reviewed By: mcrosier

Subscribers: mcrosier, jmolloy, ab, srhines, llvm-commits, rengolin, aemerson

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

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

9 years agoAppease AArch64ISelLowering.cpp miscompiled by g++-4.7.2.
NAKAMURA Takumi [Tue, 17 Mar 2015 22:55:01 +0000 (22:55 +0000)]
Appease AArch64ISelLowering.cpp miscompiled by g++-4.7.2.

I will revert this when 4.7.3 is ready.

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

9 years agoAdd the option -no-symbolic-operands to llvm-objdump used with -macho and
Kevin Enderby [Tue, 17 Mar 2015 22:26:11 +0000 (22:26 +0000)]
Add the option -no-symbolic-operands to llvm-objdump used with -macho and
-disassemble to not symbolic operands when disassembling.

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

9 years agoXformToShuffleWithZero - Added clearer early outs and general tidy up. NFCI
Simon Pilgrim [Tue, 17 Mar 2015 22:19:08 +0000 (22:19 +0000)]
XformToShuffleWithZero - Added clearer early outs and general tidy up. NFCI

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

9 years agoSelection DAG preprocessing on Hexagon
Krzysztof Parzyszek [Tue, 17 Mar 2015 21:47:16 +0000 (21:47 +0000)]
Selection DAG preprocessing on Hexagon

Simplify: (or (select c x 0) z)  ->  (select c (or x z) z)
          (or (select c 0 y) z)  ->  (select c z (or y z))

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

9 years agoRemove StringRef->std::string->StringRef conversions.
Yaron Keren [Tue, 17 Mar 2015 21:33:38 +0000 (21:33 +0000)]
Remove StringRef->std::string->StringRef conversions.

As StringInit::get() accepts StringRef there is no need
to construct a std::string out of the StringRef input and
then construct a new StringRef from the std::string.

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

9 years agoDebugInfo: Drop fake DW_TAG_expression
Duncan P. N. Exon Smith [Tue, 17 Mar 2015 21:32:46 +0000 (21:32 +0000)]
DebugInfo: Drop fake DW_TAG_expression

Break MDExpression off of DebugNode (inherit directly from `MDNode`) and
drop the fake `DW_TAG_expression` tag in the process.

AFAICT, there's no real functionality change here.  The tag was
originally used by `DIDescriptor::isExpression()` to discriminate
between `MDNode`s, but in the new hierarchy we don't need that.

Fixes PR22780.

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

9 years agoEmit the offset directly instead of creating a dummy expression.
Rafael Espindola [Tue, 17 Mar 2015 21:30:21 +0000 (21:30 +0000)]
Emit the offset directly instead of creating a dummy expression.

We were creating an expression of the form (S+C)-S which is just C.

Patch by Frédéric Riss. I just added the testcase.

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

9 years agoAdd the option, -no-leading-addr llvm-objdump used with -macho and
Kevin Enderby [Tue, 17 Mar 2015 21:07:39 +0000 (21:07 +0000)]
Add the option, -no-leading-addr llvm-objdump used with -macho and
-disassemble or -section to not print the leading addresses on each line.

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

9 years ago[docs] Fix some malformed links.
Sean Silva [Tue, 17 Mar 2015 21:02:37 +0000 (21:02 +0000)]
[docs] Fix some malformed links.

Patch by Stanislav Manilov!

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

9 years agoRevert "COFF: Let globals with private linkage reside in their own section"
David Majnemer [Tue, 17 Mar 2015 20:41:11 +0000 (20:41 +0000)]
Revert "COFF: Let globals with private linkage reside in their own section"

This reverts commit r232539.  This was committed accidently.

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

9 years agoInternalize BitcodeReader. Not used outside of BitcodeReader.cpp.
Benjamin Kramer [Tue, 17 Mar 2015 20:40:24 +0000 (20:40 +0000)]
Internalize BitcodeReader. Not used outside of BitcodeReader.cpp.

NFC.

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