oota-llvm.git
10 years agoFix non-deterministic behavior.
Rafael Espindola [Thu, 5 Dec 2013 18:28:01 +0000 (18:28 +0000)]
Fix non-deterministic behavior.

We use CSEBlocks to initialize a worklist:

SmallVector<BasicBlock *, 8> CSEWorkList(CSEBlocks.begin(), CSEBlocks.end());

so it must have a deterministic order.

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

10 years agoRename DwarfUnits to DwarfFile to help avoid some naming confusion.
Eric Christopher [Thu, 5 Dec 2013 18:06:10 +0000 (18:06 +0000)]
Rename DwarfUnits to DwarfFile to help avoid some naming confusion.

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

10 years agoMI-Sched: Model "reserved" processor resources.
Andrew Trick [Thu, 5 Dec 2013 17:56:02 +0000 (17:56 +0000)]
MI-Sched: Model "reserved" processor resources.

This allows a target to use MI-Sched as an in-order scheduler that
will model strict resource conflicts without defining a processor
itinerary. Instead, the target can now use the new per-operand machine
model and define in-order resources with BufferSize=0. For example,
this would allow restricting the type of operations that can be formed
into a dispatch group. (Normally NumMicroOps is sufficient to enforce
dispatch groups).

If the intent is to model latency in in-order pipeline, as opposed to
resource conflicts, then a resource with BufferSize=1 should be
defined instead.

This feature is only casually tested as there are no in-tree targets
using it yet. However, Hal will be experimenting with POWER7.

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

10 years agoMI-Sched: handle latency of in-order operations with the new machine model.
Andrew Trick [Thu, 5 Dec 2013 17:55:58 +0000 (17:55 +0000)]
MI-Sched: handle latency of in-order operations with the new machine model.

The per-operand machine model allows the target to define "unbuffered"
processor resources. This change is a quick, cheap way to model stalls
caused by the latency of operations that use such resources. This only
applies when the processor's micro-op buffer size is non-zero
(Out-of-Order). We can't precisely model in-order stalls during
out-of-order execution, but this is an easy and effective
heuristic. It benefits cortex-a9 scheduling when using the new
machine model, which is not yet on by default.

MI-Sched for armv7 was evaluated on Swift (and only not enabled because
of a performance bug related to predication). However, we never
evaluated Cortex-A9 performance on MI-Sched in its current form. This
change adds MI-Sched functionality to reach performance goals on
A9. The only remaining change is to allow MI-Sched to run as a PostRA
pass.

I evaluated performance using a set of options to estimate the performance impact once MI sched is default on armv7:
-mcpu=cortex-a9 -disable-post-ra -misched-bench -scheditins=false

For a simple saxpy loop I see a 1.7x speedup. Here are the llvm-testsuite results:
(min run time over 2 runs, filtering tiny changes)

Speedups:
| Benchmarks/BenchmarkGame/recursive         |  52.39% |
| Benchmarks/VersaBench/beamformer           |  20.80% |
| Benchmarks/Misc/pi                         |  19.97% |
| Benchmarks/Misc/mandel-2                   |  19.95% |
| SPEC/CFP2000/188.ammp                      |  18.72% |
| Benchmarks/McCat/08-main/main              |  18.58% |
| Benchmarks/Misc-C++/Large/sphereflake      |  18.46% |
| Benchmarks/Olden/power                     |  17.11% |
| Benchmarks/Misc-C++/mandel-text            |  16.47% |
| Benchmarks/Misc/oourafft                   |  15.94% |
| Benchmarks/Misc/flops-7                    |  14.99% |
| Benchmarks/FreeBench/distray               |  14.26% |
| SPEC/CFP2006/470.lbm                       |  14.00% |
| mediabench/mpeg2/mpeg2dec/mpeg2decode      |  12.28% |
| Benchmarks/SmallPT/smallpt                 |  10.36% |
| Benchmarks/Misc-C++/Large/ray              |   8.97% |
| Benchmarks/Misc/fp-convert                 |   8.75% |
| Benchmarks/Olden/perimeter                 |   7.10% |
| Benchmarks/Bullet/bullet                   |   7.03% |
| Benchmarks/Misc/mandel                     |   6.75% |
| Benchmarks/Olden/voronoi                   |   6.26% |
| Benchmarks/Misc/flops-8                    |   5.77% |
| Benchmarks/Misc/matmul_f64_4x4             |   5.19% |
| Benchmarks/MiBench/security-rijndael       |   5.15% |
| Benchmarks/Misc/flops-6                    |   5.10% |
| Benchmarks/Olden/tsp                       |   4.46% |
| Benchmarks/MiBench/consumer-lame           |   4.28% |
| Benchmarks/Misc/flops-5                    |   4.27% |
| Benchmarks/mafft/pairlocalalign            |   4.19% |
| Benchmarks/Misc/himenobmtxpa               |   4.07% |
| Benchmarks/Misc/lowercase                  |   4.06% |
| SPEC/CFP2006/433.milc                      |   3.99% |
| Benchmarks/tramp3d-v4                      |   3.79% |
| Benchmarks/FreeBench/pifft                 |   3.66% |
| Benchmarks/Ptrdist/ks                      |   3.21% |
| Benchmarks/Adobe-C++/loop_unroll           |   3.12% |
| SPEC/CINT2000/175.vpr                      |   3.12% |
| Benchmarks/nbench                          |   2.98% |
| SPEC/CFP2000/183.equake                    |   2.91% |
| Benchmarks/Misc/perlin                     |   2.85% |
| Benchmarks/Misc/flops-1                    |   2.82% |
| Benchmarks/Misc-C++-EH/spirit              |   2.80% |
| Benchmarks/Misc/flops-2                    |   2.77% |
| Benchmarks/NPB-serial/is                   |   2.42% |
| Benchmarks/ASC_Sequoia/CrystalMk           |   2.33% |
| Benchmarks/BenchmarkGame/n-body            |   2.28% |
| Benchmarks/SciMark2-C/scimark2             |   2.27% |
| Benchmarks/Olden/bh                        |   2.03% |
| skidmarks10/skidmarks                      |   1.81% |
| Benchmarks/Misc/flops                      |   1.72% |

