Defect formation in ion-irradiated Al2O3 and MgAl2O4: effects of grain boundaries and fusion transmutation products