I haven't done it in a while but if connecting int'l to int'l you never need clear customs and won't need a visa. I'm not terribly familiar with GRU (only done it 5-6 times) but upon arrival you'll walk down a hallway with windows on one side and the wall of the terminal on the other. You'll be able to see into the terminal. At the end of this, you should see a set of stairs/escalator leading downwards. YOU DO NOT want to go down there, that's customs/immigration.
Instead, there should be a sign with an arrow pointing left to redirect you back into the terminal to meet your connecting flight. Should you need to transit between Terminal 1 and 2, you'll need to exit the secured area but will not need to clear customs/immigration. Go to the second floor (the lounges are there as well) and cross over to the terminal you need. You'll then reclear security to get back into the passenger terminal. If you have lounge access, note that the lines can get rather long. Leave yourself plenty of time to clear security and get to the gate. Enjoy!