AMD, Intel, Microsoft, and Nvidia, all have their own Field Application Engineers that are available to help optimise CPU/GPU codepaths for your product.
So yes, it can, and absolutely does happen. (although I'm in no way implying that marcClintDion is correct in everything he says obviously!)
I'm not sure about MS on the Windows side, but this is absolutely the case with the hardware companies, and for Xbox and PS devs too. That's partly what those NVIDIA/AMD splash logos on games are about. And developers DO get paid to support new DirectX versions and features. All the time. Quite a bit of money changed hands when DX11 was released, in order to have some games support it. The payers are simply the people who get the most immediate and concrete benefit from gamers needing the latest DirectX features. That's not Microsoft, it's the IHVs.
What Microsoft has done, historically, is to go out of their way to make DirectX development easy for small and large developers. And they did that very well for a very long time.