Slowdowns:
| Benchmarks/llubenchmark/llu                | -14.14% |
| Benchmarks/Polybench/stencils/seidel-2d    |  -5.67% |
| Benchmarks/Adobe-C++/functionobjects       |  -5.25% |
| Benchmarks/Misc-C++/oopack_v1p8            |  -5.00% |
| Benchmarks/Shootout/hash                   |  -2.35% |
| Benchmarks/Prolangs-C++/ocean              |  -2.01% |
| Benchmarks/Polybench/medley/floyd-warshall |  -1.98% |
| Polybench/linear-algebra/kernels/3mm       |  -1.95% |
| Benchmarks/McCat/09-vor/vor                |  -1.68% |

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

10 years agoMachine model comments. Explain a ProcessorUnit's BufferSize.
Andrew Trick [Thu, 5 Dec 2013 17:55:53 +0000 (17:55 +0000)]
Machine model comments. Explain a ProcessorUnit's BufferSize.

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

10 years agoFix the A9 machine model. VTRN writes two registers.
Andrew Trick [Thu, 5 Dec 2013 17:55:49 +0000 (17:55 +0000)]
Fix the A9 machine model. VTRN writes two registers.

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

10 years agocomment typo and reformat
Andrew Trick [Thu, 5 Dec 2013 17:55:47 +0000 (17:55 +0000)]
comment typo and reformat

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

10 years agoAdd a default constructor to get deterministic behavior.
Rafael Espindola [Thu, 5 Dec 2013 16:21:17 +0000 (16:21 +0000)]
Add a default constructor to get deterministic behavior.

Should fix the msan and valgrind bots.

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

10 years agoSLPVectorizer: An in-tree vectorized entry cannot also be a scalar external use
Arnold Schwaighofer [Thu, 5 Dec 2013 15:14:40 +0000 (15:14 +0000)]
SLPVectorizer: An in-tree vectorized entry cannot also be a scalar external use

We were creating external uses for scalar values in MustGather entries that also
had a ScalarToTreeEntry (they also are present in a vectorized tuple). This
meant we would keep a value 'alive' as a scalar and vectorized causing havoc.
This is not necessary because when we create a MustGather vector we explicitly
create external uses entries for the insertelement instructions of the
MustGather vector elements.

Fixes PR18129.

radar://15582184

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

10 years ago[tsan] fix PR18146: sometimes a variable written into vptr could have an integer...
Kostya Serebryany [Thu, 5 Dec 2013 15:03:02 +0000 (15:03 +0000)]
[tsan] fix PR18146: sometimes a variable written into vptr could have an integer type (after other optimizations)

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

10 years ago[NVPTX] Fix off-by-one error when creating the VT list for an SDNode
Justin Holewinski [Thu, 5 Dec 2013 12:58:00 +0000 (12:58 +0000)]
[NVPTX] Fix off-by-one error when creating the VT list for an SDNode

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

10 years agoAdd forgotten header guards
Alexey Samsonov [Thu, 5 Dec 2013 12:52:32 +0000 (12:52 +0000)]
Add forgotten header guards

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

10 years ago[mips] Small code generation improvement for conditional operator (select)
Matheus Almeida [Thu, 5 Dec 2013 12:07:05 +0000 (12:07 +0000)]
[mips] Small code generation improvement for conditional operator (select)
in case the operands are constants and its difference is |1|.
It should be possible in those cases to rematerialize the result using
MIPS's slt and similar instructions.

