update / fix bit_index