Use unsafe read/write for speed.