There are two types of upgrades. Those done in advance and those that clear off the airport list just before boarding. In the first, if you two are on the same PNR or one is listed as the companion of the other, then the algorithm really should try to seat you together if possible, as it will always upgrade either both of you or neither of you. I don't know whether it seats you together consistently or at all. I seem to recall it does not. I believe your saved seat preference will trump any attempt to seat you together. However, if it's an advance upgrade there are likely seats still open so you can reposition yourselves after you've been upgraded. That's what I do.
With the airport list, they are normally pulled off one by one and there will be no attempt made to seat two together, even if possible. Usually it's a moot point, as there is unlikely any pairs open that close to boarding.
Still, I have to say the OP and companion were handled in the stupidest way possible given the open seats. I wonder if the GA or the T-40 automation did it.