what figure of speech is represented in the sentence "he was sweating like a racehorse"?

ASAP PO​