Actually, real silencers are likely to be bulkier and noisier than the ones in a Hollywood stockroom. Many are actually larger than the guns they are designed to work with, and no silencer can remove ALL sound of a shot.
Most of a gunshot's noise comes from hot gasses bursting out of the gun behind the bullet. The more suddenly these gasses emerge, the sharper and louder the sound will be. A silencer works by slowing and cooling this burst of gas, trapping it in a spiral of steel wool and forcing it to exit the gun more gradually. As they emerge, these slower moving gasses make less sound than the concentrated burst of a normal gunshot.
You can feel the difference yourself by making the sounds "Bam!" and "Phoof!" The sharp burst of air following the "B" sound of "Bam!" will make a sharper, more percussive noise than the more gradual escape of "Phoof!" It's the same difference as letting the air out of a balloon slowly instead of popping it.
Both gun silencers and car mufflers work the same way---they were invented by the same person, Hiram Maxim, in the early twentieth century. Maxim didn't care much about gun-toting assassins or spy movie screenwriters. He was ecologically minded. What was his main, ecological concern? Noise pollution!