mbox series

[v3,0/7] silence the compiler warnings

Message ID 20201116024810.2415819-1-kuhn.chenqun@huawei.com (mailing list archive)
Headers show
Series silence the compiler warnings | expand

Message

Chen Qun Nov. 16, 2020, 2:48 a.m. UTC
Hi folks,
  This series fix some "fall through" warnings reported by GCC_9.3. They've been 
reviewed for a long time. Some of these patchs may be important for QEMU 5.2. 
Such as the Patch6 miss a break statement. Others only add "fall through" 
comments and may not have a negative impact for QEMU 5.2.


Thanks,
Chen Qun


Since v2:
- Patch3:Add Richard Henderson、Philippe Mathieu-Daudé and Thomas Huth reviewed tag.
- Patch4: Laurent pull it to master, remove it.
- Patch6->Patch5: Add Richard Henderson and Philippe Mathieu-Daudé reviewed tag.
- Patch7->Patch6: Add Thomas Huth reviewed tag and David Gibson acked tag.
- Patch8->Patch7: Tweak LOG_UNIMP message base on Thomas Huth comment; 
  Add Philippe Mathieu-Daudé and Thomas Huth reviewed tag; Add David Gibson acked tag.

Since v1:
- Patch1: Add comments to explain the two case of fall through.
  Addressed Richard Henderson and Thomas Huth review comment.
- Patch2: Addressed Peter Maydell review comment.
- Patch3: Add QEMU_NORETURN to cpu_exit_tb_from_sighandler() function to
  avoid the compiler warnings.
- Patch4: Addressed Thomas Huth review comment.
- Patch5: Addressed Artyom Tarasenko and Philippe Mathieu-Daudé review
  comment.
- Patch6: Combine the /* fall through */ to the preceding comments.
  Addressed  Artyom Tarasenko review comment.
- Patch7: Add a "break" statement here instead of /* fall through */
  comments.