The small update to some of the tests in cmov.ll, sel1c.ll and sel2c.ll was needed
otherwise the optimization implemented in this patch would have been triggered
(difference between the operands was 1) and that would have changed the semantic
of the tests.

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

10 years ago[mips] Add some comments related to the optimization performed in performSELECTCombine.
Matheus Almeida [Thu, 5 Dec 2013 11:56:56 +0000 (11:56 +0000)]
[mips] Add some comments related to the optimization performed in performSELECTCombine.
The structure of the code was slightly modified so that the next patch is easier to read/review.

No functional changes.

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

10 years ago[mips][msa] Fix issue with immediate fields of LD/ST instructions
Matheus Almeida [Thu, 5 Dec 2013 11:06:22 +0000 (11:06 +0000)]
[mips][msa] Fix issue with immediate fields of LD/ST instructions
not being correctly encoded/decoded.
In more detail, immediate fields of LD/ST instructions should be
divided/multiplied by the size of the data format before encoding and
after decoding, respectively.

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

10 years agoARM: fix yet another stack-folding bug
Tim Northover [Thu, 5 Dec 2013 11:02:02 +0000 (11:02 +0000)]
ARM: fix yet another stack-folding bug

We were trying to fold the stack adjustment into the wrong instruction in the
situation where the entire basic-block was epilogue code. Really, it can only
ever be valid to do the folding precisely where the "add sp, ..." would be
placed so there's no need for a separate iterator to track that.

Should fix PR18136.

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

10 years agoDwarfDebug/DwarfUnit: Push abbreviation structures down into DwarfUnits to reduce...
David Blaikie [Thu, 5 Dec 2013 07:43:55 +0000 (07:43 +0000)]
DwarfDebug/DwarfUnit: Push abbreviation structures down into DwarfUnits to reduce duplication

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

10 years agoUse isIntrinsic() instead of checking for "llvm."
Matt Arsenault [Thu, 5 Dec 2013 06:05:43 +0000 (06:05 +0000)]
Use isIntrinsic() instead of checking for "llvm."

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

10 years agoRemove the isImplicitlyPrivate argument of getNameWithPrefix.
Rafael Espindola [Thu, 5 Dec 2013 05:53:12 +0000 (05:53 +0000)]
Remove the isImplicitlyPrivate argument of getNameWithPrefix.

getSymbolWithGlobalValueBase use is to create a name of a new symbol based
on the name of an existing GV. Assert that and then remove the last call
to pass true to isImplicitlyPrivate.

This gives the mangler API a 1:1 mapping from GV to names, which is what we
need to drop the mangler dependency on the target (and use an extended
datalayout instead).

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

10 years agoCorrect word hyphenations
Alp Toker [Thu, 5 Dec 2013 05:44:44 +0000 (05:44 +0000)]
Correct word hyphenations

This patch tries to avoid unrelated changes other than fixing a few
hyphen-related ambiguities and contractions in nearby lines.

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

10 years agoHide the stub created for MO_ExternalSymbol too.
Rafael Espindola [Thu, 5 Dec 2013 05:19:12 +0000 (05:19 +0000)]
Hide the stub created for MO_ExternalSymbol too.

given

declare void @llvm.memset.p0i8.i32(i8* nocapture, i8, i32, i32, i1)
declare void @foo()
define void @bar() {
  call void @foo()
  call void @llvm.memset.p0i8.i32(i8* null, i8 0, i32 188, i32 1, i1 false)
  ret void
}

We used to produce

L_foo$stub:
        .indirect_symbol        _foo
        .ascii  "\364\364\364\364\364"

_memset$stub:
        .indirect_symbol        _memset
        .ascii  "\364\364\364\364\364"

We not produce a private stub for memset too.

Stubs are not needed with recent linkers, but we still produce them for darwin8.

Thanks to David Fang for confirming that gcc used to do this too.

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

10 years agoR600/SI: Add comments for number of used registers.
Matt Arsenault [Thu, 5 Dec 2013 05:15:35 +0000 (05:15 +0000)]
R600/SI: Add comments for number of used registers.

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

10 years agoTry harder to get a consistent floating point results.
Rafael Espindola [Thu, 5 Dec 2013 04:14:33 +0000 (04:14 +0000)]
Try harder to get a consistent floating point results.

This just extends the existing hack. It should be enough to get a reproducible bootstrap
on 32 bits.

I will open a bug to track getting a real fix for this.

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

10 years agoMove llvm/test/MC/ELF/thumb-st_other.s to test/MC/ARM.
NAKAMURA Takumi [Thu, 5 Dec 2013 02:21:44 +0000 (02:21 +0000)]
Move llvm/test/MC/ELF/thumb-st_other.s to test/MC/ARM.

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

10 years agoFor AArch64, add missing register cost calculation for big value types like v4i64...
Jiangning Liu [Thu, 5 Dec 2013 02:12:01 +0000 (02:12 +0000)]
For AArch64, add missing register cost calculation for big value types like v4i64 and v8i64.

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

