I've been playing since GT1 and although you will see a small and steady drop in horsepower with used cars, it has never been permanent, at least not significantly... but that depends on the overall mileage. That's why we have engine rebuilds... As for new cars, I haven't heard of this being an issue.
Here's a handy link for you, though it's a little hard to parse.
There's three separate conditions of the car that combine to give the total horsepower. If your car is broken in, it's been less than 200km since your last oil change, and you're not past 15000km, your car will be at maximum horsepower.