In my experience this is largely a function of environment.
If you give a realistic estimate and constantly get "stop padding your estimates" or "this needs to be done quicker" in response, after a while you start giving hopelessly optimistic estimates.
You might be right, however what I've often observed is that people will estimate a task based on how long it would take them to do it if that were their only responsibility. They often ignore the fact that they don't get a full days worth of solid, productive coding due to meetings, build problems, releasing, code review, recruitment, fire alarms, sickness, status reporting...
As I recall, at IBM they used to give 3 estimates, best / expected / worst case, and then weight them something like 1/3/5 to get the planning estimate.
One person I worked with recorded estimate vs actual for multiple years. They were frequently an order of magnitude out.
If you give a realistic estimate and constantly get "stop padding your estimates" or "this needs to be done quicker" in response, after a while you start giving hopelessly optimistic estimates.