]> git.ipfire.org Git - thirdparty/qemu.git/commit
target/sparc: Fix gdbstub incorrectly handling registers f32-f62
authorMikael Szreder <git@miszr.win>
Fri, 14 Feb 2025 07:03:43 +0000 (08:03 +0100)
committerMichael Tokarev <mjt@tls.msk.ru>
Sat, 22 Mar 2025 07:52:25 +0000 (10:52 +0300)
commit3085db5cad11cb91c3055e490fcea2fc16d7cad2
tree5194411525abffc8aed7b6a3ee8ec0a5702a8af0
parent9d820b19b14d8cbef88763ee54ced8325431ba56
target/sparc: Fix gdbstub incorrectly handling registers f32-f62

The gdbstub implementation for the Sparc architecture would
incorrectly calculate the the floating point register offset.
This resulted in, for example, registers f32 and f34 to point to
the same value.

The issue was caused by the confusion between even register numbers
and even register indexes. For example, the register index of f32 is 64
and f34 is 65.

Cc: qemu-stable@nongnu.org
Fixes: 30038fd81808 ("target-sparc: Change fpr representation to doubles.")
Signed-off-by: Mikael Szreder <git@miszr.win>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250214070343.11501-1-git@miszr.win>
(cherry picked from commit 7a74e468089a58756b438d31a2a9a97f183780d7)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
target/sparc/gdbstub.c