Message ID | 68848170-59cb-6546-6e7f-527f65a8c1fe@suse.com |
---|---|
State | Accepted |
Headers |
Return-Path: <binutils-bounces+ouuuleilei=gmail.com@sourceware.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp790176wrd; Fri, 10 Mar 2023 02:25:58 -0800 (PST) X-Google-Smtp-Source: AK7set/M38XPIqwm2bcJTB+ZJJwzHw0ok5pHPjTyez5H3OeWVziFLTiF7FgOxe0x9oyZP44/+kti X-Received: by 2002:a17:906:ee82:b0:8b1:7891:19e8 with SMTP id wt2-20020a170906ee8200b008b1789119e8mr31886666ejb.44.1678443958804; Fri, 10 Mar 2023 02:25:58 -0800 (PST) Received: from sourceware.org (server2.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id gj16-20020a170906e11000b008b17e235ac3si1503199ejb.924.2023.03.10.02.25.58 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 10 Mar 2023 02:25:58 -0800 (PST) Received-SPF: pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; dkim=pass header.i=@sourceware.org header.s=default header.b=fYU7Kzi6; arc=fail (signature failed); spf=pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="binutils-bounces+ouuuleilei=gmail.com@sourceware.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 3F0FD385021B for <ouuuleilei@gmail.com>; Fri, 10 Mar 2023 10:25:05 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 3F0FD385021B DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1678443905; bh=X8fdXjgVuX9HiovB3R7V1kaNDAQdF/e+ex5AhLjDSCk=; h=Date:Subject:To:Cc:References:In-Reply-To:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=fYU7Kzi6GKqeboPMWF6CdlwB4L6Td7oFqKIlFqeLGUupeDeYCebrqW2yqq0D2+cnZ VX0FH+QhfEEECFqNBtm8tZ6hkCw3twJL19S6BHGliCZttftJx28v6LmAXXqNfCuVj6 +yMMFd8oqBfx1lPNM/f1iRzVvCNsm6/t1gtNQopE= X-Original-To: binutils@sourceware.org Delivered-To: binutils@sourceware.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04on2046.outbound.protection.outlook.com [40.107.6.46]) by sourceware.org (Postfix) with ESMTPS id E5077384D192 for <binutils@sourceware.org>; Fri, 10 Mar 2023 10:24:56 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org E5077384D192 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ifYYW+hELTD+nW39LuEgFLPEv/4sFijqua+6LmtgYaUgypnniUOOiJEc/Ywg0BFzPCJlbpNfNr8DcnLxyVm5K6JJylA8IyZwicNxQkQgmI1Bp5X9+9M2rooKIVyV7QY8Mlxui1DXbJStjpMBBIvrvtCkun2wkQ3BVCFagMtnUSj84TEPc5B7zs2O6QR8Y83sygKw1kkATVKDMFTyb/WkDVl87A0ptuDZQk+iUQ2reD4E0BF6lV/HV/bNsqRaPTzXrHcEB8YK046pik3NOkDkx3p5goDWgLBLfWIHKCoQVmFGVcW5It0u7TS+C/2nKl/y8S6t3DdTVworqkfiaDf5uw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; 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=X8fdXjgVuX9HiovB3R7V1kaNDAQdF/e+ex5AhLjDSCk=; b=QwHF9DrEudE3pMxsITyRwBejgh6OO3b0mBgUhIdsw+JpjCTXLz6kVo/Y1t4JeqCewlMleQRcZzZEp0mGkLFOayS2gUrW+KYKOPhvtWr1EHFdhTT1RUdXJDZZkJ4/jYfVldfRmPruSxWcMm16zM0Lrc9vc/QnC10R3wcVN4DPCvlO1oMzNdH/Kcj5AEmm8p0HwGu3TI7o1iuGr8fF6HIlOBxKE3aV2kPui2rLabCMUXjbtJwpX2meaO8/V7o7DJlJIP0Os18Eqfr4mtNw4Hdp++mhYQqePy/IJ3POSj1UGisqZumft/V0Tdx6fbTJvSJ4wEssk/7QkjumIVxnKovPow== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none Received: from VE1PR04MB6560.eurprd04.prod.outlook.com (2603:10a6:803:122::25) by AM0PR04MB7138.eurprd04.prod.outlook.com (2603:10a6:208:19e::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.19; Fri, 10 Mar 2023 10:24:55 +0000 Received: from VE1PR04MB6560.eurprd04.prod.outlook.com ([fe80::154e:166d:ec25:531b]) by VE1PR04MB6560.eurprd04.prod.outlook.com ([fe80::154e:166d:ec25:531b%5]) with mapi id 15.20.6178.019; Fri, 10 Mar 2023 10:24:55 +0000 Message-ID: <68848170-59cb-6546-6e7f-527f65a8c1fe@suse.com> Date: Fri, 10 Mar 2023 11:24:53 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.8.0 Subject: [PATCH v2 10/14] x86: allow for multiple immediates in output_disp() Content-Language: en-US To: Binutils <binutils@sourceware.org> Cc: "H.J. Lu" <hjl.tools@gmail.com>, "Jiang, Haochen" <haochen.jiang@intel.com> References: <b3625235-faf6-00ad-69c2-82583531fe43@suse.com> In-Reply-To: <b3625235-faf6-00ad-69c2-82583531fe43@suse.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-ClientProxiedBy: FR2P281CA0141.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10:9e::20) To VE1PR04MB6560.eurprd04.prod.outlook.com (2603:10a6:803:122::25) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: VE1PR04MB6560:EE_|AM0PR04MB7138:EE_ X-MS-Office365-Filtering-Correlation-Id: f3597e09-c2f6-4ac3-b0c1-08db2151b13c X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: FyboIN7cQZIYY3czwALxgJGijl/UHN6kfwwsL7ZMbdX7p8RyRu3plJSzrQLbZQN+xUAda5W57JTUzVEB/u2ccsdc3B5ROjrqGTcnGcC66SRSTjOP0rGvGw9dln6dBNEC4M5y9RQGqnRZNxIHBk+5v2cGhtLHZXkqUiAWZ509YBn5Y+1pV8ocYRQB2LxTR7cIf53BS3VzADgRO6x1gnYTuPuI2m6VgIcpUYrI5bvhbTrC83DrYz6e1J6lcE6bHsq2acNw6yo0/luNCkVFAJM8brRgbAZlF0VVxSDkamLHAcp7NAWhljT1f1D3PsmWtqEDv+LpcqoYg1vwwyEGtm50VT1giml7dmMq4RCa73QVOMSVPyDJJ4yvDDqmSpzDLeg8rOOSlNNrD4SHoDPHlAU5e4FjA0JqtRA/VANg/CruSbcQNLUaeN+cmMlD6zpG45/9xhRQhdsKydnz9Hp3rIJGyUNM6WYaE3o63Qn2YI85MEPg58G8/L6nMAPZa2Qg9qVUnEYneN3Sun+XMc+e3lyycQ6qhO7d46m/mSWgRgGyFOZ+K1aPv5ZmK6IVfPbL+otNk+hMG4SA/jOd1O3TTTU8jLUkYHwAgvpjIc78utrZjAAVIlQy6u1vTpttM0cMTbjchXQnXSAaIRAJFsKPAtpmW5gKATvMHlRtjz3XoSDoy2YxNGwsE5dkoySwMO+deSpiGKz7nMga1Pd4bRXjtnnizvlLRoPscg5INoKgyseuWfOV0BUYPUBM2jHqJ77gw9Vn X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:VE1PR04MB6560.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230025)(396003)(346002)(39860400002)(376002)(136003)(366004)(451199018)(31686004)(83380400001)(36756003)(6512007)(54906003)(478600001)(316002)(38100700002)(8936002)(6486002)(2616005)(41300700001)(6506007)(26005)(186003)(5660300002)(4744005)(8676002)(66476007)(66946007)(66556008)(2906002)(6916009)(4326008)(31696002)(86362001)(14773001)(43740500002)(45980500001); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?9BGEL7ZjzlZiGgitcnLmiTKKkClt?= =?utf-8?q?2Cbf6rsLKKEKujMPVtk5GMSdy1BkibSt0Ed0s7aiwnaHxAVtyuJF76uu72Xe5ZkN1?= =?utf-8?q?6vn0ULR8AEhdl5dzNn07RlHcNKQnqId8e5n+dzm4sRiczQh17t5bJX3ar8b3nfpGK?= =?utf-8?q?GXEmsUDYN/Lb3u5Ljo7Q1eaCJasXTuuRWow//ige3T2WePxgGNKbAvArrAailbmi6?= =?utf-8?q?vvB4aAamiuMDOvPlep4KKdb63aG3kJ2xYrAk6sFrhWG+i0Yc4MfefPm5Znkyx+7Ef?= =?utf-8?q?rNBW8+H4gkTFVCkjqQK4suhipt7geWthdc86CbDFYsjK+0zbBnI0Fdy/za4gqcUx4?= =?utf-8?q?nJhjWigCpZgc98EM4G0ptwIFYAXky8hYPtXKwug6NIK9Bmf3SEJ+/OLy7Fd5+WG3p?= =?utf-8?q?hEFL4MrwS1JWmSCfPO6lo/wGNgoN23akZEGyCCJkXTh34QwhdZVnsr+GbGCR+t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q?qQCH1GPvfRH6dJt6EcMZWHXkjwdlr+KNkhMnXAMa2nFwcDyWXisQzy7ykzlsaFqXh?= =?utf-8?q?Lpkn5Q1v7KNmLgUzmzf0MCPWyo4dQaNeuzDfAmJrbwuC7VbJ3P10ribLCgF4LO/BR?= =?utf-8?q?6rrJmUYdFQIY1IT9JPlTDLOlcCv2Z50Q7mX2vVei3o9Oq3Oj6GdYK2CYx13trB5sw?= =?utf-8?q?WtGHVMyYrmB5?= X-OriginatorOrg: suse.com X-MS-Exchange-CrossTenant-Network-Message-Id: f3597e09-c2f6-4ac3-b0c1-08db2151b13c X-MS-Exchange-CrossTenant-AuthSource: VE1PR04MB6560.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Mar 2023 10:24:55.3919 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f7a17af6-1c5c-4a36-aa8b-f5be247aa4ba X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: o2nKXxZCOtlK7QWOWSsSYUg+b+arNTp+1OsZKgb2wgPM95S7wnVRWq4AZcs6UsM5k/XfBU9H+qrf+xL89S8riQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR04MB7138 X-Spam-Status: No, score=-3028.2 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: binutils@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Binutils mailing list <binutils.sourceware.org> List-Unsubscribe: <https://sourceware.org/mailman/options/binutils>, <mailto:binutils-request@sourceware.org?subject=unsubscribe> List-Archive: <https://sourceware.org/pipermail/binutils/> List-Post: <mailto:binutils@sourceware.org> List-Help: <mailto:binutils-request@sourceware.org?subject=help> List-Subscribe: <https://sourceware.org/mailman/listinfo/binutils>, <mailto:binutils-request@sourceware.org?subject=subscribe> From: Jan Beulich via Binutils <binutils@sourceware.org> Reply-To: Jan Beulich <jbeulich@suse.com> Errors-To: binutils-bounces+ouuuleilei=gmail.com@sourceware.org Sender: "Binutils" <binutils-bounces+ouuuleilei=gmail.com@sourceware.org> X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1759976052942665192?= X-GMAIL-MSGID: =?utf-8?q?1759976052942665192?= |
Series |
x86: new .insn directive
|
|
Checks
Context | Check | Description |
---|---|---|
snail/binutils-gdb-check | success | Github commit url |
Commit Message
Jan Beulich
March 10, 2023, 10:24 a.m. UTC
.insn isn't going to have a constraint of only a single immediate when, in particular, RIP-relative addressing is used. --- Of course this could be folded into the relevant subsequent patch, but I'm wondering in particular whether limiting the new behavior to .insn is actually necessary (if not, this wouldn't be a good fit to merge into that later patch).
--- a/gas/config/tc-i386.c +++ b/gas/config/tc-i386.c @@ -10065,13 +10065,13 @@ output_disp (fragS *insn_start_frag, off if (operand_type_check (i.types[n1], imm)) { /* Only one immediate is allowed for PC - relative address. */ - gas_assert (sz == 0); - sz = imm_size (n1); - i.op[n].disps->X_add_number -= sz; + relative address, except with .insn. */ + gas_assert (sz == 0 || dot_insn ()); + sz += imm_size (n1); } - /* We should find the immediate. */ + /* We should find at least one immediate. */ gas_assert (sz != 0); + i.op[n].disps->X_add_number -= sz; } p = frag_more (size);