Some minor improvements to the thread safety intermediate language -- mostly const correctness and reformatting. Fixes the types involved with castOpcode().

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@205976 91177308-0d34-0410-b5e6-96231b3b80d8
CodeGen: Move PGO initialization into Release()

Emitting the PGO initialization in EmitGlobalFunctionDefinition is
inefficient, since this only has an effect once per module.  We move
this to Release() with the rest of the once-per-module logic.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@205977 91177308-0d34-0410-b5e6-96231b3b80d8