Every basic block section symbol created by -fbasic-block-sections will contain ".__part." to know that this symbol corresponds to a basic block fragment of the function.
This patch solves two problems:
a) Like D89617, we want function symbols with suffixes to be properly qualified so that external tools like profile aggregators know exactly what this symbol corresponds to.
b) The current basic block naming just adds a ".N" to the symbol name where N is some integer. This collides with how clang creates __cxx_global_var_init.N. clang creates these symbol names to call constructor functions and basic block symbol naming should not use the same style.
I have fixed all the test cases and added an extra test for __cxx_global_var_init breakage.
Suffix = (Suffix + Twine(".__part.") + Twine(SectionID.Number)).str();