A period is a contiguous sequence of phase ids in some run. It is coded as follows:
sign, always 0 1 bit runid 17 bits last phase id: 7 bits #phases before last: 7 bits
// Dmitry: sign == 0 isn't actually always true, in some cases phaseId == -1 is used for shifts, that easily creates code < 0
An ordinal number for phases. First phase has number 1.
An ordinal number for compiler runs. First run has number 1.
The number of bits needed to encode a phase identifier.