value_indices keeps track of the value index of each instruction in the function (i.e skips instruction which do not have a result)