Skip to content

Improve QNN backend AOT user experience#17989

Open
abhinaykukkadapu wants to merge 2 commits intogh/abhinaykukkadapu/16/basefrom
gh/abhinaykukkadapu/16/head
Open

Improve QNN backend AOT user experience#17989
abhinaykukkadapu wants to merge 2 commits intogh/abhinaykukkadapu/16/basefrom
gh/abhinaykukkadapu/16/head

Conversation

@abhinaykukkadapu
Copy link
Contributor

@abhinaykukkadapu abhinaykukkadapu commented Mar 7, 2026

Stack from ghstack (oldest at bottom):

  • Read QNN_VERSION from qnn_config.sh instead of hardcoding in
    download_qnn_sdk.py, eliminating version duplication
  • Add download progress bars for SDK (~2.4GB), libc++ (~575MB), and
    glibc (~10MB) downloads with percentage and MB counters
  • Add extraction progress for SDK, libc++, and tar archives
  • Add retry + resume for SDK download — on mid-stream failures
    (ChunkedEncodingError, ConnectionError), resumes from where it
    left off using HTTP Range headers instead of restarting
  • Replace NullHandler logger with configured StreamHandler so users
    see status messages (previously all output was swallowed)
  • Cache SDK at ~/.cache/executorch/qnn/sdk-/ instead of
    inside the pip package directory, surviving pip reinstalls
  • Include version in cache directory name for automatic upgrade
    detection when qnn_config.sh version changes
  • Set both QNN_SDK_ROOT and LD_LIBRARY_PATH after auto-download
  • Print SDK version and path on first import (cached or fresh)
  • Print user-provided QNN_SDK_ROOT path when set via env var
  • Add visible warning before glibc re-exec with guidance
  • Replace unhelpful "check logs above" error with actionable message
    including full SDK download URL and env var setup instructions

- Read QNN_VERSION from qnn_config.sh instead of hardcoding in
  download_qnn_sdk.py, eliminating version duplication
- Add download progress bars for SDK (~2.4GB), libc++ (~575MB), and
  glibc (~10MB) downloads with percentage and MB counters
- Add extraction progress for SDK, libc++, and tar archives
- Add retry + resume for SDK download — on mid-stream failures
  (ChunkedEncodingError, ConnectionError), resumes from where it
  left off using HTTP Range headers instead of restarting
- Replace NullHandler logger with configured StreamHandler so users
  see status messages (previously all output was swallowed)
- Cache SDK at ~/.cache/executorch/qnn/sdk-<version>/ instead of
  inside the pip package directory, surviving pip reinstalls
- Include version in cache directory name for automatic upgrade
  detection when qnn_config.sh version changes
- Set both QNN_SDK_ROOT and LD_LIBRARY_PATH after auto-download
- Print SDK version and path on first import (cached or fresh)
- Print user-provided QNN_SDK_ROOT path when set via env var
- Add visible warning before glibc re-exec with guidance
- Replace unhelpful "check logs above" error with actionable message
  including full SDK download URL and env var setup instructions

[ghstack-poisoned]
@pytorch-bot
Copy link

pytorch-bot bot commented Mar 7, 2026

🔗 Helpful Links

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

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

❌ 3 New Failures, 2 Unrelated Failures

As of commit 496f338 with merge base 258d503 (image):

NEW FAILURES - The following jobs have failed:

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

BROKEN TRUNK - The following job failed but was present on the merge base:

👉 Rebase onto the `viable/strict` branch to avoid these failures

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 Mar 7, 2026
@github-actions
Copy link

github-actions bot commented Mar 7, 2026

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.

- Read QNN_VERSION from qnn_config.sh instead of hardcoding in
  download_qnn_sdk.py, eliminating version duplication
- Add download progress bars for SDK (~2.4GB), libc++ (~575MB), and
  glibc (~10MB) downloads with percentage and MB counters
- Add extraction progress for SDK, libc++, and tar archives
- Add retry + resume for SDK download — on mid-stream failures
  (ChunkedEncodingError, ConnectionError), resumes from where it
  left off using HTTP Range headers instead of restarting
- Replace NullHandler logger with configured StreamHandler so users
  see status messages (previously all output was swallowed)
- Cache SDK at ~/.cache/executorch/qnn/sdk-<version>/ instead of
  inside the pip package directory, surviving pip reinstalls
- Include version in cache directory name for automatic upgrade
  detection when qnn_config.sh version changes
- Set both QNN_SDK_ROOT and LD_LIBRARY_PATH after auto-download
- Print SDK version and path on first import (cached or fresh)
- Print user-provided QNN_SDK_ROOT path when set via env var
- Add visible warning before glibc re-exec with guidance
- Replace unhelpful "check logs above" error with actionable message
  including full SDK download URL and env var setup instructions

[ghstack-poisoned]
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.

1 participant