From nobody Mon Feb 9 02:12:21 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1608158145; cv=none; d=zohomail.com; s=zohoarc; b=W3QzD+qlEZul4ZzROCNekawT/XVLq45iYE2rhRJv25i4bICRZxLrgYkSHn+3O2vhiwJ+E7HqiKtwtRy0yNQcsFjOijExibkdkZSvmOQzoAUjYpCG4pp80g5HHPKCxRci8YxpHpkbMLp/XkU6MJ2uu1v5WvvzMP3gbB2wZswqW58= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1608158145; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=xk5OvThqMihubCF0P3A0z7+E9P5KeyCisuh+GKV4O6w=; b=CuNEBdx3Ir1rpYmIEZpy97jhgF8DjCwIAXAl10IlamOL4abk4d9mK3/DZjSm4HVsInwRT8tm+MGZOusye/xvqaAFoVQI5R+bucEOgYB4oVlsHekUMW/t0H7yKw9sMc47vDCtBvWaCwcjDDmra8LaC82ZaCEPqJLyGPTuhzGwm5I= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1608158145383213.45403449910657; Wed, 16 Dec 2020 14:35:45 -0800 (PST) Received: from localhost ([::1]:33284 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kpag2-0002Gf-TW for importer@patchew.org; Wed, 16 Dec 2020 12:33:26 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:48778) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kpacn-0008Mg-2H for qemu-devel@nongnu.org; Wed, 16 Dec 2020 12:30:05 -0500 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:21302) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1kpacj-000127-U7 for qemu-devel@nongnu.org; Wed, 16 Dec 2020 12:30:04 -0500 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-525-Fj8MuVT7NpyhBFIiu2yFEg-1; Wed, 16 Dec 2020 12:29:58 -0500 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id E910D801817; Wed, 16 Dec 2020 17:29:56 +0000 (UTC) Received: from thuth.com (ovpn-113-7.ams2.redhat.com [10.36.113.7]) by smtp.corp.redhat.com (Postfix) with ESMTP id 0C9E310016F4; Wed, 16 Dec 2020 17:29:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1608139801; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=xk5OvThqMihubCF0P3A0z7+E9P5KeyCisuh+GKV4O6w=; b=dkPUlMfGO/2c37BApQLBVA1I9sO1FuzNiPb8/texpk40MrtrHcIhkAXX1G2JR3f/jsoYZ8 pjuPO3+pH1KJ1AjVYWo4dB5BzIiiaR8FSU3bamQLoQdjfgJs5gqKBkTZZgs8G32Sx3+NM0 OH6R1jGvgHZ6nF7VuoX0JQWsCv8skCY= X-MC-Unique: Fj8MuVT7NpyhBFIiu2yFEg-1 From: Thomas Huth To: Peter Maydell , qemu-devel@nongnu.org Subject: [PULL 01/12] disas/libvixl: Fix fall-through annotation for GCC >= 7 Date: Wed, 16 Dec 2020 18:29:38 +0100 Message-Id: <20201216172949.57380-2-thuth@redhat.com> In-Reply-To: <20201216172949.57380-1-thuth@redhat.com> References: <20201216172949.57380-1-thuth@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=thuth@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=216.205.24.124; envelope-from=thuth@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Chen Qun , =?UTF-8?q?Alex=20Benn=C3=A9e?= Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" For compiling with -Wimplicit-fallthrough we need to fix the fallthrough annotations in the libvixl code. This is based on the following upstream vixl commit by Martyn Capewell: https://git.linaro.org/arm/vixl.git/commit/?id=3Dde326f850f736c3a337 "GCC 7 enables switch/case fallthrough checking, but this fails in VIXL, because the annotation we use is Clang specific. Also, fix a missing annotation in the disassembler." Signed-off-by: Thomas Huth Reviewed-by: Peter Maydell Message-Id: <20201211152426.350966-2-thuth@redhat.com> Signed-off-by: Thomas Huth --- disas/libvixl/vixl/a64/disasm-a64.cc | 4 ++++ disas/libvixl/vixl/globals.h | 6 ++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/disas/libvixl/vixl/a64/disasm-a64.cc b/disas/libvixl/vixl/a64/= disasm-a64.cc index 7a58a5c087..f34d1d68da 100644 --- a/disas/libvixl/vixl/a64/disasm-a64.cc +++ b/disas/libvixl/vixl/a64/disasm-a64.cc @@ -2985,6 +2985,10 @@ int Disassembler::SubstituteImmediateField(const Ins= truction* instr, } return 3; } + default: { + VIXL_UNIMPLEMENTED(); + return 0; + } } } case 'C': { // ICondB - Immediate Conditional Branch. diff --git a/disas/libvixl/vixl/globals.h b/disas/libvixl/vixl/globals.h index 61dc9f7f7e..7099aa599f 100644 --- a/disas/libvixl/vixl/globals.h +++ b/disas/libvixl/vixl/globals.h @@ -108,10 +108,12 @@ inline void USE(T1, T2, T3, T4) {} #define __has_warning(x) 0 #endif =20 -// Note: This option is only available for Clang. And will only be enabled= for -// C++11(201103L). +// Fallthrough annotation for Clang and C++11(201103L). #if __has_warning("-Wimplicit-fallthrough") && __cplusplus >=3D 201103L #define VIXL_FALLTHROUGH() [[clang::fallthrough]] //NOLINT +// Fallthrough annotation for GCC >=3D 7. +#elif __GNUC__ >=3D 7 + #define VIXL_FALLTHROUGH() __attribute__((fallthrough)) #else #define VIXL_FALLTHROUGH() do {} while (0) #endif --=20 2.27.0