No, discrimination doesn't cause wars. We don't risk our lives and waste resources just getting rid of those we don't like.
Humans usually fight over resources, not just because of discrimination and disagreements. Wars are over water, farmland, status for the leaders and the rewards for the subordinates.
Dehumanization of the rival is a precursor to being able to kill them.