10 years agoAdd FileCheck statements for r196435.
Cameron McInally [Thu, 5 Dec 2013 01:20:36 +0000 (01:20 +0000)]
Add FileCheck statements for r196435.

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

10 years agoCompiler.h: Disable initializer list usage with clang-cl
Reid Kleckner [Thu, 5 Dec 2013 01:03:23 +0000 (01:03 +0000)]
Compiler.h: Disable initializer list usage with clang-cl

Most people are using MSVC 2012, which lacks the <initializer_list>
header.  MSVC 2013 shipped with that header, but it has not yet been
tested.  If clang works with the 2013 header, then we can enable this by
checking the value of _MSC_VER.

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

10 years agoExport symbols in tools that support loading plugins.
Will Dietz [Thu, 5 Dec 2013 01:01:58 +0000 (01:01 +0000)]
Export symbols in tools that support loading plugins.

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

10 years agoDwarfDebug: Avoid unnecessary abbreviation lookup when emitting DIEs
David Blaikie [Thu, 5 Dec 2013 01:01:41 +0000 (01:01 +0000)]
DwarfDebug: Avoid unnecessary abbreviation lookup when emitting DIEs

DIEs already contain references directly to their DIEAbbrev, use that
instead of looking it up based on index.

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

10 years agoDwarfDebug: Remove trivial function wrapper
David Blaikie [Thu, 5 Dec 2013 01:01:37 +0000 (01:01 +0000)]
DwarfDebug: Remove trivial function wrapper

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

10 years agoMake these two tests resilient in the face of compile unit size
Eric Christopher [Thu, 5 Dec 2013 01:00:12 +0000 (01:00 +0000)]
Make these two tests resilient in the face of compile unit size
changes.

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

10 years ago80-column.
Eric Christopher [Thu, 5 Dec 2013 00:36:21 +0000 (00:36 +0000)]
80-column.

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

10 years agoRemove special handling for DW_AT_ranges support by constructing the
Eric Christopher [Thu, 5 Dec 2013 00:36:17 +0000 (00:36 +0000)]
Remove special handling for DW_AT_ranges support by constructing the
values with the correct behavior.

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

10 years ago[mc] Fix ELF st_other flag.
Logan Chien [Thu, 5 Dec 2013 00:34:11 +0000 (00:34 +0000)]
[mc] Fix ELF st_other flag.

ELF_Other_Weakref and ELF_Other_ThumbFunc seems to be LLVM
internal ELF symbol flags.  These should not be emitted to
object file.

This commit defines ELF_STO_Shift for the target-defined
flags for st_other, and increase the value of
ELF_Other_Shift to 16.

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

10 years agoUse present fast-math flags when applicable in CreateBinOp
Michael Ilseman [Thu, 5 Dec 2013 00:32:09 +0000 (00:32 +0000)]
Use present fast-math flags when applicable in CreateBinOp

We were previously not adding fast-math flags through CreateBinOp()
when it happened to be making a floating point binary operator. This
patch updates it to do so similarly to directly calling CreateF*().

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

10 years agoFix comment.
Eric Christopher [Thu, 5 Dec 2013 00:13:15 +0000 (00:13 +0000)]
Fix comment.

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

10 years agoAdd AVX512 patterns for v16i32 broadcast and v2i64 zero extend load.
Cameron McInally [Thu, 5 Dec 2013 00:11:25 +0000 (00:11 +0000)]
Add AVX512 patterns for v16i32 broadcast and v2i64 zero extend load.

Patch by Aleksey Bader.

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

10 years agoFix typo.
Eric Christopher [Wed, 4 Dec 2013 23:55:09 +0000 (23:55 +0000)]
Fix typo.

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

10 years agoDwarfUnit: Correct comment by generalizing over all units, not just compilation units.
David Blaikie [Wed, 4 Dec 2013 23:39:02 +0000 (23:39 +0000)]
DwarfUnit: Correct comment by generalizing over all units, not just compilation units.

Code review feedback on r196394 by Paul Robinson.

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

10 years agoFix a bug in darwin's 32-bit X86 handling of evaluating fixups.
Kevin Enderby [Wed, 4 Dec 2013 23:36:24 +0000 (23:36 +0000)]
Fix a bug in darwin's 32-bit X86 handling of evaluating fixups.

Where it would use a scattered relocation entry but falls back to a
normal relocation entry because the FixupOffset is more than 24-bits.

The bug is in the X86MachObjectWriter::RecordScatteredRelocation() where
it changes reference parameter FixedValue but then returns false to indicate
it did not create a scattered relocation entry.  The fix is simply to save the
original value of the parameter FixedValue at the start of the method and
restore it if we are returning false in that case.

rdar://15526046

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

10 years agoUpdate comment.
Eric Christopher [Wed, 4 Dec 2013 23:24:38 +0000 (23:24 +0000)]
Update comment.

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

