Convert LdFuncCachedCommon() and LdClsCachedCommon() to SSA

Reviewed By: @alexmalyshev

Differential Revision: D1568449