From nobody Mon Nov 23 22:28:41 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; arc=pass (i=1 dmarc=pass fromdomain=amd.com); dmarc=pass(p=quarantine dis=none) header.from=amd.com ARC-Seal: i=2; a=rsa-sha256; t=1794318584; cv=pass; d=zohomail.com; s=zohoarc; b=j8d3Vo4NNZX0LrS9GXIPMk1xGsKo4KuTYtAkqsUeLWwe5VJhf2lVYenLSm7zkhaih75bgF7rxVF9Zrh87RMRW1Mx6tM2Uitw/gyRcmGjg3ru90A9OxAQS6MBWzOo4Xt6qXFZBRhJd2enLBr0IKQ6sBu3/6bCGhxXgRSdjgdH/hE= ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1794318584; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=dE2zp+rFWGkRR9tJlzJkOjTI0CowSUW9LQLrai0vfs8=; b=S2cfrkV+aEtOHQF/GIzfWZQlzYrHcLJZ+4emf7cWJf6bbuHyqnRwf4mV4crKeMlmJmKW0AtMysQ6E+5Bt1cxDHVUBjVw9L71fKAayahmkQIAa97xtOTD4z5lTrrnUzbszfWIOkJMobobNTuRoDluwIhuAJDaaDy3FZmYi+F/ANw= ARC-Authentication-Results: i=2; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; arc=pass (i=1 dmarc=pass fromdomain=amd.com); dmarc=pass header.from= (p=quarantine dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1794318583840643.4723179331112; Tue, 10 Nov 2026 05:49:43 -0800 (PST) Received: from list by lists.xenproject.org with outflank-mailman.1481831.1685732 (Exim 4.92) (envelope-from ) id 1xQmE3-0000tf-Ed; Tue, 10 Nov 2026 13:49:27 +0000 Received: by outflank-mailman (output) from mailman id 1481831.1685732; Tue, 10 Nov 2026 13:49:27 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1xQmE3-0000tQ-B3; Tue, 10 Nov 2026 13:49:27 +0000 Received: by outflank-mailman (input) for mailman id 1481831; Tue, 10 Nov 2026 13:49:25 +0000 Received: from mx.expurgate.net ([194.145.224.20]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1xQmE1-0000rx-FV for xen-devel@lists.xenproject.org; Tue, 10 Nov 2026 13:49:25 +0000 Received: from mx.expurgate.net (helo=localhost) by mx.expurgate.net with esmtp id 1xQmE0-00Asfv-HD for xen-devel@lists.xenproject.org; Tue, 10 Nov 2026 14:49:24 +0100 Received: from [10.42.69.3] (helo=localhost) by localhost with ESMTP (eXpurgate MTA 0.9.1) (envelope-from ) id 6af320d9-e002-0a2a0a5209dd-0a2a4503cb58-36 for ; Tue, 10 Nov 2026 14:49:24 +0100 Received: from [40.107.201.16] (helo=CH4PR04CU002.outbound.protection.outlook.com) by tlsNG-33051d.mxtls.expurgate.net with ESMTPS (eXpurgate 4.57.1) (envelope-from ) id 6af320e2-fae8-0a2a45030019-286bc910d113-3 for ; Tue, 10 Nov 2026 14:49:23 +0100 Received: from SJ0PR05CA0206.namprd05.prod.outlook.com (2603:10b6:a03:330::31) by SN7PR12MB7810.namprd12.prod.outlook.com (2603:10b6:806:34c::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.615.8; Tue, 10 Nov 2026 13:49:18 +0000 Received: from SJ1PEPF00002314.namprd03.prod.outlook.com (2603:10b6:a03:330:cafe::53) by SJ0PR05CA0206.outlook.office365.com (2603:10b6:a03:330::31) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.615.8 via Frontend Transport; Tue, 10 Nov 2026 13:49:18 +0000 Received: from satlexmb07.amd.com (165.204.84.17) by SJ1PEPF00002314.mail.protection.outlook.com (10.167.242.168) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.615.4 via Frontend Transport; Tue, 10 Nov 2026 13:49:17 +0000 Received: from jim-System-Product-Name.amd.com (10.180.168.240) by satlexmb07.amd.com (10.181.42.216) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.53; Tue, 10 Nov 2026 07:49:15 -0600 X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" Authentication-Results: eu.smtp.expurgate.cloud; dkim=pass header.s=selector1 header.d=amd.com header.i="@amd.com" header.h="From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=aND7mpj7gDgIlje9hFQACScsqjQVME9OLze3rTlf5ZTBxYwF2u1kDrz7Pd/RqapdeMyP5BK4XWEuqw01dEtJ+/dp+C7cceWB2OiwOap4aYPZ2co/QHASYK40iGrv1p+lXJ2PhebmZ2v74kdka7estU9zlW2H5ik4Ern4VjkN6s4SvLtZrS3Y29zKYq8F6tQHjBetUvoHOPUxuhIZfyOX2ROC9DSJ0YGA45Wiv/U0+FXOK3Q3KsWPH7Yf9fDwKVP3T2l4lqjalEqXAZTSk26NGkfJsDEuCN8Y6AO3H+d7lyVdZebcNiruAhUatV/lUdEiP7uMMM3psrjwIqSS0uKtVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=dE2zp+rFWGkRR9tJlzJkOjTI0CowSUW9LQLrai0vfs8=; b=D+zMvwabVpONebjdKm7Nm86/9c/EC2+IbrPkqBoUT3I2vtOSUVSdz98IQPR+OAWeipFLsAxeFsB+JDaLsBRqnFHDN5sahG8LgDDZyool7rGstS2lFi25I8273y/aYEqmPPmBkFQLUH/VaiD7x50XLkRWhATteRA81hJS0EepZsrlw35mXnp9kDTf9xOv6e1KrxwS6h21gPt5F7rfdCcanPZp9VrUjIvyS9L2JxGC66TgYAenUUMyBQI+PFosU3r/i7bFQXlebjV3yf0cKCijeHv/xupwdbSeqCIL5mJ035clPpckiKRY8QLxHNCnibw4KbGdH0tbNuRp57jMDLUpCA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=dE2zp+rFWGkRR9tJlzJkOjTI0CowSUW9LQLrai0vfs8=; b=5UOj8L/2Fbp3Ru4xZjPgPwlL6AUg3bRavnl43LYWywhLkbK7HZS5vSX2XWGzdTTYDW42xYA50kdZpJfXobeFDrrPvaUQjiX7YFBc9e8Y5fACG8IlEBbgGIrvcE5iy29P4yYYZ9cuBpUfoRBDSv7Q6JFvTcP5C+ILEf+/GZpJiqA= X-MS-Exchange-Authentication-Results: mx.microsoft.com 1; spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=satlexmb07.amd.com; pr=C From: Shuaidong Chen To: CC: Jan Beulich , Andrew Cooper , =?UTF-8?q?Roger=20Pau=20Monn=C3=A9?= , Stefano Stabellini , "Nicola Vetrini" , Alejandro Vallejo , Shuaidong Chen Subject: [PATCH v3] automation/eclair: deviate R2.6 for the x86 emulator Date: Tue, 10 Nov 2026 21:49:02 +0800 Message-ID: <20261110134902.2891528-1-shuaidong.chen@amd.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: satlexmb07.amd.com (10.181.42.216) To satlexmb07.amd.com (10.181.42.216) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ1PEPF00002314:EE_|SN7PR12MB7810:EE_ X-MS-Office365-Filtering-Correlation-Id: 2ae757ae-0f49-44c0-3882-08df3f316a55 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|82310400026|36860700016|1800799024|23010399003|376014|11063799006|56012099006|18002099003|6133799003|10067099003|261009223027099003|261102123227099003|261026135527099003|261026121527099003|261026140227099003|261026130827099003|261021135927099003|261021133027099003|261021130227099003|261021123027099003|261021121427099003|261022115727099003|261022113327099003|261022105027099003|261022075727099003|261028144727099003; X-Microsoft-Antispam-Message-Info: 264Yq43Nl4pYacNHe7wvkpNbz4aV6MtY78+ah+4pf/EKiOWYoJ3m/29FLQc61/18BpKeF1KOlev/IxutIQz1qWf6S72U695GK35CE6/c3vx/MmZVyHFoMNPP5PQBMFhzqvdv8YtWEGag2kVxKy1mrlnY7aoxLhyj11E1Ql6/vrRRxVN0vz+2oS9eSsTWOFkV2c1dKlfGmHeZnR4DmmNFRDRqlUyfePkHQLMkSq9ienwqOmtXjqq1GdwpvlEn6v0RFnHW+kXJYDfMfc+rYaPktArgs3WAjb0EfupWsgtxzIRP9DnlgfsrA2UMFSU/XlJqMaeN2FgU/VwQhAOQBiZsRq6fAQDbKQ/fRylqdud+yQmIp64I4mRuhnhtYYWZq3npERBRp8qmX+9WQkk2zWubOMcom5N2QQ/uVMTUIRINZeIpFRu9A2EVScqf2r3GS4eLh/VPjDwPSdQBV3jIGvWv4qBVGvTb+fjN92MGtv3bQ9Jm5DKGP2WM3MXmGwpIAaslPWznW4jn8WqyOiSJZYMqbqqTOZ87Vm898+mhCptqqAEPUuwsLZAwj2NT5CRr9yW4dx82wg9t07Lzw7wQvjbW/PA2p6lE2jczvlAV6rcqfHORHFnqrc9GfG+mKIrOytAY5c1ZeC1W1OjUfyptUtK9wICzcYvxk/GrX4qBktueeos66iXscn6DtrAhK/pWEzefU8nBpK1nZrfdbxZ9s9F+jQ== X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:satlexmb07.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230040)(82310400026)(36860700016)(1800799024)(23010399003)(376014)(11063799006)(56012099006)(18002099003)(6133799003)(10067099003)(261009223027099003)(261102123227099003)(261026135527099003)(261026121527099003)(261026140227099003)(261026130827099003)(261021135927099003)(261021133027099003)(261021130227099003)(261021123027099003)(261021121427099003)(261022115727099003)(261022113327099003)(261022105027099003)(261022075727099003)(261028144727099003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: LcUwnrY2q1qWhT8ZtLwc0ulU/+X58POUamubQ4zwoY5MZ7BZPftRYkB+pvEPWsKrSFaib1xks+X8wAx1j29QQoqJIXmY0QGTBeCEgUBpjXrvgy3vXeO0ooeAlMSM8Yc3IGzw7hmgCejvJLLUSW+XVYbfMtnZ82CWcZ6O4DkMA312XB9ph2Uu1cS3789MQLWfab+GUcjYZSh34NvHI2MaaQCYU1eMvNtP7wgHcv9NOQ+TzLKBQk1axkN7E4bcOqo2Yh/GVn+T7jpgknmxcivbHsGpGswG9T/xCXp94mdJvy/18WAx113uPz/3zOIGkgdmAk/FnLbh9o3n7ti54V4p8yBUAMVRQoog9//jOZL6YVnKiW9M/MRCbyigD1sUAX/BSQcno/r1Gv2iJPItD5PzLzdDpyfuGGbd+ZZv/XNUoKUTBPpJrZFtWifyKcRhyPVp X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Nov 2026 13:49:17.8533 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2ae757ae-0f49-44c0-3882-08df3f316a55 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[satlexmb07.amd.com] X-MS-Exchange-CrossTenant-AuthSource: SJ1PEPF00002314.namprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN7PR12MB7810 X-purgate-ID: tlsNG-33051d/1794318564-75EFF4E9-3000DE17/0/0 X-purgate-type: clean X-purgate-size: 3067 X-ZohoMail-DKIM: pass (identity @amd.com) X-ZM-MESSAGEID: 1794318586643158500 Content-Type: text/plain; charset="utf-8" MISRA C:2012 Rule 2.6 (advisory) states that "a function should not contain unused label declarations". Depending on which parts of the x86 emulator are compiled in, some of its labels end up with no goto targeting them. For example, with CONFIG_HVM=3Dn private.h defines X86EMUL_NO_FPU, X86EMUL_NO_MMX and X86EMUL_NO_SIMD: the CASE_SIMD_* macros then expand to plain labels instead of case labels, and the gotos to several hand-written simd_* labels are preprocessed out, leaving 91 unused labels in x86_emulate.c. The build already acknowledges this by passing -Wno-unused-label for that object. Annotating these labels would only add churn to the emulator. As done for Rule 16.2, deviate the rule for the emulator as a whole. Signed-off-by: Shuaidong Chen Acked-by: Jan Beulich # docs/misra/ Acked-by: Nicola Vetrini # eclair --- v3: - Drop the CONFIG_HVM=3Dn specifics from the deviation text, as the deviation itself isn't limited to that configuration. v2: - Drop the __maybe_unused annotations (v1 patch 1) and the CASE_SIMD_* specific deviation (v1 patch 2) in favour of an emulator-wide deviation, following the existing one for Rule 16.2. - Trim the Cc list. automation/eclair_analysis/ECLAIR/deviations.ecl | 5 +++++ docs/misra/deviations.rst | 8 ++++++++ 2 files changed, 13 insertions(+) diff --git a/automation/eclair_analysis/ECLAIR/deviations.ecl b/automation/= eclair_analysis/ECLAIR/deviations.ecl index 296340bb4c..12afc758dd 100644 --- a/automation/eclair_analysis/ECLAIR/deviations.ecl +++ b/automation/eclair_analysis/ECLAIR/deviations.ecl @@ -55,6 +55,11 @@ removed by the compiler, the resulting slowdown is negli= gible." -config=3DMC3A2.R2.6,reports+=3D{deliberate, "any_area(text(^.*__maybe_unu= sed.*$))"} -doc_end =20 +-doc_begin=3D"Depending on which parts of the x86 emulator are compiled in= , some of its labels, many of them generated by the CASE_SIMD_* macros, may= end up with no goto targeting them. +Annotating them would only add churn to the emulator, therefore it is deem= ed better to leave such files as is." +-config=3DMC3A2.R2.6,reports+=3D{deliberate, "any_area(any_loc(file(^xen/a= rch/x86/x86_emulate/.*$)))"} +-doc_end + # # Series 3. # diff --git a/docs/misra/deviations.rst b/docs/misra/deviations.rst index bee4686675..7b983db264 100644 --- a/docs/misra/deviations.rst +++ b/docs/misra/deviations.rst @@ -116,6 +116,14 @@ Deviations related to MISRA C:2012 Rules: such labels poses no risks. - Tagged as `deliberate` for ECLAIR. =20 + * - R2.6 + - Depending on which parts of the x86 emulator are compiled in, some = of + its labels, many of them generated by the CASE_SIMD_* macros, may e= nd + up with no goto targeting them. Annotating them would only add churn + to the emulator, therefore it is deemed better to leave such files = as + is. + - Tagged as `deliberate` for ECLAIR. + * - R3.1 - Comments starting with '/\*' and containing URLs are safe as they a= re not instances of commented-out code. --=20 2.34.1