[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 18/40] tests/tcg/arm: Use vmrs/vmsr instead of mcr/mrc
From: |
Alex Bennée |
Subject: |
[PULL 18/40] tests/tcg/arm: Use vmrs/vmsr instead of mcr/mrc |
Date: |
Fri, 5 Jul 2024 16:30:30 +0100 |
From: Richard Henderson <richard.henderson@linaro.org>
Clang 14 generates
/home/rth/qemu/src/tests/tcg/arm/fcvt.c:431:9: error: invalid operand for
instruction
asm("mrc p10, 7, r1, cr1, cr0, 0\n\t"
^
<inline asm>:1:6: note: instantiated into assembly here
mrc p10, 7, r1, cr1, cr0, 0
^
/home/rth/qemu/src/tests/tcg/arm/fcvt.c:432:32: error: invalid operand for
instruction
"orr r1, r1, %[flags]\n\t"
^
<inline asm>:3:6: note: instantiated into assembly here
mcr p10, 7, r1, cr1, cr0, 0
^
This is perhaps a clang bug, but using the neon mnemonic is clearer.
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Akihiko Odaki <akihiko.odaki@daynix.com>
Message-Id: <20240630190050.160642-14-richard.henderson@linaro.org>
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20240705084047.857176-19-alex.bennee@linaro.org>
diff --git a/tests/tcg/arm/fcvt.c b/tests/tcg/arm/fcvt.c
index d8c61cd29f..ecebbb0247 100644
--- a/tests/tcg/arm/fcvt.c
+++ b/tests/tcg/arm/fcvt.c
@@ -427,10 +427,9 @@ int main(int argc, char *argv[argc])
/* And now with ARM alternative FP16 */
#if defined(__arm__)
- /* See glibc sysdeps/arm/fpu_control.h */
- asm("mrc p10, 7, r1, cr1, cr0, 0\n\t"
+ asm("vmrs r1, fpscr\n\t"
"orr r1, r1, %[flags]\n\t"
- "mcr p10, 7, r1, cr1, cr0, 0\n\t"
+ "vmsr fpscr, r1"
: /* no output */ : [flags] "n" (1 << 26) : "r1" );
#else
asm("mrs x1, fpcr\n\t"
--
2.39.2
- [PULL 32/40] gdbstub: Add support for target-specific stubs, (continued)
- [PULL 32/40] gdbstub: Add support for target-specific stubs, Alex Bennée, 2024/07/05
- [PULL 21/40] test/plugin: make insn plugin less noisy by default, Alex Bennée, 2024/07/05
- [PULL 29/40] accel/tcg: Move qemu_plugin_vcpu_init__async() to plugins/, Alex Bennée, 2024/07/05
- [PULL 34/40] target/arm: Make some MTE helpers widely available, Alex Bennée, 2024/07/05
- [PULL 25/40] plugins/lockstep: mention the one-insn-per-tb option, Alex Bennée, 2024/07/05
- [PULL 24/40] plugins/lockstep: make mixed-mode safe, Alex Bennée, 2024/07/05
- [PULL 23/40] plugins/lockstep: preserve sock_path, Alex Bennée, 2024/07/05
- [PULL 36/40] gdbstub: Make hex conversion function non-internal, Alex Bennée, 2024/07/05
- [PULL 39/40] gdbstub: Add support for MTE in user mode, Alex Bennée, 2024/07/05
- [PULL 18/40] tests/tcg/arm: Use vmrs/vmsr instead of mcr/mrc,
Alex Bennée <=
- [PULL 19/40] linux-user/main: Suppress out-of-range comparison warning for clang, Alex Bennée, 2024/07/05
- [PULL 28/40] plugins: Free CPUPluginState before destroying vCPU state, Alex Bennée, 2024/07/05
- [PULL 38/40] gdbstub: Use true to set cmd_startswith, Alex Bennée, 2024/07/05
- [PULL 33/40] target/arm: Fix exception case in allocation_tag_mem_probe, Alex Bennée, 2024/07/05
- [PULL 30/40] gdbstub: Clean up process_string_cmd, Alex Bennée, 2024/07/05
- [PULL 26/40] plugins/lockstep: clean-up output, Alex Bennée, 2024/07/05
- [PULL 22/40] test/plugins: preserve the instruction record over translations, Alex Bennée, 2024/07/05
- [PULL 20/40] gitlab: don't bother with KVM for TCI builds, Alex Bennée, 2024/07/05
- [PULL 31/40] gdbstub: Move GdbCmdParseEntry into a new header file, Alex Bennée, 2024/07/05
- Re: [PULL 00/40] maintainer updates for testing, plugins and gdbstub, Richard Henderson, 2024/07/05