optimize the struct