The real Cid, as opposed to the legendary one, was quite willing to fight on the Muslim side when it suited him.