diff options
author | Nadav Rotem <nrotem@apple.com> | 2012-12-24 05:51:12 +0000 |
---|---|---|
committer | Nadav Rotem <nrotem@apple.com> | 2012-12-24 05:51:12 +0000 |
commit | 99b7a993762a926f042e7cb582e45c577ede596d (patch) | |
tree | d5db7e43d326767b9d75e3656412ac1a58c27f1b /lib/Analysis | |
parent | 85e910fe5cc308956edc0c71165b6714a1654df9 (diff) | |
download | external_llvm-99b7a993762a926f042e7cb582e45c577ede596d.zip external_llvm-99b7a993762a926f042e7cb582e45c577ede596d.tar.gz external_llvm-99b7a993762a926f042e7cb582e45c577ede596d.tar.bz2 |
Update the docs of the cost model.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171016 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis')
-rw-r--r-- | lib/Analysis/CostModel.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/lib/Analysis/CostModel.cpp b/lib/Analysis/CostModel.cpp index 0d0a893..28d6a86 100644 --- a/lib/Analysis/CostModel.cpp +++ b/lib/Analysis/CostModel.cpp @@ -8,9 +8,12 @@ //===----------------------------------------------------------------------===// // // This file defines the cost model analysis. It provides a very basic cost -// estimation for LLVM-IR. The cost result can be thought of as cycles, but it -// is really unit-less. The estimated cost is ment to be used for comparing -// alternatives. +// estimation for LLVM-IR. This analysis uses the services of the codegen +// to approximate the cost of any IR instruction when lowered to machine +// instructions. The cost results are unit-less and the cost number represents +// the throughput of the machine assuming that all loads hit the cache, all +// branches are predicted, etc. The cost numbers can be added in order to +// compare two or more transformation alternatives. // //===----------------------------------------------------------------------===// |