summary refs log tree commit diff stats
path: root/results/classifier/zero-shot/105/mistranslation/2977
blob: fca35b4b7a8b51d553bc058d51060d0377accb16 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
mistranslation: 0.880
device: 0.805
instruction: 0.785
graphic: 0.698
semantic: 0.643
vnc: 0.638
socket: 0.416
network: 0.399
boot: 0.377
other: 0.316
assembly: 0.188
KVM: 0.095

QEMU SVM VMCB exit_code is uint32_t when AMD spec requires uint64_t
Description of problem:
QEMU's SVM implementation incorrectly uses a 32-bit parameter for the exit code in the `cpu_vmexit` function, despite the AMD SVM specification requiring a 64-bit exit code field in the VMCB (Virtual Machine Control Block).

I think the issue is in `target/i386/svm.c` in the `cpu_vmexit` function.

The `exit_code` parameter is declared as `uint32_t` but should be `uint64_t` according to the AMD SVM specification. This causes exit codes to be truncated to 32 bits, resulting in values like 0xffff_ffff instead of the expected 0xffff_ffff_ffff_ffff.
Steps to reproduce:

Additional information:
[this](https://stackoverflow.com/questions/79632531/qemu-svm-vmcb-exit-code-is-uint32-t-when-amd-spec-requires-uint64-t?noredirect=1#comment140448815_79632531) question I posted on stack overflow