Use 32 bit type for idx element of struct gap.