A grand prix has a decent effect on the local economy. All the teams and spectators fill hotel rooms, eat food and generally spend money in the area. Id guess this cash injection would be larger than the government contribution to the race too.
So while the event itself might not be a winner for the track owner, it is for the country and city that its in.
There are other similar but non economic effects. If a government helps its city by creating incentives for sports, arts and other events like trade fairs etc the citizens are less likely to get bored and move out (like I did from my city). Citizens moving out generally has a bad effect on the economy.