Actually, you kind of have that backwards. You compress a gas, which causes it to heat up in accordance with your favorite gas law (I like PV=nRT). If you're trying to chill something, you obviously perform this process on an the other side of an insulated barrier from what you want chilled. Over time, the compressed gas' heat dissipates into the surroundings, and you then pump the compressed gas over to what you want chilled. Then you decompress the gas, and since P and T are directly proportional, the temperature of the gas decreases as pressure decreases.