Light emission and microstructure of Mg-doped AlGaN grown on patterned sapphire