10 years agoUpdate comment.
Eric Christopher [Wed, 4 Dec 2013 23:24:28 +0000 (23:24 +0000)]
Update comment.

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

10 years agoRemove incorrect comment and pointless cast.
Eric Christopher [Wed, 4 Dec 2013 23:05:21 +0000 (23:05 +0000)]
Remove incorrect comment and pointless cast.

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

10 years agoconst on its own line is confusing.
Eric Christopher [Wed, 4 Dec 2013 22:54:45 +0000 (22:54 +0000)]
const on its own line is confusing.

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

10 years agoAdd support for parsing ARM symbol variants on ELF targets
David Peixotto [Wed, 4 Dec 2013 22:43:20 +0000 (22:43 +0000)]
Add support for parsing ARM symbol variants on ELF targets

ARM symbol variants are written with parens instead of @ like this:

  .word __GLOBAL_I_a(target1)

This commit adds support for parsing these symbol variants in
expressions. We introduce a new flag to MCAsmInfo that indicates the
parser should use parens to parse the symbol variant. The expression
parser is modified to look for symbol variants using parens instead
of @ when the corresponding MCAsmInfo flag is true.

The MCAsmInfo parens flag is enabled only for ARM on ELF.

By adding this flag to MCAsmInfo, we are able to get rid of
redundant ARM-specific symbol variants and use the generic variants
instead (e.g. VK_GOT instead of VK_ARM_GOT). We use the new
UseParensForSymbolVariant attribute in MCAsmInfo to correctly print
the symbol variants for arm.

To achive this we need to keep a handle to the MCAsmInfo in the
MCSymbolRefExpr class that we can check when printing the symbol
variant.

Updated Tests:
  Changed case of symbol variant to match the generic kind.
  test/CodeGen/ARM/tls-models.ll
  test/CodeGen/ARM/tls1.ll
  test/CodeGen/ARM/tls2.ll
  test/CodeGen/Thumb2/tls1.ll
  test/CodeGen/Thumb2/tls2.ll

PR18080

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

10 years agoSimplify check.
Eric Christopher [Wed, 4 Dec 2013 22:29:02 +0000 (22:29 +0000)]
Simplify check.

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

10 years agoReformat slightly.
Eric Christopher [Wed, 4 Dec 2013 22:26:43 +0000 (22:26 +0000)]
Reformat slightly.

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

10 years agoMake RangeSpanList take a symbol for the beginning of the range
Eric Christopher [Wed, 4 Dec 2013 22:04:50 +0000 (22:04 +0000)]
Make RangeSpanList take a symbol for the beginning of the range
rather than magically making the names match.

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

10 years agoAdd a FIXME for making the symbol emission functions const.
Eric Christopher [Wed, 4 Dec 2013 22:04:46 +0000 (22:04 +0000)]
Add a FIXME for making the symbol emission functions const.

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

10 years agoDwarfDebug: Unconditionalize trivial asm comments
David Blaikie [Wed, 4 Dec 2013 21:51:05 +0000 (21:51 +0000)]
DwarfDebug: Unconditionalize trivial asm comments

While we still have a few (~4) non-trivial comments with string
concatenation, etc that should remain conditionalized, these trivial
literal comments can be simplified.

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

10 years agoDwarfDebug: Reduce code duplication for sec offset emission
David Blaikie [Wed, 4 Dec 2013 21:31:26 +0000 (21:31 +0000)]
DwarfDebug: Reduce code duplication for sec offset emission

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

10 years agoCouple of small logical cleanups to use !empty rather than other
Eric Christopher [Wed, 4 Dec 2013 21:20:15 +0000 (21:20 +0000)]
Couple of small logical cleanups to use !empty rather than other
checks. No functional change.

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

10 years agollvm-cov: Replace size() with empty() in bool check.
Yuchen Wu [Wed, 4 Dec 2013 19:18:23 +0000 (19:18 +0000)]
llvm-cov: Replace size() with empty() in bool check.

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

10 years agoUse move and stack allocation for RangeSpanLists. As a result make
Eric Christopher [Wed, 4 Dec 2013 19:06:58 +0000 (19:06 +0000)]
Use move and stack allocation for RangeSpanLists. As a result make
a few things more const as well because we're now using const
references to refer to iterators.

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

10 years agoDebugInfo: Improve test to use llvm-dwarfdump
David Blaikie [Wed, 4 Dec 2013 18:40:29 +0000 (18:40 +0000)]
DebugInfo: Improve test to use llvm-dwarfdump

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

10 years agoTest fix for r196394
David Blaikie [Wed, 4 Dec 2013 18:34:28 +0000 (18:34 +0000)]
Test fix for r196394

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