- Patch8: Replace the TODO by a LOG_UNIMP call and add break statement
- Patch9: Discard this patch since a patch already exists for fix this 
  issue(https://lore.kernel.org/qemu-devel/20200711154242.41222-1-ysato@users)


Chen Qun (7):
  target/i386: silence the compiler warnings in gen_shiftd_rm_T1
  hw/intc/arm_gicv3_kvm: silence the compiler warnings
  accel/tcg/user-exec: silence the compiler warnings
  target/sparc/translate: silence the compiler warnings
  target/sparc/win_helper: silence the compiler warnings
  ppc: Add a missing break for PPC6xx_INPUT_TBEN
  target/ppc: replaced the TODO with LOG_UNIMP and add break for silence
    warnings

 accel/tcg/user-exec.c     | 3 ++-
 hw/intc/arm_gicv3_kvm.c   | 8 ++++++++
 hw/ppc/ppc.c              | 1 +
 target/i386/translate.c   | 7 +++++--
 target/ppc/mmu_helper.c   | 5 +++--
 target/sparc/translate.c  | 2 +-
 target/sparc/win_helper.c | 2 +-
 7 files changed, 21 insertions(+), 7 deletions(-)

Comments

Chen Qun Dec. 11, 2020, 2:22 a.m. UTC | #1
Kindly ping!

Hi all,
  Patch 1 to Patch 5 are not in the queue.  Could someone pick them up?

Patch1~Patch5:
  target/i386: silence the compiler warnings in gen_shiftd_rm_T1
  hw/intc/arm_gicv3_kvm: silence the compiler warnings
  accel/tcg/user-exec: silence the compiler warnings
  target/sparc/translate: silence the compiler warnings
  target/sparc/win_helper: silence the compiler warnings

Thanks,
Chen Qun

> -----Original Message-----
> From: Chenqun (kuhn)
> Sent: Monday, November 16, 2020 10:48 AM
> To: qemu-devel@nongnu.org; qemu-trivial@nongnu.org
> Cc: Zhanghailiang <zhang.zhanghailiang@huawei.com>; ganqixin
> <ganqixin@huawei.com>; Chenqun (kuhn) <kuhn.chenqun@huawei.com>
> Subject: [PATCH v3 0/7] silence the compiler warnings
> 
> Hi folks,
>   This series fix some "fall through" warnings reported by GCC_9.3. They've
> been reviewed for a long time. Some of these patchs may be important for
> QEMU 5.2.
> Such as the Patch6 miss a break statement. Others only add "fall through"
> comments and may not have a negative impact for QEMU 5.2.
> 
> 
> Thanks,
> Chen Qun
> 
> 
> Since v2:
> - Patch3:Add Richard Henderson、Philippe Mathieu-Daudé and Thomas Huth
> reviewed tag.
> - Patch4: Laurent pull it to master, remove it.
> - Patch6->Patch5: Add Richard Henderson and Philippe Mathieu-Daudé
> reviewed tag.
> - Patch7->Patch6: Add Thomas Huth reviewed tag and David Gibson acked tag.
> - Patch8->Patch7: Tweak LOG_UNIMP message base on Thomas Huth
> comment;
>   Add Philippe Mathieu-Daudé and Thomas Huth reviewed tag; Add David
> Gibson acked tag.
> 
> Since v1:
> - Patch1: Add comments to explain the two case of fall through.
>   Addressed Richard Henderson and Thomas Huth review comment.
> - Patch2: Addressed Peter Maydell review comment.
> - Patch3: Add QEMU_NORETURN to cpu_exit_tb_from_sighandler() function to
>   avoid the compiler warnings.
> - Patch4: Addressed Thomas Huth review comment.
> - Patch5: Addressed Artyom Tarasenko and Philippe Mathieu-Daudé review
>   comment.
> - Patch6: Combine the /* fall through */ to the preceding comments.
>   Addressed  Artyom Tarasenko review comment.
> - Patch7: Add a "break" statement here instead of /* fall through */
>   comments.
> - Patch8: Replace the TODO by a LOG_UNIMP call and add break statement
> - Patch9: Discard this patch since a patch already exists for fix this
> 
> issue(https://lore.kernel.org/qemu-devel/20200711154242.41222-1-ysato@us
> ers)
> 
> 
> Chen Qun (7):
>   target/i386: silence the compiler warnings in gen_shiftd_rm_T1
>   hw/intc/arm_gicv3_kvm: silence the compiler warnings
>   accel/tcg/user-exec: silence the compiler warnings
>   target/sparc/translate: silence the compiler warnings
>   target/sparc/win_helper: silence the compiler warnings
>   ppc: Add a missing break for PPC6xx_INPUT_TBEN
>   target/ppc: replaced the TODO with LOG_UNIMP and add break for silence
>     warnings
> 
>  accel/tcg/user-exec.c     | 3 ++-
>  hw/intc/arm_gicv3_kvm.c   | 8 ++++++++
>  hw/ppc/ppc.c              | 1 +
>  target/i386/translate.c   | 7 +++++--
>  target/ppc/mmu_helper.c   | 5 +++--
>  target/sparc/translate.c  | 2 +-
>  target/sparc/win_helper.c | 2 +-
>  7 files changed, 21 insertions(+), 7 deletions(-)
> 
> --
> 2.27.0
Thomas Huth Dec. 11, 2020, 8:30 a.m. UTC | #2
On 11/12/2020 03.22, Chenqun (kuhn) wrote:
> Kindly ping!
> 
> Hi all,
>   Patch 1 to Patch 5 are not in the queue.  Could someone pick them up?

 Hi,

yes, I'm currently preparing another patch series that includes your
patches, which will finally turn on -Wimplicit-fallthrough for everybody.
I'll send it out once David's ppc pull request has been merged, so that I
don't have to include the ppc patches again.

 Thomas