update doc and comments