At my company, we prepare one-off marketing and legal email blasts in advance, and need the final recipient list a couple days before sending. This allows time for processing the list for opt-outs, duplicates, etc.
That sounds like O(minutes) processing time with a reasonably written program/indexed db and a few million subs? And I’m sure you could get it to be faster than that. Based on all these comments, it frankly sounds like the real answer is that no one gives enough of a shit to do this right.