Just to chime in here... Spock and McCoy were supposed to be friends. It didn't always come across this way, for sure, but they were friends. So McCoy's jabs at Spock was one friend picking on another. Sure, McCoy may have gotten heated in his rants on Vulcans and it may have extended past Spock at times but McCoy couldn't be racist if one of his closest friends was a member of that race.