ok i’m just gonna drop this fun theory out there but consider:
the only thing standing in the way of mary becoming the new moriarty was whatever magnussen had on her
and mycroft knew that
and by shooting magnussen sherlock inadvertently allowed mary to achieve her goal
hence mycroft’s “oh sherlock, what have you done”
and that is why moriarty wasn’t “back” until after magnussen was eliminated
