Misc visibility changes for compiled autograd (#105298)

Pull Request resolved: https://github.com/pytorch/pytorch/pull/105298
Approved by: https://github.com/albanD, https://github.com/soulitzer
This commit is contained in:
Jason Ansel
2023-07-17 14:44:22 -07:00
committed by PyTorch MergeBot
parent cf404a8ce4
commit e9fd815226
5 changed files with 23 additions and 8 deletions

View File

@ -230,6 +230,11 @@ struct TORCH_API Node : std::enable_shared_from_this<Node> {
return input_metadata_[index];
}
// Danger: not thread safe, caller must protect with lock
InputMetadata& mutable_input_metadata(size_t index) {
return input_metadata_[index];
}
/**
* Note: Function Streams
* A function's stream (for a given device type) is the stream of the first