In order for the hot/cold splitting pass to graduate out of experimental
status,[PM/CC1] Add -f[no-]split-cold-code CC1 options to toggle splitting
This patch adds -f[no-]split-cold-code CC1 options to clang. users need some way to safely enable it.
the splitting pass to be toggled on/off. The current method of passing `-mllvm -hot-cold-split=true` to clang is
not safe, because directly setting a cl::opt cannot interact well with`-mllvm -hot-cold-split=true` to clang isn't ideal as it may not compose
other CC1 options (e.g. `-O0`correctly (say, or `-disable-llvm-passes`with `-O0` or `-Oz`).
This patch adds -f[no-]To implement the -fsplit-cold-code CC1 options to clang so that the, an attribute is applied to
splitting pass can be toggled/combined with other options without issue.functions to indicate that they may be considered for splitting. This
This makes it possible to deploy the new pass on a large scale.
I've held off on adding a driver option because the ultimate goal is toremoves some complexity from the old/new PM pipeline builders, and
remove these options, and to simply have the pasbehaves as expected when LTO is enabled by defaultd.