blockfreq: Defer to BranchProbability::scale() (again)
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>
Tue, 29 Apr 2014 16:31:29 +0000 (16:31 +0000)
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>
Tue, 29 Apr 2014 16:31:29 +0000 (16:31 +0000)
commit07f96126af8dc4b6a2081d55ebcca2d113528cf3
tree2913507dfb67a00f3e6dfbb322d2ddf869279843
parent18f4763a081b4b4f9c843bc9cc513f5b5254ca3c
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
include/llvm/Support/BlockFrequency.h
lib/Support/BlockFrequency.cpp
unittests/Support/BlockFrequencyTest.cpp