update dwz function