update share memory