oota-llvm.git
9 years ago[CodeGen] Replace the reused stores' chain for extractelt expansion.
Ahmed Bougacha [Mon, 9 Mar 2015 22:51:05 +0000 (22:51 +0000)]
[CodeGen] Replace the reused stores' chain for extractelt expansion.

This fixes a subtle issue that was introduced in r205153.

When reusing a store for the extractelement expansion (to load directly
from it, inserting of going through the stack), later stores to the
same location might have overwritten the data we were expecting to
extract from.

To fix that, we need to explicitly replace the chain going out of the
reused store, so that later stores also have an explicit dependency on
the generated element-extracting loads, and can't clobber them.

rdar://20066785
Differential Revision: http://reviews.llvm.org/D8180

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

9 years ago[X86] Add nounwind to vector-idiv.ll testcases. NFC.
Ahmed Bougacha [Mon, 9 Mar 2015 22:46:02 +0000 (22:46 +0000)]
[X86] Add nounwind to vector-idiv.ll testcases.  NFC.

In preparation for a patch where cfi directives get in the way.

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

9 years agoReland r229944: EH: Prune unreachable resume instructions during Dwarf EH preparation
Reid Kleckner [Mon, 9 Mar 2015 22:45:16 +0000 (22:45 +0000)]
Reland r229944: EH: Prune unreachable resume instructions during Dwarf EH preparation

Fix the double-deletion of AnalysisResolver when delegating through to
Dwarf EH preparation by creating one from scratch. Hopefully the new
pass manager simplifies this.

This reverts commit r229952.

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

9 years agoUse a MapVector instead of an extra sort.
Rafael Espindola [Mon, 9 Mar 2015 22:08:37 +0000 (22:08 +0000)]
Use a MapVector instead of an extra sort.

This also has the advantage of not depending on the brittle getLabelBeginName.

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

9 years ago[Hexagon] Use single tailcall pseudoinst and fix checking for label jumping versus...
Colin LeMahieu [Mon, 9 Mar 2015 22:05:21 +0000 (22:05 +0000)]
[Hexagon] Use single tailcall pseudoinst and fix checking for label jumping versus tail calling.

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

9 years ago[Hexagon] Reapply r231699. Remove assumption that second operand is an immediate...
Colin LeMahieu [Mon, 9 Mar 2015 21:48:13 +0000 (21:48 +0000)]
[Hexagon] Reapply r231699.  Remove assumption that second operand is an immediate when checking if A2_tfrsi is combinable.

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

9 years ago[SCEV] Unify getUnsignedRange and getSignedRange
Sanjoy Das [Mon, 9 Mar 2015 21:43:43 +0000 (21:43 +0000)]
[SCEV] Unify getUnsignedRange and getSignedRange

Summary:
This removes some duplicated code, and also helps optimization: e.g. in
the test case added, `%idx ULT 128` in `@x` is not currently optimized
to `true` by `-indvars` but will be, after this change.

The only functional change in ths commit is that for add recurrences,
ScalarEvolution::getRange will be more aggressive -- computing the
unsigned (resp. signed) range for a SCEVAddRecExpr will now look at the
NSW (resp. NUW) bits and check for signed (resp. unsigned) overflow.
This can be a strict improvement in some cases (such as the attached
test case), and should be no worse in other cases.

Reviewers: atrick, nlewycky

Subscribers: llvm-commits

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

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

9 years ago[SCEV] Add a `scalar-evolution-print-constant-ranges' option
Sanjoy Das [Mon, 9 Mar 2015 21:43:39 +0000 (21:43 +0000)]
[SCEV] Add a `scalar-evolution-print-constant-ranges' option

Summary:
Unused in this commit, but will be used in a subsequent change (D8142)
by a FileCheck test.

Reviewers: atrick

Subscribers: llvm-commits

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

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

9 years ago[Hexagon] Reverting r231699
Colin LeMahieu [Mon, 9 Mar 2015 21:19:02 +0000 (21:19 +0000)]
[Hexagon] Reverting r231699

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

9 years agoDwarfAccelTable: fix obvious typo.
Frederic Riss [Mon, 9 Mar 2015 21:09:50 +0000 (21:09 +0000)]
DwarfAccelTable: fix obvious typo.

