MicrosoftEdge / MicrosoftEdge/WebView2Feedback
[Problem/Bug]: WebView2 deadlocks and crashes when sending large messages on ARM64 Windows with x64 target
@david-risney is already working on this.
Since May 28, 2024.
- Dominant language
- PowerShell
- Stars
- 526
- Forks
- 67
- PR merge metrics
- No merged PRs in 30d
Description
What happened?
Description:
When running a WebView2-based application built with C# targeting x64 on an ARM64 Windows machine, attempting to send large messages to the WebView2 control leads to deadlocks and eventual crashes of the entire application. This issue occurs in the following scenarios:
- Returning large data from a
[ComVisible]method on a bridge between C# and JavaScript. - Posting large JSON payloads to the WebView2 control using
CoreWebView2.PostWebMessageAsJson. - Sending large strings to the WebView2 control using
CoreWebView2.PostWebMessageAsString.
The application becomes unresponsive and eventually crashes, indicating a fundamental issue with the translation layer for WebView2 when running x64 applications on ARM64 Windows.
Expected behavior:
The application should be able to send and receive large messages without any deadlocks or crashes, regardless of the target platform (x64) and the underlying architecture (ARM64).
Actual behavior:
The application deadlocks when attempting to send large messages to the WebView2 control and eventually crashes, making it impossible to use WebView2 reliably in x64 applications running on ARM64 Windows.
Additional context:
This issue is critical for developers targeting x64 applications that use WebView2 and need to support ARM64 Windows devices, especially since Steam only supports the x64 platform. The deadlocks and crashes make it impossible to use WebView2 reliably in such scenarios, severely limiting the usability of the control on ARM64 Windows machines.
Importance
Blocking. My app's basic functions are not working due to this issue.
Runtime Channel
Stable release (WebView2 Runtime), Prerelease (Edge Canary/Dev/Beta)
Runtime Version
1.0.2526-prerelease
SDK Version
1.0.2526-prerelease
Framework
Win32 (.NET 9) (I am manually creating and managing my window without winforms or WPF, but the official example apps crash too.)
Operating System
Windows 11
OS Version
No response
Repro steps
- Set up a Windows 11 ARM64 virtual machine running on macOS with an M1 processor.
- Create a C# application that uses WebView2 and targets the x64 platform (as it is the only platform supported by Steam).
- Implement a scenario where large messages are sent to the WebView2 control, such as:
- Returning large data from a
[ComVisible]method on a bridge between C# and JavaScript. - Posting large JSON payloads using
CoreWebView2.PostWebMessageAsJson. - Sending large strings using
CoreWebView2.PostWebMessageAsString.
- Run the application on the ARM64 Windows virtual machine.
Repros in Edge Browser
No, issue does not reproduce in the corresponding Edge version
Regression
Don't know
Last working version (if regression)
No response
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.