LinkModulesTest.cpp: Use test-specific Ctx instead of getGlobalContext(). The global context might not be free'd. [vg_leak]

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207535 91177308-0d34-0410-b5e6-96231b3b80d8
[CMake] Enable llvm/unittests/LinkerTests. It had not been enabled since r199354.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207537 91177308-0d34-0410-b5e6-96231b3b80d8
DwarfDebug: Split the initialization of abstract and non-abstract subprogram DIEs.

These were called from distinct places and had significant distinct
behavior. No need to make that a dynamic check inside the function
rather than just having two functions (refactoring some common code into
a helper function to be called from the two separate functions).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207539 91177308-0d34-0410-b5e6-96231b3b80d8
Support: Add unit tests for BranchProbability

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207540 91177308-0d34-0410-b5e6-96231b3b80d8
Support: Simplify BranchProbability operators

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207541 91177308-0d34-0410-b5e6-96231b3b80d8
Document recently added sphinx documentation options in
CMake.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207543 91177308-0d34-0410-b5e6-96231b3b80d8
Support: Add BranchProbability::scale() and ::scaleByInverse()

Add API to `BranchProbability` for scaling big integers.  Next job is to
rip the logic out of `BlockMass` and `BlockFrequency`.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207544 91177308-0d34-0410-b5e6-96231b3b80d8
Support: remove unnecessary namespace

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207545 91177308-0d34-0410-b5e6-96231b3b80d8
blockfreq: Remove BlockMass*BlockMass

Since `BlockMass` is an implementation detail and there are no current
users of this, delete `BlockMass::operator*=(BlockMass)`.  I might need
this when I try to strip out `UnsignedFloat`, but I can pull it back in
at that point.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207546 91177308-0d34-0410-b5e6-96231b3b80d8
blockfreq: Defer to BranchProbability::scale()

`BlockMass` can now defer to `BranchProbability::scale()`.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207547 91177308-0d34-0410-b5e6-96231b3b80d8
[mips] Remove redundant 'let Predicates = [HasStdEnc]' statements

Summary:
The MipsPat class already initializes Predicates to [HasStdEnc].

No functional change (confirmed by diffing tablegen-erated files before and
after)

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207548 91177308-0d34-0410-b5e6-96231b3b80d8
blockfreq: Defer to BranchProbability::scale() (again)

Change `BlockFrequency` to defer to `BranchProbability::scale()` and
`BranchProbability::scaleByInverse()`.

This removes `BlockFrequency::scale()` from its API (and drops the
ability to see the remainder), but the only user was the unit tests.  If
some code in the future needs an API that exposes the remainder, we can
add something to `BranchProbability`, but I find that unlikely.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207550 91177308-0d34-0410-b5e6-96231b3b80d8
[mips] Remove more redundant 'let Predicates = [HasStdEnc]' statements

Summary:
The InstSE class already initializes Predicates to [HasStdEnc].

No functional change (confirmed by diffing tablegen-erated files before and
after)

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207551 91177308-0d34-0410-b5e6-96231b3b80d8
Support: BlockFrequencyTest => BranchProbabilityTest

Move a detailed test of `BranchProbability::scale()` from
`BlockFrequencyTest` over to `BranchProbabilityTest`.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207552 91177308-0d34-0410-b5e6-96231b3b80d8
Support: Fix test name

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207553 91177308-0d34-0410-b5e6-96231b3b80d8
Support: More BlockFrequencyTest => BranchProbabilityTest

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207554 91177308-0d34-0410-b5e6-96231b3b80d8
Support: Remove out-of-date comments

The code is now shared... no need for a note.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207555 91177308-0d34-0410-b5e6-96231b3b80d8
[mips] Remove two more redundant 'let Predicates = [HasStdEnc]' statements that were missed

Summary:
The InstSE class already initializes Predicates to [HasStdEnc].

No functional change (confirmed by diffing tablegen-erated files before and
after)

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207558 91177308-0d34-0410-b5e6-96231b3b80d8
BranchProb: Simplify printing code

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