A racing game? If you don't have a wheel or decent controller then the PS3 and it isn't close. Also, you are almost certain to have a better online community for the game on the PS3 if you are in to that.
If you have a decent controller/wheel for your PC, much tougher call. With a decent system you'll get superior visuals on the PC, but it isn't likely you'll have nearly the options for a populated on line experience.
Yes, I bought a wheel 10 years ago but have never hooked it up, and bought controllers for the PC I don't use either, so the PC is pretty much keyboard/mouse.
The controller and the larger screen are pluses for the PS3.
On the other hand, I'm not sure what resolution the PS3 runs at, but I do think my 4870 1920x1080 PC graphics are said to be better than PS3 generally.
I rarely get too involved in the 'online community' part of it, especially a racing game.
Sometimes they make it easier - like 'the game was remade with bunch added for the PC, definitely the better version'. When they're similar, it's a harder pick.
I think the issue comes down more to preference for controller and PC graphics versus large screen.
I should probably get a PC set up with the large screen and controllers...