In this paper we generalize a theorem of Kudla-Rapoport-Yang which gives a formula for the arithmetic degree of the moduli space of CM elliptic curves together with a special endomorphism of a specified degree. Our extension is to the moduli space of QM abelian surfaces with CM together with a special endomorphism of a specified QM degree.
Andrew Phillips (Fri,) studied this question.