I remember Sampras drinking Coke at the US Open against Corretja, in 1996 I think it was. It seemed to help him back after throwing up towards the end

Coke has alot of sugar, which acts fast to provide energy for a period. With the heat and the match nearing a conclusion, it served a purpose. I know people who drink Coke after hitting the gym, some even go for Pop Tarts instead. Quick acting carbs to get the glycogen opening up the muscles for nutrients is never a bad thing in those circumstances.

What a funny guy, he drinks coke because sports drinks are too mainstream

He is definitely unique, I watched him practice last week and I don't think he even whacked a ball most of the time, he spent most of the time bouncing the ball on the rim of the racket and doing tricks, then his mate came over and they spent some time playing lawn bowls with tennis balls.

He's a professional athlete, I'm sure he knows what he is doing. He has a number of people and trainers watching after him to make sure he is ok. I doubt after the time he took off last year, the trainers would allow him to drink or eat anything that would hamper his performance during a match.