Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a null check for tracer in the Module::load_method #6319

Merged
merged 1 commit into from
Oct 17, 2024

Conversation

pytorchbot
Copy link
Collaborator

Summary:
When testing the LLM Manual, I found etdump is not generated :(. It seems to be a bug introduced in D62520386 when a tracer parameter was added to Module::load_method. It overrides the event_tracer_.get(), resulting tracer being null program_->load_method is called and thus etdump is not generated.

This diff just adds a check: it tracer is not null, use it; otherwise use the tracer get from class member event_tracer_.

Differential Revision: D64481537

#6298)

Summary:
Pull Request resolved: #6298

When testing the [LLM Manual](https://pytorch.org/executorch/0.4/llm/getting-started.html#profiling-and-debugging), I found etdump is not generated :(. It seems to be a bug introduced in D62520386 when a `tracer` parameter was added to `Module::load_method`. It overrides the `event_tracer_.get()`, resulting `tracer` being null and passed to `program_->load_method`, thus etdump is not generated.

This diff just adds a check: it `tracer` is not null, use it; otherwise use the tracer get from class member event_tracer_.

Reviewed By: tarun292, Gasoonjia, dbort

Differential Revision: D64481537

fbshipit-source-id: 86cecbaea2b7293be28d60f4147deb31535fa6ea
(cherry picked from commit ad0e5e8)
Copy link

pytorch-bot bot commented Oct 17, 2024

🔗 Helpful Links

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

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

❌ 1 New Failure

As of commit bbcb95a with merge base eecf74f (image):

NEW FAILURE - The following job has failed:

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

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Oct 17, 2024
Copy link
Contributor

@dvorjackz dvorjackz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-running a failed test, seems to be a flake

@dvorjackz dvorjackz merged commit d59a511 into release/0.4 Oct 17, 2024
40 of 41 checks passed
@dvorjackz dvorjackz deleted the cherry-pick-6298-by-pytorch_bot_bot_ branch October 17, 2024 17:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants