In this paper, the processes and mechanisms of X-ray production are discussed by numerically investigating a typical aluminum-wire-array Z-pinch implosion on the S-300 facility. It is shown that the line emission accounts for over 70% of the total radiation, and the continuum including free-free and free-bound transitions occupies less than 30%. In the line emission, most photons are generated from L-shell transitions which take place everywhere, while high-energy K-shell photons are much fewer and are mainly produced in the interior region, where the electron temperature is relatively high. Corresponding to the variation of plasma conditions in different phases of the implosion, the dominant atomic processes and radiation mechanisms show great difference. In the run-in phase, the ionization and excitation processes dominate with the increase of electron temperature, thus causing a large number of ions in excited states and, in turn, the increase of the line emission. However, the share of the line emission decreases slightly because of the strong self-absorption of lines and much weaker opacity effect on the continuum. At stagnation, the plasma is compressed to the state of high density; three-body recombination plays a key role in determining the populations of ions. Consequently, the populations of some important excited states increase rapidly, resulting in an increase of the share of line emission. After stagnation, the plasma expands, and the electron number density decreases, and the three-body recombination decreases more quickly than the radiation recombination, thus again leading to a gradual decrease in the share of line emission.