Skip to content

Conversation

@Conarnar
Copy link
Contributor

Summary

Turning on the EXECUTORCH_ENABLE_EVENT_TRACER option will enable event tracing in the Wasm module API. The results can be obtained with the etdump() method.

Test plan

Added two tests depending on whether EXECUTORCH_ENABLE_EVENT_TRACER is turned on or not. Added the --enable-etdump option to scripts/build_wasm_tests.sh which turns on the above option.

Added configurations to the unittest-wasm-bindings CI test to run with and without --enable-etdump.

@pytorch-bot
Copy link

pytorch-bot bot commented Aug 11, 2025

🔗 Helpful Links

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

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

❌ 1 New Failure

As of commit ebeb7de with merge base 8e73c09 (image):

NEW FAILURE - The following job has failed:

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

@meta-cla meta-cla 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 Aug 11, 2025
@github-actions
Copy link

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

@Conarnar Conarnar marked this pull request as draft August 12, 2025 00:13
@Conarnar Conarnar marked this pull request as ready for review August 12, 2025 00:31
if [ "$arg" == "--enable-etdump" ]; then
ETDUMP_OPTS="-DEXECUTORCH_ENABLE_EVENT_TRACER=ON \
-DEXECUTORCH_BUILD_DEVTOOLS=ON \
-DFLATCC_ALLOW_WERROR=OFF"
Copy link
Contributor

Choose a reason for hiding this comment

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

Add a comment here on why this flag is required?

Copy link
Contributor

@lucylq lucylq left a comment

Choose a reason for hiding this comment

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

LGTM, also cc @Gasoonjia on devtools

@Gasoonjia
Copy link
Contributor

LGTM.
Is there any buck target we need to update?

@lucylq
Copy link
Contributor

lucylq commented Aug 12, 2025

LGTM. Is there any buck target we need to update?

I think all of the wasm work has been in OSS, so there aren't buck targets for it and it won't break CI.

Conan and I had a quick look, and there is emscripten internally that we could use from fbsource/third-party if we wanted to buckify things cc @JacobSzwejbka

@Conarnar Conarnar merged commit a4b59cc into pytorch:main Aug 12, 2025
102 of 103 checks passed
agrima1304 pushed a commit to agrima1304/executorch that referenced this pull request Aug 26, 2025
### Summary
Turning on the `EXECUTORCH_ENABLE_EVENT_TRACER` option will enable event
tracing in the Wasm module API. The results can be obtained with the
`etdump()` method.

### Test plan
Added two tests depending on whether `EXECUTORCH_ENABLE_EVENT_TRACER` is
turned on or not. Added the `--enable-etdump` option to
`scripts/build_wasm_tests.sh` which turns on the above option.

Added configurations to the `unittest-wasm-bindings` CI test to run with
and without `--enable-etdump`.
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.

3 participants