Yes, but different powders create different volumes of gas. And sticking a compensator on the end of the barrel turns the usual "less gas = less recoil" dynamic on its head. Without a comp, all the gas that leaves the barrel comes straight out, and acts like a short-duration rocket pushing the barrel straight backwards, increasing recoil. With a comp, a substantial volume - a majority, even - is diverted upwards, and even slightly to the rear. That gas then pushes the gun
down and even pulls it slightly
forward. So more gas = less recoil
with a comp.
Note, too, that these dynamics also mean that comps are less effective on 45ACP's than on, say, 38 supers. That's because the 45 runs at a lower pressure - and the jets of gas being used to push the gun down and pull it forward are less powerful jets. So the comp does less work.
The Shooting Times had a great article on this topics.
http://www.shootingtimes.com/ballistics/compensators-pressure-gas/