When you wan't to make it look like you're saying Good Morning, when you don't really mean it. So you shorten it to GM, to make it seem like you're saying Good Morning
I thought he was telling me good morning when he said "gm" but it turns out he meant Gbad Morning