KEMBAR78
Support torch.Event elapsed_time method on XPU by guangyey · Pull Request #140865 · pytorch/pytorch · GitHub
Skip to content

Conversation

@guangyey
Copy link
Collaborator

@guangyey guangyey commented Nov 16, 2024

Stack from ghstack (oldest at bottom):

Motivation

This PR aims to support c10::Event/torch.Event elapsed_time method on XPU. We create a profiling tag Event when the timing flag is enabled.

cc @gujinghui @EikanWang @fengyuan14

@pytorch-bot
Copy link

pytorch-bot bot commented Nov 16, 2024

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/140865

Note: Links to docs will display an error until the docs builds have been completed.

✅ You can merge normally! (1 Unrelated Failure)

As of commit 4644add with merge base 9e299b8 (image):

FLAKY - The following job failed but was likely due to flakiness present on trunk:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

guangyey added a commit that referenced this pull request Nov 16, 2024
ghstack-source-id: c5bfd7e
Pull Request resolved: #140865
@guangyey guangyey added ciflow/xpu Run XPU CI tasks ciflow/trunk Trigger trunk jobs on your pull request release notes: xpu release notes category labels Nov 16, 2024
@guangyey guangyey added module: xpu Intel XPU related issues and removed open source labels Nov 16, 2024
@guangyey guangyey marked this pull request as draft November 16, 2024 03:34
@guangyey guangyey changed the title Support torch.Event elapsed_time method on XPU [WIP] [Reland] Support torch.Event elapsed_time method on XPU Nov 16, 2024
@guangyey guangyey changed the title [WIP] [Reland] Support torch.Event elapsed_time method on XPU [WIP] Support torch.Event elapsed_time method on XPU Nov 16, 2024
[ghstack-poisoned]
[ghstack-poisoned]
[ghstack-poisoned]
[ghstack-poisoned]
@guangyey
Copy link
Collaborator Author

@pytorchbot rebase -b main

@pytorchmergebot
Copy link
Collaborator

@pytorchbot started a rebase job onto refs/remotes/origin/main. Check the current status here

[ghstack-poisoned]
@pytorchmergebot
Copy link
Collaborator

Successfully rebased gh/guangyey/95/orig onto refs/remotes/origin/main, please pull locally before adding more changes (for example, via ghstack checkout https://github.com/pytorch/pytorch/pull/140865)

[ghstack-poisoned]
@guangyey guangyey added this to the 2.6.0 milestone Nov 21, 2024
[ghstack-poisoned]
[ghstack-poisoned]
[ghstack-poisoned]
[ghstack-poisoned]
@guangyey guangyey marked this pull request as ready for review November 26, 2024 07:18
@guangyey guangyey changed the title [WIP] Support torch.Event elapsed_time method on XPU Support torch.Event elapsed_time method on XPU Nov 26, 2024
[ghstack-poisoned]
[ghstack-poisoned]
@guangyey
Copy link
Collaborator Author

@gujinghui @EikanWang May I know if you could help review this PR?

[ghstack-poisoned]
@pytorchmergebot
Copy link
Collaborator

Rebased gh/guangyey/97/orig onto refs/remotes/origin/viable/strict because #140873 was rebased, please pull locally before adding more changes (for example, via ghstack checkout https://github.com/pytorch/pytorch/pull/140865)

pytorchmergebot pushed a commit that referenced this pull request Nov 28, 2024
# Motivation
This PR intends to reland #134666 that has been reverted in #140872
We reverted it because I forgot to support `elapsed_time` for `XPUGuardImpl`, which resulted in `c10::Event` not supporting' elapsed_time' and blocking XPU CI.

# Additional Context
We split #134666 into two parts: one part, PR #140865, supports `elapsed_time` for `torch.Event` and another one, this PR, supports for `torch.xpu.elapsed_time`.

Pull Request resolved: #140873
Approved by: https://github.com/gujinghui
ghstack dependencies: #140865
pytorchmergebot pushed a commit that referenced this pull request Dec 3, 2024
# Motivation
Fix this UT failure introduced by #140865. The unrelated failure suppressed this UT failure.
It goes to happen since #141546 is landed.

Pull Request resolved: #141800
Approved by: https://github.com/EikanWang
pobin6 pushed a commit to pobin6/pytorch that referenced this pull request Dec 5, 2024
# Motivation
This PR aims to support c10::Event/torch.Event elapsed_time method on XPU. We create a profiling tag Event when the timing flag is enabled.

Pull Request resolved: pytorch#140865
Approved by: https://github.com/Samkm0084, https://github.com/gujinghui
pobin6 pushed a commit to pobin6/pytorch that referenced this pull request Dec 5, 2024
# Motivation
This PR intends to reland pytorch#134666 that has been reverted in pytorch#140872
We reverted it because I forgot to support `elapsed_time` for `XPUGuardImpl`, which resulted in `c10::Event` not supporting' elapsed_time' and blocking XPU CI.

# Additional Context
We split pytorch#134666 into two parts: one part, PR pytorch#140865, supports `elapsed_time` for `torch.Event` and another one, this PR, supports for `torch.xpu.elapsed_time`.

Pull Request resolved: pytorch#140873
Approved by: https://github.com/gujinghui
ghstack dependencies: pytorch#140865
pobin6 pushed a commit to pobin6/pytorch that referenced this pull request Dec 5, 2024
# Motivation
Fix this UT failure introduced by pytorch#140865. The unrelated failure suppressed this UT failure.
It goes to happen since pytorch#141546 is landed.

Pull Request resolved: pytorch#141800
Approved by: https://github.com/EikanWang
@github-actions github-actions bot deleted the gh/guangyey/95/head branch December 30, 2024 02:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ciflow/trunk Trigger trunk jobs on your pull request ciflow/xpu Run XPU CI tasks Merged module: xpu Intel XPU related issues open source release notes: xpu release notes category

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

5 participants