X-Men has been a platform to discuss bigotry for a very long time. You can see whichever subgroup you want in mutants because Claremont (and to a lesser extent previous writers) put parallels to every subgroup he could think of.
Yes Magneto is a terrorist, he's also the villain, but he's a villain with a point. Remember he's a Holocaust survivor, he's this stuff before, or at least he's pretty sure he's seen it before. In the comics they develop that stronger with some character popping in from the future, a future in which everything Magneto fears has come to pass. As well as fear of Holocaust 2 Magneto is also driven by ego, he really likes being a really powerful mutant, which is really the thing that pushes him over from being someone merely concerned (like Charles) to a terrorist.
I don't think any of that makes it tainted, because he's the bad guy. The bad guy is supposed to do and say things that are wrong, that's why they're bad guys.
I think you are spending wayyyy too much time obsessing. This was a comic book brought to life. If there was a political message it flew right over my head (which means its in the stratosphere for most sheeple)..
P.S. Yeah, I am no more approving of Sir Ian McKellen's very open deviancy than you are, but as an actor he is impossible to take your eyes off of - a pleasure to watch. Patrick Stewart - an excellent character actor in his own right - looks downright wooden next to McKellen.