We compare the adsorption, desorption, trapping, and release of Ar, N2, O2, CO, and CH4 by dense (nonporous) and highly porous amorphous solid water (ASW) films. Molecular beam deposition techniques are used to control the porosity of the vapor-deposited ASW thin films. Experiments where the gas species is deposited on top of and underneath dense and porous ASW are conducted. For the film thickness used in this study, the porous films are found to adsorb between 20 and 50 times more gas than the dense films. The desorption temperature of the adsorbed gas is also dependent on the porosity of the ASW film. Differences between desorption from porous and dense ASW films are attributed to differences in their ability to trap weakly physisorbed gases. The results are largely independent of the gas studied, confirming that the adsorption and trapping of gases are dominated by the ASW porosity. These findings show that laboratory studies must account for the growth conditions and their effects on ASW morphology in order to accurately predict the properties of astrophysical ices.