Could be either.
Generally, a setup that is geared too low will have the motor heat up more/before the controller. If it's geared too high... the controller will have more heat issues.
So, generally if the motor is getting too hot, try gearing up even though it sounds backwards. And if the ESC is cooking, try gearing down.
But.... this isn't always the case of course, and depends on the the entire setup... which esc, etc. An esc that can barely handle the setup might run hot no matter what... while a Monster Max might stay cool even when the gearing is too tall for the motor. So there are no hard and fast rules...
And some motors will run hot in a particular car no matter what the gearing. For example, a Feigao L can motor in a 1/8 buggy is going to run pretty hot even with a good gearing, while a Neu 1512 can be geared all over the place without cooking.