[Bug Skip] XPU Dynamo Graph Lowering - stream_index None#10
Draft
Stonepia wants to merge 1 commit into
Draft
Conversation
[upstream_ut] test/dynamo/test_higher_order_ops.py test_dropout failed with RuntimeError: CUDA not available
7 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
[Bug Skip] XPU Dynamo Graph Lowering - stream_index None
Fixes intel/torch-xpu-ops#3388
Root Cause: In torch/_dynamo/variables/builder.py wrap_fx_proxy_cls (line 3547-3559), when a StreamVariable is created from a proxy whose target is device_interface.current_stream rather than get_external_object_by_index, user_object_index is set to None. Subsequently, when record_event() or wait_event() is called on this StreamVariable, None is passed as stream_index to torch.ops.streams.record_event/wait_stream, causing the RuntimeError since those ops require an int.
Failed Tests:
third_party/torch-xpu-ops/test/xpu/dynamo/test_ctx_manager_xpu.py::CtxManagerTests::test_cuda_event_methodDiff stat: