compute struct member offset