Not the guy you think he was. He worked for and commanded Moors when it suited his purposes.
Yes I know El Cid worked awhile for the Moors. In the end he helped drive them out of the Iberian peninsula. For that reason, he is a hero in Spain.