Thank you so much for your help. 
I tried the code, but the gather_list after diffdist.functional.all_gather(gather_list, tensor) also doesn’t contain each tensor’s grad_fn.
I found there is a parameter self.next_backprop in your code, do I need to set it? Sorry to bother you again.