Skip to content

Use metal instance for Android emulator for KVM support#5127

Merged
facebook-github-bot merged 1 commit intomainfrom
run-android-emulator-on-metal
Sep 7, 2024
Merged

Use metal instance for Android emulator for KVM support#5127
facebook-github-bot merged 1 commit intomainfrom
run-android-emulator-on-metal

Conversation

@huydhn
Copy link
Contributor

@huydhn huydhn commented Sep 6, 2024

A known issue when running Android emulator test on our Linux runner is that the runner, already a virtual machine, doesn't support KVM/hardware accelerator, for example https://github.com/pytorch/executorch/actions/runs/10732304130/job/29764671347#step:9:37. It means that emulating anything takes longer.

There are some metal Linux runners around in our infra that folks uses for CPU benchmarking. I think we can try to use them as there are still spare capacity and the current Android emulator job is relatively small to squeeze in. AWS metal runners are "real" and supports KVM.

Testing

The current emulator job takes around 7 to 10m https://hud.pytorch.org/hud/pytorch/executorch/main/1?per_page=50&name_filter=emulator

After running on metal instance, it takes https://github.com/pytorch/executorch/actions/runs/10732098391/job/29764069309?pr=5127, the emulator job takes around 2m

@pytorch-bot
Copy link

pytorch-bot bot commented Sep 6, 2024

🔗 Helpful Links

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

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

✅ No Failures

As of commit e693f5c with merge base 8afdc48 (image):
💚 Looks good so far! There are no failures yet. 💚

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 Sep 6, 2024
@huydhn huydhn marked this pull request as ready for review September 6, 2024 14:26
@facebook-github-bot
Copy link
Contributor

@huydhn has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

Summary:
A known issue when running Android emulator test on our Linux runner is that the runner, already a virtual machine, doesn't support KVM/hardware accelerator, for example https://github.com/pytorch/executorch/actions/runs/10732304130/job/29764671347#step:9:37.  The drawback is that it takes longer to emulate anything there.

There are some metal Linux runners around in our infra that folks uses for CPU benchmarking.  I think we can try to use them as there are still spare capacity and the current Android emulator test is relatively fast.

### Testing

The current emulator job takes around 7 to 10m https://hud.pytorch.org/hud/pytorch/executorch/main/1?per_page=50&name_filter=emulator

After running on metal instance, it takes https://github.com/pytorch/executorch/actions/runs/10732098391/job/29764069309?pr=5127, the emulator job takes around 2m

Pull Request resolved: #5127

Reviewed By: kirklandsign

Differential Revision: D62299612

Pulled By: huydhn
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D62299612

@huydhn huydhn force-pushed the run-android-emulator-on-metal branch from 731214d to e693f5c Compare September 6, 2024 23:01
@facebook-github-bot facebook-github-bot merged commit ab4810c into main Sep 7, 2024
@facebook-github-bot facebook-github-bot deleted the run-android-emulator-on-metal branch September 7, 2024 00:12
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. fb-exported

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants