summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGCUDARuntime.cpp
diff options
context:
space:
mode:
authorBob Wilson <bob.wilson@apple.com>2014-03-25 23:26:31 +0000
committerBob Wilson <bob.wilson@apple.com>2014-03-25 23:26:31 +0000
commit0ed74d9634f40d1069df1cebb7e7c45c83a37151 (patch)
tree202a8094b1a5cf1c4c840f473fc0c0224a92bc85 /clang/lib/CodeGen/CGCUDARuntime.cpp
parent3a485fba1f660ef3c127b83fd28cbe67f5777493 (diff)
downloadbcm5719-llvm-0ed74d9634f40d1069df1cebb7e7c45c83a37151.tar.gz
bcm5719-llvm-0ed74d9634f40d1069df1cebb7e7c45c83a37151.zip
[PGO] Add simplified branch weights for Objective-C for-collection loops.
Conceptually one of these loops is just a while-loop, but the actual code-gen is more complicated. We don't instrument all the different control flow edges to get accurate counts for each conditional branch, nor do I think it makes sense to do so. Instead, make the simplifying assumption that the loop behaves like a while-loop. Use the same branch weights for the first check for an empty collection as would be used for the back-edge of a while loop, and use that same weighting for the innermost loop, ignoring the possibility that there may be some extra code to go fetch more elements. llvm-svn: 204767
Diffstat (limited to 'clang/lib/CodeGen/CGCUDARuntime.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud