Live snapshot reversal causes qemu 11.0.1 crash on Apple Silicon
<!--
This is the upstream QEMU issue tracker.
If you are able to, it will greatly facilitate bug triage if you attempt
to reproduce the problem with the latest qemu.git master built from
source. See https://www.qemu.org/download/#source for instructions on
how to do this.
QEMU generally supports the last two releases advertised on
https://www.qemu.org/. Problems with distro-packaged versions of QEMU
older than this should be reported to the distribution instead.
See https://www.qemu.org/contribute/report-a-bug/ for additional
guidance.
If this is a security issue, please consult
https://www.qemu.org/contribute/security-process/
-->
## Host environment
- Operating system: macOS Tahoe 26.5.1 (25F80)
- OS/kernel version: Darwin NG-DMITRY-MO 25.5.0 Darwin Kernel Version 25.5.0: Mon Apr 27 20:41:06 PDT 2026; root:xnu-12377.121.6~2/RELEASE_ARM64_T6030 arm64 arm Darwin
- Architecture: ARM (aarch64)
- QEMU flavor: qemu-system-aarch64
- QEMU version: 11.0.1
## Emulated/Virtualized environment
- Operating system: Ubuntu 24.04
- OS/kernel version: Linux ubuntu24.04-test-arm64.local 6.8.0-88-generic #89-Ubuntu SMP PREEMPT_DYNAMIC Sat Oct 11 00:59:18 UTC 2025 aarch64 aarch64 aarch64 GNU/Linux
- Architecture: ARM (aarch64)
## Description of problem
<!-- Describe the problem, including any error/crash messages seen. -->
## Steps to reproduce
1. Create a new domain with `virt-install`
2. Start a domain and wait till it boots:
```shell
$ virsh start --console ubuntu24.04-test-arm64
```
3. Create a new snapshot:
```shell
$ virsh snapshot-create-as --domain ubuntu24.04-test-arm64 --atomic --name pristine
Domain snapshot pristine created
```
4. Revert to the snapshot:
```shell
$ virsh snapshot-revert --domain ubuntu24.04-test-arm64 --snapshotname pristine
error: Failed to revert snapshot pristine
error: internal error: Missing monitor reply object
```
Looking after that into `~/.cache/libvirt/qemu/log/ubuntu24.04-test-arm64.log`, I see this:
```
ERROR:../target/arm/machine.c:1045:cpu_pre_load: assertion failed: (!cpu->cpreg_vmstate_indexes)
Bail out! ERROR:../target/arm/machine.c:1045:cpu_pre_load: assertion failed: (!cpu->cpreg_vmstate_indexes)
```
## Additional information
<!--
Attach logs, stack traces, screenshots, etc. Compress the files if necessary.
If using libvirt, libvirt logs and XML domain information may be relevant.
If attaching binary test cases you should describe where they were obtained
from, preferably linking to the original source. We greatly prefer test cases in
the form of source code that can be audited before compiling by the engineer.
-->
This happens only if the snapshot was taken while the domain was running. If the domain was stopped at the moment of snapshot creation, further reversal to the snapshot succeeds.
## Regression
The exact same scenario works well with qemu 10.2.2. It's only qemu 11.0.1, which fails.
<!--
The line below ensures that proper tags are added to the issue.
Please do not remove it.
-->
issue