Using Pam on a Gas Grill
Non-stick spray is just oil with a little added emulsifiers to make it extra non-sticky. It isn't any more dangerous when burnt than the oil you apply to your meat.

Spraying oil on the grate will also help season it and keep it from rusting.

The biggest reason not to do it when the grate is hot is that the atomized oil is quite flammable. That said, I spray non-stick spray on the grill and enjoy the pyrotechnics.