You start with a greater good and a higher purpose, and then you buy in on the idea that the end justifies the means, and if they believe in God, that the means are acceptable to God. With Christianity at least, you have a belief in place that people are supposed to have a choice if their obedience is to be meaningful, and that the future course of the great events of history are ultimately under the control of God, not ourselves. Christianity does not encourage people to think that the end justifies the means.
Just to give you an example, you hear a lot of anti-gay preaching from Christians in America, but even when you hear of queerbashings, religious condemnations of homosexuality, in almost all cases, aren't even used as a pretext, much less a motivation. Why?
Why were there these mass killings in countries like China, Nazi Germany, and revolutionary France, and Soviet Russia. The French and Russian revolutions started off with what appear to be good motives about overthrowing tyrannical monarchs and fair treatment for workers. The French started with liberty, equality and fraternity and ended up with Madame la Guillotine. The Russian revolution overthrew the Tsar, and put in the Party.
Some atheists today think that they have a great purpose of saving the world from religion. I am starting to hear "the end justifies the means" reasoning from some of them. Let's be honest, these people have no qualms about stirring up anti-religious hatred. What other than their lack of power to do so will prevent them from doing the kind of harm these previous revolutionaries did, all in the name of reason and science.