I have a test for that issue, but I didn't include it in the commit as it's
a 200KB file for a pretty minor issue. (The reason the file is so big is
that it needs > 1024 variables/functions to trigger and that with debug
information.

The issue/fix on the other side is totally trivial. If poeple want the test
commited, I can do that. It just didn't seem worth it to me.

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

9 years ago[Hexagon] Updating constant set to simpler versions.
Colin LeMahieu [Mon, 9 Mar 2015 20:33:12 +0000 (20:33 +0000)]
[Hexagon] Updating constant set to simpler versions.

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

9 years agoTableGen: Use 'enum : uint64_t' for feature flags to fix -Wmicrosoft
Reid Kleckner [Mon, 9 Mar 2015 20:23:14 +0000 (20:23 +0000)]
TableGen: Use 'enum : uint64_t' for feature flags to fix -Wmicrosoft

clang-cl would warn that this value is not representable in 'int':
  enum { FeatureX = 1ULL << 31 };
All MS enums are 'ints' unless otherwise specified, so we have to use an
explicit type.  The AMDGPU target just hit 32 features, triggering this
warning.

Now that we have C++11 strong enum types, we can also eliminate the
'const uint64_t' codepath from tablegen and just use 'enum : uint64_t'.

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

9 years agoRemove the remaining uses of abs64 and nuke it.
Benjamin Kramer [Mon, 9 Mar 2015 20:20:16 +0000 (20:20 +0000)]
Remove the remaining uses of abs64 and nuke it.

std::abs works just fine and we're already using it in many places. NFC intended.

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

9 years ago[Hexagon] Removing old halfword codegen instructions and updating const32/64 splitting.
Colin LeMahieu [Mon, 9 Mar 2015 20:11:02 +0000 (20:11 +0000)]
[Hexagon] Removing old halfword codegen instructions and updating const32/64 splitting.

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

9 years agoDon't prime the section map.
Rafael Espindola [Mon, 9 Mar 2015 20:09:58 +0000 (20:09 +0000)]
Don't prime the section map.

This was just creating unused labels for .text when the module had no
functions.

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

9 years ago[Hexagon] Eliminating immediate condition set.
Colin LeMahieu [Mon, 9 Mar 2015 19:57:18 +0000 (19:57 +0000)]
[Hexagon] Eliminating immediate condition set.

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

9 years ago[Hexagon] Removing TFR_condset_ir/TFR_condset_ri modeling.
Colin LeMahieu [Mon, 9 Mar 2015 19:31:25 +0000 (19:31 +0000)]
[Hexagon] Removing TFR_condset_ir/TFR_condset_ri modeling.

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

9 years ago[Hexagon] Changing AddrFI back to ADDRri to address test issue.
Colin LeMahieu [Mon, 9 Mar 2015 18:57:33 +0000 (18:57 +0000)]
[Hexagon] Changing AddrFI back to ADDRri to address test issue.

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

9 years agoInstrProf: Use the proftext format for these coverage tests
Justin Bogner [Mon, 9 Mar 2015 18:54:58 +0000 (18:54 +0000)]
InstrProf: Use the proftext format for these coverage tests

This format's easier to understand and update by hand.

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

9 years agoInstrProf: Allow hexadecimal function hashes in proftext format
Justin Bogner [Mon, 9 Mar 2015 18:54:49 +0000 (18:54 +0000)]
InstrProf: Allow hexadecimal function hashes in proftext format

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

9 years agoR600/SI: Move gds operand to the end of operand list
Tom Stellard [Mon, 9 Mar 2015 18:49:54 +0000 (18:49 +0000)]
R600/SI: Move gds operand to the end of operand list

Also print it in the assembly string.

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

9 years agoR600/SI: Refactor DS instruction defs
Tom Stellard [Mon, 9 Mar 2015 18:49:45 +0000 (18:49 +0000)]
R600/SI: Refactor DS instruction defs

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

9 years agoDelete dead code. NFC.
Rafael Espindola [Mon, 9 Mar 2015 18:48:29 +0000 (18:48 +0000)]
Delete dead code. NFC.

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

9 years agoAdd support for Nuxi CloudABI.
Ed Schouten [Mon, 9 Mar 2015 18:40:45 +0000 (18:40 +0000)]
Add support for Nuxi CloudABI.

CloudABI is a POSIX-like runtime environment built around the concept of
capability-based security. More details:

https://github.com/NuxiNL/cloudlibc

CloudABI uses its own ELFOSABI number. This number has been allocated by
the maintainers of ELF a couple of days ago.

Reviewed by: echristo

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

9 years agoDrop the hacks used for partial C99 math libraries.
Benjamin Kramer [Mon, 9 Mar 2015 18:35:18 +0000 (18:35 +0000)]
Drop the hacks used for partial C99 math libraries.

All supported platforms have half-way decent C99 support.

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

9 years ago[Hexagon] Adding PackHL nodes and some missing modeling instructions and patterns
Colin LeMahieu [Mon, 9 Mar 2015 18:34:05 +0000 (18:34 +0000)]
[Hexagon] Adding PackHL nodes and some missing modeling instructions and patterns

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

9 years agoPrint jump tables before exception tables.
Rafael Espindola [Mon, 9 Mar 2015 18:29:12 +0000 (18:29 +0000)]
Print jump tables before exception tables.

In the case where just tables are part of the function section, this produces
more readable assembly by avoiding switching to the eh section and back
to .text.

This would also break with non unique section names, as trying to switch to
a unique section actually creates a new one.

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

9 years agoDon't repeat name in comment. NFC.
Rafael Espindola [Mon, 9 Mar 2015 18:11:42 +0000 (18:11 +0000)]
Don't repeat name in comment. NFC.

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

9 years agoRemove dummy method implementations.
Rafael Espindola [Mon, 9 Mar 2015 17:58:49 +0000 (17:58 +0000)]
Remove dummy method implementations.

These are pure virtual in the base class, so the compiler checks that they
are implemented.

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

9 years agoAdd logical ops to Mips fast-isel
Reed Kotler [Mon, 9 Mar 2015 16:28:10 +0000 (16:28 +0000)]
Add logical ops to Mips fast-isel

Summary:
Code is mostly copied from AArch64 port and modified where needed for Mips.

This handles the "non" legal cases of logical ops. Legal cases are handled by tablegen patterns.

Test Plan:
Make check test logopm.ll

All of test-suite passes at O0/O2 and mips32 r1/r2 with this new change.

Reviewers: dsanders

Reviewed By: dsanders

Subscribers: echristo, llvm-commits, aemerson, rfuhler

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

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

9 years agoMake helper functions static.
Benjamin Kramer [Mon, 9 Mar 2015 16:23:46 +0000 (16:23 +0000)]
Make helper functions static.

Found by -Wmissing-prototypes. NFC.

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

9 years agoR600/SI: Fix DS definitions and add missing instructions
Tom Stellard [Mon, 9 Mar 2015 16:03:45 +0000 (16:03 +0000)]
R600/SI: Fix DS definitions and add missing instructions

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

9 years agoR600/SI: Fix opcode for ds_read2_b64 and ds_read2st64_b64
Tom Stellard [Mon, 9 Mar 2015 16:03:39 +0000 (16:03 +0000)]
R600/SI: Fix opcode for ds_read2_b64 and ds_read2st64_b64

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

9 years agoMove unreferenced passes into the cpp file
Benjamin Kramer [Mon, 9 Mar 2015 15:50:58 +0000 (15:50 +0000)]
Move unreferenced passes into the cpp file

NFC.

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

9 years agoSymbolRewriter: Hide implementation details
Benjamin Kramer [Mon, 9 Mar 2015 15:50:47 +0000 (15:50 +0000)]
SymbolRewriter: Hide implementation details

NFC.

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

9 years agoR600/SI: Limit SGPRs to 80 on Tonga and Iceland
Marek Olsak [Mon, 9 Mar 2015 15:48:09 +0000 (15:48 +0000)]
R600/SI: Limit SGPRs to 80 on Tonga and Iceland

This is a candidate for stable.

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

9 years agoR600/SI: Fix getNumSGPRsAllowed for VI
Marek Olsak [Mon, 9 Mar 2015 15:48:00 +0000 (15:48 +0000)]
R600/SI: Fix getNumSGPRsAllowed for VI

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

9 years agoFix line ending in test CodeGen/X86/pr22774.ll. NFC.
Andrea Di Biagio [Mon, 9 Mar 2015 15:02:01 +0000 (15:02 +0000)]
Fix line ending in test CodeGen/X86/pr22774.ll. NFC.

Also, replaced line with 'target triple' with flag -mtriple on the RUN line.
Removed the data layout string as it is not needed.

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

9 years agoRevert r231630 - Run LICM pass after loop unrolling pass.
Kevin Qin [Mon, 9 Mar 2015 07:26:37 +0000 (07:26 +0000)]
Revert r231630 - Run LICM pass after loop unrolling pass.

As it broke llvm bootstrap.

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

9 years agoFix a bug in the LLParser where we failed to diagnose landingpads with non-constant...
Owen Anderson [Mon, 9 Mar 2015 07:13:42 +0000 (07:13 +0000)]
Fix a bug in the LLParser where we failed to diagnose landingpads with non-constant clause operands.

Fixing this also exposed a related issue where the landingpad under construction was not
cleaned up when an error was raised, which would cause bad reference errors before the
error could actually be printed.

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

9 years ago[AArch64] Enable partial & runtime unrolling on cortex-a57
Kevin Qin [Mon, 9 Mar 2015 06:14:28 +0000 (06:14 +0000)]
[AArch64] Enable partial & runtime unrolling on cortex-a57

For inner one of nested loops, it is more likely to be a hot loop,
and the runtime check can be promoted out from patch 0001, so the
overhead is less, we can try a doubled threshold to unroll more loops.

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

9 years agoIntroduce runtime unrolling disable matadata and use it to mark the scalar loop from...
Kevin Qin [Mon, 9 Mar 2015 06:14:18 +0000 (06:14 +0000)]
Introduce runtime unrolling disable matadata and use it to mark the scalar loop from vectorization.

Runtime unrolling is an expensive optimization which can bring benefit
only if the loop is hot and iteration number is relatively large enough.
For some loops, we know they are not worth to be runtime unrolled.
The scalar loop from vectorization is one of the cases.

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

9 years agoRun LICM pass after loop unrolling pass.
Kevin Qin [Mon, 9 Mar 2015 06:14:07 +0000 (06:14 +0000)]
Run LICM pass after loop unrolling pass.

Runtime unrollng will introduce a runtime check in loop prologue.
If the unrolled loop is a inner loop, then the proglogue will be inside
the outer loop. LICM pass can help to promote the runtime check out if
the checked value is loop invariant.

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

9 years agoInstCombine: fix fold "fcmp x, undef" to account for NaN
Mehdi Amini [Mon, 9 Mar 2015 03:20:25 +0000 (03:20 +0000)]
InstCombine: fix fold "fcmp x, undef" to account for NaN

Summary:
See the two test cases.

; Can fold fcmp with undef on one side by choosing NaN for the undef

; Can fold fcmp with undef on both side
;   fcmp u_pred undef, undef -> true
;   fcmp o_pred undef, undef -> false
; because whatever you choose for the first undef
; you can choose NaN for the other undef

Reviewers: hfinkel, chandlerc, majnemer

Reviewed By: majnemer

Subscribers: majnemer, llvm-commits

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

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

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

9 years agoDCE: isArrayMalloc() is not used neither in LLVM nor Clang
Mehdi Amini [Mon, 9 Mar 2015 02:57:32 +0000 (02:57 +0000)]
DCE: isArrayMalloc() is not used neither in LLVM nor Clang

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

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

9 years agoSimplify expressions involving boolean constants with clang-tidy
David Blaikie [Mon, 9 Mar 2015 01:57:13 +0000 (01:57 +0000)]
Simplify expressions involving boolean constants with clang-tidy

Patch by Richard (legalize at xmission dot com).

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

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

9 years agoTeach DataLayout to infer a plausible alignment for things even when nothing is speci...
Owen Anderson [Sun, 8 Mar 2015 21:53:59 +0000 (21:53 +0000)]
Teach DataLayout to infer a plausible alignment for things even when nothing is specified by the user.

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

9 years ago[X86][AVX] Fix wrong lowering of VPERM2X128 nodes
Andrea Di Biagio [Sun, 8 Mar 2015 16:28:47 +0000 (16:28 +0000)]
[X86][AVX] Fix wrong lowering of VPERM2X128 nodes

There were cases where the backend computed a wrong permute mask for a VPERM2X128 node.

Example:
\code
define <8 x float> @foo(<8 x float> %a, <8 x float> %b) {
  %shuffle = shufflevector <8 x float> %a, <8 x float> %b, <8 x i32> <i32 undef, i32 undef, i32 6, i32 7, i32 undef, i32 undef, i32 6, i32 7>
  ret <8 x float> %shuffle
}
\code end

Before this patch, llc (with -mattr=+avx) emitted the following vperm2f128:
  vperm2f128 $0, %ymm0, %ymm0, %ymm0  # ymm0 = ymm0[0,1,0,1]

With this patch, llc emits a vperm2f128 with a correct permute mask:
  vperm2f128 $17, %ymm0, %ymm0, %ymm0  # ymm0 = ymm0[2,3,2,3]

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

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

9 years agoMake static variables const if possible. Makes them go into a read-only section.
Benjamin Kramer [Sun, 8 Mar 2015 16:07:39 +0000 (16:07 +0000)]
Make static variables const if possible. Makes them go into a read-only section.

Or fold them into a initializer list which has the same effect. NFC.

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

9 years ago[DAGCombiner] Add a shuffle mask commutation helper function. NFCI.
Simon Pilgrim [Sat, 7 Mar 2015 22:33:11 +0000 (22:33 +0000)]
[DAGCombiner] Add a shuffle mask commutation helper function. NFCI.

We have an increasing number of cases where we are creating commuted shuffle masks - all implementing nearly the same code.

This patch adds a static helper function - ShuffleVectorSDNode::commuteMask() and replaces a number of cases to use it.

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

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

9 years agoFix the autoconf build
David Majnemer [Sat, 7 Mar 2015 21:47:46 +0000 (21:47 +0000)]
Fix the autoconf build

lib/ExecutionEngine/Targets has no Makefile, causing the autoconf build
to fail.  Solve this by bringing the COFF implementation of RuntimeDyld
in line like the Mach-O and ELF implementations.

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

9 years agoMake the assertion macros in Verifier and Linter truly variadic.
Benjamin Kramer [Sat, 7 Mar 2015 21:15:40 +0000 (21:15 +0000)]
Make the assertion macros in Verifier and Linter truly variadic.

NFC.

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

9 years agoFix unused variable/function warnings
David Majnemer [Sat, 7 Mar 2015 20:56:50 +0000 (20:56 +0000)]
Fix unused variable/function warnings

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

9 years agoExecutionEngine: Preliminary support for dynamically loadable coff objects
David Majnemer [Sat, 7 Mar 2015 20:21:27 +0000 (20:21 +0000)]
ExecutionEngine: Preliminary support for dynamically loadable coff objects

Provide basic support for dynamically loadable coff objects. Only handles a subset of x64 currently.

Patch by Andy Ayers!

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

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

9 years agoMake constant arrays that are passed to functions as const.
Benjamin Kramer [Sat, 7 Mar 2015 17:41:00 +0000 (17:41 +0000)]
Make constant arrays that are passed to functions as const.

In theory this allows the compiler to skip materializing the array on
the stack. In practice clang often fails to do that, but that's a
different story. NFC.

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

9 years agoUse SDValue bool check to tidyup some possible combines. NFC.
Simon Pilgrim [Sat, 7 Mar 2015 16:34:55 +0000 (16:34 +0000)]
Use SDValue bool check to tidyup some possible combines. NFC.

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

9 years agoAdding parenthesis around logical expressions to silence a -Wparentheses warning...
Aaron Ballman [Sat, 7 Mar 2015 15:16:27 +0000 (15:16 +0000)]
Adding parenthesis around logical expressions to silence a -Wparentheses warning; NFC.

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

9 years agoRemoving spurious semi-colons; NFC
Aaron Ballman [Sat, 7 Mar 2015 15:10:32 +0000 (15:10 +0000)]
Removing spurious semi-colons; NFC

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

9 years agoX86: Roll repetitive code into a loop. NFC.
Benjamin Kramer [Sat, 7 Mar 2015 15:06:16 +0000 (15:06 +0000)]
X86: Roll repetitive code into a loop. NFC.

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

9 years ago[DAGCombiner] Fix wrong folding of AND dag nodes.
Andrea Di Biagio [Sat, 7 Mar 2015 12:24:55 +0000 (12:24 +0000)]
[DAGCombiner] Fix wrong folding of AND dag nodes.

This patch fixes the logic in the DAGCombiner that folds an AND node according
to rule: (and (X (load V)), C) -> (X (load V))

An AND between a vector load 'X' and a constant build_vector 'C' can be folded
into the load itself only if we can prove that the AND operation is redundant.
The algorithm implemented by 'visitAND' firstly computes the splat value 'S'
from C, and then checks if S has the lower 'B' bits set (where B is the size in
bits of the vector element type). The algorithm takes into account also the
'undef' bits in the splat mask.

Unfortunately, the algorithm only worked under the assumption that the size of S
is a multiple of the vector element type. With this patch, we conservatively
avoid folding the AND if the splat bits are not compatible with the vector
element type.

Added X86 test and-load-fold.ll

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

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

9 years ago[Modules] Include the header needed for make_unique, otherwise we can't
Chandler Carruth [Sat, 7 Mar 2015 10:55:47 +0000 (10:55 +0000)]
[Modules] Include the header needed for make_unique, otherwise we can't
build this header in a module.

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

9 years agoTeach the LLVM CMake build how to explicitly use libc++abi when using
Chandler Carruth [Sat, 7 Mar 2015 10:30:34 +0000 (10:30 +0000)]
Teach the LLVM CMake build how to explicitly use libc++abi when using
libc++. This lets me almost self-host on Linux with libc++ and libc++abi
very simply.

Currently, MCJIT and OrcJIT are failing due to uncaught exceptions, and
the Go binding tests are failing to build due to not linking in the
correct C++ standard library.

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

9 years ago[PM] Fixup for r231556 where I missed a dependency on intrinsics
Chandler Carruth [Sat, 7 Mar 2015 09:08:20 +0000 (09:08 +0000)]
[PM] Fixup for r231556 where I missed a dependency on intrinsics
generation.

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

9 years ago[PM] Create a separate library for high-level pass management code.
Chandler Carruth [Sat, 7 Mar 2015 09:02:36 +0000 (09:02 +0000)]
[PM] Create a separate library for high-level pass management code.

This will provide the analogous replacements for the PassManagerBuilder
and other code long term. This code is extracted from the opt tool
currently, and I plan to extend it as I build up support for using the
new pass manager in Clang and other places.

Mailing this out for review in part to let folks comment on the terrible names
here. A brief word about why I chose the names I did.

The library is called "Passes" to try and make it clear that it is a high-level
utility and where *all* of the passes come together and are registered in
a common library. I didn't want it to be *limited* to a registry though, the
registry is just one component.

The class is a "PassBuilder" but this name I'm less happy with. It doesn't
build passes in any traditional sense and isn't a Builder-style API at all. The
class is a PassRegisterer or PassAdder, but neither of those really make a lot
of sense. This class is responsible for constructing passes for registry in an
analysis manager or for population of a pass pipeline. If anyone has a better
name, I would love to hear it. The other candidate I looked at was
PassRegistrar, but that doesn't really fit either. There is no register of all
the passes in use, and so I think continuing the "registry" analog outside of
the registry of pass *names* and *types* is a mistake. The objects themselves
are just objects with the new pass manager.

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

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

9 years ago[DAGCombiner] SCALAR_TO_VECTOR(EXTRACT_VECTOR_ELT(V,C)) -> VECTOR_SHUFFLE
Simon Pilgrim [Sat, 7 Mar 2015 05:52:42 +0000 (05:52 +0000)]
[DAGCombiner] SCALAR_TO_VECTOR(EXTRACT_VECTOR_ELT(V,C)) -> VECTOR_SHUFFLE

This patch attempts to convert a SCALAR_TO_VECTOR using an operand from an EXTRACT_VECTOR_ELT into a VECTOR_SHUFFLE.

This prevents many cases of spilling scalar data between the gpr + simd registers.

At present the optimization only accepts cases where there is no TRUNC of the scalar type (i.e. all types must match).

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

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

9 years agoTypo.
Eric Christopher [Sat, 7 Mar 2015 01:39:09 +0000 (01:39 +0000)]
Typo.

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

9 years agoRemove use of misched-bench from this test and replace it with
Eric Christopher [Sat, 7 Mar 2015 01:39:06 +0000 (01:39 +0000)]
Remove use of misched-bench from this test and replace it with
non-temporary enabling options. This is part of removing misched-bench
as an option.

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

9 years ago[dsymutil] Apply relocations to DIE data before cloning.
Frederic Riss [Sat, 7 Mar 2015 01:25:09 +0000 (01:25 +0000)]
[dsymutil] Apply relocations to DIE data before cloning.

Doing this gets function's low_pc and global variable's locations right
in the output debug info. It also could get right other attributes
that need to be relocated (in linker terms), but I don't know of any
other than the address attributes.

This doesn't fixup low_pc attributes in compile_unit, lexical_block
or inlined subroutine, nor does it get right high_pc attributes
for function. This will come in a subsequent commit.

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

9 years agoRecommit r231324 with a fix to the ARM execution domain code
Eric Christopher [Sat, 7 Mar 2015 00:12:22 +0000 (00:12 +0000)]
Recommit r231324 with a fix to the ARM execution domain code
to disable lane switching if we don't actually have the instruction
set we want to switch to. Models the earlier check above the
conditional for the pass.

The testcase is one that triggered with the assert that's added
as part of the fix, use it to avoid adding a new testcase as it
highlights the same problem.

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

9 years ago[modules] Mark Analysis/TargetLibraryInfo.def as a textual header.
Richard Smith [Fri, 6 Mar 2015 23:39:54 +0000 (23:39 +0000)]
[modules] Mark Analysis/TargetLibraryInfo.def as a textual header.

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

9 years ago[dsymutil] Support cloning DIE reference attributes.
Frederic Riss [Fri, 6 Mar 2015 23:22:53 +0000 (23:22 +0000)]
[dsymutil] Support cloning DIE reference attributes.

Reference attributes are mainly handled by just creating DIEEntry
attributes for them. There is a special case for DW_FORM_ref_addr
attributes though, because the DIEEntry code needs a DwarfDebug
code to emit them (and we don't have one as we do no CodeGen).
In that case, just use DIEInteger attributes with the right form.

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

9 years ago[dsymutil] Set linked unit start offset early. NFC.
Frederic Riss [Fri, 6 Mar 2015 23:22:50 +0000 (23:22 +0000)]
[dsymutil] Set linked unit start offset early. NFC.

The start offset of a linked unit is known before starting to clone
its DIEs. Handling DW_FORM_ref_addr attributes requires that this
offset is set while cloning the unit. Split CompileUnit::computeOffsets()
into setStartOffset() and computeNextUnitOffset() and call them
repsectively before cloning the DIEs and right after.

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

9 years agoAdd DIEInteger::setValue() method.
Frederic Riss [Fri, 6 Mar 2015 23:22:46 +0000 (23:22 +0000)]
Add DIEInteger::setValue() method.

dsymutil needs to 'patch' attribute values after creating them. Just
add this trivial capability.

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

9 years agoDo not restrict interleaved unrolling to small loops, depending on the target.
Olivier Sallenave [Fri, 6 Mar 2015 23:12:04 +0000 (23:12 +0000)]
Do not restrict interleaved unrolling to small loops, depending on the target.

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

9 years ago[AArch64][LoadStoreOptimizer] Generate LDP + SXTW instead of LD[U]R + LD[U]RSW.
Quentin Colombet [Fri, 6 Mar 2015 22:42:10 +0000 (22:42 +0000)]
[AArch64][LoadStoreOptimizer] Generate LDP + SXTW instead of LD[U]R + LD[U]RSW.
Teach the load store optimizer how to sign extend a result of a load pair when
it helps creating more pairs.
The rational is that loads are more expensive than sign extensions, so if we
gather some in one instruction this is better!

<rdar://problem/20072968>

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

9 years agofixed to test features, not CPUs
Sanjay Patel [Fri, 6 Mar 2015 21:50:42 +0000 (21:50 +0000)]
fixed to test features, not CPUs

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

9 years agofixed to test features, not CPUs
Sanjay Patel [Fri, 6 Mar 2015 21:50:27 +0000 (21:50 +0000)]
fixed to test features, not CPUs

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

9 years agoloosen checking for buildbots
Sanjay Patel [Fri, 6 Mar 2015 21:30:18 +0000 (21:30 +0000)]
loosen checking for buildbots

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

9 years agofixed to test only the feature, not the feature and a CPU
Sanjay Patel [Fri, 6 Mar 2015 21:24:56 +0000 (21:24 +0000)]
fixed to test only the feature, not the feature and a CPU

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

9 years agofixed to test only the feature, not the feature and a CPU
Sanjay Patel [Fri, 6 Mar 2015 21:19:32 +0000 (21:19 +0000)]
fixed to test only the feature, not the feature and a CPU

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

9 years agofixed test to use FileCheck
Sanjay Patel [Fri, 6 Mar 2015 21:16:15 +0000 (21:16 +0000)]
fixed test to use FileCheck

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

9 years agofixed to use CHECK-LABELs
Sanjay Patel [Fri, 6 Mar 2015 21:05:02 +0000 (21:05 +0000)]
fixed to use CHECK-LABELs

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

9 years agofixed to test only the feature, not the feature and a CPU
Sanjay Patel [Fri, 6 Mar 2015 20:58:15 +0000 (20:58 +0000)]
fixed to test only the feature, not the feature and a CPU

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

9 years agofixed to test only the feature, not the feature and a CPU
Sanjay Patel [Fri, 6 Mar 2015 20:57:40 +0000 (20:57 +0000)]
fixed to test only the feature, not the feature and a CPU

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

9 years agofixed to test feature, not CPU
Sanjay Patel [Fri, 6 Mar 2015 20:51:25 +0000 (20:51 +0000)]
fixed to test feature, not CPU

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

9 years agofixed to test features, not CPUs
Sanjay Patel [Fri, 6 Mar 2015 20:46:16 +0000 (20:46 +0000)]
fixed to test features, not CPUs

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

9 years agofixed test to use SSE2 attribute
Sanjay Patel [Fri, 6 Mar 2015 20:38:55 +0000 (20:38 +0000)]
fixed test to use SSE2 attribute

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

9 years agofixed to test only the feature, not the feature and a CPU
Sanjay Patel [Fri, 6 Mar 2015 20:34:20 +0000 (20:34 +0000)]
fixed to test only the feature, not the feature and a CPU

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

9 years agoDAGCombiner: Canonicalize select(and/or,x,y) depending on target.
Matthias Braun [Fri, 6 Mar 2015 19:49:10 +0000 (19:49 +0000)]
DAGCombiner: Canonicalize select(and/or,x,y) depending on target.

This is based on the following equivalences:
select(C0 & C1, X, Y) <=> select(C0, select(C1, X, Y), Y)
select(C0 | C1, X, Y) <=> select(C0, X, select(C1, X, Y))

Many target cannot perform and/or on the CPU flags and therefore the
right side should be choosen to avoid materializign the i1 flags in an
integer register. If the target can perform this operation efficiently
we normalize to the left form.

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

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

9 years agoDAGCombiner: Factor out some and/or combines.
Matthias Braun [Fri, 6 Mar 2015 19:49:06 +0000 (19:49 +0000)]
DAGCombiner: Factor out some and/or combines.

This is in preparation for changing visitSELECT to normalize towards
select(Cond0, select(Cond1, X, Y), Y);
select(Cond0, X, select(Cond1, X, Y)) which perfom an implicit and/or of
the conditions.

The factored function contains all DAGCombine rules which reduce two values
combined by an And/Or operation to a single value. This does not include rules
involving constants as visitSELECT already handles that case.

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

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

9 years ago[AsmPrinter][TLOF] Remove AArch64 test to appease buildbots
Bruno Cardoso Lopes [Fri, 6 Mar 2015 19:42:18 +0000 (19:42 +0000)]
[AsmPrinter][TLOF] Remove AArch64 test to appease buildbots

Follow up from r231497. Using XFAIL would still trigger fail on some
buildbots. Will re-introduce it as soon as I have a fix.

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

9 years agoLoopInterchange: Remove empty method.
Benjamin Kramer [Fri, 6 Mar 2015 19:37:26 +0000 (19:37 +0000)]
LoopInterchange: Remove empty method.

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

9 years agoLoopInterchange: Rephrase instruction moving using ilist's splice and factor it into...
Benjamin Kramer [Fri, 6 Mar 2015 18:59:14 +0000 (18:59 +0000)]
LoopInterchange: Rephrase instruction moving using ilist's splice and factor it into a function

+ Random cleanups. No functional change.

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

9 years agoExecutionDepsFix: Indizes -> Indices.
Matthias Braun [Fri, 6 Mar 2015 18:56:20 +0000 (18:56 +0000)]
ExecutionDepsFix: Indizes -> Indices.

Translate german to english.

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

9 years ago[AsmPrinter][TLOF] XFAIL AArch64 test to appease buildbots
Bruno Cardoso Lopes [Fri, 6 Mar 2015 18:38:42 +0000 (18:38 +0000)]
[AsmPrinter][TLOF] XFAIL AArch64 test to appease buildbots

The checking for extgotequiv and localgotequiv rely on the emission
order, which is not guaranteed because we use DenseMap to hold the GOT
equivalents. XFAIL this now until I get time to use MapVector and test
out the solution. In the meantime, appease buildbots.

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

9 years agoFix typo.
Eric Christopher [Fri, 6 Mar 2015 18:20:23 +0000 (18:20 +0000)]
Fix typo.

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

9 years ago[dsymutil] Add debug_str construction support.
Frederic Riss [Fri, 6 Mar 2015 17:56:30 +0000 (17:56 +0000)]
[dsymutil] Add debug_str construction support.

With this comes the ability to correctly clone string attributes in DIEs.

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

9 years agoR600/SI: Remove unused register class
Tom Stellard [Fri, 6 Mar 2015 17:00:16 +0000 (17:00 +0000)]
R600/SI: Remove unused register class

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

9 years agoFold init() helpers into constructors. NFC.
Benjamin Kramer [Fri, 6 Mar 2015 16:21:15 +0000 (16:21 +0000)]
Fold init() helpers into constructors. NFC.

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

9 years agoAvoid calls to dumpPassInfo and RegionBase<Tr>::getNameStr() in RGPassManager if
Chad Rosier [Fri, 6 Mar 2015 16:15:04 +0000 (16:15 +0000)]
Avoid calls to dumpPassInfo and RegionBase<Tr>::getNameStr() in RGPassManager if
-debug-pass is not specified, as the string is only used when dumping pass
information.  There is a big cost of determining the name in
ReginBase<Tr>:getNameStr() if the region's entry or exit block doesn't have a
name.  This is the case for the Release build, as names are not preserved by the
front-end.

RegionPass is mainly used by Polly, resulting in long compile time for one file
of a customer application with the Release build (1m24s) vs Release+Asserts
build (10s) when Polly is used.  With this change, the compile time with the
Release build went down to 8s.

Patch by Sanjin Sijaric <ssijaric@codeaurora.org>!
Phabricator: http://reviews.llvm.org/D8076

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