perform the function of vs play the role of

perform the function of

play the role of

How often have the words perform the function of and play the role of occurred in a corpus of books? (source: Google Ngram Viewer )