[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 08/12] target/sparc/translate: silence the compiler warnings
From: |
Thomas Huth |
Subject: |
[PULL 08/12] target/sparc/translate: silence the compiler warnings |
Date: |
Wed, 16 Dec 2020 18:29:45 +0100 |
From: Chen Qun <kuhn.chenqun@huawei.com>
When using -Wimplicit-fallthrough in our CFLAGS, the compiler showed warning:
target/sparc/translate.c: In function ‘gen_st_asi’:
target/sparc/translate.c:2320:12: warning: this statement may fall through
[-Wimplicit-fallthrough=]
2320 | if (!(dc->def->features & CPU_FEATURE_HYPV)) {
| ^
target/sparc/translate.c:2329:5: note: here
2329 | case GET_ASI_DIRECT:
| ^~~~
The "fall through" statement place is not correctly identified by the compiler.
Reported-by: Euler Robot <euler.robot@huawei.com>
Signed-off-by: Chen Qun <kuhn.chenqun@huawei.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Artyom Tarasenko <atar4qemu@gmail.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20201211152426.350966-9-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
---
target/sparc/translate.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/target/sparc/translate.c b/target/sparc/translate.c
index 30c73f8d2e..4bfa3179f8 100644
--- a/target/sparc/translate.c
+++ b/target/sparc/translate.c
@@ -2324,8 +2324,8 @@ static void gen_st_asi(DisasContext *dc, TCGv src, TCGv
addr,
}
/* in OpenSPARC T1+ CPUs TWINX ASIs in store instructions
* are ST_BLKINIT_ ASIs */
- /* fall through */
#endif
+ /* fall through */
case GET_ASI_DIRECT:
gen_address_mask(dc, addr);
tcg_gen_qemu_st_tl(src, addr, da.mem_idx, da.memop);
--
2.27.0
- [PULL 02/12] target/unicore32/translate: Add missing fallthrough annotations, (continued)
- [PULL 02/12] target/unicore32/translate: Add missing fallthrough annotations, Thomas Huth, 2020/12/16
- [PULL 03/12] hw/rtc/twl92230: Silence warnings about missing fallthrough statements, Thomas Huth, 2020/12/16
- [PULL 04/12] hw/timer/renesas_tmr: silence the compiler warnings, Thomas Huth, 2020/12/16
- [PULL 05/12] target/i386: silence the compiler warnings in gen_shiftd_rm_T1, Thomas Huth, 2020/12/16
- [PULL 06/12] hw/intc/arm_gicv3_kvm: silence the compiler warnings, Thomas Huth, 2020/12/16
- [PULL 09/12] target/sparc/win_helper: silence the compiler warnings, Thomas Huth, 2020/12/16
- [PULL 07/12] accel/tcg/user-exec: silence the compiler warnings, Thomas Huth, 2020/12/16
- [PULL 11/12] tests/fp: Do not emit implicit-fallthrough warnings in the softfloat tests, Thomas Huth, 2020/12/16
- [PULL 12/12] configure: Compile with -Wimplicit-fallthrough=2, Thomas Huth, 2020/12/16
- [PULL 10/12] tcg/optimize: Add fallthrough annotations, Thomas Huth, 2020/12/16
- [PULL 08/12] target/sparc/translate: silence the compiler warnings,
Thomas Huth <=
- Re: [PULL 00/12] Compile QEMU with -Wimplicit-fallthrough, no-reply, 2020/12/16
- Re: [PULL 00/12] Compile QEMU with -Wimplicit-fallthrough, Peter Maydell, 2020/12/17
- Re: [PULL 00/12] Compile QEMU with -Wimplicit-fallthrough, Thomas Huth, 2020/12/17
- Status/future of QEMU bsd-user impl ? (Wea Re: [PULL 00/12] Compile QEMU with -Wimplicit-fallthrough), Daniel P . Berrangé, 2020/12/17
- Re: Status/future of QEMU bsd-user impl ? (Wea Re: [PULL 00/12] Compile QEMU with -Wimplicit-fallthrough), Warner Losh, 2020/12/17
- Re: Status/future of QEMU bsd-user impl ? (Wea Re: [PULL 00/12] Compile QEMU with -Wimplicit-fallthrough), Peter Maydell, 2020/12/17
- Re: Status/future of QEMU bsd-user impl ? (Wea Re: [PULL 00/12] Compile QEMU with -Wimplicit-fallthrough), Warner Losh, 2020/12/17
- Re: Status/future of QEMU bsd-user impl ? (Wea Re: [PULL 00/12] Compile QEMU with -Wimplicit-fallthrough), Warner Losh, 2020/12/17