OSDN Git Service

[HotColdSplit] Mark inherently cold functions as such
authorVedant Kumar <vsk@apple.com>
Sat, 19 Jan 2019 02:38:47 +0000 (02:38 +0000)
committerVedant Kumar <vsk@apple.com>
Sat, 19 Jan 2019 02:38:47 +0000 (02:38 +0000)
commit3dfba4afc6d9dfa896e7de4640c88bc9c9180d7c
tree5e690d3750b1eaa232d6af2e09e28c070e747e94
parent1054bdf35560e528d67369213bec852c0c29373d
[HotColdSplit] Mark inherently cold functions as such

If an inherently cold function is found, mark it as cold. For now this
means applying the `cold` and `minsize` attributes.

As a drive-by, revisit and clean up the criteria for considering a
function for splitting. Add tests.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@351623 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/IPO/HotColdSplitting.cpp
test/Transforms/HotColdSplit/X86/do-not-split.ll
test/Transforms/HotColdSplit/addr-taken.ll [new file with mode: 0644]
test/Transforms/HotColdSplit/minsize.ll