Generalized Planar Fault Energy (GPFE) curves are widely used to evaluate the deformation behavior of metals and alloys. In the present work, a systematic analysis of the microscopic plastic deformation mechanism of face-centered cubic Al in comparison to Cu was conducted based on GPFE curves generated via first-principles calculations. Focus has been put on the effects of Mg impurities in terms of local concentration and local atomic arrangement nearby the deformation plane, upon the GPFE curve of Al, with the aim to investigate the twinnability of Al-Mg alloys subjected to plastic deformation.It is found that Mg exhibites a Suzuki segregation feature to the stacking fault of Al, either intrinsic or extrinsic. Mg atoms residing in the stacking fault plane can decrease the intrinsic stacking fault energy ISFE and enhance the twinning propensity of Al. However, the ISFE value does not decrease monotonically with increasing Mg concentration in the alloy, and a continuous twinnability increase with increasing Mg content is not observed. It is also seen that different local concentrations and atomic configurations of Mg atoms in the vicinity of deformation plane could yield a large variation of ISFE and the twinning propensity of Al. It is proposed that Mg alloying cannot substantially enhance the twinning propensity of Al alloys.