I believe there is something that automatically adjusts the rpm to compensate for load, the reason, the engine (when everything is running properly) maintains a constant rpm, regardless. I suppose if this is failing/has failed, the load of the compressor could cause what is happening to happen.
Look at the rpm, at idle, without the a/c on, and then turn it on a see what the rpm does. I suspect it drops considerably, almost to a stall. Perhaps someone can identify what I am referring to and help out here. I quit working on engines when they started using fuel injectors, so most of this electronic $hit is foreign to me, other than what I read and learn.