Natural selection is usually thought of as causing the evolution of properties of organisms like
their structure, physiology and behaviour, which are controlled by the instructions encoded in
their genomes. However, genomes themselves are the product of evolution, and natural selection
must play a major role in shaping their organization. Detecting and quantifying this aspect of
selection and its interactions with other evolutionary factors, such as mutation and random
sampling effects due to finite population size, is a major challenge for biologists, especially as the
intensity of selection on many genomic features is probably so small as to be inaccessible to
experimental measurement. It is increasingly recognised that patterns of DNA sequence variation
within populations offer considerable power to detect and estimate selective effects of the order
of one in a million or less, if these patterns are compared with the predictions of models of the
evolutionary processes involved. The utility of approaches based on such model-based analyses of
sequence data is illustrated with two examples from Drosophila population genetic studies. One
concerns selection on codon usage bias, the non-random use of alternative codons for the same
amino-acid, and the related problem of the GC content of sequences. The other concerns selection
on the size of non-coding sequences, especially introns. The evidence for pervasive selection on
these and other features of genomes raises the old problem of the ‘genetic load’; how can a
population survive the action of selection at tens or hundreds of millions of sites throughout the
genome? Two alternative resolutions of this problem are presented.