A recently developed nonlocal history dependent model for electron and hole impact ionization is used to compute the gain and the excess noise factor in avalanche photodiodes featuring heterojunctions of III-V compound semiconductors while accounting for both carriers. The model has been calibrated with measurements by our group, as well as on noise versus gain data from the literature. We explore the avalanche photodiode design trade-offs related to the number of GaAs/AlGaAs conduction band steps for X-ray spectroscopy applications.