pytorch/test/cpp
Nikitha Malgi 197f9f0826 Merge CUDA Streams and Events (#53902)
Summary:
-----------
- Updates current_stream and default stream API's to take `optional[device]` argument
- Adds parsing logic to replace `torch.cuda.Stream` and `torch.cuda.Event` -> `torch.classes.cuda.Stream` and `torch.classes.cuda.Event` for JIT
- Merges StreamContext manager for both Eager and JIT.

Pull Request resolved: https://github.com/pytorch/pytorch/pull/53902

Test Plan:
------
Run JIT tests:
python test/test_jit.py -v TestCUDA

Run eager tests:
python test/test_cuda.py -v TestCuda

Reviewed By: glaringlee

Differential Revision: D27494627

Pulled By: nikithamalgifb

fbshipit-source-id: b30b0570e38a33fb335c83762eb06ffd46a44b5c
2021-04-05 08:19:55 -07:00
..
api Flip clip_grad_norm default for error_if_nonfinite to false (#55169) 2021-04-02 12:25:32 -07:00
common Trim libshm deps, move tempfile.h to c10 (#17019) 2019-02-13 19:38:35 -08:00
dist_autograd Forbid trailing whitespace (#53406) 2021-03-05 17:22:55 -08:00
jit Merge CUDA Streams and Events (#53902) 2021-04-05 08:19:55 -07:00
lite_interpreter_runtime [PyTorch] Enable test_lite_interpreter_runtime running in android (#54579) 2021-03-24 14:45:27 -07:00
rpc Transition to new tensorpipe::Pipe API. (#55193) 2021-04-02 02:28:07 -07:00
tensorexpr [TensorExpr] Nuke FunctionCall. (#54998) 2021-04-01 19:47:59 -07:00
__init__.py remediation of S205607 2020-07-17 17:19:47 -07:00