10 years agoDebugInfo: Remove unused start/end labels for the debug_abbrevs section
David Blaikie [Wed, 4 Dec 2013 18:12:28 +0000 (18:12 +0000)]
DebugInfo: Remove unused start/end labels for the debug_abbrevs section

Since we always emit only one abbrevation section (shared by all the
compilation units in this module) there's no need for a separate label
at the start of each one (and we weren't using the CU ID anyway, so
there really was only one label). Use the section label instead and drop
the wholely unused debug_abbrev_end label.

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

10 years agoFix assembly syntax for AVX512 vector blend instructions.
Cameron McInally [Wed, 4 Dec 2013 18:05:36 +0000 (18:05 +0000)]
Fix assembly syntax for AVX512 vector blend instructions.

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

10 years agoDebugInfo: Avoid recreating matching labels in disparate places.
David Blaikie [Wed, 4 Dec 2013 17:55:41 +0000 (17:55 +0000)]
DebugInfo: Avoid recreating matching labels in disparate places.

Instead, reuse the same MCSymbol - this should make the code easier to
follow by avoiding hard to trace dependencies between different bits of
code.

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

10 years ago[X86] Check YMM31/ZMM31 as well
Michael Liao [Wed, 4 Dec 2013 17:44:22 +0000 (17:44 +0000)]
[X86] Check YMM31/ZMM31 as well

- No test case as there's no calling convention preserve YMM31/ZMM31 only

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

10 years agoUpdate the UseFusedMAC definition to directly specify its dependence on having
Chad Rosier [Wed, 4 Dec 2013 17:16:36 +0000 (17:16 +0000)]
Update the UseFusedMAC definition to directly specify its dependence on having
VFP4.
Patch by Daniel Stewart!

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

10 years agoSuppress '(x < y) ? a : 0 -> (x < y) & a' transform on X86 architectures with dedicat...
Cameron McInally [Wed, 4 Dec 2013 14:52:33 +0000 (14:52 +0000)]
Suppress '(x < y) ? a : 0 -> (x < y) & a' transform on X86 architectures with dedicated mask registers.

Patch by Aleksey Bader.

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

10 years ago[CMake] add_lit_target: Let lit.site.cfg free from "--param build_mode" on single...
NAKAMURA Takumi [Wed, 4 Dec 2013 11:15:17 +0000 (11:15 +0000)]
[CMake] add_lit_target: Let lit.site.cfg free from "--param build_mode" on single configuration builds, like autoconf build.

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

10 years agoUpdate email address.
Bill Wendling [Wed, 4 Dec 2013 09:42:49 +0000 (09:42 +0000)]
Update email address.

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

10 years agoUn-revert r196358: "llvm-cov: Added support for function checksums."
Daniel Jasper [Wed, 4 Dec 2013 08:57:17 +0000 (08:57 +0000)]
Un-revert r196358: "llvm-cov: Added support for function checksums."

And add the proper fix.

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

10 years agoRevert r196358: "llvm-cov: Added support for function checksums."
Daniel Jasper [Wed, 4 Dec 2013 08:23:33 +0000 (08:23 +0000)]
Revert r196358: "llvm-cov: Added support for function checksums."

This currently breaks clang/test/CodeGen/code-coverage.c. The root cause
is that the newly introduced access to Funcs[j] is out of bounds.

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

10 years ago[AArch64 Neon] Add ACLE intrinsic vceqz_f64.
Kevin Qin [Wed, 4 Dec 2013 08:02:34 +0000 (08:02 +0000)]
[AArch64 Neon] Add ACLE intrinsic vceqz_f64.

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

10 years ago[AArch64 NEON] Add missing compare intrinsics.
Kevin Qin [Wed, 4 Dec 2013 07:53:28 +0000 (07:53 +0000)]
[AArch64 NEON] Add missing compare intrinsics.

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

10 years agollvm-cov: Added support for function checksums.
Yuchen Wu [Wed, 4 Dec 2013 06:00:17 +0000 (06:00 +0000)]
llvm-cov: Added support for function checksums.

The function checksums are hashed from the concatenation of the function
name and line number.

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

10 years agollvm-cov: Added checks for ident, checksum, name.
Yuchen Wu [Wed, 4 Dec 2013 05:42:28 +0000 (05:42 +0000)]
llvm-cov: Added checks for ident, checksum, name.

Added additional checks for the Identifier, CfgChecksum and Name for
each GCOVFunction. Also added function names in error messages.

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

10 years agollvm-cov: Capitalized GCNO and GCDA for consistency.
Yuchen Wu [Wed, 4 Dec 2013 05:07:36 +0000 (05:07 +0000)]
llvm-cov: Capitalized GCNO and GCDA for consistency.

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

10 years agollvm-cov: Split GCOVFile's read into GCNO and GCDA.
Yuchen Wu [Wed, 4 Dec 2013 04:49:23 +0000 (04:49 +0000)]
llvm-cov: Split GCOVFile's read into GCNO and GCDA.

This splits the file-scope read() function into readGCNO() and
readGCDA(). Also broke file format read into functions that first read
the file type, then check the version.

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

10 years agoFix a funny typo.
Rafael Espindola [Wed, 4 Dec 2013 02:26:54 +0000 (02:26 +0000)]
Fix a funny typo.

Thanks for j`ey and Sean Silva for noticing it.

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

10 years ago[LangRef] Remove (non-normative) paragraph that doesn't make sense.
Sean Silva [Wed, 4 Dec 2013 02:19:25 +0000 (02:19 +0000)]
[LangRef] Remove (non-normative) paragraph that doesn't make sense.

It appears to be referring to nonexistent entities. This must be a
carry-over from an older version of the document.

Patch by Mikael Lyngvig!

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

10 years agoProduce deterministic coff files.
Rafael Espindola [Wed, 4 Dec 2013 02:02:55 +0000 (02:02 +0000)]
Produce deterministic coff files.

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

10 years agoAdd -mcpu=core2 to all llc invocations in this test.
Rafael Espindola [Wed, 4 Dec 2013 01:25:24 +0000 (01:25 +0000)]
Add -mcpu=core2 to all llc invocations in this test.

Should fix the atom buildbot.

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

10 years ago[Stackmap] Specify the triple and cpu to fix the unit test.
Juergen Ributzka [Wed, 4 Dec 2013 01:02:37 +0000 (01:02 +0000)]
[Stackmap] Specify the triple and cpu to fix the unit test.

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

10 years ago[Stackmap] Emit multi-byte nops for X86.
Juergen Ributzka [Wed, 4 Dec 2013 00:39:08 +0000 (00:39 +0000)]
[Stackmap] Emit multi-byte nops for X86.

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

10 years agofinal patch for very long conditional branches for mips16 constant islands.
Reed Kotler [Tue, 3 Dec 2013 23:42:51 +0000 (23:42 +0000)]
final patch for very long conditional branches for mips16 constant islands.
this completes the basic port of ARM constant islands to Mips16.
More testing, code review, cleanup is in order but basically everything
seems to be working. A bug in gas is preventing some of the runtime
testing but I hope to resolve this soon.

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

10 years agocheck-llvm: Ask llvm-config about assertion mode, instead of llc.
NAKAMURA Takumi [Tue, 3 Dec 2013 23:22:25 +0000 (23:22 +0000)]
check-llvm: Ask llvm-config about assertion mode, instead of llc.

Add --assertion-mode to llvm-config. It emits ON or OFF according to NDEBUG.

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

10 years agoutils/llvm-lit: Generate "llvm-lit.py" rather than "llvm-lit" on Win32 hosts to let...
NAKAMURA Takumi [Tue, 3 Dec 2013 23:22:18 +0000 (23:22 +0000)]
utils/llvm-lit: Generate "llvm-lit.py" rather than "llvm-lit" on Win32 hosts to let llvm-lit.py --use-processes work.

llvm-lit needs suffix.py for multiprocess to find a main module.

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

10 years agoUpdate comment grammar and contents.
Eric Christopher [Tue, 3 Dec 2013 22:05:55 +0000 (22:05 +0000)]
Update comment grammar and contents.

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

10 years agoUse CHECK-LABEL to make this test more strict.
Rafael Espindola [Tue, 3 Dec 2013 21:12:36 +0000 (21:12 +0000)]
Use CHECK-LABEL to make this test more strict.

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

10 years agoFix mingw32 thiscall + sret.
Rafael Espindola [Tue, 3 Dec 2013 20:51:23 +0000 (20:51 +0000)]
Fix mingw32 thiscall + sret.

Unlike msvc, when handling a thiscall + sret gcc will
* Put the sret in %ecx
* Put the this pointer is (%esp)

This fixes, for example, calling stringstream::str.

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

10 years agoFixed various whitespace/spelling/80+ issues.
Michael Gottesman [Tue, 3 Dec 2013 20:21:17 +0000 (20:21 +0000)]
Fixed various whitespace/spelling/80+ issues.

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

10 years agoReturn true on success in cl::ExpandResponseFiles
Reid Kleckner [Tue, 3 Dec 2013 19:13:18 +0000 (19:13 +0000)]
Return true on success in cl::ExpandResponseFiles

This fixes a logic bug pointed out by Juraj Ivancic.

No behavior change because none of the in-tree clients of
cl::ExpandResponseFiles check the return value.  In this case, the
@prefixed arguments are left in the command line.  Downstream command
line processing has the opportunity to emit errors about it, so this
isn't that bad.

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

10 years agollvm-cov: Another fix to llvm-cov test.
Yuchen Wu [Tue, 3 Dec 2013 19:05:03 +0000 (19:05 +0000)]
llvm-cov: Another fix to llvm-cov test.

Copy all test files to temporary directory, not just test.* files. Tests
didn't fail because the missing files occurred in XFAILS.

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

10 years agoFix a typo in a comment
Timur Iskhodzhanov [Tue, 3 Dec 2013 18:57:43 +0000 (18:57 +0000)]
Fix a typo in a comment

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

10 years agoAvoid buffer copies when a Twine already is a StringRef.
David Blaikie [Tue, 3 Dec 2013 18:18:28 +0000 (18:18 +0000)]
Avoid buffer copies when a Twine already is a StringRef.

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

10 years agoTeach the internalize pass to skip dllexported symbols because they could be
Yunzhong Gao [Tue, 3 Dec 2013 18:05:14 +0000 (18:05 +0000)]
Teach the internalize pass to skip dllexported symbols because they could be
referenced in a way that even the linker does not see.

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

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

10 years agoopt: Mirror vectorization presets of clang
Arnold Schwaighofer [Tue, 3 Dec 2013 16:33:06 +0000 (16:33 +0000)]
opt: Mirror vectorization presets of clang

clang enables vectorization at optimization levels > 1 and size level < 2. opt
should behave similarily.

Loop vectorization and SLP vectorization can be disabled with the flags
-disable-(loop/slp)-vectorization.

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

10 years agoReland 196270 "Generalize debug info / EH emission in AsmPrinter"
Timur Iskhodzhanov [Tue, 3 Dec 2013 15:10:23 +0000 (15:10 +0000)]
Reland 196270 "Generalize debug info / EH emission in AsmPrinter"

Addressing the existense AMDGPUAsmPrinter and other subclasses of AsmPrinter

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

10 years agollvm-config: With --build-mode, show ${CMAKE_CFG_INTDIR} on multiconfig builder.
NAKAMURA Takumi [Tue, 3 Dec 2013 14:35:17 +0000 (14:35 +0000)]
llvm-config: With --build-mode, show ${CMAKE_CFG_INTDIR} on multiconfig builder.

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

10 years agoFix lit config for disabled MCJIT tests on ARM
Renato Golin [Tue, 3 Dec 2013 13:48:28 +0000 (13:48 +0000)]
Fix lit config for disabled MCJIT tests on ARM

Separating permanent from temporary targets, added the bug that
will fix the temporary (PR18057).

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

10 years agoRevert r196270, "Generalize debug info / EH emission in AsmPrinter"
NAKAMURA Takumi [Tue, 3 Dec 2013 13:15:54 +0000 (13:15 +0000)]
Revert r196270, "Generalize debug info / EH emission in AsmPrinter"

It broke CodeGen/R600 tests with +Asserts.

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

10 years agoGeneralize debug info / EH emission in AsmPrinter
Timur Iskhodzhanov [Tue, 3 Dec 2013 12:05:18 +0000 (12:05 +0000)]
Generalize debug info / EH emission in AsmPrinter

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

10 years agoAddrspacecasts are no-ops on ARM.
James Molloy [Tue, 3 Dec 2013 11:23:11 +0000 (11:23 +0000)]
Addrspacecasts are no-ops on ARM.

Testcase added.

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

10 years ago[SystemZ] Fix choice of known-zero mask in insertion optimization
Richard Sandiford [Tue, 3 Dec 2013 11:01:54 +0000 (11:01 +0000)]
[SystemZ] Fix choice of known-zero mask in insertion optimization

The backend converts 64-bit ORs into subreg moves if the upper 32 bits
of one operand and the low 32 bits of the other are known to be zero.
It then tries to peel away redundant ANDs from the upper 32 bits.

Since AND masks are canonicalized to exclude known-zero bits,
the test ORs the mask and the known-zero bits together before
checking for redundancy.  The problem was that it was using the
wrong node when checking for known-zero bits, so could drop ANDs
that were still needed.

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

10 years agoEnhance the fix of PR17631
Michael Liao [Tue, 3 Dec 2013 09:17:32 +0000 (09:17 +0000)]
Enhance the fix of PR17631

- The fix to PR17631 fixes part of the cases where 'vzeroupper' should
  not be issued before 'call' insn. There're other cases where helper
  calls will be inserted not limited to epilog. These helper calls do
  not follow the standard calling convention and won't clobber any YMM
  registers. (So far, all call conventions will clobber any or part of
  YMM registers.)
  This patch enhances the previous fix to cover more cases 'vzerosupper' should
  not be inserted by checking if that function call won't clobber any YMM
  registers and skipping it if so.

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

10 years agoDisable Remote MCJIT tests on ARM
Renato Golin [Tue, 3 Dec 2013 08:39:15 +0000 (08:39 +0000)]
Disable Remote MCJIT tests on ARM

The communication protocol is unstable on ARM when compiled
with Clang, which is disrupting the self-hosting buildbots that
are going to be added this week. I'm working on a solution, but
remote MCJIT is not high-priority for ARM at the moment, so it
might take a while.

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